@cube-dev/ui-kit 0.1.2 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -1
- package/dist/cjs/components/GridProvider.d.ts +4 -4
- package/dist/cjs/components/{Action.d.ts → actions/Action.d.ts} +2 -2
- package/dist/{mjs/atoms → cjs/components/actions}/Button/Button.d.ts +1 -1
- package/dist/cjs/{atoms → components/actions}/Button/Submit.d.ts +0 -0
- package/dist/{mjs/atoms → cjs/components/actions}/ButtonGroup/ButtonGroup.d.ts +1 -1
- package/dist/cjs/{atoms → components/content}/Avatar/Avatar.d.ts +3 -3
- package/dist/cjs/{atoms → components/content}/Badge/Badge.d.ts +2 -2
- package/dist/cjs/{atoms → components/content}/Card/Card.d.ts +1 -1
- package/dist/{mjs/components → cjs/components/content}/Content.d.ts +1 -1
- package/dist/{mjs/components → cjs/components/content}/Divider.d.ts +1 -1
- package/dist/cjs/components/{Footer.d.ts → content/Footer.d.ts} +1 -1
- package/dist/cjs/components/{Header.d.ts → content/Header.d.ts} +1 -1
- package/dist/cjs/components/{Paragraph.d.ts → content/Paragraph.d.ts} +1 -1
- package/dist/cjs/{atoms → components/content}/Placeholder/Placeholder.d.ts +3 -3
- package/dist/{mjs/atoms → cjs/components/content}/PrismCode/PrismCode.d.ts +1 -1
- package/dist/cjs/{atoms → components/content}/Skeleton/Skeleton.d.ts +14 -2
- package/dist/cjs/components/content/Tag/Tag.d.ts +10 -0
- package/dist/cjs/components/content/Text.d.ts +32 -0
- package/dist/cjs/components/content/Title.d.ts +12 -0
- package/dist/cjs/{atoms → components/forms}/Checkbox/Checkbox.d.ts +2 -2
- package/dist/{mjs/atoms → cjs/components/forms}/Checkbox/CheckboxGroup.d.ts +2 -2
- package/dist/cjs/{atoms → components/forms}/Checkbox/context.d.ts +0 -0
- package/dist/cjs/components/{FieldWrapper.d.ts → forms/FieldWrapper.d.ts} +5 -5
- package/dist/cjs/{atoms → components/forms}/Form/Field.d.ts +1 -1
- package/dist/{mjs/atoms → cjs/components/forms}/Form/Form.d.ts +2 -2
- package/dist/cjs/{atoms → components/forms}/Form/index.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/Form/useForm.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/Form/validation.d.ts +0 -0
- package/dist/cjs/components/{Label.d.ts → forms/Label.d.ts} +5 -5
- package/dist/cjs/{atoms → components/forms}/NumberInput/NumberInput.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/NumberInput/StepButton.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/PasswordInput/PasswordInput.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/RadioGroup/Radio.d.ts +4 -4
- package/dist/cjs/{atoms → components/forms}/RadioGroup/RadioGroup.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/RadioGroup/context.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/SearchInput/SearchInput.d.ts +0 -0
- package/dist/{mjs/atoms → cjs/components/forms}/Switch/Switch.d.ts +5 -5
- package/dist/cjs/{atoms → components/forms}/TextArea/TextArea.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/TextInput/TextInput.d.ts +0 -0
- package/dist/cjs/{atoms → components/forms}/TextInput/TextInputBase.d.ts +7 -7
- package/dist/cjs/components/{Flex.d.ts → layout/Flex.d.ts} +1 -1
- package/dist/{mjs/components → cjs/components/layout}/Flow.d.ts +1 -1
- package/dist/cjs/components/{Grid.d.ts → layout/Grid.d.ts} +1 -1
- package/dist/{mjs/components → cjs/components/layout}/Prefix.d.ts +1 -1
- package/dist/cjs/components/{Space.d.ts → layout/Space.d.ts} +1 -1
- package/dist/cjs/components/{Suffix.d.ts → layout/Suffix.d.ts} +1 -1
- package/dist/cjs/{atoms → components/navigation}/Link/Link.d.ts +1 -1
- package/dist/{mjs/molecules → cjs/components/navigation}/Tabs/Tabs.d.ts +4 -4
- package/dist/{mjs/molecules → cjs/components/organisms}/Alert/Alert.d.ts +2 -2
- package/dist/cjs/{molecules → components/organisms}/CopySnippet/CopySnippet.d.ts +7 -5
- package/dist/cjs/{molecules → components/organisms}/DirectoryTree/DirectoryTree.d.ts +2 -1
- package/dist/cjs/{molecules → components/organisms}/FileTabs/FileTabs.d.ts +4 -4
- package/dist/{mjs/molecules → cjs/components/organisms}/Modal/Modal.d.ts +1 -1
- package/dist/cjs/{molecules → components/organisms}/SearchResults/SearchResults.d.ts +1 -1
- package/dist/cjs/{molecules → components/organisms}/StatsCard/StatsCard.d.ts +1 -1
- package/dist/{mjs/molecules → cjs/components/organisms}/TopBar/TopBar.d.ts +1 -1
- package/dist/{mjs/atoms → cjs/components/other}/Base64Upload/Base64Upload.d.ts +1 -1
- package/dist/cjs/{atoms → components/other}/CloudLogo/CloudLogo.d.ts +1 -1
- package/dist/cjs/{molecules → components/overlays}/AlertDialog/AlertDialog.d.ts +2 -2
- package/dist/{mjs/atoms → cjs/components/overlays}/Dialog/Dialog.d.ts +1 -1
- package/dist/cjs/{atoms → components/overlays}/Dialog/DialogContainer.d.ts +0 -0
- package/dist/{mjs/atoms → cjs/components/overlays}/Dialog/DialogTrigger.d.ts +2 -2
- package/dist/{mjs/atoms → cjs/components/overlays}/Dialog/api.d.ts +1 -1
- package/dist/cjs/{atoms → components/overlays}/Dialog/context.d.ts +0 -0
- package/dist/{mjs/atoms → cjs/components/overlays}/Dialog/index.d.ts +1 -1
- package/dist/cjs/{atoms → components/overlays}/Modal/Modal.d.ts +4 -4
- package/dist/cjs/{atoms → components/overlays}/Modal/OpenTransition.d.ts +0 -0
- package/dist/cjs/{atoms → components/overlays}/Modal/Overlay.d.ts +0 -0
- package/dist/{mjs/atoms → cjs/components/overlays}/Modal/Popover.d.ts +2 -2
- package/dist/cjs/{atoms → components/overlays}/Modal/Tray.d.ts +3 -3
- package/dist/cjs/{atoms → components/overlays}/Modal/Underlay.d.ts +0 -0
- package/dist/cjs/{atoms → components/overlays}/Modal/index.d.ts +0 -0
- package/dist/cjs/{molecules → components/overlays}/Notification/Notification.d.ts +1 -1
- package/dist/cjs/components/overlays/OverlayWrapper.d.ts +11 -0
- package/dist/{mjs/atoms → cjs/components/overlays}/Tooltip/Tooltip.d.ts +4 -4
- package/dist/cjs/{atoms → components/overlays}/Tooltip/TooltipTrigger.d.ts +0 -0
- package/dist/{mjs/atoms → cjs/components/overlays}/Tooltip/context.d.ts +4 -2
- package/dist/{mjs/atoms → cjs/components/pickers}/ComboBox/ComboBox.d.ts +1 -1
- package/dist/{mjs/atoms → cjs/components/pickers}/Select/Select.d.ts +12 -11
- package/dist/cjs/{atoms → components/status}/LoadingAnimation/LoadingAnimation.d.ts +1 -1
- package/dist/{mjs/atoms → cjs/components/status}/Spin/Spin.d.ts +1 -1
- package/dist/cjs/components/types.d.ts +20 -21
- package/dist/cjs/css-properties.d.ts +62 -0
- package/dist/cjs/data/themes.d.ts +1 -1
- package/dist/cjs/index.d.ts +117 -112
- package/dist/cjs/index.js +6 -6
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/provider.d.ts +2 -2
- package/dist/cjs/providers/Styles.d.ts +2 -2
- package/dist/cjs/services/notification.d.ts +1 -1
- package/dist/cjs/shared/form.d.ts +2 -2
- package/dist/cjs/styles/color.d.ts +1 -3
- package/dist/cjs/styles/list.d.ts +4 -4
- package/dist/cjs/styles/preset.d.ts +17 -0
- package/dist/cjs/styles/size.d.ts +3 -0
- package/dist/cjs/styles/types.d.ts +9 -5
- package/dist/cjs/utils/react/Slots.d.ts +1 -2
- package/dist/cjs/utils/react/mapProps.d.ts +1 -1
- package/dist/cjs/utils/renderStyles.d.ts +4 -4
- package/dist/cjs/utils/responsive.d.ts +2 -2
- package/dist/cjs/utils/styles.d.ts +41 -41
- package/dist/cjs/utils/transitions.d.ts +7 -5
- package/dist/mjs/components/GridProvider.d.ts +4 -4
- package/dist/mjs/components/{Action.d.ts → actions/Action.d.ts} +2 -2
- package/dist/{cjs/atoms → mjs/components/actions}/Button/Button.d.ts +1 -1
- package/dist/mjs/{atoms → components/actions}/Button/Submit.d.ts +0 -0
- package/dist/{cjs/atoms → mjs/components/actions}/ButtonGroup/ButtonGroup.d.ts +1 -1
- package/dist/mjs/{atoms → components/content}/Avatar/Avatar.d.ts +3 -3
- package/dist/mjs/{atoms → components/content}/Badge/Badge.d.ts +2 -2
- package/dist/mjs/{atoms → components/content}/Card/Card.d.ts +1 -1
- package/dist/{cjs/components → mjs/components/content}/Content.d.ts +1 -1
- package/dist/{cjs/components → mjs/components/content}/Divider.d.ts +1 -1
- package/dist/mjs/components/{Footer.d.ts → content/Footer.d.ts} +1 -1
- package/dist/mjs/components/{Header.d.ts → content/Header.d.ts} +1 -1
- package/dist/mjs/components/{Paragraph.d.ts → content/Paragraph.d.ts} +1 -1
- package/dist/mjs/{atoms → components/content}/Placeholder/Placeholder.d.ts +3 -3
- package/dist/{cjs/atoms → mjs/components/content}/PrismCode/PrismCode.d.ts +1 -1
- package/dist/mjs/{atoms → components/content}/Skeleton/Skeleton.d.ts +14 -2
- package/dist/mjs/components/content/Tag/Tag.d.ts +10 -0
- package/dist/mjs/components/content/Text.d.ts +32 -0
- package/dist/mjs/components/content/Title.d.ts +12 -0
- package/dist/mjs/{atoms → components/forms}/Checkbox/Checkbox.d.ts +2 -2
- package/dist/{cjs/atoms → mjs/components/forms}/Checkbox/CheckboxGroup.d.ts +2 -2
- package/dist/mjs/{atoms → components/forms}/Checkbox/context.d.ts +0 -0
- package/dist/mjs/components/{FieldWrapper.d.ts → forms/FieldWrapper.d.ts} +5 -5
- package/dist/mjs/{atoms → components/forms}/Form/Field.d.ts +1 -1
- package/dist/{cjs/atoms → mjs/components/forms}/Form/Form.d.ts +2 -2
- package/dist/mjs/{atoms → components/forms}/Form/index.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/Form/useForm.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/Form/validation.d.ts +0 -0
- package/dist/mjs/components/{Label.d.ts → forms/Label.d.ts} +5 -5
- package/dist/mjs/{atoms → components/forms}/NumberInput/NumberInput.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/NumberInput/StepButton.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/PasswordInput/PasswordInput.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/RadioGroup/Radio.d.ts +4 -4
- package/dist/mjs/{atoms → components/forms}/RadioGroup/RadioGroup.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/RadioGroup/context.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/SearchInput/SearchInput.d.ts +0 -0
- package/dist/{cjs/atoms → mjs/components/forms}/Switch/Switch.d.ts +5 -5
- package/dist/mjs/{atoms → components/forms}/TextArea/TextArea.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/TextInput/TextInput.d.ts +0 -0
- package/dist/mjs/{atoms → components/forms}/TextInput/TextInputBase.d.ts +7 -7
- package/dist/mjs/components/{Flex.d.ts → layout/Flex.d.ts} +1 -1
- package/dist/{cjs/components → mjs/components/layout}/Flow.d.ts +1 -1
- package/dist/mjs/components/{Grid.d.ts → layout/Grid.d.ts} +1 -1
- package/dist/{cjs/components → mjs/components/layout}/Prefix.d.ts +1 -1
- package/dist/mjs/components/{Space.d.ts → layout/Space.d.ts} +1 -1
- package/dist/mjs/components/{Suffix.d.ts → layout/Suffix.d.ts} +1 -1
- package/dist/mjs/{atoms → components/navigation}/Link/Link.d.ts +1 -1
- package/dist/{cjs/molecules → mjs/components/navigation}/Tabs/Tabs.d.ts +4 -4
- package/dist/{cjs/molecules → mjs/components/organisms}/Alert/Alert.d.ts +2 -2
- package/dist/mjs/{molecules → components/organisms}/CopySnippet/CopySnippet.d.ts +7 -5
- package/dist/mjs/{molecules → components/organisms}/DirectoryTree/DirectoryTree.d.ts +2 -1
- package/dist/mjs/{molecules → components/organisms}/FileTabs/FileTabs.d.ts +4 -4
- package/dist/{cjs/molecules → mjs/components/organisms}/Modal/Modal.d.ts +1 -1
- package/dist/mjs/{molecules → components/organisms}/SearchResults/SearchResults.d.ts +1 -1
- package/dist/mjs/{molecules → components/organisms}/StatsCard/StatsCard.d.ts +1 -1
- package/dist/{cjs/molecules → mjs/components/organisms}/TopBar/TopBar.d.ts +1 -1
- package/dist/{cjs/atoms → mjs/components/other}/Base64Upload/Base64Upload.d.ts +1 -1
- package/dist/mjs/{atoms → components/other}/CloudLogo/CloudLogo.d.ts +1 -1
- package/dist/mjs/{molecules → components/overlays}/AlertDialog/AlertDialog.d.ts +2 -2
- package/dist/{cjs/atoms → mjs/components/overlays}/Dialog/Dialog.d.ts +1 -1
- package/dist/mjs/{atoms → components/overlays}/Dialog/DialogContainer.d.ts +0 -0
- package/dist/{cjs/atoms → mjs/components/overlays}/Dialog/DialogTrigger.d.ts +2 -2
- package/dist/{cjs/atoms → mjs/components/overlays}/Dialog/api.d.ts +1 -1
- package/dist/mjs/{atoms → components/overlays}/Dialog/context.d.ts +0 -0
- package/dist/{cjs/atoms → mjs/components/overlays}/Dialog/index.d.ts +1 -1
- package/dist/mjs/{atoms → components/overlays}/Modal/Modal.d.ts +4 -4
- package/dist/mjs/{atoms → components/overlays}/Modal/OpenTransition.d.ts +0 -0
- package/dist/mjs/{atoms → components/overlays}/Modal/Overlay.d.ts +0 -0
- package/dist/{cjs/atoms → mjs/components/overlays}/Modal/Popover.d.ts +2 -2
- package/dist/mjs/{atoms → components/overlays}/Modal/Tray.d.ts +3 -3
- package/dist/mjs/{atoms → components/overlays}/Modal/Underlay.d.ts +0 -0
- package/dist/mjs/{atoms → components/overlays}/Modal/index.d.ts +0 -0
- package/dist/mjs/{molecules → components/overlays}/Notification/Notification.d.ts +1 -1
- package/dist/mjs/components/overlays/OverlayWrapper.d.ts +11 -0
- package/dist/{cjs/atoms → mjs/components/overlays}/Tooltip/Tooltip.d.ts +4 -4
- package/dist/mjs/{atoms → components/overlays}/Tooltip/TooltipTrigger.d.ts +0 -0
- package/dist/{cjs/atoms → mjs/components/overlays}/Tooltip/context.d.ts +4 -2
- package/dist/{cjs/atoms → mjs/components/pickers}/ComboBox/ComboBox.d.ts +1 -1
- package/dist/{cjs/atoms → mjs/components/pickers}/Select/Select.d.ts +12 -11
- package/dist/mjs/{atoms → components/status}/LoadingAnimation/LoadingAnimation.d.ts +1 -1
- package/dist/{cjs/atoms → mjs/components/status}/Spin/Spin.d.ts +1 -1
- package/dist/mjs/components/types.d.ts +20 -21
- package/dist/mjs/css-properties.d.ts +62 -0
- package/dist/mjs/data/themes.d.ts +1 -1
- package/dist/mjs/index.d.ts +117 -112
- package/dist/mjs/index.js +7 -7
- package/dist/mjs/index.js.map +1 -1
- package/dist/mjs/provider.d.ts +2 -2
- package/dist/mjs/providers/Styles.d.ts +2 -2
- package/dist/mjs/services/notification.d.ts +1 -1
- package/dist/mjs/shared/form.d.ts +2 -2
- package/dist/mjs/styles/color.d.ts +1 -3
- package/dist/mjs/styles/list.d.ts +4 -4
- package/dist/mjs/styles/preset.d.ts +17 -0
- package/dist/mjs/styles/size.d.ts +3 -0
- package/dist/mjs/styles/types.d.ts +9 -5
- package/dist/mjs/utils/react/Slots.d.ts +1 -2
- package/dist/mjs/utils/react/mapProps.d.ts +1 -1
- package/dist/mjs/utils/renderStyles.d.ts +4 -4
- package/dist/mjs/utils/responsive.d.ts +2 -2
- package/dist/mjs/utils/styles.d.ts +41 -41
- package/dist/mjs/utils/transitions.d.ts +7 -5
- package/package.json +4 -3
- package/dist/cjs/components/OverlayWrapper.d.ts +0 -8
- package/dist/cjs/components/Text.d.ts +0 -32
- package/dist/cjs/components/Title.d.ts +0 -15
- package/dist/mjs/components/OverlayWrapper.d.ts +0 -8
- package/dist/mjs/components/Text.d.ts +0 -32
- package/dist/mjs/components/Title.d.ts +0 -15
package/dist/cjs/provider.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PropsWithChildren } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { ResponsiveStyleValue } from './utils/styles';
|
|
3
3
|
import { Props } from './components/types';
|
|
4
4
|
export declare const UIKitContext: import("react").Context<ProviderProps>;
|
|
5
5
|
export interface ProviderProps extends Props {
|
|
@@ -12,7 +12,7 @@ export interface ProviderProps extends Props {
|
|
|
12
12
|
router?: Function;
|
|
13
13
|
styles?: {
|
|
14
14
|
[key: string]: {
|
|
15
|
-
[key: string]:
|
|
15
|
+
[key: string]: ResponsiveStyleValue;
|
|
16
16
|
} | Function;
|
|
17
17
|
};
|
|
18
18
|
ref?: JSX.Element;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
2
|
+
import { Styles } from '../styles/types';
|
|
3
3
|
export declare const StyleContext: import("react").Context<any>;
|
|
4
4
|
export declare function StyleProvider({ children, ...props }: {
|
|
5
5
|
[x: string]: any;
|
|
6
6
|
children: any;
|
|
7
7
|
}): JSX.Element;
|
|
8
|
-
export declare function useContextStyles(name: any, props?: any):
|
|
8
|
+
export declare function useContextStyles(name: any, props?: any): Styles;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Props } from '../components/types';
|
|
2
|
-
import {
|
|
2
|
+
import { Styles } from '../styles/types';
|
|
3
3
|
import { ReactNode } from 'react';
|
|
4
4
|
export declare type LabelPosition = 'side' | 'top';
|
|
5
5
|
export declare type NecessityIndicator = 'icon' | 'label';
|
|
@@ -18,7 +18,7 @@ export interface FieldBaseProps {
|
|
|
18
18
|
validateTrigger?: ValidateTrigger;
|
|
19
19
|
}
|
|
20
20
|
export interface FormBaseProps {
|
|
21
|
-
labelStyles?:
|
|
21
|
+
labelStyles?: Styles;
|
|
22
22
|
labelPosition?: LabelPosition;
|
|
23
23
|
/** Whether the field presents required mark */
|
|
24
24
|
requiredMark?: boolean;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export declare const BASE_STYLES: readonly ["display", "size", "font"];
|
|
1
|
+
export declare const BASE_STYLES: readonly ["display", "size", "font", "preset"];
|
|
2
2
|
export declare const POSITION_STYLES: readonly ["gridArea", "flexGrow", "flexShrink", "order", "gridColumn", "gridRow", "placeSelf", "zIndex", "margin"];
|
|
3
|
-
export declare const BLOCK_STYLES: readonly ["reset", "padding", "shadow", "border", "radius", "opacity", "overflow", "styledScrollbar", "hide", "outline"];
|
|
3
|
+
export declare const BLOCK_STYLES: readonly ["reset", "padding", "shadow", "border", "radius", "opacity", "overflow", "styledScrollbar", "hide", "outline", "textAlign"];
|
|
4
4
|
export declare const COLOR_STYLES: readonly ["color", "fill"];
|
|
5
|
-
export declare const TEXT_STYLES: readonly ["
|
|
5
|
+
export declare const TEXT_STYLES: readonly ["textTransform", "fontWeight", "fontStyle"];
|
|
6
6
|
export declare const DIMENSION_STYLES: readonly ["width", "height", "flexBasis"];
|
|
7
7
|
export declare const FLOW_STYLES: readonly ["flow", "placeItems", "placeContent", "alignItems", "alignContent", "justifyItems", "justifyContent", "gap", "gridColumns", "gridRows", "gridTemplate", "gridAreas"];
|
|
8
|
-
export declare const CONTAINER_STYLES: readonly ["display", "size", "font", "color", "fill", "width", "height", "flexBasis", "gridArea", "flexGrow", "flexShrink", "order", "gridColumn", "gridRow", "placeSelf", "zIndex", "margin", "reset", "padding", "shadow", "border", "radius", "opacity", "overflow", "styledScrollbar", "hide", "outline", "flow", "placeItems", "placeContent", "alignItems", "alignContent", "justifyItems", "justifyContent", "gap", "gridColumns", "gridRows", "gridTemplate", "gridAreas"];
|
|
8
|
+
export declare const CONTAINER_STYLES: readonly ["display", "size", "font", "preset", "color", "fill", "width", "height", "flexBasis", "gridArea", "flexGrow", "flexShrink", "order", "gridColumn", "gridRow", "placeSelf", "zIndex", "margin", "reset", "padding", "shadow", "border", "radius", "opacity", "overflow", "styledScrollbar", "hide", "outline", "textAlign", "flow", "placeItems", "placeContent", "alignItems", "alignContent", "justifyItems", "justifyContent", "gap", "gridColumns", "gridRows", "gridTemplate", "gridAreas"];
|
|
9
9
|
export declare const OUTER_STYLES: readonly ["gridArea", "flexGrow", "flexShrink", "order", "gridColumn", "gridRow", "placeSelf", "zIndex", "margin", "width", "height", "flexBasis"];
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare function presetStyle({ preset }: {
|
|
2
|
+
preset: any;
|
|
3
|
+
}): "" | {
|
|
4
|
+
'font-size': any;
|
|
5
|
+
'line-height': any;
|
|
6
|
+
'letter-spacing': any;
|
|
7
|
+
'font-weight': any;
|
|
8
|
+
'text-transform': any;
|
|
9
|
+
'--font-size': any;
|
|
10
|
+
'--line-height': any;
|
|
11
|
+
'--letter-spacing': any;
|
|
12
|
+
'--font-weight': any;
|
|
13
|
+
'--text-transform': any;
|
|
14
|
+
};
|
|
15
|
+
export declare namespace presetStyle {
|
|
16
|
+
var __lookupStyles: string[];
|
|
17
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { CSSProperties } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { ResponsiveStyleValue } from '../utils/styles';
|
|
3
3
|
declare type NamedColor = 'purple' | 'purple-text' | 'purple-01' | 'purple-02' | 'purple-03' | 'purple-04' | 'dark' | 'dark-01' | 'dark-02' | 'dark-03' | 'dark-04' | 'dark-05' | 'text' | 'primary' | 'disabled' | 'disabled-bg' | 'disabled-text' | 'danger' | 'danger-bg' | 'danger-text' | 'success' | 'success-bg' | 'success-text' | 'note' | 'note-bg' | 'note-text' | 'white' | 'light' | 'light-grey' | 'black' | 'pink' | 'pink-01' | 'pink-02' | 'border' | 'clear' | 'shadow' | 'draft' | 'minor';
|
|
4
4
|
declare type Digit = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9;
|
|
5
5
|
declare type OpaquePercentage = '' | `.${Digit}` | `.${Digit}${Digit}` | '.100';
|
|
6
6
|
export declare type NoType = false | null | undefined;
|
|
7
|
-
export interface
|
|
7
|
+
export interface StylesInterface extends Omit<CSSProperties, 'color' | 'fill' | 'font' | 'outline'> {
|
|
8
8
|
/** Set the background color of the element.
|
|
9
9
|
* ```
|
|
10
10
|
* fill="#{name_of_the_color}"
|
|
@@ -92,10 +92,14 @@ export interface NuStylesInterface extends Omit<CSSProperties, 'color' | 'fill'
|
|
|
92
92
|
* Syntax: <value> 'inset'?
|
|
93
93
|
*/
|
|
94
94
|
outline?: CSSProperties['fontFamily'] | boolean;
|
|
95
|
+
/**
|
|
96
|
+
* The preset style sets the base text settings according to the names preset. Affected styles: `font-size`, `line-height`, `letter-spacing`, `font-weight` and `text-transform`.
|
|
97
|
+
*/
|
|
98
|
+
preset?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h5s' | 'h5m' | 'h6' | 't1' | 't2' | 't3' | 't4' | 't4m' | 'p1' | 'p2' | 'p3' | 'p4' | 'tag' | 'default' | string;
|
|
95
99
|
}
|
|
96
|
-
export declare type
|
|
97
|
-
[key in keyof
|
|
100
|
+
export declare type Styles = {
|
|
101
|
+
[key in keyof StylesInterface]?: ResponsiveStyleValue<StylesInterface[key]>;
|
|
98
102
|
} & {
|
|
99
|
-
[key: string]:
|
|
103
|
+
[key: string]: ResponsiveStyleValue<string | number | boolean | undefined>;
|
|
100
104
|
};
|
|
101
105
|
export {};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
3
|
-
export declare function useSlotProps(props: Props, defaultSlot: any): Props;
|
|
2
|
+
export declare function useSlotProps(props: Record<string, any>, defaultSlot: any): Record<string, any>;
|
|
4
3
|
export declare function SlotProvider(props: any): JSX.Element;
|
|
5
4
|
export declare function ClearSlots(props: any): JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CubeButtonProps } from '../../
|
|
1
|
+
import { CubeButtonProps } from '../../components/actions/Button/Button';
|
|
2
2
|
import { AriaButtonProps } from '@react-types/button';
|
|
3
3
|
/** Converts AriaButtonProps to CubeButtonProps */
|
|
4
4
|
export declare function ariaToCubeButtonProps(props: AriaButtonProps<'button'>): CubeButtonProps;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { StyleHandler } from './styles';
|
|
2
|
+
import { Styles } from '../styles/types';
|
|
3
3
|
declare type StyleHandlerMap = {
|
|
4
|
-
[key: string]:
|
|
4
|
+
[key: string]: StyleHandler[];
|
|
5
5
|
};
|
|
6
6
|
/**
|
|
7
7
|
* Render style props to complete Styled Components CSS.
|
|
@@ -10,6 +10,6 @@ declare type StyleHandlerMap = {
|
|
|
10
10
|
* @param styleHandlerMap - Style to handler list map.
|
|
11
11
|
* @return {string}
|
|
12
12
|
*/
|
|
13
|
-
export declare function renderStyles(styles:
|
|
13
|
+
export declare function renderStyles(styles: Styles, responsive: number[], styleHandlerMap?: StyleHandlerMap): string;
|
|
14
14
|
export declare function createStyle(styleName: string, cssStyle?: string, converter?: Function): any;
|
|
15
15
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ResponsiveStyleValue } from './styles';
|
|
2
2
|
export declare function mediaWrapper(cssRules: any, points: any): any;
|
|
3
3
|
export interface ResponsiveZone {
|
|
4
4
|
max?: number;
|
|
@@ -6,4 +6,4 @@ export interface ResponsiveZone {
|
|
|
6
6
|
mediaQuery?: string;
|
|
7
7
|
}
|
|
8
8
|
export declare function pointsToZones(points: number[]): any;
|
|
9
|
-
export declare function normalizeStyleZones(value:
|
|
9
|
+
export declare function normalizeStyleZones(value: ResponsiveStyleValue, zoneNumber: number): any[] | null | undefined;
|
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare type
|
|
3
|
-
export declare type
|
|
4
|
-
[key: string]:
|
|
1
|
+
import { Styles } from '../styles/types';
|
|
2
|
+
export declare type StyleValue<T = string> = number | null | boolean | undefined | T;
|
|
3
|
+
export declare type StyleValueStateMap<T> = {
|
|
4
|
+
[key: string]: StyleValue<T>;
|
|
5
5
|
};
|
|
6
|
-
export declare type
|
|
7
|
-
export declare type
|
|
8
|
-
export declare type
|
|
6
|
+
export declare type ResponsiveStyleValue<T = string> = StyleValue<T> | StyleValue<T>[] | StyleValueStateMap<T> | StyleValueStateMap<T>[];
|
|
7
|
+
export declare type ComputeModel = string | number;
|
|
8
|
+
export declare type CSSMap = {
|
|
9
9
|
$?: string;
|
|
10
10
|
} & {
|
|
11
11
|
[key: string]: string | string[];
|
|
12
12
|
};
|
|
13
|
-
export declare type
|
|
13
|
+
export declare type StyleHandler = ((StyleValue: any) => CSSMap | CSSMap[]) & {
|
|
14
14
|
__lookupStyles: string[];
|
|
15
15
|
};
|
|
16
|
-
export interface
|
|
17
|
-
model?:
|
|
16
|
+
export interface StyleStateData {
|
|
17
|
+
model?: ComputeModel;
|
|
18
18
|
tokens?: string[];
|
|
19
|
-
value:
|
|
19
|
+
value: ResponsiveStyleValue;
|
|
20
20
|
/** The list of mods to apply */
|
|
21
21
|
mods: string[];
|
|
22
22
|
/** The list of **not** mods to apply (e.g. `:not(:hover)`) */
|
|
23
23
|
notMods: string[];
|
|
24
24
|
}
|
|
25
|
-
export declare type
|
|
26
|
-
export declare type
|
|
27
|
-
[key: string]:
|
|
25
|
+
export declare type StyleStateDataList = StyleStateData[];
|
|
26
|
+
export declare type StyleStateDataListMap = {
|
|
27
|
+
[key: string]: StyleStateDataList;
|
|
28
28
|
};
|
|
29
29
|
/** An object that describes a relation between specific modifiers and style value. **/
|
|
30
|
-
export interface
|
|
30
|
+
export interface StyleState {
|
|
31
31
|
/** The list of mods to apply */
|
|
32
32
|
mods: string[];
|
|
33
33
|
/** The list of **not** mods to apply (e.g. `:not(:hover)`) */
|
|
34
34
|
notMods: string[];
|
|
35
35
|
/** The value to apply */
|
|
36
|
-
value:
|
|
36
|
+
value: StyleMap;
|
|
37
37
|
}
|
|
38
|
-
export declare type
|
|
39
|
-
export declare type
|
|
40
|
-
export declare type
|
|
41
|
-
[key: string]:
|
|
38
|
+
export declare type ComputeUnit = string | (string | string[])[];
|
|
39
|
+
export declare type StyleStateList = StyleState[];
|
|
40
|
+
export declare type StyleMap = {
|
|
41
|
+
[key: string]: ResponsiveStyleValue;
|
|
42
42
|
};
|
|
43
|
-
export declare type
|
|
44
|
-
[key: string]:
|
|
43
|
+
export declare type StyleStateMap = {
|
|
44
|
+
[key: string]: StyleState;
|
|
45
45
|
};
|
|
46
|
-
export declare type
|
|
47
|
-
export declare type
|
|
48
|
-
[key: string]:
|
|
46
|
+
export declare type StyleStateMapList = StyleStateMap[];
|
|
47
|
+
export declare type StyleStateListMap = {
|
|
48
|
+
[key: string]: StyleStateList;
|
|
49
49
|
};
|
|
50
50
|
export declare const NO_VALUES: (string | boolean)[];
|
|
51
51
|
export declare const YES_VALUES: (string | boolean)[];
|
|
@@ -128,20 +128,20 @@ export declare function extendStyles(defaultStyles: any, newStyles: any): {};
|
|
|
128
128
|
*/
|
|
129
129
|
export declare function extractStyles(props: {
|
|
130
130
|
[key: string]: any;
|
|
131
|
-
}, styleList?: readonly string[], defaultStyles?:
|
|
131
|
+
}, styleList?: readonly string[], defaultStyles?: Styles, propMap?: {
|
|
132
132
|
[key: string]: string;
|
|
133
|
-
}, ignoreList?: readonly string[]):
|
|
133
|
+
}, ignoreList?: readonly string[]): Styles;
|
|
134
134
|
/**
|
|
135
|
-
* Render
|
|
135
|
+
* Render CSSMap to Styled Components CSS
|
|
136
136
|
* @param styles
|
|
137
137
|
* @param [selector]
|
|
138
138
|
*/
|
|
139
|
-
export declare function renderStylesToSC(styles:
|
|
139
|
+
export declare function renderStylesToSC(styles: CSSMap | CSSMap[], selector?: string): any;
|
|
140
140
|
/**
|
|
141
141
|
* Compile states to finite CSS with selectors.
|
|
142
142
|
* State values should contain a string value with CSS style list.
|
|
143
143
|
* @param {string} selector
|
|
144
|
-
* @param {
|
|
144
|
+
* @param {StyleStateList|StyleStateMapList} states
|
|
145
145
|
*/
|
|
146
146
|
export declare function applyStates(selector: any, states: any): any;
|
|
147
147
|
export declare function styleHandlerCacheWrapper(styleHandler: any, limit?: number): ((arg: any) => any) & {
|
|
@@ -149,26 +149,26 @@ export declare function styleHandlerCacheWrapper(styleHandler: any, limit?: numb
|
|
|
149
149
|
};
|
|
150
150
|
/**
|
|
151
151
|
* Fill all unspecified states and cover all possible combinations of presented modifiers.
|
|
152
|
-
* @param {
|
|
152
|
+
* @param {StyleStateList} stateList
|
|
153
153
|
* @param {string[]} [allModes]
|
|
154
|
-
* @return {
|
|
154
|
+
* @return {StyleStateList}
|
|
155
155
|
*/
|
|
156
156
|
export declare function normalizeStates(stateList: any, allModes: any): any;
|
|
157
157
|
/**
|
|
158
158
|
* Replace state values with new ones.
|
|
159
159
|
* For example, if you want to replace initial values with finite CSS code.
|
|
160
|
-
* @param {
|
|
160
|
+
* @param {StyleStateList|StyleStateMapList} states
|
|
161
161
|
* @param {Function} replaceFn
|
|
162
162
|
*/
|
|
163
163
|
export declare function replaceStateValues(states: any, replaceFn: any): any;
|
|
164
164
|
/**
|
|
165
165
|
* Get all presented modes from style state list.
|
|
166
|
-
* @param {
|
|
166
|
+
* @param {StyleStateList} stateList
|
|
167
167
|
*/
|
|
168
168
|
export declare function getModesFromStyleStateList(stateList: any): any;
|
|
169
169
|
/**
|
|
170
170
|
* Get all presented modes from style state list map.
|
|
171
|
-
* @param {
|
|
171
|
+
* @param {StyleStateMapList} stateListMap
|
|
172
172
|
* @return {string[]}
|
|
173
173
|
*/
|
|
174
174
|
export declare function getModesFromStyleStateListMap(stateListMap: any): string[];
|
|
@@ -177,7 +177,7 @@ export declare function getModesFromStyleStateListMap(stateListMap: any): string
|
|
|
177
177
|
* @param styleMap
|
|
178
178
|
* @param filterKeys
|
|
179
179
|
*/
|
|
180
|
-
export declare function styleMapToStyleMapStateList(styleMap:
|
|
180
|
+
export declare function styleMapToStyleMapStateList(styleMap: StyleMap, filterKeys?: string[]): StyleStateList;
|
|
181
181
|
export declare const STATE_OPERATORS: {
|
|
182
182
|
NOT: string;
|
|
183
183
|
AND: string;
|
|
@@ -188,10 +188,10 @@ export declare const STATE_OPERATOR_LIST: string[];
|
|
|
188
188
|
export declare const parseStateNotation: (arg: any) => any;
|
|
189
189
|
/**
|
|
190
190
|
*
|
|
191
|
-
* @param {
|
|
192
|
-
* @return {{ states:
|
|
191
|
+
* @param {StyleStateMap|string|number|boolean|null|undefined} styleStateMap
|
|
192
|
+
* @return {{ states: StyleStateDataList, mods: string[] }}
|
|
193
193
|
*/
|
|
194
|
-
export declare function styleStateMapToStyleStateDataList(styleStateMap:
|
|
194
|
+
export declare function styleStateMapToStyleStateDataList(styleStateMap: StyleStateMap | ResponsiveStyleValue): {
|
|
195
195
|
states: {
|
|
196
196
|
model: null;
|
|
197
197
|
mods: never[];
|
|
@@ -199,7 +199,7 @@ export declare function styleStateMapToStyleStateDataList(styleStateMap: NuStyle
|
|
|
199
199
|
}[];
|
|
200
200
|
mods: never[];
|
|
201
201
|
} | {
|
|
202
|
-
states:
|
|
202
|
+
states: StyleStateDataList;
|
|
203
203
|
mods: string[];
|
|
204
204
|
};
|
|
205
205
|
export declare const COMPUTE_FUNC_MAP: {
|
|
@@ -211,7 +211,7 @@ export declare const COMPUTE_FUNC_MAP: {
|
|
|
211
211
|
/**
|
|
212
212
|
* Compute a result based on model and incoming map.
|
|
213
213
|
*/
|
|
214
|
-
export declare function computeState(computeModel:
|
|
214
|
+
export declare function computeState(computeModel: ComputeModel, valueMap: (number | boolean)[] | {
|
|
215
215
|
[key: string]: boolean;
|
|
216
216
|
} | Function): any;
|
|
217
217
|
export declare function cacheWrapper(handler: Function, limit?: number): (arg: any) => any;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
export
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
minScale?: string |
|
|
5
|
-
|
|
1
|
+
export interface OverlayTransitionCSSProps {
|
|
2
|
+
suffix?: string;
|
|
3
|
+
placement?: string;
|
|
4
|
+
minScale?: string | number;
|
|
5
|
+
minOffset?: string;
|
|
6
|
+
}
|
|
7
|
+
export declare const getOverlayTransitionCSS: ({ suffix, placement, minScale, minOffset, }?: OverlayTransitionCSSProps) => string;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Styles } from '../styles/types';
|
|
3
3
|
export interface CubeGridProviderProps {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
columns?: number;
|
|
6
|
-
gap?:
|
|
7
|
-
width?:
|
|
8
|
-
initialWidth?:
|
|
6
|
+
gap?: Styles['gap'];
|
|
7
|
+
width?: Styles['width'];
|
|
8
|
+
initialWidth?: Styles['width'];
|
|
9
9
|
}
|
|
10
10
|
export declare const GridProvider: import("react").ForwardRefExoticComponent<CubeGridProviderProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { MouseEventHandler } from 'react';
|
|
2
|
-
import { BaseProps, ContainerStyleProps, TagNameProps, TextStyleProps } from '
|
|
2
|
+
import { BaseProps, BaseStyleProps, ContainerStyleProps, TagNameProps, TextStyleProps } from '../types';
|
|
3
3
|
import { AriaButtonProps } from '@react-types/button';
|
|
4
|
-
export interface CubeActionProps extends BaseProps, TagNameProps, ContainerStyleProps, TextStyleProps, Omit<AriaButtonProps, 'type'> {
|
|
4
|
+
export interface CubeActionProps extends BaseProps, TagNameProps, BaseStyleProps, ContainerStyleProps, TextStyleProps, Omit<AriaButtonProps, 'type'> {
|
|
5
5
|
to?: string;
|
|
6
6
|
label?: string;
|
|
7
7
|
skipWarnings?: boolean;
|
|
File without changes
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { CubeSpaceProps } from '../../
|
|
2
|
+
import { CubeSpaceProps } from '../../layout/Space';
|
|
3
3
|
export declare const ButtonGroup: import("react").ForwardRefExoticComponent<CubeSpaceProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { BaseProps, ContainerStyleProps } from '../../
|
|
3
|
-
import {
|
|
2
|
+
import { BaseProps, ContainerStyleProps } from '../../types';
|
|
3
|
+
import { Styles } from '../../../styles/types';
|
|
4
4
|
export interface CubeAvatarProps extends BaseProps, ContainerStyleProps {
|
|
5
5
|
icon?: JSX.Element;
|
|
6
|
-
size?:
|
|
6
|
+
size?: Styles['size'];
|
|
7
7
|
}
|
|
8
8
|
export declare const Avatar: import("react").ForwardRefExoticComponent<CubeAvatarProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import THEMES from '
|
|
3
|
-
import { BaseProps, ContainerStyleProps } from '../../
|
|
2
|
+
import THEMES from '../../../data/themes';
|
|
3
|
+
import { BaseProps, ContainerStyleProps } from '../../types';
|
|
4
4
|
export interface CubeBadgeProps extends BaseProps, ContainerStyleProps {
|
|
5
5
|
type?: keyof typeof THEMES;
|
|
6
6
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { BaseProps, ContainerStyleProps } from '../../
|
|
2
|
+
import { BaseProps, ContainerStyleProps } from '../../types';
|
|
3
3
|
export interface CubeCardProps extends BaseProps, ContainerStyleProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const Card: import("react").ForwardRefExoticComponent<CubeCardProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { BaseProps, ContainerStyleProps, TextStyleProps } from '
|
|
2
|
+
import { BaseProps, ContainerStyleProps, TextStyleProps } from '../types';
|
|
3
3
|
export interface CubeContentProps extends BaseProps, ContainerStyleProps, TextStyleProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const Content: import("react").ForwardRefExoticComponent<CubeContentProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { BaseProps, OuterStyleProps } from '
|
|
2
|
+
import { BaseProps, OuterStyleProps } from '../types';
|
|
3
3
|
export interface CubeDividerProps extends BaseProps, OuterStyleProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const Divider: import("react").ForwardRefExoticComponent<CubeDividerProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { BaseProps, ContainerStyleProps, TextStyleProps } from '
|
|
2
|
+
import { BaseProps, ContainerStyleProps, TextStyleProps } from '../types';
|
|
3
3
|
export interface CubeFooterProps extends BaseProps, ContainerStyleProps, TextStyleProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const Footer: import("react").ForwardRefExoticComponent<CubeFooterProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { BaseProps, ContainerStyleProps, TextStyleProps } from '
|
|
2
|
+
import { BaseProps, ContainerStyleProps, TextStyleProps } from '../types';
|
|
3
3
|
export interface CubeHeaderProps extends BaseProps, ContainerStyleProps, TextStyleProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const Header: import("react").ForwardRefExoticComponent<CubeHeaderProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { CubeTextProps } from './Text';
|
|
3
|
-
import { ContainerStyleProps } from '
|
|
3
|
+
import { ContainerStyleProps } from '../types';
|
|
4
4
|
export interface CubeParagraphProps extends CubeTextProps, ContainerStyleProps {
|
|
5
5
|
}
|
|
6
6
|
export declare const Paragraph: import("react").ForwardRefExoticComponent<CubeParagraphProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
3
|
-
import { BaseProps, ContainerStyleProps } from '../../
|
|
2
|
+
import { Styles } from '../../../styles/types';
|
|
3
|
+
import { BaseProps, ContainerStyleProps } from '../../types';
|
|
4
4
|
export interface CubePlaceholderProps extends BaseProps, ContainerStyleProps {
|
|
5
|
-
size?:
|
|
5
|
+
size?: Styles['size'];
|
|
6
6
|
circle?: boolean;
|
|
7
7
|
}
|
|
8
8
|
export declare const Placeholder: import("react").ForwardRefExoticComponent<CubePlaceholderProps & import("react").RefAttributes<unknown>>;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
2
|
+
import { CubePlaceholderProps } from '../Placeholder/Placeholder';
|
|
3
|
+
import { CubeGridProps } from '../../layout/Grid';
|
|
4
|
+
import { BaseProps, ContainerStyleProps } from '../../types';
|
|
3
5
|
declare const LAYOUT_MAP: {
|
|
4
6
|
readonly page: ({ lines, children, ...props }: {
|
|
5
7
|
[x: string]: any;
|
|
@@ -36,9 +38,19 @@ declare const LAYOUT_MAP: {
|
|
|
36
38
|
columns: any;
|
|
37
39
|
}) => JSX.Element;
|
|
38
40
|
};
|
|
39
|
-
export interface CubeSkeletonProps extends BaseProps, ContainerStyleProps {
|
|
41
|
+
export interface CubeSkeletonProps extends CubeGridProps, CubePlaceholderProps, BaseProps, ContainerStyleProps {
|
|
40
42
|
/** The type of the layout */
|
|
41
43
|
layout?: keyof typeof LAYOUT_MAP;
|
|
44
|
+
/** The number of columns for table layout */
|
|
45
|
+
columns?: number;
|
|
46
|
+
/** The number of rows for table layout */
|
|
47
|
+
rows?: number;
|
|
48
|
+
/** The number of placeholder lines */
|
|
49
|
+
lines?: number;
|
|
50
|
+
/** The number of tabs */
|
|
51
|
+
tabs?: number;
|
|
52
|
+
/** The number of cards */
|
|
53
|
+
cards?: number;
|
|
42
54
|
}
|
|
43
55
|
export declare function Skeleton({ layout, ...props }: CubeSkeletonProps): JSX.Element;
|
|
44
56
|
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import THEMES from '../../../data/themes';
|
|
3
|
+
import { BaseProps, ContainerStyleProps } from '../../types';
|
|
4
|
+
export interface CubeTagProps extends BaseProps, ContainerStyleProps {
|
|
5
|
+
type?: keyof typeof THEMES;
|
|
6
|
+
isClosable?: boolean;
|
|
7
|
+
onClose?: () => void;
|
|
8
|
+
}
|
|
9
|
+
declare const _Tag: import("react").ForwardRefExoticComponent<CubeTagProps & import("react").RefAttributes<unknown>>;
|
|
10
|
+
export { _Tag as Tag };
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { CSSProperties } from 'react';
|
|
2
|
+
import { ResponsiveStyleValue } from '../../utils/styles';
|
|
3
|
+
import { BaseProps, BaseStyleProps, ColorStyleProps, TagNameProps, TextStyleProps } from '../types';
|
|
4
|
+
export interface CubeTextProps extends BaseProps, TagNameProps, TextStyleProps, BaseStyleProps, ColorStyleProps {
|
|
5
|
+
/**
|
|
6
|
+
* Whether the text uses the monospace font.
|
|
7
|
+
*/
|
|
8
|
+
monospace?: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Whether the text overflow is ellipsis
|
|
11
|
+
*/
|
|
12
|
+
ellipsis?: boolean;
|
|
13
|
+
/**
|
|
14
|
+
* Whether the text is not wrapping
|
|
15
|
+
*/
|
|
16
|
+
nowrap?: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* Whether the text has italic style
|
|
19
|
+
*/
|
|
20
|
+
italic?: ResponsiveStyleValue<CSSProperties['fontStyle']>;
|
|
21
|
+
weight?: string | number;
|
|
22
|
+
align?: ResponsiveStyleValue<CSSProperties['textAlign']>;
|
|
23
|
+
transform?: ResponsiveStyleValue<CSSProperties['textTransform']>;
|
|
24
|
+
}
|
|
25
|
+
declare const Text: import("react").ForwardRefExoticComponent<CubeTextProps & import("react").RefAttributes<unknown>> & {
|
|
26
|
+
Minor: import("react").ForwardRefExoticComponent<CubeTextProps & import("react").RefAttributes<unknown>>;
|
|
27
|
+
Danger: import("react").ForwardRefExoticComponent<CubeTextProps & import("react").RefAttributes<unknown>>;
|
|
28
|
+
Success: import("react").ForwardRefExoticComponent<CubeTextProps & import("react").RefAttributes<unknown>>;
|
|
29
|
+
Strong: import("react").ForwardRefExoticComponent<CubeTextProps & import("react").RefAttributes<unknown>>;
|
|
30
|
+
Selection: import("react").ForwardRefExoticComponent<CubeTextProps & import("react").RefAttributes<unknown>>;
|
|
31
|
+
};
|
|
32
|
+
export { Text };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { CubeTextProps } from './Text';
|
|
3
|
+
import { BaseProps, BlockStyleProps, PositionStyleProps, TagNameProps } from '../types';
|
|
4
|
+
export interface CubeTitleProps extends BaseProps, CubeTextProps, TagNameProps, BlockStyleProps, PositionStyleProps {
|
|
5
|
+
/** The level of the heading **/
|
|
6
|
+
level?: 1 | 2 | 3 | 4 | 5 | 6;
|
|
7
|
+
}
|
|
8
|
+
declare const Title: import("react").ForwardRefExoticComponent<CubeTitleProps & import("react").RefAttributes<unknown>> & {
|
|
9
|
+
Danger: import("react").ForwardRefExoticComponent<CubeTitleProps & import("react").RefAttributes<unknown>>;
|
|
10
|
+
Success: import("react").ForwardRefExoticComponent<CubeTitleProps & import("react").RefAttributes<unknown>>;
|
|
11
|
+
};
|
|
12
|
+
export { Title };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { AriaCheckboxProps } from '@react-types/checkbox';
|
|
3
|
-
import { BaseProps } from '../../
|
|
4
|
-
import { FormFieldProps } from '
|
|
3
|
+
import { BaseProps } from '../../types';
|
|
4
|
+
import { FormFieldProps } from '../../../shared';
|
|
5
5
|
export interface CubeCheckboxProps extends BaseProps, AriaCheckboxProps, FormFieldProps {
|
|
6
6
|
}
|
|
7
7
|
/**
|