@vaneui/md 0.9.0-alpha.20260105111433.5364a62 → 0.9.0-alpha.20260106191130.bc0ea5f
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/index.esm.js +89 -139
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +89 -139
- package/dist/index.js.map +1 -1
- package/dist/styles/index.css +332 -539
- package/package.json +2 -2
package/dist/index.esm.js
CHANGED
|
@@ -8560,10 +8560,8 @@ const LAYOUT_FLEX = ['wrap', 'gap', 'flexDirection', 'reverse'];
|
|
|
8560
8560
|
const PADDING = ['padding'];
|
|
8561
8561
|
/** Responsive breakpoint properties for different screen sizes */
|
|
8562
8562
|
const BREAKPOINT = ['breakpoint'];
|
|
8563
|
-
/** Responsive CSS variable switching for automatic breakpoint adaptation */
|
|
8564
|
-
const RESPONSIVE = ['responsive'];
|
|
8565
8563
|
/** Core visual properties including appearance colors and transparency */
|
|
8566
|
-
const VISUAL_CORE = ['appearance'
|
|
8564
|
+
const VISUAL_CORE = ['appearance'];
|
|
8567
8565
|
/** Border properties for visual decoration */
|
|
8568
8566
|
const BORDER = ['border'];
|
|
8569
8567
|
/** Visual decoration properties for shadows and focus rings */
|
|
@@ -8617,8 +8615,6 @@ const ComponentKeys = {
|
|
|
8617
8615
|
padding: ['padding', 'noPadding'],
|
|
8618
8616
|
/** CSS positioning: relative, absolute, fixed, sticky, static */
|
|
8619
8617
|
position: ['relative', 'absolute', 'fixed', 'sticky', 'static'],
|
|
8620
|
-
/** Responsive CSS variable switching: responsive (enabled) */
|
|
8621
|
-
responsive: ['responsive'],
|
|
8622
8618
|
/** Reverse the order of flex items */
|
|
8623
8619
|
reverse: ['reverse'],
|
|
8624
8620
|
/** Focus ring visibility: ring (show) or noRing (hide) */
|
|
@@ -8637,8 +8633,6 @@ const ComponentKeys = {
|
|
|
8637
8633
|
textDecoration: ['underline', 'lineThrough', 'noUnderline', 'overline'],
|
|
8638
8634
|
/** Text case transformation: UPPERCASE, lowercase, Capitalize, normalCase */
|
|
8639
8635
|
textTransform: ['uppercase', 'lowercase', 'capitalize', 'normalCase'],
|
|
8640
|
-
/** Make background (layout/UI) or text (typography) transparent */
|
|
8641
|
-
transparent: ['transparent'],
|
|
8642
8636
|
/** Style variant: filled (solid background) or outline (border only) */
|
|
8643
8637
|
variant: ['filled', 'outline'],
|
|
8644
8638
|
/** Flex item wrapping behavior: wrap, no-wrap, or wrap-reverse */
|
|
@@ -8667,7 +8661,7 @@ const CHIP_CATEGORIES = INTERACTIVE_CATEGORIES;
|
|
|
8667
8661
|
const CODE_CATEGORIES = INTERACTIVE_CATEGORIES;
|
|
8668
8662
|
/** Typography component categories */
|
|
8669
8663
|
/** Categories for typography components like Text, Title, Link */
|
|
8670
|
-
const TYPOGRAPHY_CATEGORIES = [...TYPOGRAPHY_FULL, ...LAYOUT_CORE, ...VISUAL_CORE, ...VARIANT
|
|
8664
|
+
const TYPOGRAPHY_CATEGORIES = [...TYPOGRAPHY_FULL, ...LAYOUT_CORE, ...VISUAL_CORE, ...VARIANT];
|
|
8671
8665
|
/** Categories for list components with typography and list-specific styling */
|
|
8672
8666
|
const LIST_CATEGORIES = [...TYPOGRAPHY_FULL, ...LIST_STYLE, ...LAYOUT_CORE, ...VISUAL_CORE, ...PADDING, ...VARIANT];
|
|
8673
8667
|
/** Layout component categories */
|
|
@@ -8686,7 +8680,7 @@ const CARD_CATEGORIES = [...TYPOGRAPHY_FULL, ...LAYOUT_FULL, ...BREAKPOINT, ...V
|
|
|
8686
8680
|
/** Categories for divider components with basic layout and visual properties */
|
|
8687
8681
|
const DIVIDER_CATEGORIES = [...LAYOUT_CORE, ...VISUAL_CORE, ...PADDING, ...VARIANT];
|
|
8688
8682
|
/** Categories for section layout components with full responsive support */
|
|
8689
|
-
const SECTION_CATEGORIES = [...LAYOUT_FULL, ...VISUAL_LAYOUT, ...PADDING, ...BREAKPOINT, ...VARIANT
|
|
8683
|
+
const SECTION_CATEGORIES = [...LAYOUT_FULL, ...VISUAL_LAYOUT, ...PADDING, ...BREAKPOINT, ...VARIANT];
|
|
8690
8684
|
/** Form component categories */
|
|
8691
8685
|
/** Categories for checkbox form components */
|
|
8692
8686
|
const CHECKBOX_CATEGORIES = [...LAYOUT_CORE, ...VISUAL_CORE, ...BORDER, ...VISUAL_DECORATION, ...SHAPE, ...VARIANT];
|
|
@@ -11703,13 +11697,14 @@ const defaultTypographyThemes = {
|
|
|
11703
11697
|
textAlign: new TextAlignTheme()
|
|
11704
11698
|
};
|
|
11705
11699
|
class ComponentTheme {
|
|
11706
|
-
constructor(tag, base, themes, defaults = {}, categories, tagFunction) {
|
|
11700
|
+
constructor(tag, base, themes, defaults = {}, categories, tagFunction, vaneType) {
|
|
11707
11701
|
this.tag = tag;
|
|
11708
11702
|
this.base = base;
|
|
11709
11703
|
this.defaults = defaults;
|
|
11710
11704
|
this.extraClasses = {};
|
|
11711
11705
|
this.categories = categories;
|
|
11712
11706
|
this.tagFunction = tagFunction;
|
|
11707
|
+
this.vaneType = vaneType;
|
|
11713
11708
|
// Type assertion: we trust that all default themes provide complete objects
|
|
11714
11709
|
this.themes = themes;
|
|
11715
11710
|
}
|
|
@@ -11728,7 +11723,7 @@ class ComponentTheme {
|
|
|
11728
11723
|
}
|
|
11729
11724
|
}
|
|
11730
11725
|
// No need for border/noBorder mutual exclusion logic anymore
|
|
11731
|
-
// since noBorder is now part of the border category and
|
|
11726
|
+
// since noBorder is now part of the border category and
|
|
11732
11727
|
// pickFirstTruthyKeyByCategory handles the priority naturally
|
|
11733
11728
|
const walk = (map) => {
|
|
11734
11729
|
for (const key of Object.keys(map)) {
|
|
@@ -11786,6 +11781,9 @@ class ComponentTheme {
|
|
|
11786
11781
|
const finalClasses = twMerge(...themeGeneratedClasses, className);
|
|
11787
11782
|
// Build data attributes for key categories
|
|
11788
11783
|
const dataAttributes = {};
|
|
11784
|
+
if (this.vaneType) {
|
|
11785
|
+
dataAttributes['data-vane-type'] = this.vaneType;
|
|
11786
|
+
}
|
|
11789
11787
|
if (extractedKeys.size) {
|
|
11790
11788
|
dataAttributes['data-size'] = extractedKeys.size;
|
|
11791
11789
|
}
|
|
@@ -11795,9 +11793,6 @@ class ComponentTheme {
|
|
|
11795
11793
|
if (extractedKeys.variant) {
|
|
11796
11794
|
dataAttributes['data-variant'] = extractedKeys.variant;
|
|
11797
11795
|
}
|
|
11798
|
-
if (extractedKeys.transparent) {
|
|
11799
|
-
dataAttributes['data-transparent'] = 'true';
|
|
11800
|
-
}
|
|
11801
11796
|
return {
|
|
11802
11797
|
Tag: componentTag,
|
|
11803
11798
|
finalClasses,
|
|
@@ -11807,35 +11802,21 @@ class ComponentTheme {
|
|
|
11807
11802
|
}
|
|
11808
11803
|
|
|
11809
11804
|
/**
|
|
11810
|
-
* Font size theme -
|
|
11811
|
-
* CSS
|
|
11812
|
-
* using semantic classes and data attributes.
|
|
11813
|
-
*
|
|
11814
|
-
* When the 'responsive' prop is set, adds Tailwind classes to switch
|
|
11815
|
-
* between breakpoint-specific variables for automatic size adaptation.
|
|
11805
|
+
* Font size theme - applies text size using pre-computed breakpoint variables.
|
|
11806
|
+
* CSS computes --fs-desktop/tablet/mobile from --fs-unit (with fallbacks for responsive overrides).
|
|
11816
11807
|
*/
|
|
11817
11808
|
class FontSizeTheme extends BaseTheme {
|
|
11818
11809
|
constructor() {
|
|
11819
11810
|
super(...arguments);
|
|
11820
|
-
/**
|
|
11821
|
-
this.
|
|
11822
|
-
/**
|
|
11823
|
-
this.
|
|
11824
|
-
/**
|
|
11825
|
-
this.
|
|
11826
|
-
/** Responsive tablet unit class */
|
|
11827
|
-
this.responsiveMobile = "max-mobile:[--fs-unit:var(--fs-unit-mobile)]";
|
|
11811
|
+
/** Desktop: apply font size using --fs-desktop */
|
|
11812
|
+
this.desktop = "text-(length:--fs-desktop)";
|
|
11813
|
+
/** Tablet: apply font size using --fs-tablet */
|
|
11814
|
+
this.tablet = "max-tablet:text-(length:--fs-tablet)";
|
|
11815
|
+
/** Mobile: apply font size using --fs-mobile */
|
|
11816
|
+
this.mobile = "max-mobile:text-(length:--fs-mobile)";
|
|
11828
11817
|
}
|
|
11829
|
-
getClasses(
|
|
11830
|
-
|
|
11831
|
-
return [
|
|
11832
|
-
this.responsiveDesktop,
|
|
11833
|
-
this.responsiveTablet,
|
|
11834
|
-
this.responsiveMobile,
|
|
11835
|
-
this.fontSize
|
|
11836
|
-
];
|
|
11837
|
-
}
|
|
11838
|
-
return [this.fontSize];
|
|
11818
|
+
getClasses(_extractedKeys) {
|
|
11819
|
+
return [this.desktop, this.tablet, this.mobile];
|
|
11839
11820
|
}
|
|
11840
11821
|
}
|
|
11841
11822
|
|
|
@@ -11856,36 +11837,22 @@ class LineHeightTheme extends BaseTheme {
|
|
|
11856
11837
|
}
|
|
11857
11838
|
|
|
11858
11839
|
/**
|
|
11859
|
-
* Gap theme -
|
|
11860
|
-
* CSS
|
|
11861
|
-
* using semantic classes and data attributes.
|
|
11862
|
-
*
|
|
11863
|
-
* When the 'responsive' prop is set, adds Tailwind classes to switch
|
|
11864
|
-
* between breakpoint-specific variables for automatic size adaptation.
|
|
11840
|
+
* Gap theme - applies gap using pre-computed breakpoint variables.
|
|
11841
|
+
* CSS computes --gap-desktop/tablet/mobile from --gap-unit (with fallbacks for responsive overrides).
|
|
11865
11842
|
*/
|
|
11866
11843
|
class GapTheme extends BaseTheme {
|
|
11867
11844
|
constructor() {
|
|
11868
11845
|
super(...arguments);
|
|
11869
|
-
/**
|
|
11870
|
-
this.
|
|
11871
|
-
/**
|
|
11872
|
-
this.
|
|
11873
|
-
/**
|
|
11874
|
-
this.
|
|
11875
|
-
/** Responsive tablet unit class */
|
|
11876
|
-
this.responsiveMobile = "max-mobile:[--gap-unit:var(--gap-unit-mobile)]";
|
|
11846
|
+
/** Desktop: apply gap using --gap-desktop */
|
|
11847
|
+
this.desktop = "gap-(--gap-desktop)";
|
|
11848
|
+
/** Tablet: apply gap using --gap-tablet */
|
|
11849
|
+
this.tablet = "max-tablet:gap-(--gap-tablet)";
|
|
11850
|
+
/** Mobile: apply gap using --gap-mobile */
|
|
11851
|
+
this.mobile = "max-mobile:gap-(--gap-mobile)";
|
|
11877
11852
|
}
|
|
11878
11853
|
getClasses(extractedKeys) {
|
|
11879
11854
|
if ((extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.gap) === 'gap') {
|
|
11880
|
-
|
|
11881
|
-
return [
|
|
11882
|
-
this.responsiveDesktop,
|
|
11883
|
-
this.responsiveTablet,
|
|
11884
|
-
this.responsiveMobile,
|
|
11885
|
-
this.gap
|
|
11886
|
-
];
|
|
11887
|
-
}
|
|
11888
|
-
return [this.gap];
|
|
11855
|
+
return [this.desktop, this.tablet, this.mobile];
|
|
11889
11856
|
}
|
|
11890
11857
|
return [];
|
|
11891
11858
|
}
|
|
@@ -12003,55 +11970,44 @@ class FocusVisibleTheme extends BaseTheme {
|
|
|
12003
11970
|
}
|
|
12004
11971
|
|
|
12005
11972
|
/**
|
|
12006
|
-
* Horizontal padding theme -
|
|
12007
|
-
* CSS
|
|
12008
|
-
* in vars.css using semantic classes and data attributes.
|
|
11973
|
+
* Horizontal padding theme - applies px using pre-computed breakpoint variables.
|
|
11974
|
+
* CSS computes --px-desktop/tablet/mobile from --py-unit and --aspect-ratio.
|
|
12009
11975
|
*/
|
|
12010
11976
|
class PxTheme extends BaseTheme {
|
|
12011
11977
|
constructor() {
|
|
12012
11978
|
super(...arguments);
|
|
12013
|
-
/**
|
|
12014
|
-
this.
|
|
11979
|
+
/** Desktop: apply horizontal padding using --px-desktop */
|
|
11980
|
+
this.desktop = "px-(--px-desktop)";
|
|
11981
|
+
/** Tablet: apply horizontal padding using --px-tablet */
|
|
11982
|
+
this.tablet = "max-tablet:px-(--px-tablet)";
|
|
11983
|
+
/** Mobile: apply horizontal padding using --px-mobile */
|
|
11984
|
+
this.mobile = "max-mobile:px-(--px-mobile)";
|
|
12015
11985
|
}
|
|
12016
11986
|
getClasses(extractedKeys) {
|
|
12017
11987
|
if ((extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.padding) === 'padding' || (extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.padding) === undefined) {
|
|
12018
|
-
return [this.
|
|
11988
|
+
return [this.desktop, this.tablet, this.mobile];
|
|
12019
11989
|
}
|
|
12020
11990
|
return [];
|
|
12021
11991
|
}
|
|
12022
11992
|
}
|
|
12023
11993
|
|
|
12024
11994
|
/**
|
|
12025
|
-
* Vertical padding theme -
|
|
12026
|
-
* CSS
|
|
12027
|
-
* using semantic classes and data attributes.
|
|
12028
|
-
*
|
|
12029
|
-
* When the 'responsive' prop is set, adds Tailwind classes to switch
|
|
12030
|
-
* between breakpoint-specific variables for automatic size adaptation.
|
|
11995
|
+
* Vertical padding theme - applies py using pre-computed breakpoint variables.
|
|
11996
|
+
* CSS computes --py-desktop/tablet/mobile from --py-unit (with fallbacks for responsive overrides).
|
|
12031
11997
|
*/
|
|
12032
11998
|
class PyTheme extends BaseTheme {
|
|
12033
11999
|
constructor() {
|
|
12034
12000
|
super(...arguments);
|
|
12035
|
-
/**
|
|
12036
|
-
this.
|
|
12037
|
-
/**
|
|
12038
|
-
this.
|
|
12039
|
-
/**
|
|
12040
|
-
this.
|
|
12041
|
-
/** Responsive tablet unit class */
|
|
12042
|
-
this.responsiveMobile = "max-mobile:[--py-unit:var(--py-unit-mobile)]";
|
|
12001
|
+
/** Desktop: apply vertical padding using --py-desktop */
|
|
12002
|
+
this.desktop = "py-(--py-desktop)";
|
|
12003
|
+
/** Tablet: apply vertical padding using --py-tablet */
|
|
12004
|
+
this.tablet = "max-tablet:py-(--py-tablet)";
|
|
12005
|
+
/** Mobile: apply vertical padding using --py-mobile */
|
|
12006
|
+
this.mobile = "max-mobile:py-(--py-mobile)";
|
|
12043
12007
|
}
|
|
12044
12008
|
getClasses(extractedKeys) {
|
|
12045
12009
|
if ((extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.padding) === 'padding' || (extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.padding) === undefined) {
|
|
12046
|
-
|
|
12047
|
-
return [
|
|
12048
|
-
this.responsiveDesktop,
|
|
12049
|
-
this.responsiveTablet,
|
|
12050
|
-
this.responsiveMobile,
|
|
12051
|
-
this.py
|
|
12052
|
-
];
|
|
12053
|
-
}
|
|
12054
|
-
return [this.py];
|
|
12010
|
+
return [this.desktop, this.tablet, this.mobile];
|
|
12055
12011
|
}
|
|
12056
12012
|
return [];
|
|
12057
12013
|
}
|
|
@@ -12100,8 +12056,8 @@ class SimpleConsumerTheme extends BaseTheme {
|
|
|
12100
12056
|
if (this.category === 'focusVisible' && (extractedKeys.focusVisible === 'noFocusVisible' || extractedKeys.focusVisible === undefined)) {
|
|
12101
12057
|
return [];
|
|
12102
12058
|
}
|
|
12103
|
-
// Only output classes if an appearance
|
|
12104
|
-
if (!this.alwaysOutput && !(extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.appearance)
|
|
12059
|
+
// Only output classes if an appearance is set (unless alwaysOutput is true)
|
|
12060
|
+
if (!this.alwaysOutput && !(extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.appearance)) {
|
|
12105
12061
|
return [];
|
|
12106
12062
|
}
|
|
12107
12063
|
const classes = [];
|
|
@@ -12121,43 +12077,42 @@ class SimpleConsumerTheme extends BaseTheme {
|
|
|
12121
12077
|
}
|
|
12122
12078
|
}
|
|
12123
12079
|
|
|
12080
|
+
/**
|
|
12081
|
+
* Shadow theme using CSS variables for customizable shadows.
|
|
12082
|
+
*
|
|
12083
|
+
* Shadow variables (--shadow-base, --shadow-hover) are set via CSS rules in vars.css
|
|
12084
|
+
* based on data-vane-type and data-size attributes.
|
|
12085
|
+
* This theme only outputs the consumer classes that use those variables.
|
|
12086
|
+
* - UI: shadow-(--shadow-base) + hover:shadow-(--shadow-hover) (interactive with hover)
|
|
12087
|
+
* - Layout: shadow-(--shadow-base) (static, no hover)
|
|
12088
|
+
*/
|
|
12124
12089
|
class ShadowAppearanceTheme extends BaseTheme {
|
|
12125
|
-
constructor(
|
|
12090
|
+
constructor(shadowClasses) {
|
|
12126
12091
|
super();
|
|
12127
|
-
|
|
12128
|
-
this[key] = initial;
|
|
12129
|
-
});
|
|
12092
|
+
this.shadowClasses = shadowClasses;
|
|
12130
12093
|
}
|
|
12131
12094
|
getClasses(extractedKeys) {
|
|
12132
|
-
var _a, _b;
|
|
12133
|
-
const appearance = (_a = extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.appearance) !== null && _a !== void 0 ? _a : 'primary';
|
|
12134
|
-
const size = (_b = extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.size) !== null && _b !== void 0 ? _b : 'md';
|
|
12135
12095
|
const shadow = extractedKeys === null || extractedKeys === void 0 ? void 0 : extractedKeys.shadow;
|
|
12136
12096
|
return shadow === undefined || shadow === 'noShadow'
|
|
12137
12097
|
? []
|
|
12138
|
-
:
|
|
12098
|
+
: this.shadowClasses;
|
|
12139
12099
|
}
|
|
12140
12100
|
static createUITheme() {
|
|
12141
|
-
return new ShadowAppearanceTheme(ShadowAppearanceTheme.
|
|
12101
|
+
return new ShadowAppearanceTheme(ShadowAppearanceTheme.uiShadowClasses);
|
|
12142
12102
|
}
|
|
12143
12103
|
static createLayoutTheme() {
|
|
12144
|
-
return new ShadowAppearanceTheme(ShadowAppearanceTheme.
|
|
12104
|
+
return new ShadowAppearanceTheme(ShadowAppearanceTheme.layoutShadowClasses);
|
|
12145
12105
|
}
|
|
12146
12106
|
}
|
|
12147
|
-
|
|
12148
|
-
|
|
12149
|
-
|
|
12150
|
-
|
|
12151
|
-
|
|
12152
|
-
|
|
12153
|
-
|
|
12154
|
-
|
|
12155
|
-
|
|
12156
|
-
sm: { base: "shadow-xs", hover: "", active: "", focus: "", focusVisible: "" },
|
|
12157
|
-
md: { base: "shadow-sm", hover: "", active: "", focus: "", focusVisible: "" },
|
|
12158
|
-
lg: { base: "shadow-md", hover: "", active: "", focus: "", focusVisible: "" },
|
|
12159
|
-
xl: { base: "shadow-lg", hover: "", active: "", focus: "", focusVisible: "" }
|
|
12160
|
-
};
|
|
12107
|
+
// UI shadows: consumer classes (CSS sets variables based on data-vane-type + data-size)
|
|
12108
|
+
ShadowAppearanceTheme.uiShadowClasses = [
|
|
12109
|
+
"shadow-(--shadow-base)",
|
|
12110
|
+
"hover:shadow-(--shadow-hover)"
|
|
12111
|
+
];
|
|
12112
|
+
// Layout shadows: consumer class only (no hover)
|
|
12113
|
+
ShadowAppearanceTheme.layoutShadowClasses = [
|
|
12114
|
+
"shadow-(--shadow-base)"
|
|
12115
|
+
];
|
|
12161
12116
|
|
|
12162
12117
|
class WrapTheme extends BaseTheme {
|
|
12163
12118
|
constructor() {
|
|
@@ -12282,7 +12237,6 @@ const themeDefaults = {
|
|
|
12282
12237
|
noBorder: true,
|
|
12283
12238
|
noRing: true,
|
|
12284
12239
|
noShadow: true,
|
|
12285
|
-
responsive: true,
|
|
12286
12240
|
sharp: true,
|
|
12287
12241
|
},
|
|
12288
12242
|
stack: {
|
|
@@ -12403,7 +12357,6 @@ const themeDefaults = {
|
|
|
12403
12357
|
sans: true,
|
|
12404
12358
|
semibold: true,
|
|
12405
12359
|
textLeft: true,
|
|
12406
|
-
responsive: true,
|
|
12407
12360
|
outline: true,
|
|
12408
12361
|
primary: true,
|
|
12409
12362
|
},
|
|
@@ -12412,7 +12365,6 @@ const themeDefaults = {
|
|
|
12412
12365
|
sans: true,
|
|
12413
12366
|
semibold: true,
|
|
12414
12367
|
textLeft: true,
|
|
12415
|
-
responsive: true,
|
|
12416
12368
|
outline: true,
|
|
12417
12369
|
primary: true,
|
|
12418
12370
|
},
|
|
@@ -12421,7 +12373,6 @@ const themeDefaults = {
|
|
|
12421
12373
|
sans: true,
|
|
12422
12374
|
semibold: true,
|
|
12423
12375
|
textLeft: true,
|
|
12424
|
-
responsive: true,
|
|
12425
12376
|
outline: true,
|
|
12426
12377
|
primary: true,
|
|
12427
12378
|
},
|
|
@@ -12462,7 +12413,6 @@ const themeDefaults = {
|
|
|
12462
12413
|
filled: true,
|
|
12463
12414
|
},
|
|
12464
12415
|
wrapper: {
|
|
12465
|
-
transparent: true,
|
|
12466
12416
|
md: true,
|
|
12467
12417
|
inlineGrid: true,
|
|
12468
12418
|
itemsCenter: true,
|
|
@@ -12538,7 +12488,7 @@ const defaultButtonTheme = new ComponentTheme("button", "vane-button w-fit h-fit
|
|
|
12538
12488
|
}, themeDefaults.button, BUTTON_CATEGORIES, (props) => {
|
|
12539
12489
|
// Determine tag based on href prop
|
|
12540
12490
|
return props.href ? "a" : "button";
|
|
12541
|
-
});
|
|
12491
|
+
}, 'ui');
|
|
12542
12492
|
|
|
12543
12493
|
const defaultBadgeTheme = new ComponentTheme("span", "vane-badge w-fit h-fit transition-all duration-200 whitespace-nowrap", {
|
|
12544
12494
|
size: {
|
|
@@ -12568,7 +12518,7 @@ const defaultBadgeTheme = new ComponentTheme("span", "vane-badge w-fit h-fit tra
|
|
|
12568
12518
|
typography: defaultTypographyThemes,
|
|
12569
12519
|
}, themeDefaults.badge, BADGE_CATEGORIES, (props) => {
|
|
12570
12520
|
return props.href ? "a" : "span";
|
|
12571
|
-
});
|
|
12521
|
+
}, 'ui');
|
|
12572
12522
|
|
|
12573
12523
|
const defaultChipTheme = new ComponentTheme("span", "vane-chip w-fit h-fit transition-all duration-200 whitespace-nowrap", {
|
|
12574
12524
|
size: {
|
|
@@ -12598,7 +12548,7 @@ const defaultChipTheme = new ComponentTheme("span", "vane-chip w-fit h-fit trans
|
|
|
12598
12548
|
typography: defaultTypographyThemes,
|
|
12599
12549
|
}, themeDefaults.chip, CHIP_CATEGORIES, (props) => {
|
|
12600
12550
|
return props.href ? "a" : "span";
|
|
12601
|
-
});
|
|
12551
|
+
}, 'ui');
|
|
12602
12552
|
|
|
12603
12553
|
const defaultCodeTheme = new ComponentTheme("code", "vane-code", {
|
|
12604
12554
|
size: {
|
|
@@ -12626,7 +12576,7 @@ const defaultCodeTheme = new ComponentTheme("code", "vane-code", {
|
|
|
12626
12576
|
flexDirection: new DirectionTheme(),
|
|
12627
12577
|
},
|
|
12628
12578
|
typography: defaultTypographyThemes,
|
|
12629
|
-
}, themeDefaults.code, CODE_CATEGORIES);
|
|
12579
|
+
}, themeDefaults.code, CODE_CATEGORIES, undefined, 'ui');
|
|
12630
12580
|
|
|
12631
12581
|
/**
|
|
12632
12582
|
* Link-specific variant theme that handles text colors
|
|
@@ -12828,7 +12778,7 @@ const defaultCardTheme = new ComponentTheme("div", "vane-card", {
|
|
|
12828
12778
|
ring: new SimpleConsumerTheme({ base: ringConsumerClass }, 'ring'),
|
|
12829
12779
|
},
|
|
12830
12780
|
typography: defaultTypographyThemes,
|
|
12831
|
-
}, themeDefaults.card, CARD_CATEGORIES);
|
|
12781
|
+
}, themeDefaults.card, CARD_CATEGORIES, undefined, 'layout');
|
|
12832
12782
|
|
|
12833
12783
|
const defaultRowTheme = new ComponentTheme("div", "vane-row", {
|
|
12834
12784
|
size: {
|
|
@@ -12850,7 +12800,7 @@ const defaultRowTheme = new ComponentTheme("div", "vane-row", {
|
|
|
12850
12800
|
ring: new SimpleConsumerTheme({ base: ringConsumerClass }, 'ring'),
|
|
12851
12801
|
shadow: ShadowAppearanceTheme.createLayoutTheme(),
|
|
12852
12802
|
}
|
|
12853
|
-
}, themeDefaults.row, ROW_CATEGORIES);
|
|
12803
|
+
}, themeDefaults.row, ROW_CATEGORIES, undefined, 'layout');
|
|
12854
12804
|
|
|
12855
12805
|
const defaultDividerTheme = new ComponentTheme("div", "vane-divider h-(--bw) w-full", {
|
|
12856
12806
|
size: {
|
|
@@ -12861,7 +12811,7 @@ const defaultDividerTheme = new ComponentTheme("div", "vane-divider h-(--bw) w-f
|
|
|
12861
12811
|
background: new SimpleConsumerTheme({ base: '[background:var(--border-color)]' }, 'bg'),
|
|
12862
12812
|
},
|
|
12863
12813
|
layout: defaultLayoutsThemes,
|
|
12864
|
-
}, themeDefaults.divider, DIVIDER_CATEGORIES);
|
|
12814
|
+
}, themeDefaults.divider, DIVIDER_CATEGORIES, undefined, 'layout');
|
|
12865
12815
|
|
|
12866
12816
|
/**
|
|
12867
12817
|
* Size theme - can operate in two modes:
|
|
@@ -12922,7 +12872,7 @@ const defaultContainerTheme = new ComponentTheme("div", "vane-container mx-auto
|
|
|
12922
12872
|
ring: new SimpleConsumerTheme({ base: ringConsumerClass }, 'ring'),
|
|
12923
12873
|
shadow: ShadowAppearanceTheme.createLayoutTheme(),
|
|
12924
12874
|
}
|
|
12925
|
-
}, themeDefaults.container, CONTAINER_CATEGORIES);
|
|
12875
|
+
}, themeDefaults.container, CONTAINER_CATEGORIES, undefined, 'layout');
|
|
12926
12876
|
|
|
12927
12877
|
const defaultColTheme = new ComponentTheme("div", "vane-col", {
|
|
12928
12878
|
size: {
|
|
@@ -12943,7 +12893,7 @@ const defaultColTheme = new ComponentTheme("div", "vane-col", {
|
|
|
12943
12893
|
ring: new SimpleConsumerTheme({ base: ringConsumerClass }, 'ring'),
|
|
12944
12894
|
shadow: ShadowAppearanceTheme.createLayoutTheme(),
|
|
12945
12895
|
}
|
|
12946
|
-
}, themeDefaults.col, COL_CATEGORIES);
|
|
12896
|
+
}, themeDefaults.col, COL_CATEGORIES, undefined, 'layout');
|
|
12947
12897
|
|
|
12948
12898
|
const defaultStackTheme = new ComponentTheme("div", "vane-stack", {
|
|
12949
12899
|
size: {
|
|
@@ -12967,7 +12917,7 @@ const defaultStackTheme = new ComponentTheme("div", "vane-stack", {
|
|
|
12967
12917
|
ring: new SimpleConsumerTheme({ base: ringConsumerClass }, 'ring'),
|
|
12968
12918
|
shadow: ShadowAppearanceTheme.createLayoutTheme(),
|
|
12969
12919
|
}
|
|
12970
|
-
}, themeDefaults.stack, STACK_CATEGORIES);
|
|
12920
|
+
}, themeDefaults.stack, STACK_CATEGORIES, undefined, 'layout');
|
|
12971
12921
|
|
|
12972
12922
|
const defaultSectionTheme = new ComponentTheme("div", "vane-section w-full", {
|
|
12973
12923
|
size: {
|
|
@@ -12991,7 +12941,7 @@ const defaultSectionTheme = new ComponentTheme("div", "vane-section w-full", {
|
|
|
12991
12941
|
ring: new RingTheme(),
|
|
12992
12942
|
radius: new RadiusTheme(),
|
|
12993
12943
|
},
|
|
12994
|
-
}, themeDefaults.section, SECTION_CATEGORIES);
|
|
12944
|
+
}, themeDefaults.section, SECTION_CATEGORIES, undefined, 'layout');
|
|
12995
12945
|
|
|
12996
12946
|
const gridSubThemes = {
|
|
12997
12947
|
size: {
|
|
@@ -13010,7 +12960,7 @@ const gridSubThemes = {
|
|
|
13010
12960
|
border: new BorderTheme(),
|
|
13011
12961
|
},
|
|
13012
12962
|
};
|
|
13013
|
-
const defaultGrid2Theme = new ComponentTheme("div", "vane-grid vane-grid-2 grid-cols-1 md:grid-cols-2", gridSubThemes, themeDefaults.grid2, GRID_CATEGORIES);
|
|
12963
|
+
const defaultGrid2Theme = new ComponentTheme("div", "vane-grid vane-grid-2 grid-cols-1 md:grid-cols-2", gridSubThemes, themeDefaults.grid2, GRID_CATEGORIES, undefined, 'layout');
|
|
13014
12964
|
const defaultGrid3Theme = new ComponentTheme("div", "vane-grid vane-grid-3 grid-cols-1 md:grid-cols-3", gridSubThemes, themeDefaults.grid3, GRID_CATEGORIES);
|
|
13015
12965
|
const defaultGrid4Theme = new ComponentTheme("div", "vane-grid vane-grid-4 grid-cols-1 sm:grid-cols-2 lg:grid-cols-4", gridSubThemes, themeDefaults.grid4, GRID_CATEGORIES);
|
|
13016
12966
|
const defaultGrid5Theme = new ComponentTheme("div", "vane-grid vane-grid-5 grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-5", gridSubThemes, themeDefaults.grid5, GRID_CATEGORIES);
|
|
@@ -13038,7 +12988,7 @@ const defaultCheckboxTheme = new ComponentTheme("input", "vane-checkbox peer col
|
|
|
13038
12988
|
check: new SimpleConsumerTheme({ base: checkedBgConsumerClass }, 'bg'),
|
|
13039
12989
|
shadow: ShadowAppearanceTheme.createUITheme(),
|
|
13040
12990
|
}
|
|
13041
|
-
}, ((_a = themeDefaults.checkbox) === null || _a === void 0 ? void 0 : _a.input) || {}, CHECKBOX_CATEGORIES);
|
|
12991
|
+
}, ((_a = themeDefaults.checkbox) === null || _a === void 0 ? void 0 : _a.input) || {}, CHECKBOX_CATEGORIES, undefined, 'ui');
|
|
13042
12992
|
const defaultCheckTheme = new ComponentTheme("span", "invisible col-start-1 row-start-1 peer-checked:visible", {
|
|
13043
12993
|
checkElement: () => jsx("svg", { viewBox: "0 0 14 14", fill: "none", children: jsx("path", { d: "M3 8L6 11L11 3.5", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", fill: "none", stroke: "currentColor" }) }),
|
|
13044
12994
|
appearance: {
|
|
@@ -13085,7 +13035,7 @@ const defaultLabelTheme = new ComponentTheme("label", "vane-label has-[input]:cu
|
|
|
13085
13035
|
wrap: new WrapTheme(),
|
|
13086
13036
|
flexDirection: new DirectionTheme(),
|
|
13087
13037
|
},
|
|
13088
|
-
}, themeDefaults.label, LABEL_CATEGORIES);
|
|
13038
|
+
}, themeDefaults.label, LABEL_CATEGORIES, undefined, 'ui');
|
|
13089
13039
|
|
|
13090
13040
|
const defaultImgTheme = new ComponentTheme("img", "vane-img object-cover", // Default to cover for better image display
|
|
13091
13041
|
{
|
|
@@ -13103,7 +13053,7 @@ const defaultImgTheme = new ComponentTheme("img", "vane-img object-cover", // De
|
|
|
13103
13053
|
focusVisible: new SimpleConsumerTheme({ base: focusVisibleConsumerClass }, 'focusVisible'),
|
|
13104
13054
|
shadow: ShadowAppearanceTheme.createLayoutTheme()
|
|
13105
13055
|
}
|
|
13106
|
-
}, themeDefaults.img, IMG_CATEGORIES);
|
|
13056
|
+
}, themeDefaults.img, IMG_CATEGORIES, undefined, 'layout');
|
|
13107
13057
|
|
|
13108
13058
|
const defaultInputTheme = new ComponentTheme("input", "vane-input w-full transition-all duration-200", {
|
|
13109
13059
|
size: {
|
|
@@ -13131,7 +13081,7 @@ const defaultInputTheme = new ComponentTheme("input", "vane-input w-full transit
|
|
|
13131
13081
|
flexDirection: new DirectionTheme(),
|
|
13132
13082
|
},
|
|
13133
13083
|
typography: defaultTypographyThemes,
|
|
13134
|
-
}, themeDefaults.input, INPUT_CATEGORIES, () => "input");
|
|
13084
|
+
}, themeDefaults.input, INPUT_CATEGORIES, () => "input", 'ui');
|
|
13135
13085
|
|
|
13136
13086
|
const defaultTheme = {
|
|
13137
13087
|
button: defaultButtonTheme,
|
|
@@ -13414,7 +13364,7 @@ const Checkbox = forwardRef(function Checkbox(props, ref) {
|
|
|
13414
13364
|
// Size props
|
|
13415
13365
|
xs, sm, md, lg, xl,
|
|
13416
13366
|
// Appearance props
|
|
13417
|
-
primary, brand, accent, secondary, tertiary, success, danger, warning, info,
|
|
13367
|
+
primary, brand, accent, secondary, tertiary, success, danger, warning, info,
|
|
13418
13368
|
// Variant props
|
|
13419
13369
|
filled, outline,
|
|
13420
13370
|
// Shape props
|
|
@@ -13425,7 +13375,7 @@ const Checkbox = forwardRef(function Checkbox(props, ref) {
|
|
|
13425
13375
|
id, className, tabIndex, 'aria-label': ariaLabel, ...remainingProps } = props;
|
|
13426
13376
|
const themeProps = {
|
|
13427
13377
|
xs, sm, md, lg, xl,
|
|
13428
|
-
primary, brand, accent, secondary, tertiary, success, danger, warning, info,
|
|
13378
|
+
primary, brand, accent, secondary, tertiary, success, danger, warning, info,
|
|
13429
13379
|
filled, outline,
|
|
13430
13380
|
pill, sharp, rounded
|
|
13431
13381
|
};
|