mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-18 11:36:36 +00:00
run yarn prepack
This commit is contained in:
parent
6a67f4145a
commit
ee10776a7e
6 changed files with 137 additions and 27 deletions
|
@ -1,6 +1,6 @@
|
|||
# Component Index
|
||||
|
||||
> 167 components exported from carbon-components-svelte@0.33.0.
|
||||
> 168 components exported from carbon-components-svelte@0.33.0.
|
||||
|
||||
## Components
|
||||
|
||||
|
@ -27,6 +27,7 @@
|
|||
- [`ContextMenu`](#contextmenu)
|
||||
- [`ContextMenuDivider`](#contextmenudivider)
|
||||
- [`ContextMenuGroup`](#contextmenugroup)
|
||||
- [`ContextMenuInner`](#contextmenuinner)
|
||||
- [`ContextMenuOption`](#contextmenuoption)
|
||||
- [`ContextMenuRadioGroup`](#contextmenuradiogroup)
|
||||
- [`Copy`](#copy)
|
||||
|
@ -737,7 +738,7 @@ None.
|
|||
|
||||
| Prop name | Kind | Reactive | Type | Default value | Description |
|
||||
| :-------- | :--------------- | :------- | :---------------------------------------- | ------------------ | -------------------------------------------------------------------------------- |
|
||||
| ref | <code>let</code> | Yes | <code>null | HTMLUListElement</code> | <code>null</code> | Obtain a reference to the unordered list HTML element |
|
||||
| ref | <code>let</code> | Yes | <code>HTMLUListElement | null</code> | <code>null</code> | Obtain a reference to the unordered list HTML element |
|
||||
| y | <code>let</code> | Yes | <code>number</code> | <code>0</code> | Specify the vertical offset of the menu position |
|
||||
| x | <code>let</code> | Yes | <code>number</code> | <code>0</code> | Specify the horizontal offset of the menu position |
|
||||
| open | <code>let</code> | Yes | <code>boolean</code> | <code>false</code> | Set to `true` to open the menu<br />Either `x` and `y` must be greater than zero |
|
||||
|
@ -750,12 +751,7 @@ None.
|
|||
|
||||
### Events
|
||||
|
||||
| Event name | Type | Detail |
|
||||
| :--------- | :--------- | :----- |
|
||||
| click | forwarded | -- |
|
||||
| keydown | forwarded | -- |
|
||||
| open | dispatched | -- |
|
||||
| close | dispatched | -- |
|
||||
None.
|
||||
|
||||
## `ContextMenuDivider`
|
||||
|
||||
|
@ -790,6 +786,32 @@ None.
|
|||
|
||||
None.
|
||||
|
||||
## `ContextMenuInner`
|
||||
|
||||
### Props
|
||||
|
||||
| Prop name | Kind | Reactive | Type | Default value | Description |
|
||||
| :-------- | :--------------- | :------- | :---------------------------------------- | ------------------ | -------------------------------------------------------------------------------- |
|
||||
| ref | <code>let</code> | Yes | <code>null | HTMLUListElement</code> | <code>null</code> | Obtain a reference to the unordered list HTML element |
|
||||
| y | <code>let</code> | Yes | <code>number</code> | <code>0</code> | Specify the vertical offset of the menu position |
|
||||
| x | <code>let</code> | Yes | <code>number</code> | <code>0</code> | Specify the horizontal offset of the menu position |
|
||||
| open | <code>let</code> | Yes | <code>boolean</code> | <code>false</code> | Set to `true` to open the menu<br />Either `x` and `y` must be greater than zero |
|
||||
|
||||
### Slots
|
||||
|
||||
| Slot name | Default | Props | Fallback |
|
||||
| :-------- | :------ | :---- | :------- |
|
||||
| -- | Yes | -- | -- |
|
||||
|
||||
### Events
|
||||
|
||||
| Event name | Type | Detail |
|
||||
| :--------- | :--------- | :----- |
|
||||
| click | forwarded | -- |
|
||||
| keydown | forwarded | -- |
|
||||
| open | dispatched | -- |
|
||||
| close | dispatched | -- |
|
||||
|
||||
## `ContextMenuOption`
|
||||
|
||||
### Props
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"total": 167,
|
||||
"total": 168,
|
||||
"components": [
|
||||
{
|
||||
"moduleName": "Accordion",
|
||||
|
@ -1609,7 +1609,7 @@
|
|||
"name": "ref",
|
||||
"kind": "let",
|
||||
"description": "Obtain a reference to the unordered list HTML element",
|
||||
"type": "null | HTMLUListElement",
|
||||
"type": "HTMLUListElement | null",
|
||||
"value": "null",
|
||||
"isFunction": false,
|
||||
"constant": false,
|
||||
|
@ -1617,14 +1617,8 @@
|
|||
}
|
||||
],
|
||||
"slots": [{ "name": "__default__", "default": true, "slot_props": "{}" }],
|
||||
"events": [
|
||||
{ "type": "forwarded", "name": "click", "element": "ul" },
|
||||
{ "type": "forwarded", "name": "keydown", "element": "ul" },
|
||||
{ "type": "dispatched", "name": "open" },
|
||||
{ "type": "dispatched", "name": "close" }
|
||||
],
|
||||
"typedefs": [],
|
||||
"rest_props": { "type": "Element", "name": "ul" }
|
||||
"events": [],
|
||||
"typedefs": []
|
||||
},
|
||||
{
|
||||
"moduleName": "ContextMenuDivider",
|
||||
|
@ -1662,6 +1656,61 @@
|
|||
"events": [],
|
||||
"typedefs": []
|
||||
},
|
||||
{
|
||||
"moduleName": "ContextMenuInner",
|
||||
"filePath": "src/ContextMenu/ContextMenuInner.svelte",
|
||||
"props": [
|
||||
{
|
||||
"name": "open",
|
||||
"kind": "let",
|
||||
"description": "Set to `true` to open the menu\nEither `x` and `y` must be greater than zero",
|
||||
"type": "boolean",
|
||||
"value": "false",
|
||||
"isFunction": false,
|
||||
"constant": false,
|
||||
"reactive": true
|
||||
},
|
||||
{
|
||||
"name": "x",
|
||||
"kind": "let",
|
||||
"description": "Specify the horizontal offset of the menu position",
|
||||
"type": "number",
|
||||
"value": "0",
|
||||
"isFunction": false,
|
||||
"constant": false,
|
||||
"reactive": true
|
||||
},
|
||||
{
|
||||
"name": "y",
|
||||
"kind": "let",
|
||||
"description": "Specify the vertical offset of the menu position",
|
||||
"type": "number",
|
||||
"value": "0",
|
||||
"isFunction": false,
|
||||
"constant": false,
|
||||
"reactive": true
|
||||
},
|
||||
{
|
||||
"name": "ref",
|
||||
"kind": "let",
|
||||
"description": "Obtain a reference to the unordered list HTML element",
|
||||
"type": "null | HTMLUListElement",
|
||||
"value": "null",
|
||||
"isFunction": false,
|
||||
"constant": false,
|
||||
"reactive": true
|
||||
}
|
||||
],
|
||||
"slots": [{ "name": "__default__", "default": true, "slot_props": "{}" }],
|
||||
"events": [
|
||||
{ "type": "forwarded", "name": "click", "element": "ul" },
|
||||
{ "type": "forwarded", "name": "keydown", "element": "ul" },
|
||||
{ "type": "dispatched", "name": "open" },
|
||||
{ "type": "dispatched", "name": "close" }
|
||||
],
|
||||
"typedefs": [],
|
||||
"rest_props": { "type": "Element", "name": "ul" }
|
||||
},
|
||||
{
|
||||
"moduleName": "ContextMenuOption",
|
||||
"filePath": "src/ContextMenu/ContextMenuOption.svelte",
|
||||
|
|
|
@ -76,6 +76,9 @@
|
|||
"ContextMenuGroup": {
|
||||
"path": "carbon-components-svelte/src/ContextMenu/ContextMenuGroup.svelte"
|
||||
},
|
||||
"ContextMenuInner": {
|
||||
"path": "carbon-components-svelte/src/ContextMenu/ContextMenuInner.svelte"
|
||||
},
|
||||
"ContextMenuOption": {
|
||||
"path": "carbon-components-svelte/src/ContextMenu/ContextMenuOption.svelte"
|
||||
},
|
||||
|
|
12
types/ContextMenu/ContextMenu.d.ts
vendored
12
types/ContextMenu/ContextMenu.d.ts
vendored
|
@ -1,8 +1,7 @@
|
|||
/// <reference types="svelte" />
|
||||
import { SvelteComponentTyped } from "svelte";
|
||||
|
||||
export interface ContextMenuProps
|
||||
extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]> {
|
||||
export interface ContextMenuProps {
|
||||
/**
|
||||
* Set to `true` to open the menu
|
||||
* Either `x` and `y` must be greater than zero
|
||||
|
@ -26,16 +25,11 @@ export interface ContextMenuProps
|
|||
* Obtain a reference to the unordered list HTML element
|
||||
* @default null
|
||||
*/
|
||||
ref?: null | HTMLUListElement;
|
||||
ref?: HTMLUListElement | null;
|
||||
}
|
||||
|
||||
export default class ContextMenu extends SvelteComponentTyped<
|
||||
ContextMenuProps,
|
||||
{
|
||||
click: WindowEventMap["click"];
|
||||
keydown: WindowEventMap["keydown"];
|
||||
open: CustomEvent<any>;
|
||||
close: CustomEvent<any>;
|
||||
},
|
||||
{},
|
||||
{ default: {} }
|
||||
> {}
|
||||
|
|
41
types/ContextMenu/ContextMenuInner.d.ts
vendored
Normal file
41
types/ContextMenu/ContextMenuInner.d.ts
vendored
Normal file
|
@ -0,0 +1,41 @@
|
|||
/// <reference types="svelte" />
|
||||
import { SvelteComponentTyped } from "svelte";
|
||||
|
||||
export interface ContextMenuInnerProps
|
||||
extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]> {
|
||||
/**
|
||||
* Set to `true` to open the menu
|
||||
* Either `x` and `y` must be greater than zero
|
||||
* @default false
|
||||
*/
|
||||
open?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the horizontal offset of the menu position
|
||||
* @default 0
|
||||
*/
|
||||
x?: number;
|
||||
|
||||
/**
|
||||
* Specify the vertical offset of the menu position
|
||||
* @default 0
|
||||
*/
|
||||
y?: number;
|
||||
|
||||
/**
|
||||
* Obtain a reference to the unordered list HTML element
|
||||
* @default null
|
||||
*/
|
||||
ref?: null | HTMLUListElement;
|
||||
}
|
||||
|
||||
export default class ContextMenuInner extends SvelteComponentTyped<
|
||||
ContextMenuInnerProps,
|
||||
{
|
||||
click: WindowEventMap["click"];
|
||||
keydown: WindowEventMap["keydown"];
|
||||
open: CustomEvent<any>;
|
||||
close: CustomEvent<any>;
|
||||
},
|
||||
{ default: {} }
|
||||
> {}
|
1
types/index.d.ts
vendored
1
types/index.d.ts
vendored
|
@ -13,6 +13,7 @@ export { default as CheckboxSkeleton } from "./Checkbox/CheckboxSkeleton";
|
|||
export { default as ContentSwitcher } from "./ContentSwitcher/ContentSwitcher";
|
||||
export { default as Switch } from "./ContentSwitcher/Switch";
|
||||
export { default as ContextMenu } from "./ContextMenu/ContextMenu";
|
||||
export { default as ContextMenuInner } from "./ContextMenu/ContextMenuInner";
|
||||
export { default as ContextMenuDivider } from "./ContextMenu/ContextMenuDivider";
|
||||
export { default as ContextMenuGroup } from "./ContextMenu/ContextMenuGroup";
|
||||
export { default as ContextMenuOption } from "./ContextMenu/ContextMenuOption";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue