@svadmin/ui 0.73.0 → 0.75.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 +53 -28
- package/dist/app.css +3733 -4119
- package/dist/app.theme.css +3733 -4119
- package/dist/component-registry.d.ts +14977 -0
- package/dist/component-registry.js +216 -0
- package/dist/components/AboutSettings.svelte +7 -1
- package/dist/components/AboutSettings.svelte.d.ts +4 -1
- package/dist/components/ActivityFeed.svelte +9 -3
- package/dist/components/ActivityFeed.svelte.d.ts +3 -0
- package/dist/components/AdminApp.svelte +24 -15
- package/dist/components/AdminApp.svelte.d.ts +6 -0
- package/dist/components/ApiSettings.svelte +41 -5
- package/dist/components/ApprovalCenter.svelte +283 -0
- package/dist/components/ApprovalCenter.svelte.d.ts +10 -0
- package/dist/components/AuditLogViewer.svelte +3 -1
- package/dist/components/AutoForm.svelte +33 -3
- package/dist/components/AutoForm.svelte.d.ts +1 -0
- package/dist/components/AutoTable.svelte +610 -47
- package/dist/components/AutoTable.svelte.d.ts +17 -1
- package/dist/components/BoundRecordDetailDrawer.svelte +9 -0
- package/dist/components/BoundRecordDetailDrawer.svelte.d.ts +2 -0
- package/dist/components/Breadcrumbs.svelte +11 -1
- package/dist/components/CancelTaskButton.svelte +12 -42
- package/dist/components/ColorPicker.svelte +73 -0
- package/dist/components/ColorPicker.svelte.d.ts +15 -0
- package/dist/components/ComboboxField.svelte +114 -27
- package/dist/components/ComboboxField.svelte.d.ts +1 -0
- package/dist/components/DashboardView.svelte +99 -0
- package/dist/components/DashboardView.svelte.d.ts +14 -0
- package/dist/components/DatePicker.svelte +10 -0
- package/dist/components/DatePicker.svelte.d.ts +6 -0
- package/dist/components/DateRangeInput.svelte +85 -5
- package/dist/components/DateRangeInput.svelte.d.ts +10 -0
- package/dist/components/DateRangePicker.svelte +10 -0
- package/dist/components/DateRangePicker.svelte.d.ts +6 -0
- package/dist/components/DateTimeInput.svelte +85 -16
- package/dist/components/DateTimeInput.svelte.d.ts +19 -11
- package/dist/components/DateTimePicker.svelte +10 -0
- package/dist/components/DateTimePicker.svelte.d.ts +6 -0
- package/dist/components/DevTools.svelte +34 -26
- package/dist/components/DevframePanel.svelte +123 -0
- package/dist/components/DevframePanel.svelte.d.ts +3 -0
- package/dist/components/ErrorSummary.svelte +52 -0
- package/dist/components/ErrorSummary.svelte.d.ts +14 -0
- package/dist/components/FieldRenderer.svelte +82 -81
- package/dist/components/FileUpload.svelte +214 -52
- package/dist/components/FileUpload.svelte.d.ts +11 -0
- package/dist/components/FilterBuilder.svelte +88 -66
- package/dist/components/FilterCollectionInput.svelte +80 -0
- package/dist/components/FilterCollectionInput.svelte.d.ts +10 -0
- package/dist/components/GanttChart.svelte +66 -14
- package/dist/components/GanttChart.svelte.d.ts +6 -0
- package/dist/components/Header.svelte +18 -2
- package/dist/components/ImportWizard.svelte +339 -17
- package/dist/components/ImportWizard.svelte.d.ts +11 -0
- package/dist/components/JsonSchemaForm.svelte +120 -52
- package/dist/components/JsonSchemaForm.svelte.d.ts +7 -1
- package/dist/components/KanbanBoard.svelte +195 -40
- package/dist/components/KanbanBoard.svelte.d.ts +9 -2
- package/dist/components/Layout.svelte +4 -2
- package/dist/components/LazyAutoForm.svelte +28 -0
- package/dist/components/LazyAutoForm.svelte.d.ts +8 -0
- package/dist/components/LazyAutoTable.svelte +28 -0
- package/dist/components/LazyAutoTable.svelte.d.ts +8 -0
- package/dist/components/LazyPage.svelte +3 -3
- package/dist/components/LazyPage.svelte.d.ts +2 -2
- package/dist/components/LazySettingsPage.svelte +28 -0
- package/dist/components/LazySettingsPage.svelte.d.ts +8 -0
- package/dist/components/LazyShowPage.svelte +28 -0
- package/dist/components/LazyShowPage.svelte.d.ts +8 -0
- package/dist/components/ListPage.svelte +5 -1
- package/dist/components/ListPage.svelte.d.ts +3 -0
- package/dist/components/LoginPage.svelte +1 -1
- package/dist/components/MultiTabKeepAlive.svelte +11 -6
- package/dist/components/NotificationsSettings.svelte +69 -2
- package/dist/components/NotificationsSettings.svelte.d.ts +25 -1
- package/dist/components/PasswordInput.svelte +3 -3
- package/dist/components/PasswordInput.svelte.d.ts +2 -1
- package/dist/components/PermissionMatrix.svelte +20 -1
- package/dist/components/PivotExportButton.svelte +157 -0
- package/dist/components/PivotExportButton.svelte.d.ts +16 -0
- package/dist/components/PivotTable.svelte +229 -74
- package/dist/components/PivotTable.svelte.d.ts +19 -2
- package/dist/components/RadioGroup.svelte +121 -0
- package/dist/components/RadioGroup.svelte.d.ts +43 -0
- package/dist/components/RangeSlider.svelte +127 -0
- package/dist/components/RangeSlider.svelte.d.ts +22 -0
- package/dist/components/Rate.svelte +121 -0
- package/dist/components/Rate.svelte.d.ts +16 -0
- package/dist/components/RecordDetailDrawer.svelte +4 -2
- package/dist/components/RecordDetailDrawer.svelte.d.ts +2 -0
- package/dist/components/RelationPicker.svelte +341 -0
- package/dist/components/RelationPicker.svelte.d.ts +26 -0
- package/dist/components/ResourceOperationsPage.svelte +23 -19
- package/dist/components/ResourceOperationsPage.svelte.d.ts +2 -2
- package/dist/components/RetryTaskButton.svelte +12 -42
- package/dist/components/SecuritySettings.svelte +29 -5
- package/dist/components/SegmentedControl.svelte +145 -0
- package/dist/components/SegmentedControl.svelte.d.ts +38 -0
- package/dist/components/SettingsPage.svelte +3 -1
- package/dist/components/SettingsPage.svelte.d.ts +1 -0
- package/dist/components/ShowPage.svelte +18 -3
- package/dist/components/ShowPage.svelte.d.ts +3 -0
- package/dist/components/Sidebar.svelte +2 -2
- package/dist/components/Slider.svelte +100 -0
- package/dist/components/Slider.svelte.d.ts +19 -0
- package/dist/components/SpreadsheetView.svelte +1213 -95
- package/dist/components/SpreadsheetView.svelte.d.ts +19 -0
- package/dist/components/TagsInput.svelte +178 -0
- package/dist/components/TagsInput.svelte.d.ts +17 -0
- package/dist/components/TimePicker.svelte +10 -0
- package/dist/components/TimePicker.svelte.d.ts +6 -0
- package/dist/components/TooltipButton.svelte +3 -4
- package/dist/components/TreeSelect.svelte +267 -53
- package/dist/components/TreeSelect.svelte.d.ts +3 -0
- package/dist/components/TreeTable.svelte +484 -82
- package/dist/components/TreeTable.svelte.d.ts +24 -1
- package/dist/components/TwoFactorAuthPage.svelte +85 -48
- package/dist/components/TwoFactorAuthPage.svelte.d.ts +12 -1
- package/dist/components/VirtualTable.svelte +116 -20
- package/dist/components/VirtualTable.svelte.d.ts +5 -0
- package/dist/components/account/CompanyProfilePage.svelte +74 -38
- package/dist/components/account/GetStartedPage.svelte +2 -1
- package/dist/components/account/ImportMembersPage.svelte +22 -167
- package/dist/components/account/ImportMembersPage.svelte.d.ts +4 -1
- package/dist/components/account/MemberDirectory.svelte +156 -0
- package/dist/components/account/MemberDirectory.svelte.d.ts +19 -0
- package/dist/components/account/MembersStarterPage.svelte +9 -55
- package/dist/components/account/MembersStarterPage.svelte.d.ts +5 -1
- package/dist/components/account/SecurityLogPage.svelte +4 -1
- package/dist/components/account/SettingsPlainPage.svelte +7 -38
- package/dist/components/account/SettingsPlainPage.svelte.d.ts +4 -1
- package/dist/components/account/SettingsSidebarPage.svelte +7 -20
- package/dist/components/account/TeamMembersPage.svelte +4 -20
- package/dist/components/account/TeamMembersPage.svelte.d.ts +5 -1
- package/dist/components/account/UserProfilePage.svelte +3 -25
- package/dist/components/account/UserProfilePage.svelte.d.ts +17 -2
- package/dist/components/buttons/ExportButton.svelte +56 -12
- package/dist/components/buttons/ExportButton.svelte.d.ts +11 -0
- package/dist/components/content/ContentPageHeader.svelte +1 -1
- package/dist/components/content/ContentPageShell.svelte +1 -1
- package/dist/components/content/MetricBlock.svelte +1 -1
- package/dist/components/content/PageToolbar.svelte +1 -1
- package/dist/components/content/ReferenceNotice.svelte +5 -0
- package/dist/components/content/ReferenceNotice.svelte.d.ts +18 -0
- package/dist/components/content/SectionHeader.svelte +1 -1
- package/dist/components/content/SettingsFieldRow.svelte +1 -1
- package/dist/components/content/SettingsGroup.svelte +1 -1
- package/dist/components/content/StatusBadge.svelte +1 -1
- package/dist/components/content/WorkspaceLayout.svelte +1 -1
- package/dist/components/export-reference.d.ts +2 -0
- package/dist/components/export-reference.js +9 -0
- package/dist/components/fieldComponentMap.js +2 -5
- package/dist/components/fields/DateField.svelte +12 -13
- package/dist/components/fields/MarkdownField.svelte +14 -5
- package/dist/components/fields/date-display.d.ts +6 -0
- package/dist/components/fields/date-display.js +24 -0
- package/dist/components/network/TeamCrewTablePage.svelte +6 -1
- package/dist/components/network/UserCardsNFTPage.svelte +2 -0
- package/dist/components/profile/PublicProfilePage.svelte +2 -0
- package/dist/components/saved-list-views.d.ts +74 -1
- package/dist/components/saved-list-views.js +191 -3
- package/dist/components/table-contract.d.ts +12 -1
- package/dist/components/task-action.svelte.d.ts +13 -0
- package/dist/components/task-action.svelte.js +73 -0
- package/dist/components/ui/DesignSystemShowcase.svelte +164 -0
- package/dist/components/ui/DesignSystemShowcase.svelte.d.ts +3 -0
- package/dist/components/ui/badge/badge-variants.d.ts +3 -2
- package/dist/components/ui/badge/badge-variants.js +2 -3
- package/dist/components/ui/badge/badge.svelte +3 -0
- package/dist/components/ui/badge/badge.svelte.d.ts +1 -0
- package/dist/components/ui/button/button-variants.d.ts +5 -4
- package/dist/components/ui/button/button-variants.js +7 -5
- package/dist/components/ui/checkbox/checkbox.svelte +5 -1
- package/dist/components/ui/checkbox/checkbox.svelte.d.ts +5 -1
- package/dist/components/ui/dropdown-menu/dropdown-menu-trigger.svelte +1 -2
- package/dist/components/ui/input/input.svelte +7 -2
- package/dist/components/ui/input/input.svelte.d.ts +4 -1
- package/dist/components/ui/select/select.svelte +4 -1
- package/dist/components/ui/select/select.svelte.d.ts +2 -1
- package/dist/components/ui/textarea/textarea.svelte +2 -2
- package/dist/components.css +33 -2
- package/dist/date-input-policy.d.ts +4 -0
- package/dist/date-input-policy.js +35 -0
- package/dist/design-system-components.d.ts +100 -0
- package/dist/design-system-components.js +101 -0
- package/dist/design-system.js +1 -1
- package/dist/devtools-bridge.d.ts +80 -0
- package/dist/devtools-bridge.js +92 -0
- package/dist/editor-config.svelte.d.ts +4 -2
- package/dist/index.d.ts +37 -2
- package/dist/index.js +23 -2
- package/dist/recipes.d.ts +960 -4
- package/dist/recipes.js +264 -4
- package/dist/tree-table-model.d.ts +24 -0
- package/dist/tree-table-model.js +111 -0
- package/dist/types.d.ts +4 -4
- package/package.json +22 -10
- package/dist/styled-system/css/conditions.js +0 -36
- package/dist/styled-system/css/css.d.ts +0 -22
- package/dist/styled-system/css/css.js +0 -45
- package/dist/styled-system/css/cva.d.ts +0 -6
- package/dist/styled-system/css/cva.js +0 -87
- package/dist/styled-system/css/cx.d.ts +0 -5
- package/dist/styled-system/css/cx.js +0 -15
- package/dist/styled-system/css/index.d.ts +0 -5
- package/dist/styled-system/css/index.js +0 -4
- package/dist/styled-system/css/sva.d.ts +0 -4
- package/dist/styled-system/css/sva.js +0 -46
- package/dist/styled-system/helpers.js +0 -316
- package/dist/styled-system/patterns/aspect-ratio.d.ts +0 -20
- package/dist/styled-system/patterns/aspect-ratio.js +0 -38
- package/dist/styled-system/patterns/bleed.d.ts +0 -21
- package/dist/styled-system/patterns/bleed.js +0 -24
- package/dist/styled-system/patterns/box.d.ts +0 -20
- package/dist/styled-system/patterns/box.js +0 -15
- package/dist/styled-system/patterns/center.d.ts +0 -20
- package/dist/styled-system/patterns/center.js +0 -21
- package/dist/styled-system/patterns/circle.d.ts +0 -20
- package/dist/styled-system/patterns/circle.js +0 -25
- package/dist/styled-system/patterns/container.d.ts +0 -20
- package/dist/styled-system/patterns/container.js +0 -21
- package/dist/styled-system/patterns/cq.d.ts +0 -21
- package/dist/styled-system/patterns/cq.js +0 -21
- package/dist/styled-system/patterns/divider.d.ts +0 -22
- package/dist/styled-system/patterns/divider.js +0 -25
- package/dist/styled-system/patterns/flex.d.ts +0 -26
- package/dist/styled-system/patterns/flex.js +0 -26
- package/dist/styled-system/patterns/float.d.ts +0 -23
- package/dist/styled-system/patterns/float.js +0 -52
- package/dist/styled-system/patterns/grid-item.d.ts +0 -25
- package/dist/styled-system/patterns/grid-item.js +0 -25
- package/dist/styled-system/patterns/grid.d.ts +0 -24
- package/dist/styled-system/patterns/grid.js +0 -27
- package/dist/styled-system/patterns/hstack.d.ts +0 -21
- package/dist/styled-system/patterns/hstack.js +0 -24
- package/dist/styled-system/patterns/index.d.ts +0 -21
- package/dist/styled-system/patterns/index.js +0 -20
- package/dist/styled-system/patterns/link-overlay.d.ts +0 -20
- package/dist/styled-system/patterns/link-overlay.js +0 -24
- package/dist/styled-system/patterns/spacer.d.ts +0 -20
- package/dist/styled-system/patterns/spacer.js +0 -25
- package/dist/styled-system/patterns/square.d.ts +0 -20
- package/dist/styled-system/patterns/square.js +0 -24
- package/dist/styled-system/patterns/stack.d.ts +0 -23
- package/dist/styled-system/patterns/stack.js +0 -24
- package/dist/styled-system/patterns/visually-hidden.d.ts +0 -20
- package/dist/styled-system/patterns/visually-hidden.js +0 -18
- package/dist/styled-system/patterns/vstack.d.ts +0 -21
- package/dist/styled-system/patterns/vstack.js +0 -24
- package/dist/styled-system/patterns/wrap.d.ts +0 -24
- package/dist/styled-system/patterns/wrap.js +0 -25
- package/dist/styled-system/recipes/content-header.d.ts +0 -31
- package/dist/styled-system/recipes/content-header.js +0 -65
- package/dist/styled-system/recipes/content-page.d.ts +0 -34
- package/dist/styled-system/recipes/content-page.js +0 -43
- package/dist/styled-system/recipes/create-recipe.js +0 -82
- package/dist/styled-system/recipes/index.d.ts +0 -17
- package/dist/styled-system/recipes/index.js +0 -16
- package/dist/styled-system/recipes/metric-block.d.ts +0 -34
- package/dist/styled-system/recipes/metric-block.js +0 -76
- package/dist/styled-system/recipes/product-list.d.ts +0 -31
- package/dist/styled-system/recipes/product-list.js +0 -73
- package/dist/styled-system/recipes/product-section.d.ts +0 -31
- package/dist/styled-system/recipes/product-section.js +0 -49
- package/dist/styled-system/recipes/product-settings-row.d.ts +0 -34
- package/dist/styled-system/recipes/product-settings-row.js +0 -58
- package/dist/styled-system/recipes/product-settings.d.ts +0 -31
- package/dist/styled-system/recipes/product-settings.js +0 -57
- package/dist/styled-system/recipes/product-status.d.ts +0 -34
- package/dist/styled-system/recipes/product-status.js +0 -45
- package/dist/styled-system/recipes/product-toolbar.d.ts +0 -31
- package/dist/styled-system/recipes/product-toolbar.js +0 -41
- package/dist/styled-system/recipes/product-workspace.d.ts +0 -34
- package/dist/styled-system/recipes/product-workspace.js +0 -58
- package/dist/styled-system/recipes/surface-metric.d.ts +0 -38
- package/dist/styled-system/recipes/surface-metric.js +0 -63
- package/dist/styled-system/recipes/surface-table.d.ts +0 -34
- package/dist/styled-system/recipes/surface-table.js +0 -62
- package/dist/styled-system/recipes/ui-badge.d.ts +0 -31
- package/dist/styled-system/recipes/ui-badge.js +0 -38
- package/dist/styled-system/recipes/ui-button.d.ts +0 -32
- package/dist/styled-system/recipes/ui-button.js +0 -43
- package/dist/styled-system/recipes/ui-input.d.ts +0 -31
- package/dist/styled-system/recipes/ui-input.js +0 -49
- package/dist/styled-system/recipes/ui-textarea.d.ts +0 -31
- package/dist/styled-system/recipes/ui-textarea.js +0 -24
- package/dist/styled-system/styles.css +0 -1257
- package/dist/styled-system/tokens/index.d.ts +0 -9
- package/dist/styled-system/tokens/index.js +0 -268
- package/dist/styled-system/tokens/tokens.d.ts +0 -36
- package/dist/styled-system/types/composition.d.ts +0 -227
- package/dist/styled-system/types/conditions.d.ts +0 -236
- package/dist/styled-system/types/csstype.d.ts +0 -22570
- package/dist/styled-system/types/index.d.ts +0 -6
- package/dist/styled-system/types/parts.d.ts +0 -8
- package/dist/styled-system/types/pattern.d.ts +0 -78
- package/dist/styled-system/types/prop-type.d.ts +0 -223
- package/dist/styled-system/types/recipe.d.ts +0 -181
- package/dist/styled-system/types/selectors.d.ts +0 -59
- package/dist/styled-system/types/static-css.d.ts +0 -56
- package/dist/styled-system/types/style-props.d.ts +0 -8088
- package/dist/styled-system/types/system-types.d.ts +0 -151
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface CircleProperties {
|
|
9
|
-
size?: SystemProperties["width"]
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
interface CircleStyles extends CircleProperties, DistributiveOmit<SystemStyleObject, keyof CircleProperties > {}
|
|
13
|
-
|
|
14
|
-
interface CirclePatternFn {
|
|
15
|
-
(styles?: CircleStyles): string
|
|
16
|
-
raw: (styles?: CircleStyles) => SystemStyleObject
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
export declare const circle: CirclePatternFn;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const circleConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
const { size, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
display: "flex",
|
|
9
|
-
alignItems: "center",
|
|
10
|
-
justifyContent: "center",
|
|
11
|
-
flex: "0 0 auto",
|
|
12
|
-
width: size,
|
|
13
|
-
height: size,
|
|
14
|
-
borderRadius: "9999px",
|
|
15
|
-
...rest
|
|
16
|
-
};
|
|
17
|
-
}}
|
|
18
|
-
|
|
19
|
-
export const getCircleStyle = (styles = {}) => {
|
|
20
|
-
const _styles = getPatternStyles(circleConfig, styles)
|
|
21
|
-
return circleConfig.transform(_styles, patternFns)
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export const circle = (styles) => css(getCircleStyle(styles))
|
|
25
|
-
circle.raw = getCircleStyle
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface ContainerProperties {
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
interface ContainerStyles extends ContainerProperties, DistributiveOmit<SystemStyleObject, keyof ContainerProperties > {}
|
|
13
|
-
|
|
14
|
-
interface ContainerPatternFn {
|
|
15
|
-
(styles?: ContainerStyles): string
|
|
16
|
-
raw: (styles?: ContainerStyles) => SystemStyleObject
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
export declare const container: ContainerPatternFn;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const containerConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
return {
|
|
7
|
-
position: "relative",
|
|
8
|
-
maxWidth: "8xl",
|
|
9
|
-
mx: "auto",
|
|
10
|
-
px: { base: "4", md: "6", lg: "8" },
|
|
11
|
-
...props
|
|
12
|
-
};
|
|
13
|
-
}}
|
|
14
|
-
|
|
15
|
-
export const getContainerStyle = (styles = {}) => {
|
|
16
|
-
const _styles = getPatternStyles(containerConfig, styles)
|
|
17
|
-
return containerConfig.transform(_styles, patternFns)
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export const container = (styles) => css(getContainerStyle(styles))
|
|
21
|
-
container.raw = getContainerStyle
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface CqProperties {
|
|
9
|
-
name?: ConditionalValue<Tokens["containerNames"] | Properties["containerName"]>
|
|
10
|
-
type?: SystemProperties["containerType"]
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
interface CqStyles extends CqProperties, DistributiveOmit<SystemStyleObject, keyof CqProperties > {}
|
|
14
|
-
|
|
15
|
-
interface CqPatternFn {
|
|
16
|
-
(styles?: CqStyles): string
|
|
17
|
-
raw: (styles?: CqStyles) => SystemStyleObject
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
export declare const cq: CqPatternFn;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const cqConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
const { name, type, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
containerType: type,
|
|
9
|
-
containerName: name,
|
|
10
|
-
...rest
|
|
11
|
-
};
|
|
12
|
-
},
|
|
13
|
-
defaultValues:{type:'inline-size'}}
|
|
14
|
-
|
|
15
|
-
export const getCqStyle = (styles = {}) => {
|
|
16
|
-
const _styles = getPatternStyles(cqConfig, styles)
|
|
17
|
-
return cqConfig.transform(_styles, patternFns)
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export const cq = (styles) => css(getCqStyle(styles))
|
|
21
|
-
cq.raw = getCqStyle
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface DividerProperties {
|
|
9
|
-
orientation?: ConditionalValue<"horizontal" | "vertical">
|
|
10
|
-
thickness?: ConditionalValue<Tokens["sizes"] | Properties["borderWidth"]>
|
|
11
|
-
color?: ConditionalValue<Tokens["colors"] | Properties["borderColor"]>
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
interface DividerStyles extends DividerProperties, DistributiveOmit<SystemStyleObject, keyof DividerProperties > {}
|
|
15
|
-
|
|
16
|
-
interface DividerPatternFn {
|
|
17
|
-
(styles?: DividerStyles): string
|
|
18
|
-
raw: (styles?: DividerStyles) => SystemStyleObject
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
export declare const divider: DividerPatternFn;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const dividerConfig = {
|
|
5
|
-
transform(props, { map }) {
|
|
6
|
-
const { orientation, thickness, color, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
"--thickness": thickness,
|
|
9
|
-
width: map(orientation, (v) => v === "vertical" ? void 0 : "100%"),
|
|
10
|
-
height: map(orientation, (v) => v === "horizontal" ? void 0 : "100%"),
|
|
11
|
-
borderBlockEndWidth: map(orientation, (v) => v === "horizontal" ? "var(--thickness)" : void 0),
|
|
12
|
-
borderInlineEndWidth: map(orientation, (v) => v === "vertical" ? "var(--thickness)" : void 0),
|
|
13
|
-
borderColor: color,
|
|
14
|
-
...rest
|
|
15
|
-
};
|
|
16
|
-
},
|
|
17
|
-
defaultValues:{orientation:'horizontal',thickness:'1px'}}
|
|
18
|
-
|
|
19
|
-
export const getDividerStyle = (styles = {}) => {
|
|
20
|
-
const _styles = getPatternStyles(dividerConfig, styles)
|
|
21
|
-
return dividerConfig.transform(_styles, patternFns)
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export const divider = (styles) => css(getDividerStyle(styles))
|
|
25
|
-
divider.raw = getDividerStyle
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface FlexProperties {
|
|
9
|
-
align?: SystemProperties["alignItems"]
|
|
10
|
-
justify?: SystemProperties["justifyContent"]
|
|
11
|
-
direction?: SystemProperties["flexDirection"]
|
|
12
|
-
wrap?: SystemProperties["flexWrap"]
|
|
13
|
-
basis?: SystemProperties["flexBasis"]
|
|
14
|
-
grow?: SystemProperties["flexGrow"]
|
|
15
|
-
shrink?: SystemProperties["flexShrink"]
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
interface FlexStyles extends FlexProperties, DistributiveOmit<SystemStyleObject, keyof FlexProperties > {}
|
|
19
|
-
|
|
20
|
-
interface FlexPatternFn {
|
|
21
|
-
(styles?: FlexStyles): string
|
|
22
|
-
raw: (styles?: FlexStyles) => SystemStyleObject
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
export declare const flex: FlexPatternFn;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const flexConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
const { direction, align, justify, wrap: wrap2, basis, grow, shrink, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
display: "flex",
|
|
9
|
-
flexDirection: direction,
|
|
10
|
-
alignItems: align,
|
|
11
|
-
justifyContent: justify,
|
|
12
|
-
flexWrap: wrap2,
|
|
13
|
-
flexBasis: basis,
|
|
14
|
-
flexGrow: grow,
|
|
15
|
-
flexShrink: shrink,
|
|
16
|
-
...rest
|
|
17
|
-
};
|
|
18
|
-
}}
|
|
19
|
-
|
|
20
|
-
export const getFlexStyle = (styles = {}) => {
|
|
21
|
-
const _styles = getPatternStyles(flexConfig, styles)
|
|
22
|
-
return flexConfig.transform(_styles, patternFns)
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export const flex = (styles) => css(getFlexStyle(styles))
|
|
26
|
-
flex.raw = getFlexStyle
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface FloatProperties {
|
|
9
|
-
offsetX?: ConditionalValue<Tokens["spacing"] | Properties["left"]>
|
|
10
|
-
offsetY?: ConditionalValue<Tokens["spacing"] | Properties["top"]>
|
|
11
|
-
offset?: ConditionalValue<Tokens["spacing"] | Properties["top"]>
|
|
12
|
-
placement?: ConditionalValue<"bottom-end" | "bottom-start" | "top-end" | "top-start" | "bottom-center" | "top-center" | "middle-center" | "middle-end" | "middle-start">
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
interface FloatStyles extends FloatProperties, DistributiveOmit<SystemStyleObject, keyof FloatProperties > {}
|
|
16
|
-
|
|
17
|
-
interface FloatPatternFn {
|
|
18
|
-
(styles?: FloatStyles): string
|
|
19
|
-
raw: (styles?: FloatStyles) => SystemStyleObject
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
export declare const float: FloatPatternFn;
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const floatConfig = {
|
|
5
|
-
transform(props, { map }) {
|
|
6
|
-
const { offset, offsetX, offsetY, placement, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
display: "inline-flex",
|
|
9
|
-
justifyContent: "center",
|
|
10
|
-
alignItems: "center",
|
|
11
|
-
position: "absolute",
|
|
12
|
-
insetBlockStart: map(placement, (v) => {
|
|
13
|
-
const [side] = v.split("-");
|
|
14
|
-
const map2 = { top: offsetY, middle: "50%", bottom: "auto" };
|
|
15
|
-
return map2[side];
|
|
16
|
-
}),
|
|
17
|
-
insetBlockEnd: map(placement, (v) => {
|
|
18
|
-
const [side] = v.split("-");
|
|
19
|
-
const map2 = { top: "auto", middle: "50%", bottom: offsetY };
|
|
20
|
-
return map2[side];
|
|
21
|
-
}),
|
|
22
|
-
insetInlineStart: map(placement, (v) => {
|
|
23
|
-
const [, align] = v.split("-");
|
|
24
|
-
const map2 = { start: offsetX, center: "50%", end: "auto" };
|
|
25
|
-
return map2[align];
|
|
26
|
-
}),
|
|
27
|
-
insetInlineEnd: map(placement, (v) => {
|
|
28
|
-
const [, align] = v.split("-");
|
|
29
|
-
const map2 = { start: "auto", center: "50%", end: offsetX };
|
|
30
|
-
return map2[align];
|
|
31
|
-
}),
|
|
32
|
-
translate: map(placement, (v) => {
|
|
33
|
-
const [side, align] = v.split("-");
|
|
34
|
-
const mapX = { start: "-50%", center: "-50%", end: "50%" };
|
|
35
|
-
const mapY = { top: "-50%", middle: "-50%", bottom: "50%" };
|
|
36
|
-
return `${mapX[align]} ${mapY[side]}`;
|
|
37
|
-
}),
|
|
38
|
-
...rest
|
|
39
|
-
};
|
|
40
|
-
},
|
|
41
|
-
defaultValues(props) {
|
|
42
|
-
const offset = props.offset || "0";
|
|
43
|
-
return { offset, offsetX: offset, offsetY: offset, placement: "top-end" };
|
|
44
|
-
}}
|
|
45
|
-
|
|
46
|
-
export const getFloatStyle = (styles = {}) => {
|
|
47
|
-
const _styles = getPatternStyles(floatConfig, styles)
|
|
48
|
-
return floatConfig.transform(_styles, patternFns)
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
export const float = (styles) => css(getFloatStyle(styles))
|
|
52
|
-
float.raw = getFloatStyle
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface GridItemProperties {
|
|
9
|
-
colSpan?: ConditionalValue<number>
|
|
10
|
-
rowSpan?: ConditionalValue<number>
|
|
11
|
-
colStart?: ConditionalValue<number>
|
|
12
|
-
rowStart?: ConditionalValue<number>
|
|
13
|
-
colEnd?: ConditionalValue<number>
|
|
14
|
-
rowEnd?: ConditionalValue<number>
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
interface GridItemStyles extends GridItemProperties, DistributiveOmit<SystemStyleObject, keyof GridItemProperties > {}
|
|
18
|
-
|
|
19
|
-
interface GridItemPatternFn {
|
|
20
|
-
(styles?: GridItemStyles): string
|
|
21
|
-
raw: (styles?: GridItemStyles) => SystemStyleObject
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
export declare const gridItem: GridItemPatternFn;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const gridItemConfig = {
|
|
5
|
-
transform(props, { map }) {
|
|
6
|
-
const { colSpan, rowSpan, colStart, rowStart, colEnd, rowEnd, ...rest } = props;
|
|
7
|
-
const spanFn = (v) => v === "auto" ? v : `span ${v}`;
|
|
8
|
-
return {
|
|
9
|
-
gridColumn: colSpan != null ? map(colSpan, spanFn) : void 0,
|
|
10
|
-
gridRow: rowSpan != null ? map(rowSpan, spanFn) : void 0,
|
|
11
|
-
gridColumnStart: colStart,
|
|
12
|
-
gridColumnEnd: colEnd,
|
|
13
|
-
gridRowStart: rowStart,
|
|
14
|
-
gridRowEnd: rowEnd,
|
|
15
|
-
...rest
|
|
16
|
-
};
|
|
17
|
-
}}
|
|
18
|
-
|
|
19
|
-
export const getGridItemStyle = (styles = {}) => {
|
|
20
|
-
const _styles = getPatternStyles(gridItemConfig, styles)
|
|
21
|
-
return gridItemConfig.transform(_styles, patternFns)
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export const gridItem = (styles) => css(getGridItemStyle(styles))
|
|
25
|
-
gridItem.raw = getGridItemStyle
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface GridProperties {
|
|
9
|
-
gap?: SystemProperties["gap"]
|
|
10
|
-
columnGap?: SystemProperties["gap"]
|
|
11
|
-
rowGap?: SystemProperties["gap"]
|
|
12
|
-
columns?: ConditionalValue<number>
|
|
13
|
-
minChildWidth?: ConditionalValue<Tokens["sizes"] | Properties["width"]>
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
interface GridStyles extends GridProperties, DistributiveOmit<SystemStyleObject, keyof GridProperties > {}
|
|
17
|
-
|
|
18
|
-
interface GridPatternFn {
|
|
19
|
-
(styles?: GridStyles): string
|
|
20
|
-
raw: (styles?: GridStyles) => SystemStyleObject
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
export declare const grid: GridPatternFn;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const gridConfig = {
|
|
5
|
-
transform(props, { map, isCssUnit }) {
|
|
6
|
-
const { columnGap, rowGap, gap, columns, minChildWidth, ...rest } = props;
|
|
7
|
-
const getValue = (v) => isCssUnit(v) ? v : `token(sizes.${v}, ${v})`;
|
|
8
|
-
return {
|
|
9
|
-
display: "grid",
|
|
10
|
-
gridTemplateColumns: columns != null ? map(columns, (v) => `repeat(${v}, minmax(0, 1fr))`) : minChildWidth != null ? map(minChildWidth, (v) => `repeat(auto-fit, minmax(${getValue(v)}, 1fr))`) : void 0,
|
|
11
|
-
gap,
|
|
12
|
-
columnGap,
|
|
13
|
-
rowGap,
|
|
14
|
-
...rest
|
|
15
|
-
};
|
|
16
|
-
},
|
|
17
|
-
defaultValues(props) {
|
|
18
|
-
return { gap: props.columnGap || props.rowGap ? void 0 : "8px" };
|
|
19
|
-
}}
|
|
20
|
-
|
|
21
|
-
export const getGridStyle = (styles = {}) => {
|
|
22
|
-
const _styles = getPatternStyles(gridConfig, styles)
|
|
23
|
-
return gridConfig.transform(_styles, patternFns)
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
export const grid = (styles) => css(getGridStyle(styles))
|
|
27
|
-
grid.raw = getGridStyle
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface HstackProperties {
|
|
9
|
-
justify?: SystemProperties["justifyContent"]
|
|
10
|
-
gap?: SystemProperties["gap"]
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
interface HstackStyles extends HstackProperties, DistributiveOmit<SystemStyleObject, keyof HstackProperties > {}
|
|
14
|
-
|
|
15
|
-
interface HstackPatternFn {
|
|
16
|
-
(styles?: HstackStyles): string
|
|
17
|
-
raw: (styles?: HstackStyles) => SystemStyleObject
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
export declare const hstack: HstackPatternFn;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const hstackConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
const { justify, gap, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
display: "flex",
|
|
9
|
-
alignItems: "center",
|
|
10
|
-
justifyContent: justify,
|
|
11
|
-
gap,
|
|
12
|
-
flexDirection: "row",
|
|
13
|
-
...rest
|
|
14
|
-
};
|
|
15
|
-
},
|
|
16
|
-
defaultValues:{gap:'8px'}}
|
|
17
|
-
|
|
18
|
-
export const getHstackStyle = (styles = {}) => {
|
|
19
|
-
const _styles = getPatternStyles(hstackConfig, styles)
|
|
20
|
-
return hstackConfig.transform(_styles, patternFns)
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export const hstack = (styles) => css(getHstackStyle(styles))
|
|
24
|
-
hstack.raw = getHstackStyle
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
export * from './box';
|
|
3
|
-
export * from './flex';
|
|
4
|
-
export * from './stack';
|
|
5
|
-
export * from './vstack';
|
|
6
|
-
export * from './hstack';
|
|
7
|
-
export * from './spacer';
|
|
8
|
-
export * from './square';
|
|
9
|
-
export * from './circle';
|
|
10
|
-
export * from './center';
|
|
11
|
-
export * from './link-overlay';
|
|
12
|
-
export * from './aspect-ratio';
|
|
13
|
-
export * from './grid';
|
|
14
|
-
export * from './grid-item';
|
|
15
|
-
export * from './wrap';
|
|
16
|
-
export * from './container';
|
|
17
|
-
export * from './divider';
|
|
18
|
-
export * from './float';
|
|
19
|
-
export * from './bleed';
|
|
20
|
-
export * from './visually-hidden';
|
|
21
|
-
export * from './cq';
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
export * from './box.js';
|
|
2
|
-
export * from './flex.js';
|
|
3
|
-
export * from './stack.js';
|
|
4
|
-
export * from './vstack.js';
|
|
5
|
-
export * from './hstack.js';
|
|
6
|
-
export * from './spacer.js';
|
|
7
|
-
export * from './square.js';
|
|
8
|
-
export * from './circle.js';
|
|
9
|
-
export * from './center.js';
|
|
10
|
-
export * from './link-overlay.js';
|
|
11
|
-
export * from './aspect-ratio.js';
|
|
12
|
-
export * from './grid.js';
|
|
13
|
-
export * from './grid-item.js';
|
|
14
|
-
export * from './wrap.js';
|
|
15
|
-
export * from './container.js';
|
|
16
|
-
export * from './divider.js';
|
|
17
|
-
export * from './float.js';
|
|
18
|
-
export * from './bleed.js';
|
|
19
|
-
export * from './visually-hidden.js';
|
|
20
|
-
export * from './cq.js';
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface LinkOverlayProperties {
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
interface LinkOverlayStyles extends LinkOverlayProperties, DistributiveOmit<SystemStyleObject, keyof LinkOverlayProperties > {}
|
|
13
|
-
|
|
14
|
-
interface LinkOverlayPatternFn {
|
|
15
|
-
(styles?: LinkOverlayStyles): string
|
|
16
|
-
raw: (styles?: LinkOverlayStyles) => SystemStyleObject
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
export declare const linkOverlay: LinkOverlayPatternFn;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const linkOverlayConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
return {
|
|
7
|
-
_before: {
|
|
8
|
-
content: '""',
|
|
9
|
-
position: "absolute",
|
|
10
|
-
inset: "0",
|
|
11
|
-
zIndex: "0",
|
|
12
|
-
...props["_before"]
|
|
13
|
-
},
|
|
14
|
-
...props
|
|
15
|
-
};
|
|
16
|
-
}}
|
|
17
|
-
|
|
18
|
-
export const getLinkOverlayStyle = (styles = {}) => {
|
|
19
|
-
const _styles = getPatternStyles(linkOverlayConfig, styles)
|
|
20
|
-
return linkOverlayConfig.transform(_styles, patternFns)
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export const linkOverlay = (styles) => css(getLinkOverlayStyle(styles))
|
|
24
|
-
linkOverlay.raw = getLinkOverlayStyle
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface SpacerProperties {
|
|
9
|
-
size?: ConditionalValue<Tokens["spacing"]>
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
interface SpacerStyles extends SpacerProperties, DistributiveOmit<SystemStyleObject, keyof SpacerProperties > {}
|
|
13
|
-
|
|
14
|
-
interface SpacerPatternFn {
|
|
15
|
-
(styles?: SpacerStyles): string
|
|
16
|
-
raw: (styles?: SpacerStyles) => SystemStyleObject
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
export declare const spacer: SpacerPatternFn;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const spacerConfig = {
|
|
5
|
-
transform(props, { map, isCssUnit, isCssVar }) {
|
|
6
|
-
const { size, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
alignSelf: "stretch",
|
|
9
|
-
justifySelf: "stretch",
|
|
10
|
-
flex: map(size, (v) => {
|
|
11
|
-
if (v == null) return "1";
|
|
12
|
-
const val = isCssUnit(v) || isCssVar(v) ? v : `token(spacing.${v}, ${v})`;
|
|
13
|
-
return `0 0 ${val}`;
|
|
14
|
-
}),
|
|
15
|
-
...rest
|
|
16
|
-
};
|
|
17
|
-
}}
|
|
18
|
-
|
|
19
|
-
export const getSpacerStyle = (styles = {}) => {
|
|
20
|
-
const _styles = getPatternStyles(spacerConfig, styles)
|
|
21
|
-
return spacerConfig.transform(_styles, patternFns)
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export const spacer = (styles) => css(getSpacerStyle(styles))
|
|
25
|
-
spacer.raw = getSpacerStyle
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
-
import type { Properties } from '../types/csstype';
|
|
4
|
-
import type { SystemProperties } from '../types/style-props';
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
-
import type { Tokens } from '../tokens/index';
|
|
7
|
-
|
|
8
|
-
export interface SquareProperties {
|
|
9
|
-
size?: SystemProperties["width"]
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
interface SquareStyles extends SquareProperties, DistributiveOmit<SystemStyleObject, keyof SquareProperties > {}
|
|
13
|
-
|
|
14
|
-
interface SquarePatternFn {
|
|
15
|
-
(styles?: SquareStyles): string
|
|
16
|
-
raw: (styles?: SquareStyles) => SystemStyleObject
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
export declare const square: SquarePatternFn;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const squareConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
const { size, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
display: "flex",
|
|
9
|
-
alignItems: "center",
|
|
10
|
-
justifyContent: "center",
|
|
11
|
-
flex: "0 0 auto",
|
|
12
|
-
width: size,
|
|
13
|
-
height: size,
|
|
14
|
-
...rest
|
|
15
|
-
};
|
|
16
|
-
}}
|
|
17
|
-
|
|
18
|
-
export const getSquareStyle = (styles = {}) => {
|
|
19
|
-
const _styles = getPatternStyles(squareConfig, styles)
|
|
20
|
-
return squareConfig.transform(_styles, patternFns)
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export const square = (styles) => css(getSquareStyle(styles))
|
|
24
|
-
square.raw = getSquareStyle
|