@luxalgo/vela-ui 0.3.0 → 0.4.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/CHANGELOG.md +153 -132
- package/LICENSE +201 -201
- package/NOTICE +28 -28
- package/README.md +86 -86
- package/cli/engine.mjs +282 -282
- package/cli/index.mjs +154 -154
- package/dist/callout-bubble.js +2 -2
- package/dist/checkbox.js +2 -2
- package/dist/{chunk-KKS6NEGI.js → chunk-BWSOMG3G.js} +1 -1
- package/dist/chunk-GUIYFQ27.js +30 -0
- package/dist/{chunk-B2EZB5ZG.js → chunk-KUWTI2PE.js} +2 -2
- package/dist/{chunk-WWHNUKSZ.js → chunk-QGWAN3EP.js} +2 -2
- package/dist/{chunk-TBXUF5YX.js → chunk-RH53NQGE.js} +18 -4
- package/dist/{chunk-IOOYDSSK.js → chunk-SKFAYTDK.js} +1 -1
- package/dist/{chunk-OQXFQMZM.js → chunk-TGJNHUYV.js} +2 -2
- package/dist/{chunk-UEO6W37Z.js → chunk-VC7SVSDK.js} +1 -1
- package/dist/{chunk-OJ2SEMN6.js → chunk-YT2BSP7O.js} +1 -1
- package/dist/collapsible.js +1 -1
- package/dist/color-picker.js +4 -4
- package/dist/context-menu.js +3 -3
- package/dist/dialog.js +3 -3
- package/dist/donut.d.ts +1 -1
- package/dist/drawer.js +1 -1
- package/dist/dropdown-menu.js +3 -3
- package/dist/field.js +8 -8
- package/dist/{stat.d.ts → figure.d.ts} +9 -9
- package/dist/figure.js +41 -0
- package/dist/glyph-select.js +3 -3
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/manifest.json +74 -74
- package/dist/number-input.js +2 -2
- package/dist/popover.js +2 -2
- package/dist/select.d.ts +1 -1
- package/dist/select.js +4 -4
- package/dist/slider.js +1 -1
- package/dist/sort-button.js +1 -1
- package/dist/switch.js +1 -1
- package/dist/tabs.js +1 -1
- package/dist/{theme-Ct-q58xz.d.ts → theme-TefB8vtl.d.ts} +2 -2
- package/dist/theme.d.ts +2 -2
- package/dist/theme.js +1 -1
- package/dist/theme.schema.json +30 -30
- package/dist/toast.d.ts +2 -2
- package/dist/toast.js +1 -1
- package/dist/toggle-group.js +1 -1
- package/dist/tooltip.js +1 -1
- package/dist/zag.d.ts +11 -2
- package/dist/zag.js +1 -1
- package/docs/theming.md +217 -217
- package/docs/what-to-change.md +20 -20
- package/docs/writing-a-component.md +250 -250
- package/llms.txt +3 -3
- package/package.json +90 -90
- package/registry/badge.ts +119 -119
- package/registry/bar-chart.ts +215 -215
- package/registry/button.ts +387 -387
- package/registry/callout-bubble.ts +347 -347
- package/registry/card.ts +379 -379
- package/registry/checkbox.ts +234 -234
- package/registry/collapsible.ts +271 -271
- package/registry/color-picker.ts +582 -582
- package/registry/context-menu.ts +208 -208
- package/registry/data-table.ts +215 -215
- package/registry/date-picker.ts +483 -483
- package/registry/dialog.ts +551 -551
- package/registry/donut.ts +145 -145
- package/registry/drawer.ts +636 -636
- package/registry/dropdown-menu.ts +762 -762
- package/registry/empty.ts +91 -91
- package/registry/field.ts +584 -584
- package/registry/{stat.ts → figure.ts} +96 -96
- package/registry/glyph-select.ts +268 -268
- package/registry/hover-card.ts +222 -222
- package/registry/input-group.ts +229 -229
- package/registry/input.ts +181 -181
- package/registry/item.ts +376 -376
- package/registry/kbd.ts +64 -64
- package/registry/line-chart.ts +218 -218
- package/registry/month-grid.ts +328 -328
- package/registry/number-input.ts +443 -443
- package/registry/popover.ts +368 -368
- package/registry/scatter-chart.ts +221 -221
- package/registry/select.ts +620 -620
- package/registry/slider.ts +259 -259
- package/registry/sort-button.ts +189 -189
- package/registry/sparkline.ts +114 -114
- package/registry/switch.ts +205 -205
- package/registry/tabs.ts +426 -426
- package/registry/text-area.ts +186 -186
- package/registry/toast.ts +965 -965
- package/registry/toggle-group.ts +295 -295
- package/registry/tooltip.ts +156 -156
- package/registry/treemap.ts +847 -847
- package/skills/theming-vela-ui/SKILL.md +137 -137
- package/skills/using-vela-ui-components/SKILL.md +139 -139
- package/skills/writing-vela-ui-components/SKILL.md +163 -163
- package/src/components/badge.ts +119 -119
- package/src/components/bar-chart.ts +215 -215
- package/src/components/button.ts +387 -387
- package/src/components/callout-bubble.ts +347 -347
- package/src/components/card.ts +379 -379
- package/src/components/checkbox.ts +234 -234
- package/src/components/collapsible.ts +271 -271
- package/src/components/color-picker.ts +582 -582
- package/src/components/context-menu.ts +208 -208
- package/src/components/data-table.ts +215 -215
- package/src/components/date-picker.ts +483 -483
- package/src/components/dialog.ts +551 -551
- package/src/components/donut.ts +145 -145
- package/src/components/drawer.ts +636 -636
- package/src/components/dropdown-menu.ts +762 -762
- package/src/components/empty.ts +91 -91
- package/src/components/field.ts +584 -584
- package/src/components/{stat.ts → figure.ts} +96 -96
- package/src/components/glyph-select.ts +268 -268
- package/src/components/hover-card.ts +222 -222
- package/src/components/input-group.ts +229 -229
- package/src/components/input.ts +181 -181
- package/src/components/item.ts +376 -376
- package/src/components/kbd.ts +64 -64
- package/src/components/line-chart.ts +218 -218
- package/src/components/month-grid.ts +328 -328
- package/src/components/number-input.ts +443 -443
- package/src/components/popover.ts +368 -368
- package/src/components/scatter-chart.ts +221 -221
- package/src/components/select.ts +620 -620
- package/src/components/slider.ts +259 -259
- package/src/components/sort-button.ts +189 -189
- package/src/components/sparkline.ts +114 -114
- package/src/components/switch.ts +205 -205
- package/src/components/tabs.ts +426 -426
- package/src/components/text-area.ts +186 -186
- package/src/components/toast.ts +965 -965
- package/src/components/toggle-group.ts +295 -295
- package/src/components/tooltip.ts +156 -156
- package/src/components/treemap.ts +847 -847
- package/src/index.ts +24 -24
- package/src/lib/calendar.ts +117 -117
- package/src/lib/chart.ts +72 -72
- package/src/lib/color.ts +89 -89
- package/src/lib/component-index.ts +163 -163
- package/src/lib/css.ts +48 -48
- package/src/lib/define.ts +45 -45
- package/src/lib/dispose.ts +36 -36
- package/src/lib/h.ts +55 -55
- package/src/lib/headless.ts +16 -16
- package/src/lib/i18n.ts +30 -30
- package/src/lib/icons.ts +244 -244
- package/src/lib/kit-text.ts +26 -26
- package/src/lib/page.ts +24 -24
- package/src/lib/palette.ts +81 -81
- package/src/lib/placement.ts +188 -188
- package/src/lib/scope.ts +135 -135
- package/src/lib/styles.ts +53 -53
- package/src/lib/surface-events.ts +31 -31
- package/src/lib/surface-exit.ts +87 -87
- package/src/lib/t.ts +68 -68
- package/src/lib/theme.ts +684 -670
- package/src/lib/tokens.ts +110 -110
- package/src/lib/variants.ts +32 -32
- package/src/lib/zag.ts +61 -46
- package/stylelint/index.mjs +60 -60
- package/stylelint/lint.mjs +81 -81
- package/stylelint/plugin.mjs +115 -115
- package/dist/chunk-P4MTEMT7.js +0 -23
- package/dist/stat.js +0 -41
|
@@ -2,12 +2,12 @@ import { V as VariantFn, a as VariantProps } from './variants-B4stUBnY.js';
|
|
|
2
2
|
import { C as ComponentDef } from './define-D5u3F5Dj.js';
|
|
3
3
|
import './t.js';
|
|
4
4
|
|
|
5
|
-
declare const
|
|
6
|
-
declare const
|
|
5
|
+
declare const figureDef: ComponentDef<"figure", "label" | "sub" | "root" | "value", never>;
|
|
6
|
+
declare const figureVariants: VariantFn<{
|
|
7
7
|
readonly tone: readonly ["neutral", "profit", "loss"];
|
|
8
8
|
}>;
|
|
9
|
-
type
|
|
10
|
-
interface
|
|
9
|
+
type FigureTone = (typeof figureVariants.spec.tone)[number];
|
|
10
|
+
interface FigureProps extends VariantProps<typeof figureVariants> {
|
|
11
11
|
label: string;
|
|
12
12
|
/** The figure (default `—`). */
|
|
13
13
|
value?: string;
|
|
@@ -16,14 +16,14 @@ interface StatProps extends VariantProps<typeof statVariants> {
|
|
|
16
16
|
/** Extra class names (layout hooks). */
|
|
17
17
|
className?: string;
|
|
18
18
|
}
|
|
19
|
-
interface
|
|
19
|
+
interface FigureHandle {
|
|
20
20
|
readonly el: HTMLElement;
|
|
21
21
|
/** A new figure, its tone and its line (`null` hides the line). */
|
|
22
|
-
set(value: string, tone?:
|
|
22
|
+
set(value: string, tone?: FigureTone, sub?: string | null): void;
|
|
23
23
|
destroy(): void;
|
|
24
24
|
}
|
|
25
25
|
/** The tone of a signed figure: a gain, a loss, or neither. */
|
|
26
|
-
declare function toneOf(n: number):
|
|
27
|
-
declare function
|
|
26
|
+
declare function toneOf(n: number): FigureTone;
|
|
27
|
+
declare function createFigure(props: FigureProps): FigureHandle;
|
|
28
28
|
|
|
29
|
-
export { type
|
|
29
|
+
export { type FigureHandle, type FigureProps, type FigureTone, createFigure, figureDef, figureVariants, toneOf };
|
package/dist/figure.js
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { variants } from './chunk-LZWZV2ZS.js';
|
|
2
|
+
import { h } from './chunk-Q6WTDVH6.js';
|
|
3
|
+
import { t } from './chunk-6QCILIT2.js';
|
|
4
|
+
import { defineComponent } from './chunk-VMCR3S2A.js';
|
|
5
|
+
import { defineStyles, css } from './chunk-XBEL4K33.js';
|
|
6
|
+
import './chunk-2GQIZM5Z.js';
|
|
7
|
+
import './chunk-BXMWQIBO.js';
|
|
8
|
+
import './chunk-X66RJAIS.js';
|
|
9
|
+
|
|
10
|
+
// src/components/figure.ts
|
|
11
|
+
var figureDef = defineComponent({
|
|
12
|
+
name: "figure",
|
|
13
|
+
parts: ["root", "label", "value", "sub"]
|
|
14
|
+
});
|
|
15
|
+
var figureVariants = variants({ tone: ["neutral", "profit", "loss"] });
|
|
16
|
+
function toneOf(n) {
|
|
17
|
+
return n > 0 ? "profit" : n < 0 ? "loss" : "neutral";
|
|
18
|
+
}
|
|
19
|
+
var injectStyles = defineStyles(
|
|
20
|
+
"vela-ui-figure",
|
|
21
|
+
css`@layer vela.ui{[data-slot=figure]:where(:not([hidden])){flex-direction:column;gap:3px;min-width:0;display:flex}[data-slot=figure-label]{color:${t.fg.muted};white-space:nowrap;text-overflow:ellipsis;font-size:11px;overflow:hidden}[data-slot=figure-value]{color:${t.fg.bright};font-variant-numeric:tabular-nums;white-space:nowrap;font-size:14px;font-weight:600}[data-slot=figure-value]:is([data-tone=profit]>*){color:${t.profit}}[data-slot=figure-value]:is([data-tone=loss]>*){color:${t.loss}}[data-slot=figure-sub]{color:${t.fg.muted};font-variant-numeric:tabular-nums;font-size:11px}}`
|
|
22
|
+
);
|
|
23
|
+
function createFigure(props) {
|
|
24
|
+
injectStyles(document);
|
|
25
|
+
const value = h("span", { slot: figureDef.slot("value"), text: props.value ?? "\u2014" });
|
|
26
|
+
const sub = h("span", { slot: figureDef.slot("sub"), text: props.sub ?? "" });
|
|
27
|
+
sub.hidden = !props.sub;
|
|
28
|
+
const el = h("div", { className: props.className, slot: figureDef.slot("root"), attrs: figureVariants(props) }, h("span", { slot: figureDef.slot("label"), text: props.label }), value, sub);
|
|
29
|
+
return {
|
|
30
|
+
el,
|
|
31
|
+
set(next, tone = "neutral", line = null) {
|
|
32
|
+
value.textContent = next;
|
|
33
|
+
el.setAttribute("data-tone", tone);
|
|
34
|
+
sub.textContent = line ?? "";
|
|
35
|
+
sub.hidden = !line;
|
|
36
|
+
},
|
|
37
|
+
destroy: () => el.remove()
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export { createFigure, figureDef, figureVariants, toneOf };
|
package/dist/glyph-select.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { GlyphSelect, WIDTH_FIELD_OPTIONS, closeWidthPopover, createGlyphSelect, glyphSelectController, glyphSelectDef, lineWidthGlyph, widthField, widthFieldOptions } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
export { GlyphSelect, WIDTH_FIELD_OPTIONS, closeWidthPopover, createGlyphSelect, glyphSelectController, glyphSelectDef, lineWidthGlyph, widthField, widthFieldOptions } from './chunk-YT2BSP7O.js';
|
|
2
|
+
import './chunk-BWSOMG3G.js';
|
|
3
3
|
import './chunk-J2QJATCD.js';
|
|
4
4
|
import './chunk-S7USVSYP.js';
|
|
5
|
-
import './chunk-
|
|
5
|
+
import './chunk-RH53NQGE.js';
|
|
6
6
|
import './chunk-TAKSIV57.js';
|
|
7
7
|
import './chunk-MMTMOV6R.js';
|
|
8
8
|
import './chunk-3Q32K4PE.js';
|
package/dist/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export { V as VariantFn, a as VariantProps, b as VariantSpec, c as VariantValues
|
|
|
5
5
|
export { C as ComponentDef, d as defineComponent } from './define-D5u3F5Dj.js';
|
|
6
6
|
export { disposeWithin, ownTeardown } from './dispose.js';
|
|
7
7
|
export { Align, CollisionBoundary, PlacementProps, Side, placePopover, zagPositioning } from './placement.js';
|
|
8
|
-
export { C as ComponentDefs, a as ComponentSettings, b as CreateThemeOptions, D as DARK_CHART, L as LIGHT_CHART, T as TOKEN_NAMES, c as ThemeInput, d as ThemeSettings, e as ThemedChart, f as TokenName, U as UiTheme, g as applyTheme, h as checkTheme, i as createTheme } from './theme-
|
|
8
|
+
export { C as ComponentDefs, a as ComponentSettings, b as CreateThemeOptions, D as DARK_CHART, L as LIGHT_CHART, T as TOKEN_NAMES, c as ThemeInput, d as ThemeSettings, e as ThemedChart, f as TokenName, U as UiTheme, g as applyTheme, h as checkTheme, i as createTheme } from './theme-TefB8vtl.js';
|
|
9
9
|
export { ChartTheme } from './tokens.js';
|
|
10
10
|
export { LAYER_ORDER, injectLayerOrder } from './styles.js';
|
|
11
11
|
import './badge.js';
|
|
@@ -34,7 +34,7 @@ import '@zag-js/menu';
|
|
|
34
34
|
import './number-input.js';
|
|
35
35
|
import './scatter-chart.js';
|
|
36
36
|
import './sparkline.js';
|
|
37
|
-
import './
|
|
37
|
+
import './figure.js';
|
|
38
38
|
import './checkbox.js';
|
|
39
39
|
import './collapsible.js';
|
|
40
40
|
import './tabs.js';
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { DARK_CHART, LIGHT_CHART, TOKEN_NAMES, applyTheme, checkTheme, createTheme } from './chunk-
|
|
1
|
+
export { DARK_CHART, LIGHT_CHART, TOKEN_NAMES, applyTheme, checkTheme, createTheme } from './chunk-RH53NQGE.js';
|
|
2
2
|
import './chunk-TAKSIV57.js';
|
|
3
3
|
import './chunk-MMTMOV6R.js';
|
|
4
4
|
export { placePopover, zagPositioning } from './chunk-3Q32K4PE.js';
|
package/dist/manifest.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "@luxalgo/vela-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"tokens": [
|
|
5
5
|
"space-1",
|
|
6
6
|
"space-2",
|
|
@@ -2101,6 +2101,79 @@
|
|
|
2101
2101
|
"data-mobile"
|
|
2102
2102
|
]
|
|
2103
2103
|
},
|
|
2104
|
+
{
|
|
2105
|
+
"name": "figure",
|
|
2106
|
+
"import": "@luxalgo/vela-ui/figure",
|
|
2107
|
+
"description": "Figure: a value under its label (Net P&L, Win rate), with an optional line under it. Its tone colors a gain or a loss; `toneOf` reads one from a signed number.",
|
|
2108
|
+
"component": "figure",
|
|
2109
|
+
"declaration": "figureDef",
|
|
2110
|
+
"parts": {
|
|
2111
|
+
"root": "figure",
|
|
2112
|
+
"label": "figure-label",
|
|
2113
|
+
"value": "figure-value",
|
|
2114
|
+
"sub": "figure-sub"
|
|
2115
|
+
},
|
|
2116
|
+
"settings": {},
|
|
2117
|
+
"variants": {
|
|
2118
|
+
"tone": [
|
|
2119
|
+
"neutral",
|
|
2120
|
+
"profit",
|
|
2121
|
+
"loss"
|
|
2122
|
+
]
|
|
2123
|
+
},
|
|
2124
|
+
"factory": "createFigure",
|
|
2125
|
+
"returns": "FigureHandle",
|
|
2126
|
+
"propsType": "FigureProps",
|
|
2127
|
+
"props": [
|
|
2128
|
+
{
|
|
2129
|
+
"name": "label",
|
|
2130
|
+
"type": "string",
|
|
2131
|
+
"required": true
|
|
2132
|
+
},
|
|
2133
|
+
{
|
|
2134
|
+
"name": "value",
|
|
2135
|
+
"type": "string",
|
|
2136
|
+
"required": false,
|
|
2137
|
+
"doc": "The figure (default `—`)."
|
|
2138
|
+
},
|
|
2139
|
+
{
|
|
2140
|
+
"name": "sub",
|
|
2141
|
+
"type": "string",
|
|
2142
|
+
"required": false,
|
|
2143
|
+
"doc": "A line under the figure (a count, a percentage)."
|
|
2144
|
+
},
|
|
2145
|
+
{
|
|
2146
|
+
"name": "className",
|
|
2147
|
+
"type": "string",
|
|
2148
|
+
"required": false,
|
|
2149
|
+
"doc": "Extra class names (layout hooks)."
|
|
2150
|
+
},
|
|
2151
|
+
{
|
|
2152
|
+
"name": "tone",
|
|
2153
|
+
"type": "\"neutral\" | \"profit\" | \"loss\"",
|
|
2154
|
+
"required": false
|
|
2155
|
+
}
|
|
2156
|
+
],
|
|
2157
|
+
"exports": [
|
|
2158
|
+
"figureDef",
|
|
2159
|
+
"figureVariants",
|
|
2160
|
+
"FigureTone",
|
|
2161
|
+
"FigureProps",
|
|
2162
|
+
"FigureHandle",
|
|
2163
|
+
"toneOf",
|
|
2164
|
+
"createFigure"
|
|
2165
|
+
],
|
|
2166
|
+
"tokens": [
|
|
2167
|
+
"fg-bright",
|
|
2168
|
+
"fg-muted",
|
|
2169
|
+
"loss",
|
|
2170
|
+
"profit"
|
|
2171
|
+
],
|
|
2172
|
+
"attributes": [
|
|
2173
|
+
"data-tone"
|
|
2174
|
+
],
|
|
2175
|
+
"example": "import { createFigure } from '@luxalgo/vela-ui/figure';\n\nconst figure = createFigure({ label: /* string */ });\nhost.append(figure.el);"
|
|
2176
|
+
},
|
|
2104
2177
|
{
|
|
2105
2178
|
"name": "glyph-select",
|
|
2106
2179
|
"import": "@luxalgo/vela-ui/glyph-select",
|
|
@@ -3960,79 +4033,6 @@
|
|
|
3960
4033
|
],
|
|
3961
4034
|
"example": "import { createSparkline } from '@luxalgo/vela-ui/sparkline';\n\nconst sparkline = createSparkline({ values: /* readonly number[] */ });\nhost.append(sparkline.el);"
|
|
3962
4035
|
},
|
|
3963
|
-
{
|
|
3964
|
-
"name": "stat",
|
|
3965
|
-
"import": "@luxalgo/vela-ui/stat",
|
|
3966
|
-
"description": "Stat: a figure under its label (Net P&L, Win rate), with an optional line under it. Its tone colors a gain or a loss; `toneOf` reads one from a signed number.",
|
|
3967
|
-
"component": "stat",
|
|
3968
|
-
"declaration": "statDef",
|
|
3969
|
-
"parts": {
|
|
3970
|
-
"root": "stat",
|
|
3971
|
-
"label": "stat-label",
|
|
3972
|
-
"value": "stat-value",
|
|
3973
|
-
"sub": "stat-sub"
|
|
3974
|
-
},
|
|
3975
|
-
"settings": {},
|
|
3976
|
-
"variants": {
|
|
3977
|
-
"tone": [
|
|
3978
|
-
"neutral",
|
|
3979
|
-
"profit",
|
|
3980
|
-
"loss"
|
|
3981
|
-
]
|
|
3982
|
-
},
|
|
3983
|
-
"factory": "createStat",
|
|
3984
|
-
"returns": "StatHandle",
|
|
3985
|
-
"propsType": "StatProps",
|
|
3986
|
-
"props": [
|
|
3987
|
-
{
|
|
3988
|
-
"name": "label",
|
|
3989
|
-
"type": "string",
|
|
3990
|
-
"required": true
|
|
3991
|
-
},
|
|
3992
|
-
{
|
|
3993
|
-
"name": "value",
|
|
3994
|
-
"type": "string",
|
|
3995
|
-
"required": false,
|
|
3996
|
-
"doc": "The figure (default `—`)."
|
|
3997
|
-
},
|
|
3998
|
-
{
|
|
3999
|
-
"name": "sub",
|
|
4000
|
-
"type": "string",
|
|
4001
|
-
"required": false,
|
|
4002
|
-
"doc": "A line under the figure (a count, a percentage)."
|
|
4003
|
-
},
|
|
4004
|
-
{
|
|
4005
|
-
"name": "className",
|
|
4006
|
-
"type": "string",
|
|
4007
|
-
"required": false,
|
|
4008
|
-
"doc": "Extra class names (layout hooks)."
|
|
4009
|
-
},
|
|
4010
|
-
{
|
|
4011
|
-
"name": "tone",
|
|
4012
|
-
"type": "\"neutral\" | \"profit\" | \"loss\"",
|
|
4013
|
-
"required": false
|
|
4014
|
-
}
|
|
4015
|
-
],
|
|
4016
|
-
"exports": [
|
|
4017
|
-
"statDef",
|
|
4018
|
-
"statVariants",
|
|
4019
|
-
"StatTone",
|
|
4020
|
-
"StatProps",
|
|
4021
|
-
"StatHandle",
|
|
4022
|
-
"toneOf",
|
|
4023
|
-
"createStat"
|
|
4024
|
-
],
|
|
4025
|
-
"tokens": [
|
|
4026
|
-
"fg-bright",
|
|
4027
|
-
"fg-muted",
|
|
4028
|
-
"loss",
|
|
4029
|
-
"profit"
|
|
4030
|
-
],
|
|
4031
|
-
"attributes": [
|
|
4032
|
-
"data-tone"
|
|
4033
|
-
],
|
|
4034
|
-
"example": "import { createStat } from '@luxalgo/vela-ui/stat';\n\nconst stat = createStat({ label: /* string */ });\nhost.append(stat.el);"
|
|
4035
|
-
},
|
|
4036
4036
|
{
|
|
4037
4037
|
"name": "switch",
|
|
4038
4038
|
"import": "@luxalgo/vela-ui/switch",
|
package/dist/number-input.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { NUMBER_CSS, NUMBER_STYLE_ID, NumberInput, clampNumber, createNumberInput, numberInputController, numberInputDef, numberInputVariants, snapToStep } from './chunk-
|
|
1
|
+
export { NUMBER_CSS, NUMBER_STYLE_ID, NumberInput, clampNumber, createNumberInput, numberInputController, numberInputDef, numberInputVariants, snapToStep } from './chunk-VC7SVSDK.js';
|
|
2
2
|
import './chunk-FVH6L7FM.js';
|
|
3
3
|
import './chunk-FN2BUFNM.js';
|
|
4
4
|
import './chunk-A72NWYNP.js';
|
|
5
|
-
import './chunk-
|
|
5
|
+
import './chunk-GUIYFQ27.js';
|
|
6
6
|
import './chunk-C3PXY2SW.js';
|
|
7
7
|
import './chunk-LZWZV2ZS.js';
|
|
8
8
|
import './chunk-Q6WTDVH6.js';
|
package/dist/popover.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { POPOVER_CSS, POPOVER_STYLE_ID, Popover, closeOpenPopovers, createPopover, eventDismissedPopover, isPopoverOpen, openPopoverTrigger, popoverController, popoverDef } from './chunk-
|
|
1
|
+
export { POPOVER_CSS, POPOVER_STYLE_ID, Popover, closeOpenPopovers, createPopover, eventDismissedPopover, isPopoverOpen, openPopoverTrigger, popoverController, popoverDef } from './chunk-BWSOMG3G.js';
|
|
2
2
|
import './chunk-J2QJATCD.js';
|
|
3
3
|
import './chunk-S7USVSYP.js';
|
|
4
|
-
import './chunk-
|
|
4
|
+
import './chunk-RH53NQGE.js';
|
|
5
5
|
import './chunk-TAKSIV57.js';
|
|
6
6
|
import './chunk-MMTMOV6R.js';
|
|
7
7
|
export { insetRect, intersectRects, placePopover, viewportRect } from './chunk-3Q32K4PE.js';
|
package/dist/select.d.ts
CHANGED
|
@@ -42,7 +42,7 @@ interface SelectController {
|
|
|
42
42
|
}
|
|
43
43
|
/** The select's options and current value, without DOM. */
|
|
44
44
|
declare function selectController(opts: SelectControllerOptions): SelectController;
|
|
45
|
-
declare const selectDef: ComponentDef<"select", "root" | "viewport" | "icon" | "trigger" | "content" | "value" | "
|
|
45
|
+
declare const selectDef: ComponentDef<"select", "root" | "viewport" | "icon" | "trigger" | "content" | "value" | "item" | "sizer" | "native" | "rail" | "thumb", "radius" | "content-radius" | "focus-ring" | "thumb-radius">;
|
|
46
46
|
declare const selectVariants: VariantFn<{
|
|
47
47
|
readonly size: readonly ["md", "sm"];
|
|
48
48
|
}>;
|
package/dist/select.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export { SELECT_CSS, SELECT_STYLE_ID, Select, createSelect, decorateSelectScroll, fillSelectList, openSelectList, selectController, selectDef, selectVariants, toggleSelectList } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
export { SELECT_CSS, SELECT_STYLE_ID, Select, createSelect, decorateSelectScroll, fillSelectList, openSelectList, selectController, selectDef, selectVariants, toggleSelectList } from './chunk-QGWAN3EP.js';
|
|
2
|
+
import './chunk-BWSOMG3G.js';
|
|
3
3
|
import './chunk-J2QJATCD.js';
|
|
4
4
|
import './chunk-S7USVSYP.js';
|
|
5
|
-
import './chunk-
|
|
5
|
+
import './chunk-RH53NQGE.js';
|
|
6
6
|
import './chunk-TAKSIV57.js';
|
|
7
7
|
import './chunk-MMTMOV6R.js';
|
|
8
8
|
import './chunk-3Q32K4PE.js';
|
|
9
9
|
import './chunk-A72NWYNP.js';
|
|
10
|
-
import './chunk-
|
|
10
|
+
import './chunk-GUIYFQ27.js';
|
|
11
11
|
import './chunk-C3PXY2SW.js';
|
|
12
12
|
import './chunk-LZWZV2ZS.js';
|
|
13
13
|
import './chunk-Q6WTDVH6.js';
|
package/dist/slider.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ownTeardown } from './chunk-A72NWYNP.js';
|
|
2
|
-
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-
|
|
2
|
+
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-GUIYFQ27.js';
|
|
3
3
|
import { h } from './chunk-Q6WTDVH6.js';
|
|
4
4
|
import { t } from './chunk-6QCILIT2.js';
|
|
5
5
|
import { defineComponent } from './chunk-VMCR3S2A.js';
|
package/dist/sort-button.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { kitTranslator } from './chunk-FVH6L7FM.js';
|
|
2
2
|
import { msg, textOf } from './chunk-FN2BUFNM.js';
|
|
3
|
-
import { nextUid } from './chunk-
|
|
3
|
+
import { nextUid } from './chunk-GUIYFQ27.js';
|
|
4
4
|
import { iconEl } from './chunk-C3PXY2SW.js';
|
|
5
5
|
import { variants } from './chunk-LZWZV2ZS.js';
|
|
6
6
|
import { h } from './chunk-Q6WTDVH6.js';
|
package/dist/switch.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ownTeardown } from './chunk-A72NWYNP.js';
|
|
2
|
-
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-
|
|
2
|
+
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-GUIYFQ27.js';
|
|
3
3
|
import { variants } from './chunk-LZWZV2ZS.js';
|
|
4
4
|
import { h } from './chunk-Q6WTDVH6.js';
|
|
5
5
|
import { t } from './chunk-6QCILIT2.js';
|
package/dist/tabs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ownTeardown } from './chunk-A72NWYNP.js';
|
|
2
|
-
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-
|
|
2
|
+
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-GUIYFQ27.js';
|
|
3
3
|
import { iconEl } from './chunk-C3PXY2SW.js';
|
|
4
4
|
import { variants } from './chunk-LZWZV2ZS.js';
|
|
5
5
|
import { h } from './chunk-Q6WTDVH6.js';
|
|
@@ -21,7 +21,7 @@ import { popoverDef } from './popover.js';
|
|
|
21
21
|
import { scatterChartDef } from './scatter-chart.js';
|
|
22
22
|
import { selectDef } from './select.js';
|
|
23
23
|
import { sparklineDef } from './sparkline.js';
|
|
24
|
-
import {
|
|
24
|
+
import { figureDef } from './figure.js';
|
|
25
25
|
import { checkboxDef } from './checkbox.js';
|
|
26
26
|
import { collapsibleDef } from './collapsible.js';
|
|
27
27
|
import { tabsDef } from './tabs.js';
|
|
@@ -212,6 +212,7 @@ interface ComponentDefs {
|
|
|
212
212
|
'dropdown-menu': typeof dropdownMenuDef;
|
|
213
213
|
empty: typeof emptyDef;
|
|
214
214
|
field: typeof fieldDef;
|
|
215
|
+
figure: typeof figureDef;
|
|
215
216
|
'glyph-select': typeof glyphSelectDef;
|
|
216
217
|
'hover-card': typeof hoverCardDef;
|
|
217
218
|
'input-group': typeof inputGroupDef;
|
|
@@ -227,7 +228,6 @@ interface ComponentDefs {
|
|
|
227
228
|
slider: typeof sliderDef;
|
|
228
229
|
'sort-button': typeof sortButtonDef;
|
|
229
230
|
sparkline: typeof sparklineDef;
|
|
230
|
-
stat: typeof statDef;
|
|
231
231
|
switch: typeof switchDef;
|
|
232
232
|
tabs: typeof tabsDef;
|
|
233
233
|
'text-area': typeof textAreaDef;
|
package/dist/theme.d.ts
CHANGED
|
@@ -21,7 +21,7 @@ import './popover.js';
|
|
|
21
21
|
import './scatter-chart.js';
|
|
22
22
|
import './select.js';
|
|
23
23
|
import './sparkline.js';
|
|
24
|
-
import './
|
|
24
|
+
import './figure.js';
|
|
25
25
|
import './checkbox.js';
|
|
26
26
|
import './collapsible.js';
|
|
27
27
|
import './tabs.js';
|
|
@@ -33,7 +33,7 @@ import './month-grid.js';
|
|
|
33
33
|
import './slider.js';
|
|
34
34
|
import './sort-button.js';
|
|
35
35
|
import './switch.js';
|
|
36
|
-
export { C as ComponentDefs, a as ComponentSettings, b as CreateThemeOptions, D as DARK_CHART, L as LIGHT_CHART, T as TOKEN_NAMES, c as ThemeInput, d as ThemeSettings, e as ThemedChart, f as TokenName, U as UiTheme, y as applyPlotOverlayTokens, g as applyTheme, z as applyThemeTokens, h as checkTheme, i as createTheme, A as ensureUIHost, B as floatingLayerHost, F as themeCss } from './theme-
|
|
36
|
+
export { C as ComponentDefs, a as ComponentSettings, b as CreateThemeOptions, D as DARK_CHART, L as LIGHT_CHART, T as TOKEN_NAMES, c as ThemeInput, d as ThemeSettings, e as ThemedChart, f as TokenName, U as UiTheme, y as applyPlotOverlayTokens, g as applyTheme, z as applyThemeTokens, h as checkTheme, i as createTheme, A as ensureUIHost, B as floatingLayerHost, F as themeCss } from './theme-TefB8vtl.js';
|
|
37
37
|
import './toggle-group.js';
|
|
38
38
|
import './tooltip.js';
|
|
39
39
|
import './treemap.js';
|
package/dist/theme.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { DARK_CHART, LIGHT_CHART, TOKEN_NAMES, applyPlotOverlayTokens, applyTheme, applyThemeTokens, checkTheme, createTheme, ensureUIHost, floatingLayerHost, themeCss } from './chunk-
|
|
1
|
+
export { DARK_CHART, LIGHT_CHART, TOKEN_NAMES, applyPlotOverlayTokens, applyTheme, applyThemeTokens, checkTheme, createTheme, ensureUIHost, floatingLayerHost, themeCss } from './chunk-RH53NQGE.js';
|
|
2
2
|
import './chunk-TAKSIV57.js';
|
|
3
3
|
import './chunk-MMTMOV6R.js';
|
|
4
4
|
import './chunk-VMCR3S2A.js';
|
package/dist/theme.schema.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
-
"title": "@luxalgo/vela-ui 0.
|
|
3
|
+
"title": "@luxalgo/vela-ui 0.4.0 theme",
|
|
4
4
|
"description": "The input of createTheme. Every field is optional: an empty theme is the dark theme.",
|
|
5
5
|
"type": "object",
|
|
6
6
|
"additionalProperties": false,
|
|
@@ -1124,6 +1124,35 @@
|
|
|
1124
1124
|
}
|
|
1125
1125
|
}
|
|
1126
1126
|
},
|
|
1127
|
+
"figure": {
|
|
1128
|
+
"type": "object",
|
|
1129
|
+
"additionalProperties": false,
|
|
1130
|
+
"properties": {
|
|
1131
|
+
"css": {
|
|
1132
|
+
"type": "object",
|
|
1133
|
+
"additionalProperties": false,
|
|
1134
|
+
"description": "CSS by part, applied after every layer of the kit. From a file, it applies only when the host passes { allowCss: true }.",
|
|
1135
|
+
"properties": {
|
|
1136
|
+
"root": {
|
|
1137
|
+
"type": "string",
|
|
1138
|
+
"description": "[data-slot~=\"figure\"]"
|
|
1139
|
+
},
|
|
1140
|
+
"label": {
|
|
1141
|
+
"type": "string",
|
|
1142
|
+
"description": "[data-slot~=\"figure-label\"]"
|
|
1143
|
+
},
|
|
1144
|
+
"value": {
|
|
1145
|
+
"type": "string",
|
|
1146
|
+
"description": "[data-slot~=\"figure-value\"]"
|
|
1147
|
+
},
|
|
1148
|
+
"sub": {
|
|
1149
|
+
"type": "string",
|
|
1150
|
+
"description": "[data-slot~=\"figure-sub\"]"
|
|
1151
|
+
}
|
|
1152
|
+
}
|
|
1153
|
+
}
|
|
1154
|
+
}
|
|
1155
|
+
},
|
|
1127
1156
|
"glyph-select": {
|
|
1128
1157
|
"type": "object",
|
|
1129
1158
|
"additionalProperties": false,
|
|
@@ -1795,35 +1824,6 @@
|
|
|
1795
1824
|
}
|
|
1796
1825
|
}
|
|
1797
1826
|
},
|
|
1798
|
-
"stat": {
|
|
1799
|
-
"type": "object",
|
|
1800
|
-
"additionalProperties": false,
|
|
1801
|
-
"properties": {
|
|
1802
|
-
"css": {
|
|
1803
|
-
"type": "object",
|
|
1804
|
-
"additionalProperties": false,
|
|
1805
|
-
"description": "CSS by part, applied after every layer of the kit. From a file, it applies only when the host passes { allowCss: true }.",
|
|
1806
|
-
"properties": {
|
|
1807
|
-
"root": {
|
|
1808
|
-
"type": "string",
|
|
1809
|
-
"description": "[data-slot~=\"stat\"]"
|
|
1810
|
-
},
|
|
1811
|
-
"label": {
|
|
1812
|
-
"type": "string",
|
|
1813
|
-
"description": "[data-slot~=\"stat-label\"]"
|
|
1814
|
-
},
|
|
1815
|
-
"value": {
|
|
1816
|
-
"type": "string",
|
|
1817
|
-
"description": "[data-slot~=\"stat-value\"]"
|
|
1818
|
-
},
|
|
1819
|
-
"sub": {
|
|
1820
|
-
"type": "string",
|
|
1821
|
-
"description": "[data-slot~=\"stat-sub\"]"
|
|
1822
|
-
}
|
|
1823
|
-
}
|
|
1824
|
-
}
|
|
1825
|
-
}
|
|
1826
|
-
},
|
|
1827
1827
|
"switch": {
|
|
1828
1828
|
"type": "object",
|
|
1829
1829
|
"additionalProperties": false,
|
package/dist/toast.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import './define-D5u3F5Dj.js';
|
|
2
|
-
export { E as ExternalToast, P as PromiseData, j as PromiseSource, S as SwipeDirection, k as ToastAction, l as ToastContent, m as ToastFunction, n as ToastId, o as ToastOffset, p as ToastPromise, q as ToastT, r as ToastType, s as ToasterHandle, t as ToasterPosition, u as ToasterProps, v as createToaster, w as toast, x as toastDef } from './theme-
|
|
2
|
+
export { E as ExternalToast, P as PromiseData, j as PromiseSource, S as SwipeDirection, k as ToastAction, l as ToastContent, m as ToastFunction, n as ToastId, o as ToastOffset, p as ToastPromise, q as ToastT, r as ToastType, s as ToasterHandle, t as ToasterPosition, u as ToasterProps, v as createToaster, w as toast, x as toastDef } from './theme-TefB8vtl.js';
|
|
3
3
|
import './i18n.js';
|
|
4
4
|
import './t.js';
|
|
5
5
|
import './badge.js';
|
|
@@ -31,7 +31,7 @@ import '@zag-js/menu';
|
|
|
31
31
|
import './number-input.js';
|
|
32
32
|
import './scatter-chart.js';
|
|
33
33
|
import './sparkline.js';
|
|
34
|
-
import './
|
|
34
|
+
import './figure.js';
|
|
35
35
|
import './checkbox.js';
|
|
36
36
|
import './collapsible.js';
|
|
37
37
|
import './tabs.js';
|
package/dist/toast.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { kitTranslator } from './chunk-FVH6L7FM.js';
|
|
2
2
|
import { msg, textOf } from './chunk-FN2BUFNM.js';
|
|
3
|
-
import { ensureUIHost } from './chunk-
|
|
3
|
+
import { ensureUIHost } from './chunk-RH53NQGE.js';
|
|
4
4
|
import './chunk-TAKSIV57.js';
|
|
5
5
|
import './chunk-MMTMOV6R.js';
|
|
6
6
|
import { iconEl } from './chunk-C3PXY2SW.js';
|
package/dist/toggle-group.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ownTeardown } from './chunk-A72NWYNP.js';
|
|
2
|
-
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-
|
|
2
|
+
import { nextUid, runMachine, normalizeProps, spreadProps } from './chunk-GUIYFQ27.js';
|
|
3
3
|
import { iconEl } from './chunk-C3PXY2SW.js';
|
|
4
4
|
import { variants } from './chunk-LZWZV2ZS.js';
|
|
5
5
|
import { h } from './chunk-Q6WTDVH6.js';
|
package/dist/tooltip.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { zagPositioning, splitPlacement } from './chunk-3Q32K4PE.js';
|
|
2
2
|
import { ownTeardown } from './chunk-A72NWYNP.js';
|
|
3
|
-
import { normalizeProps, nextUid, runMachine, spreadProps } from './chunk-
|
|
3
|
+
import { normalizeProps, nextUid, runMachine, spreadProps } from './chunk-GUIYFQ27.js';
|
|
4
4
|
import { h } from './chunk-Q6WTDVH6.js';
|
|
5
5
|
import { t } from './chunk-6QCILIT2.js';
|
|
6
6
|
import { defineComponent } from './chunk-VMCR3S2A.js';
|
package/dist/zag.d.ts
CHANGED
|
@@ -1,6 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
import { spreadProps as spreadProps$1 } from '@zag-js/vanilla';
|
|
2
|
+
export { normalizeProps } from '@zag-js/vanilla';
|
|
2
3
|
import { Machine, MachineSchema, Service } from '@zag-js/core';
|
|
3
4
|
|
|
5
|
+
/**
|
|
6
|
+
* Zag's `spreadProps`, without the style keys a part leaves unset. Zag's own spread removes
|
|
7
|
+
* those from the element, which wipes what Zag writes there itself: from 1.47 a positioner's
|
|
8
|
+
* style carries `zIndex: undefined` while the popper sets its z-index inline, so every
|
|
9
|
+
* re-render dropped an open menu under the page. A key the part set and then clears is still
|
|
10
|
+
* removed: that runs off the previous style.
|
|
11
|
+
*/
|
|
12
|
+
declare function spreadProps(...[node, attrs, machineId]: Parameters<typeof spreadProps$1>): ReturnType<typeof spreadProps$1>;
|
|
4
13
|
/** The MachineHandle for a given machine definition (package schemas aren't exported —
|
|
5
14
|
* infer them from the machine value: `HandleOf<typeof tooltip.machine>`). */
|
|
6
15
|
type HandleOf<M> = M extends Machine<infer T extends MachineSchema> ? MachineHandle<T> : never;
|
|
@@ -16,4 +25,4 @@ declare function runMachine<T extends MachineSchema>(machine: Machine<T>, props:
|
|
|
16
25
|
/** Unique ids for machine instances (Zag keys its DOM lookups on them). */
|
|
17
26
|
declare function nextUid(prefix: string): string;
|
|
18
27
|
|
|
19
|
-
export { type HandleOf, type MachineHandle, nextUid, runMachine };
|
|
28
|
+
export { type HandleOf, type MachineHandle, nextUid, runMachine, spreadProps };
|
package/dist/zag.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { nextUid, normalizeProps, runMachine, spreadProps } from './chunk-
|
|
1
|
+
export { nextUid, normalizeProps, runMachine, spreadProps } from './chunk-GUIYFQ27.js';
|
|
2
2
|
import './chunk-X66RJAIS.js';
|