@pathscale/ui 1.1.39 → 1.1.42
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/dist/components/accordion/Accordion.js +29 -30
- package/dist/components/alert/Alert.classes.d.ts +16 -0
- package/dist/components/alert/Alert.classes.js +17 -0
- package/dist/components/alert/Alert.js +17 -27
- package/dist/components/avatar/Avatar.classes.d.ts +27 -0
- package/dist/components/avatar/Avatar.classes.js +28 -0
- package/dist/components/avatar/Avatar.js +11 -28
- package/dist/components/avatar/AvatarGroup.js +10 -10
- package/dist/components/badge/Badge.classes.d.ts +30 -0
- package/dist/components/badge/Badge.classes.js +31 -0
- package/dist/components/badge/Badge.js +14 -38
- package/dist/components/breadcrumbs/Breadcrumbs.js +34 -23
- package/dist/components/button/Button.js +24 -11
- package/dist/components/button-group/ButtonGroup.js +7 -8
- package/dist/components/calendar/Calendar.js +191 -103
- package/dist/components/card/Card.js +12 -16
- package/dist/components/chatbubble/ChatBubble.js +4 -4
- package/dist/components/chatbubble/ChatBubbleAvatar.js +6 -6
- package/dist/components/chatbubble/ChatBubbleFooter.js +3 -5
- package/dist/components/chatbubble/ChatBubbleHeader.js +3 -5
- package/dist/components/chatbubble/ChatBubbleTime.js +3 -5
- package/dist/components/checkbox/Checkbox.classes.d.ts +17 -0
- package/dist/components/checkbox/Checkbox.classes.js +18 -0
- package/dist/components/checkbox/Checkbox.js +56 -31
- package/dist/components/chip/Chip.classes.d.ts +29 -0
- package/dist/components/chip/Chip.classes.js +30 -0
- package/dist/components/chip/Chip.js +42 -46
- package/dist/components/close-button/CloseButton.js +16 -8
- package/dist/components/color-area/ColorArea.classes.d.ts +6 -0
- package/dist/components/color-area/ColorArea.classes.js +7 -0
- package/dist/components/color-area/ColorArea.js +23 -19
- package/dist/components/color-field/ColorField.classes.d.ts +13 -0
- package/dist/components/color-field/ColorField.classes.js +14 -0
- package/dist/components/color-field/ColorField.js +34 -24
- package/dist/components/color-picker/ColorPicker.classes.d.ts +8 -0
- package/dist/components/color-picker/ColorPicker.classes.js +9 -0
- package/dist/components/color-picker/ColorPicker.js +26 -28
- package/dist/components/color-slider/ColorSlider.classes.d.ts +11 -0
- package/dist/components/color-slider/ColorSlider.classes.js +12 -0
- package/dist/components/color-slider/ColorSlider.js +24 -15
- package/dist/components/color-swatch/ColorSwatch.classes.d.ts +14 -0
- package/dist/components/color-swatch/ColorSwatch.classes.js +15 -0
- package/dist/components/color-swatch/ColorSwatch.js +2 -12
- package/dist/components/color-swatch-picker/ColorSwatchPicker.classes.d.ts +3 -0
- package/dist/components/color-swatch-picker/ColorSwatchPicker.classes.js +4 -0
- package/dist/components/color-swatch-picker/ColorSwatchPicker.js +4 -4
- package/dist/components/color-wheel-flower/ColorWheelFlower.js +76 -67
- package/dist/components/combo-box/ComboBox.js +95 -79
- package/dist/components/date-field/DateField.js +22 -28
- package/dist/components/date-picker/DatePicker.js +65 -44
- package/dist/components/date-range-picker/DateRangePicker.js +76 -48
- package/dist/components/description/Description.js +3 -4
- package/dist/components/drawer/Drawer.classes.d.ts +28 -0
- package/dist/components/drawer/Drawer.classes.js +29 -0
- package/dist/components/drawer/Drawer.js +55 -50
- package/dist/components/dropdown/Dropdown.classes.d.ts +11 -0
- package/dist/components/dropdown/Dropdown.classes.js +12 -0
- package/dist/components/dropdown/Dropdown.js +40 -35
- package/dist/components/empty-state/EmptyState.classes.d.ts +9 -0
- package/dist/components/empty-state/EmptyState.classes.js +10 -0
- package/dist/components/empty-state/EmptyState.js +20 -23
- package/dist/components/error-message/ErrorMessage.js +3 -4
- package/dist/components/field-error/FieldError.js +3 -4
- package/dist/components/fieldset/Fieldset.js +12 -16
- package/dist/components/flex/Flex.js +3 -4
- package/dist/components/floating-dock/FloatingDock.js +152 -144
- package/dist/components/footer/Footer.js +3 -4
- package/dist/components/footer/FooterTitle.js +3 -4
- package/dist/components/form/Form.js +3 -4
- package/dist/components/glass-panel/GlassPanel.js +37 -36
- package/dist/components/grid/Grid.js +3 -4
- package/dist/components/header/Header.js +3 -4
- package/dist/components/icon/Icon.js +3 -4
- package/dist/components/immersive-landing/ImmersiveLanding.js +21 -24
- package/dist/components/immersive-landing/ImmersiveLandingArrows.js +25 -11
- package/dist/components/immersive-landing/ImmersiveLandingNavigation.js +67 -41
- package/dist/components/immersive-landing/ImmersiveLandingPage.js +7 -5
- package/dist/components/immersive-landing/components/CookieConsent.js +110 -110
- package/dist/components/immersive-landing/components/FirefoxPWABanner.js +61 -56
- package/dist/components/immersive-landing/components/PWAInstallPrompt.js +66 -62
- package/dist/components/input/Input.classes.d.ts +24 -0
- package/dist/components/input/Input.classes.js +25 -0
- package/dist/components/input/Input.js +50 -42
- package/dist/components/input-group/InputGroup.js +15 -20
- package/dist/components/input-otp/InputOTP.js +63 -54
- package/dist/components/join/Join.classes.d.ts +8 -0
- package/dist/components/join/Join.classes.js +9 -0
- package/dist/components/join/Join.js +8 -8
- package/dist/components/kbd/Kbd.js +9 -12
- package/dist/components/language-switcher/LanguageSwitcher.js +29 -28
- package/dist/components/link/Link.js +17 -10
- package/dist/components/list-box/ListBoxItem.js +8 -8
- package/dist/components/list-box/ListBoxSection.js +10 -6
- package/dist/components/live-chat/LiveChatBubble.js +25 -9
- package/dist/components/live-chat/LiveChatPanel.js +78 -62
- package/dist/components/menu/Menu.js +4 -4
- package/dist/components/menu/MenuItem.js +12 -12
- package/dist/components/menu/MenuSection.js +10 -6
- package/dist/components/modal/Modal.js +62 -58
- package/dist/components/navbar/Navbar.js +4 -4
- package/dist/components/navbar/NavbarRow.js +3 -4
- package/dist/components/navbar/NavbarSection.js +4 -4
- package/dist/components/navbar/NavbarStack.js +3 -4
- package/dist/components/noise-background/NoiseBackground.js +39 -35
- package/dist/components/number-field/NumberField.js +18 -20
- package/dist/components/pagination/Pagination.classes.d.ts +11 -0
- package/dist/components/pagination/Pagination.classes.js +12 -0
- package/dist/components/pagination/Pagination.js +77 -33
- package/dist/components/progress-bar/ProgressBar.classes.d.ts +23 -0
- package/dist/components/progress-bar/ProgressBar.classes.js +24 -0
- package/dist/components/progress-bar/ProgressBar.css +104 -0
- package/dist/components/progress-bar/ProgressBar.d.ts +19 -0
- package/dist/components/progress-bar/ProgressBar.js +112 -0
- package/dist/components/progress-bar/index.d.ts +2 -0
- package/dist/components/progress-bar/index.js +3 -0
- package/dist/components/progress-circle/ProgressCircle.classes.d.ts +22 -0
- package/dist/components/progress-circle/ProgressCircle.classes.js +23 -0
- package/dist/components/progress-circle/ProgressCircle.css +82 -0
- package/dist/components/progress-circle/ProgressCircle.d.ts +18 -0
- package/dist/components/progress-circle/ProgressCircle.js +109 -0
- package/dist/components/progress-circle/index.d.ts +2 -0
- package/dist/components/progress-circle/index.js +3 -0
- package/dist/components/radio/Radio.classes.d.ts +13 -0
- package/dist/components/radio/Radio.classes.js +14 -0
- package/dist/components/radio/Radio.js +49 -22
- package/dist/components/radio-group/RadioGroup.classes.d.ts +21 -0
- package/dist/components/radio-group/RadioGroup.classes.js +22 -0
- package/dist/components/radio-group/RadioGroup.js +31 -19
- package/dist/components/search-field/SearchField.js +16 -20
- package/dist/components/select/Select.classes.d.ts +24 -0
- package/dist/components/select/Select.classes.js +25 -0
- package/dist/components/select/Select.js +110 -52
- package/dist/components/size-picker/SizePicker.classes.d.ts +3 -0
- package/dist/components/size-picker/SizePicker.classes.js +4 -0
- package/dist/components/size-picker/SizePicker.js +7 -6
- package/dist/components/skeleton/Skeleton.classes.d.ts +8 -0
- package/dist/components/skeleton/Skeleton.classes.js +9 -0
- package/dist/components/skeleton/Skeleton.js +4 -9
- package/dist/components/slider/Slider.js +90 -60
- package/dist/components/spinner/Spinner.classes.d.ts +25 -0
- package/dist/components/spinner/Spinner.classes.js +26 -0
- package/dist/components/{loading/Loading.d.ts → spinner/Spinner.d.ts} +4 -4
- package/dist/components/{loading/Loading.js → spinner/Spinner.js} +6 -27
- package/dist/components/spinner/index.d.ts +1 -0
- package/dist/components/spinner/index.js +5 -0
- package/dist/components/surface/Surface.js +3 -4
- package/dist/components/table/Table.classes.d.ts +26 -0
- package/dist/components/table/Table.classes.js +27 -0
- package/dist/components/table/Table.js +107 -111
- package/dist/components/tabs/Tabs.classes.d.ts +14 -0
- package/dist/components/tabs/Tabs.classes.js +15 -0
- package/dist/components/tabs/Tabs.js +43 -43
- package/dist/components/tag/Tag.js +19 -12
- package/dist/components/tag-group/TagGroup.js +8 -8
- package/dist/components/text/Text.js +3 -4
- package/dist/components/textarea/Textarea.classes.d.ts +3 -0
- package/dist/components/textarea/Textarea.classes.js +4 -0
- package/dist/components/textarea/Textarea.js +4 -5
- package/dist/components/theme-color-picker/ThemeColorPicker.classes.d.ts +10 -0
- package/dist/components/theme-color-picker/ThemeColorPicker.classes.js +11 -0
- package/dist/components/theme-color-picker/ThemeColorPicker.js +42 -33
- package/dist/components/time-field/TimeField.js +22 -28
- package/dist/components/toast/Toast.js +109 -56
- package/dist/components/toggle/Toggle.classes.d.ts +26 -0
- package/dist/components/toggle/Toggle.classes.js +27 -0
- package/dist/components/toggle/Toggle.js +55 -36
- package/dist/components/tooltip/Tooltip.classes.d.ts +8 -0
- package/dist/components/tooltip/Tooltip.classes.js +9 -0
- package/dist/components/tooltip/Tooltip.js +24 -25
- package/dist/components/utils.js +6 -4
- package/dist/components/video-preview/VideoPreview.classes.d.ts +3 -0
- package/dist/components/video-preview/VideoPreview.classes.js +4 -0
- package/dist/components/video-preview/VideoPreview.js +5 -4
- package/dist/index.css +0 -1
- package/dist/index.d.ts +7 -6
- package/dist/index.js +8 -20
- package/dist/purge-manifest.json +2469 -1433
- package/package.json +3 -3
- package/dist/components/artboard/Artboard.d.ts +0 -9
- package/dist/components/artboard/Artboard.js +0 -42
- package/dist/components/artboard/index.d.ts +0 -1
- package/dist/components/artboard/index.js +0 -3
- package/dist/components/loading/index.d.ts +0 -1
- package/dist/components/loading/index.js +0 -3
- package/dist/components/progress/Progress.css +0 -135
- package/dist/components/progress/Progress.d.ts +0 -36
- package/dist/components/progress/Progress.js +0 -197
- package/dist/components/progress/index.d.ts +0 -1
- package/dist/components/progress/index.js +0 -7
- package/dist/components/radialprogress/RadialProgress.d.ts +0 -10
- package/dist/components/radialprogress/RadialProgress.js +0 -47
- package/dist/components/radialprogress/index.d.ts +0 -1
- package/dist/components/radialprogress/index.js +0 -3
- package/dist/components/sidenav/Sidenav.css +0 -176
- package/dist/components/sidenav/Sidenav.d.ts +0 -14
- package/dist/components/sidenav/Sidenav.js +0 -66
- package/dist/components/sidenav/SidenavButton.d.ts +0 -9
- package/dist/components/sidenav/SidenavButton.js +0 -41
- package/dist/components/sidenav/SidenavGroup.d.ts +0 -10
- package/dist/components/sidenav/SidenavGroup.js +0 -45
- package/dist/components/sidenav/SidenavItem.d.ts +0 -8
- package/dist/components/sidenav/SidenavItem.js +0 -37
- package/dist/components/sidenav/SidenavLink.d.ts +0 -9
- package/dist/components/sidenav/SidenavLink.js +0 -36
- package/dist/components/sidenav/SidenavMenu.d.ts +0 -5
- package/dist/components/sidenav/SidenavMenu.js +0 -31
- package/dist/components/sidenav/index.d.ts +0 -12
- package/dist/components/sidenav/index.js +0 -13
- /package/dist/components/{loading/Loading.css → spinner/Spinner.css} +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pathscale/ui",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.42",
|
|
4
4
|
"author": "pathscale",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -81,13 +81,13 @@
|
|
|
81
81
|
"solid-js": "^1.9.7",
|
|
82
82
|
"svgo": "^3.3.2",
|
|
83
83
|
"tailwind-merge": "^3.3.0",
|
|
84
|
-
"typescript": "^5.8.3"
|
|
85
|
-
"valibot": "^1.0.0"
|
|
84
|
+
"typescript": "^5.8.3"
|
|
86
85
|
},
|
|
87
86
|
"dependencies": {
|
|
88
87
|
"@iconify/tailwind4": "^1.2.1",
|
|
89
88
|
"@pathscale/ui": "^1.1.11",
|
|
90
89
|
"@tanstack/solid-virtual": "^3.13.23",
|
|
90
|
+
"valibot": "^1.0.0",
|
|
91
91
|
"rsbuild-plugin-iconify": "^1.0.3"
|
|
92
92
|
},
|
|
93
93
|
"peerDependencies": {
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { type ParentComponent } from "solid-js";
|
|
2
|
-
import type { IComponentBaseProps } from "../types";
|
|
3
|
-
export type ArtboardProps = IComponentBaseProps & {
|
|
4
|
-
demo?: boolean;
|
|
5
|
-
size?: 1 | 2 | 3 | 4 | 5 | 6;
|
|
6
|
-
horizontal?: boolean;
|
|
7
|
-
};
|
|
8
|
-
declare const Artboard: ParentComponent<ArtboardProps>;
|
|
9
|
-
export default Artboard;
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import * as __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__ from "solid-js/web";
|
|
2
|
-
import * as __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__ from "solid-js";
|
|
3
|
-
import * as __WEBPACK_EXTERNAL_MODULE_clsx__ from "clsx";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__ from "tailwind-merge";
|
|
5
|
-
var _tmpl$ = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.template)("<div>");
|
|
6
|
-
const Artboard = (props)=>{
|
|
7
|
-
const [local, others] = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.splitProps)(props, [
|
|
8
|
-
"children",
|
|
9
|
-
"demo",
|
|
10
|
-
"size",
|
|
11
|
-
"horizontal",
|
|
12
|
-
"dataTheme",
|
|
13
|
-
"class",
|
|
14
|
-
"className"
|
|
15
|
-
]);
|
|
16
|
-
const resolvedChildren = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.children)(()=>local.children);
|
|
17
|
-
const classes = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.createMemo)(()=>(0, __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__.twMerge)("artboard", local.class, local.className, (0, __WEBPACK_EXTERNAL_MODULE_clsx__["default"])({
|
|
18
|
-
"artboard-demo": local.demo ?? true,
|
|
19
|
-
"phone-1": 1 === local.size,
|
|
20
|
-
"phone-2": 2 === local.size,
|
|
21
|
-
"phone-3": 3 === local.size,
|
|
22
|
-
"phone-4": 4 === local.size,
|
|
23
|
-
"phone-5": 5 === local.size,
|
|
24
|
-
"phone-6": 6 === local.size,
|
|
25
|
-
horizontal: local.horizontal
|
|
26
|
-
})));
|
|
27
|
-
return (()=>{
|
|
28
|
-
var _el$ = _tmpl$();
|
|
29
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.spread)(_el$, (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.mergeProps)(others, {
|
|
30
|
-
get ["data-theme"] () {
|
|
31
|
-
return local.dataTheme;
|
|
32
|
-
},
|
|
33
|
-
get ["class"] () {
|
|
34
|
-
return classes();
|
|
35
|
-
}
|
|
36
|
-
}), false, true);
|
|
37
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.insert)(_el$, resolvedChildren);
|
|
38
|
-
return _el$;
|
|
39
|
-
})();
|
|
40
|
-
};
|
|
41
|
-
const artboard_Artboard = Artboard;
|
|
42
|
-
export { artboard_Artboard as default };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default, type ArtboardProps } from "./Artboard";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default, type LoadingProps, type SpinnerSize, type SpinnerColor, type SpinnerVariant, } from "./Loading";
|
|
@@ -1,135 +0,0 @@
|
|
|
1
|
-
@layer components {
|
|
2
|
-
/* -------------------------------------------------------------------------------------------------
|
|
3
|
-
* Root
|
|
4
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
5
|
-
.progress-bar {
|
|
6
|
-
display: grid;
|
|
7
|
-
width: 100%;
|
|
8
|
-
gap: 0.25rem;
|
|
9
|
-
grid-template-areas:
|
|
10
|
-
"label output"
|
|
11
|
-
"track track";
|
|
12
|
-
grid-template-columns: 1fr auto;
|
|
13
|
-
|
|
14
|
-
--progress-bar-fill: var(--color-accent);
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
.progress-bar [data-slot="label"] {
|
|
18
|
-
grid-area: label;
|
|
19
|
-
width: fit-content;
|
|
20
|
-
font-size: 0.875rem;
|
|
21
|
-
font-weight: 500;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/* -------------------------------------------------------------------------------------------------
|
|
25
|
-
* Output
|
|
26
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
27
|
-
.progress-bar__output {
|
|
28
|
-
grid-area: output;
|
|
29
|
-
font-size: 0.875rem;
|
|
30
|
-
font-weight: 500;
|
|
31
|
-
font-variant-numeric: tabular-nums;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
/* -------------------------------------------------------------------------------------------------
|
|
35
|
-
* Track
|
|
36
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
37
|
-
.progress-bar__track {
|
|
38
|
-
grid-area: track;
|
|
39
|
-
position: relative;
|
|
40
|
-
overflow: hidden;
|
|
41
|
-
border-radius: 9999px;
|
|
42
|
-
background-color: var(--color-base-200);
|
|
43
|
-
height: 0.5rem;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
/* -------------------------------------------------------------------------------------------------
|
|
47
|
-
* Fill
|
|
48
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
49
|
-
.progress-bar__fill {
|
|
50
|
-
position: absolute;
|
|
51
|
-
top: 0;
|
|
52
|
-
left: 0;
|
|
53
|
-
height: 100%;
|
|
54
|
-
border-radius: 9999px;
|
|
55
|
-
background-color: var(--progress-bar-fill);
|
|
56
|
-
transition: width 300ms ease-out;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
@media (prefers-reduced-motion: reduce) {
|
|
60
|
-
.progress-bar__fill {
|
|
61
|
-
transition: none;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
/* -------------------------------------------------------------------------------------------------
|
|
66
|
-
* Indeterminate
|
|
67
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
68
|
-
.progress-bar:not([aria-valuenow]) .progress-bar__fill {
|
|
69
|
-
width: 40%;
|
|
70
|
-
animation: progress-bar-indeterminate 1.5s cubic-bezier(0.65, 0, 0.35, 1) infinite;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
@media (prefers-reduced-motion: reduce) {
|
|
74
|
-
.progress-bar:not([aria-valuenow]) .progress-bar__fill {
|
|
75
|
-
animation: none;
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
@keyframes progress-bar-indeterminate {
|
|
80
|
-
0% {
|
|
81
|
-
transform: translateX(-100%);
|
|
82
|
-
}
|
|
83
|
-
100% {
|
|
84
|
-
transform: translateX(350%);
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
/* -------------------------------------------------------------------------------------------------
|
|
89
|
-
* Disabled
|
|
90
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
91
|
-
.progress-bar[data-disabled="true"] {
|
|
92
|
-
opacity: 0.55;
|
|
93
|
-
cursor: not-allowed;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.progress-bar[data-disabled="true"] [data-slot="label"] {
|
|
97
|
-
opacity: 1;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
/* -------------------------------------------------------------------------------------------------
|
|
101
|
-
* Size variants
|
|
102
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
103
|
-
.progress-bar--sm .progress-bar__track {
|
|
104
|
-
height: 0.25rem;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
/* md is default */
|
|
108
|
-
|
|
109
|
-
.progress-bar--lg .progress-bar__track {
|
|
110
|
-
height: 0.75rem;
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
/* -------------------------------------------------------------------------------------------------
|
|
114
|
-
* Color variants
|
|
115
|
-
* -----------------------------------------------------------------------------------------------*/
|
|
116
|
-
.progress-bar--default {
|
|
117
|
-
--progress-bar-fill: var(--color-base-content);
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
.progress-bar--accent {
|
|
121
|
-
--progress-bar-fill: var(--color-accent);
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
.progress-bar--success {
|
|
125
|
-
--progress-bar-fill: var(--color-success);
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
.progress-bar--warning {
|
|
129
|
-
--progress-bar-fill: var(--color-warning);
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
.progress-bar--danger {
|
|
133
|
-
--progress-bar-fill: var(--color-error);
|
|
134
|
-
}
|
|
135
|
-
}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import "./Progress.css";
|
|
2
|
-
import { type Component, type JSX, type ParentComponent } from "solid-js";
|
|
3
|
-
import type { IComponentBaseProps } from "../types";
|
|
4
|
-
export type ProgressSize = "sm" | "md" | "lg";
|
|
5
|
-
export type ProgressColor = "default" | "accent" | "success" | "warning" | "danger";
|
|
6
|
-
export type ProgressRootProps = Omit<JSX.HTMLAttributes<HTMLDivElement>, "children"> & IComponentBaseProps & {
|
|
7
|
-
children: JSX.Element;
|
|
8
|
-
value?: number;
|
|
9
|
-
minValue?: number;
|
|
10
|
-
maxValue?: number;
|
|
11
|
-
isIndeterminate?: boolean;
|
|
12
|
-
label?: string;
|
|
13
|
-
size?: ProgressSize;
|
|
14
|
-
color?: ProgressColor;
|
|
15
|
-
isDisabled?: boolean;
|
|
16
|
-
formatValue?: (value: number) => string;
|
|
17
|
-
};
|
|
18
|
-
export type ProgressOutputProps = Omit<JSX.HTMLAttributes<HTMLSpanElement>, "children"> & IComponentBaseProps & {
|
|
19
|
-
children?: JSX.Element;
|
|
20
|
-
};
|
|
21
|
-
export type ProgressTrackProps = Omit<JSX.HTMLAttributes<HTMLDivElement>, "children"> & IComponentBaseProps & {
|
|
22
|
-
children: JSX.Element;
|
|
23
|
-
};
|
|
24
|
-
export type ProgressFillProps = JSX.HTMLAttributes<HTMLDivElement> & IComponentBaseProps;
|
|
25
|
-
declare const ProgressRoot: ParentComponent<ProgressRootProps>;
|
|
26
|
-
declare const ProgressOutput: Component<ProgressOutputProps>;
|
|
27
|
-
declare const ProgressTrack: ParentComponent<ProgressTrackProps>;
|
|
28
|
-
declare const ProgressFill: Component<ProgressFillProps>;
|
|
29
|
-
declare const Progress: ParentComponent<ProgressRootProps> & {
|
|
30
|
-
Root: ParentComponent<ProgressRootProps>;
|
|
31
|
-
Output: Component<ProgressOutputProps>;
|
|
32
|
-
Track: ParentComponent<ProgressTrackProps>;
|
|
33
|
-
Fill: Component<ProgressFillProps>;
|
|
34
|
-
};
|
|
35
|
-
export default Progress;
|
|
36
|
-
export { ProgressRoot, ProgressOutput, ProgressTrack, ProgressFill };
|
|
@@ -1,197 +0,0 @@
|
|
|
1
|
-
import * as __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__ from "solid-js/web";
|
|
2
|
-
import "./Progress.css";
|
|
3
|
-
import * as __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__ from "solid-js";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__ from "tailwind-merge";
|
|
5
|
-
var _tmpl$ = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.template)("<div>"), _tmpl$2 = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.template)("<span data-slot=label>"), _tmpl$3 = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.template)("<span>");
|
|
6
|
-
const ProgressContext = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.createContext)();
|
|
7
|
-
const useProgressContext = ()=>{
|
|
8
|
-
const ctx = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.useContext)(ProgressContext);
|
|
9
|
-
if (!ctx) throw new Error("Progress compound components must be used within <Progress>");
|
|
10
|
-
return ctx;
|
|
11
|
-
};
|
|
12
|
-
const SIZE_CLASS_MAP = {
|
|
13
|
-
sm: "progress-bar--sm",
|
|
14
|
-
md: "",
|
|
15
|
-
lg: "progress-bar--lg"
|
|
16
|
-
};
|
|
17
|
-
const COLOR_CLASS_MAP = {
|
|
18
|
-
default: "progress-bar--default",
|
|
19
|
-
accent: "progress-bar--accent",
|
|
20
|
-
success: "progress-bar--success",
|
|
21
|
-
warning: "progress-bar--warning",
|
|
22
|
-
danger: "progress-bar--danger"
|
|
23
|
-
};
|
|
24
|
-
const ProgressRoot = (props)=>{
|
|
25
|
-
const [local, others] = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.splitProps)(props, [
|
|
26
|
-
"children",
|
|
27
|
-
"class",
|
|
28
|
-
"className",
|
|
29
|
-
"value",
|
|
30
|
-
"minValue",
|
|
31
|
-
"maxValue",
|
|
32
|
-
"isIndeterminate",
|
|
33
|
-
"label",
|
|
34
|
-
"size",
|
|
35
|
-
"color",
|
|
36
|
-
"isDisabled",
|
|
37
|
-
"formatValue",
|
|
38
|
-
"dataTheme",
|
|
39
|
-
"style"
|
|
40
|
-
]);
|
|
41
|
-
const min = ()=>local.minValue ?? 0;
|
|
42
|
-
const max = ()=>local.maxValue ?? 100;
|
|
43
|
-
const isIndeterminate = ()=>Boolean(local.isIndeterminate);
|
|
44
|
-
const percentage = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.createMemo)(()=>{
|
|
45
|
-
if (isIndeterminate() || void 0 === local.value) return 0;
|
|
46
|
-
const clamped = Math.min(Math.max(local.value, min()), max());
|
|
47
|
-
return (clamped - min()) / (max() - min()) * 100;
|
|
48
|
-
});
|
|
49
|
-
const valueText = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.createMemo)(()=>{
|
|
50
|
-
if (isIndeterminate()) return "";
|
|
51
|
-
if (local.formatValue && void 0 !== local.value) return local.formatValue(local.value);
|
|
52
|
-
return `${Math.round(percentage())}%`;
|
|
53
|
-
});
|
|
54
|
-
const ctx = {
|
|
55
|
-
percentage,
|
|
56
|
-
isIndeterminate,
|
|
57
|
-
valueText
|
|
58
|
-
};
|
|
59
|
-
return (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.createComponent)(ProgressContext.Provider, {
|
|
60
|
-
value: ctx,
|
|
61
|
-
get children () {
|
|
62
|
-
var _el$ = _tmpl$();
|
|
63
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.spread)(_el$, (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.mergeProps)(others, {
|
|
64
|
-
role: "progressbar",
|
|
65
|
-
get ["class"] () {
|
|
66
|
-
return (0, __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__.twMerge)("progress-bar", SIZE_CLASS_MAP[local.size ?? "md"], COLOR_CLASS_MAP[local.color ?? "accent"], local.class, local.className);
|
|
67
|
-
},
|
|
68
|
-
"data-slot": "progress-bar",
|
|
69
|
-
get ["data-theme"] () {
|
|
70
|
-
return local.dataTheme;
|
|
71
|
-
},
|
|
72
|
-
get style () {
|
|
73
|
-
return local.style;
|
|
74
|
-
},
|
|
75
|
-
get ["aria-valuenow"] () {
|
|
76
|
-
return isIndeterminate() ? void 0 : local.value;
|
|
77
|
-
},
|
|
78
|
-
get ["aria-valuemin"] () {
|
|
79
|
-
return min();
|
|
80
|
-
},
|
|
81
|
-
get ["aria-valuemax"] () {
|
|
82
|
-
return max();
|
|
83
|
-
},
|
|
84
|
-
get ["aria-valuetext"] () {
|
|
85
|
-
return (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.memo)(()=>!!isIndeterminate())() ? void 0 : valueText();
|
|
86
|
-
},
|
|
87
|
-
get ["aria-label"] () {
|
|
88
|
-
return local.label;
|
|
89
|
-
},
|
|
90
|
-
get ["aria-disabled"] () {
|
|
91
|
-
return local.isDisabled ? "true" : void 0;
|
|
92
|
-
},
|
|
93
|
-
get ["data-disabled"] () {
|
|
94
|
-
return local.isDisabled ? "true" : void 0;
|
|
95
|
-
}
|
|
96
|
-
}), false, true);
|
|
97
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.insert)(_el$, (()=>{
|
|
98
|
-
var _c$ = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.memo)(()=>!!local.label);
|
|
99
|
-
return ()=>_c$() && (()=>{
|
|
100
|
-
var _el$2 = _tmpl$2();
|
|
101
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.insert)(_el$2, ()=>local.label);
|
|
102
|
-
return _el$2;
|
|
103
|
-
})();
|
|
104
|
-
})(), null);
|
|
105
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.insert)(_el$, ()=>local.children, null);
|
|
106
|
-
return _el$;
|
|
107
|
-
}
|
|
108
|
-
});
|
|
109
|
-
};
|
|
110
|
-
const ProgressOutput = (props)=>{
|
|
111
|
-
const [local, others] = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.splitProps)(props, [
|
|
112
|
-
"children",
|
|
113
|
-
"class",
|
|
114
|
-
"className",
|
|
115
|
-
"dataTheme",
|
|
116
|
-
"style"
|
|
117
|
-
]);
|
|
118
|
-
const ctx = useProgressContext();
|
|
119
|
-
return (()=>{
|
|
120
|
-
var _el$3 = _tmpl$3();
|
|
121
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.spread)(_el$3, (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.mergeProps)(others, {
|
|
122
|
-
get ["class"] () {
|
|
123
|
-
return (0, __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__.twMerge)("progress-bar__output", local.class, local.className);
|
|
124
|
-
},
|
|
125
|
-
"data-slot": "progress-bar-output",
|
|
126
|
-
get ["data-theme"] () {
|
|
127
|
-
return local.dataTheme;
|
|
128
|
-
},
|
|
129
|
-
get style () {
|
|
130
|
-
return local.style;
|
|
131
|
-
}
|
|
132
|
-
}), false, true);
|
|
133
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.insert)(_el$3, ()=>local.children ?? ctx.valueText());
|
|
134
|
-
return _el$3;
|
|
135
|
-
})();
|
|
136
|
-
};
|
|
137
|
-
const ProgressTrack = (props)=>{
|
|
138
|
-
const [local, others] = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.splitProps)(props, [
|
|
139
|
-
"children",
|
|
140
|
-
"class",
|
|
141
|
-
"className",
|
|
142
|
-
"dataTheme",
|
|
143
|
-
"style"
|
|
144
|
-
]);
|
|
145
|
-
return (()=>{
|
|
146
|
-
var _el$4 = _tmpl$();
|
|
147
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.spread)(_el$4, (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.mergeProps)(others, {
|
|
148
|
-
get ["class"] () {
|
|
149
|
-
return (0, __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__.twMerge)("progress-bar__track", local.class, local.className);
|
|
150
|
-
},
|
|
151
|
-
"data-slot": "progress-bar-track",
|
|
152
|
-
get ["data-theme"] () {
|
|
153
|
-
return local.dataTheme;
|
|
154
|
-
},
|
|
155
|
-
get style () {
|
|
156
|
-
return local.style;
|
|
157
|
-
}
|
|
158
|
-
}), false, true);
|
|
159
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.insert)(_el$4, ()=>local.children);
|
|
160
|
-
return _el$4;
|
|
161
|
-
})();
|
|
162
|
-
};
|
|
163
|
-
const ProgressFill = (props)=>{
|
|
164
|
-
const [local, others] = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.splitProps)(props, [
|
|
165
|
-
"class",
|
|
166
|
-
"className",
|
|
167
|
-
"dataTheme",
|
|
168
|
-
"style"
|
|
169
|
-
]);
|
|
170
|
-
const ctx = useProgressContext();
|
|
171
|
-
return (()=>{
|
|
172
|
-
var _el$5 = _tmpl$();
|
|
173
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.spread)(_el$5, (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.mergeProps)(others, {
|
|
174
|
-
get ["class"] () {
|
|
175
|
-
return (0, __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__.twMerge)("progress-bar__fill", local.class, local.className);
|
|
176
|
-
},
|
|
177
|
-
"data-slot": "progress-bar-fill",
|
|
178
|
-
get ["data-theme"] () {
|
|
179
|
-
return local.dataTheme;
|
|
180
|
-
},
|
|
181
|
-
get style () {
|
|
182
|
-
return Object.assign({}, local.style, ctx.isIndeterminate() ? void 0 : {
|
|
183
|
-
width: `${ctx.percentage()}%`
|
|
184
|
-
});
|
|
185
|
-
}
|
|
186
|
-
}), false, false);
|
|
187
|
-
return _el$5;
|
|
188
|
-
})();
|
|
189
|
-
};
|
|
190
|
-
const Progress = Object.assign(ProgressRoot, {
|
|
191
|
-
Root: ProgressRoot,
|
|
192
|
-
Output: ProgressOutput,
|
|
193
|
-
Track: ProgressTrack,
|
|
194
|
-
Fill: ProgressFill
|
|
195
|
-
});
|
|
196
|
-
const progress_Progress = Progress;
|
|
197
|
-
export { ProgressFill, ProgressOutput, ProgressRoot, ProgressTrack, progress_Progress as default };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default, ProgressRoot, ProgressOutput, ProgressTrack, ProgressFill, type ProgressSize, type ProgressColor, type ProgressRootProps, type ProgressOutputProps, type ProgressTrackProps, type ProgressFillProps, } from "./Progress";
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as __WEBPACK_EXTERNAL_MODULE__Progress_js_2910ac00__ from "./Progress.js";
|
|
2
|
-
var __webpack_exports__ProgressFill = __WEBPACK_EXTERNAL_MODULE__Progress_js_2910ac00__.ProgressFill;
|
|
3
|
-
var __webpack_exports__ProgressOutput = __WEBPACK_EXTERNAL_MODULE__Progress_js_2910ac00__.ProgressOutput;
|
|
4
|
-
var __webpack_exports__ProgressRoot = __WEBPACK_EXTERNAL_MODULE__Progress_js_2910ac00__.ProgressRoot;
|
|
5
|
-
var __webpack_exports__ProgressTrack = __WEBPACK_EXTERNAL_MODULE__Progress_js_2910ac00__.ProgressTrack;
|
|
6
|
-
var __webpack_exports__default = __WEBPACK_EXTERNAL_MODULE__Progress_js_2910ac00__["default"];
|
|
7
|
-
export { __webpack_exports__ProgressFill as ProgressFill, __webpack_exports__ProgressOutput as ProgressOutput, __webpack_exports__ProgressRoot as ProgressRoot, __webpack_exports__ProgressTrack as ProgressTrack, __webpack_exports__default as default };
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { JSX } from "solid-js";
|
|
2
|
-
import type { IComponentBaseProps, ComponentColor } from "../types";
|
|
3
|
-
export type RadialProgressProps = JSX.HTMLAttributes<HTMLDivElement> & IComponentBaseProps & {
|
|
4
|
-
value: number;
|
|
5
|
-
size?: string;
|
|
6
|
-
thickness?: string;
|
|
7
|
-
color?: ComponentColor;
|
|
8
|
-
};
|
|
9
|
-
declare const RadialProgress: (props: RadialProgressProps) => JSX.Element;
|
|
10
|
-
export default RadialProgress;
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import * as __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__ from "solid-js/web";
|
|
2
|
-
import * as __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__ from "solid-js";
|
|
3
|
-
import * as __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__ from "tailwind-merge";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_clsx__ from "clsx";
|
|
5
|
-
var _tmpl$ = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.template)("<div role=progressbar aria-valuemin=0 aria-valuemax=100>");
|
|
6
|
-
const RadialProgress = (props)=>{
|
|
7
|
-
const [local, others] = (0, __WEBPACK_EXTERNAL_MODULE_solid_js_aeefcc6d__.splitProps)(props, [
|
|
8
|
-
"value",
|
|
9
|
-
"size",
|
|
10
|
-
"thickness",
|
|
11
|
-
"color",
|
|
12
|
-
"dataTheme",
|
|
13
|
-
"class",
|
|
14
|
-
"className",
|
|
15
|
-
"children"
|
|
16
|
-
]);
|
|
17
|
-
const displayedValue = Math.min(100, Math.max(0, local.value));
|
|
18
|
-
const classes = (0, __WEBPACK_EXTERNAL_MODULE_tailwind_merge_e05e3e95__.twMerge)("radial-progress", (0, __WEBPACK_EXTERNAL_MODULE_clsx__["default"])({
|
|
19
|
-
"text-primary": "primary" === local.color,
|
|
20
|
-
"text-secondary": "secondary" === local.color,
|
|
21
|
-
"text-accent": "accent" === local.color,
|
|
22
|
-
"text-info": "info" === local.color,
|
|
23
|
-
"text-success": "success" === local.color,
|
|
24
|
-
"text-warning": "warning" === local.color,
|
|
25
|
-
"text-error": "error" === local.color
|
|
26
|
-
}), local.class, local.className);
|
|
27
|
-
const progressStyle = {
|
|
28
|
-
"--value": displayedValue,
|
|
29
|
-
"--size": local.size ?? "4rem",
|
|
30
|
-
"--thickness": local.thickness ?? "4px"
|
|
31
|
-
};
|
|
32
|
-
return (()=>{
|
|
33
|
-
var _el$ = _tmpl$();
|
|
34
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.setAttribute)(_el$, "aria-valuenow", displayedValue);
|
|
35
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.className)(_el$, classes);
|
|
36
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.spread)(_el$, (0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.mergeProps)({
|
|
37
|
-
get ["data-theme"] () {
|
|
38
|
-
return local.dataTheme;
|
|
39
|
-
}
|
|
40
|
-
}, others), false, true);
|
|
41
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.insert)(_el$, ()=>local.children ?? `${displayedValue}%`);
|
|
42
|
-
(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.effect)((_$p)=>(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d951b7__.style)(_el$, progressStyle, _$p));
|
|
43
|
-
return _el$;
|
|
44
|
-
})();
|
|
45
|
-
};
|
|
46
|
-
const radialprogress_RadialProgress = RadialProgress;
|
|
47
|
-
export { radialprogress_RadialProgress as default };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default, type RadialProgressProps } from "./RadialProgress";
|