@nextui-org/theme 0.0.0-dev-v2-20230424221531 → 0.0.0-dev-v2-20230424224035

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.
@@ -1,11 +1,15 @@
1
- import {
2
- focusVisibleClasses
3
- } from "./chunk-INZK6TTL.mjs";
4
-
5
1
  // src/components/link.ts
6
2
  import { tv } from "tailwind-variants";
7
3
  var link = tv({
8
- base: [...focusVisibleClasses, "relative inline-flex items-center [&_svg]:ml-1"],
4
+ base: [
5
+ "relative inline-flex items-center outline-none",
6
+ "data-[focus-visible=true]:outline-none",
7
+ "data-[focus-visible=true]:ring-2",
8
+ "data-[focus-visible=true]:ring-primary",
9
+ "data-[focus-visible=true]:ring-offset-2",
10
+ "data-[focus-visible=true]:ring-offset-background",
11
+ "data-[focus-visible=true]:dark:ring-offset-background-dark"
12
+ ],
9
13
  variants: {
10
14
  size: {
11
15
  xs: "text-xs",
@@ -22,12 +26,27 @@ var link = tv({
22
26
  warning: "text-warning",
23
27
  danger: "text-danger"
24
28
  },
25
- isUnderline: {
26
- true: "hover:underline active:underline focus:underline underline-offset-4",
27
- false: "no-underline"
29
+ underline: {
30
+ none: "no-underline",
31
+ hover: "hover:underline",
32
+ always: "underline",
33
+ active: "active:underline",
34
+ focus: "focus:underline"
28
35
  },
29
36
  isBlock: {
30
- true: "px-2 py-1 hover:after:opacity-100 after:content-[' '] after:inset-0 after:opacity-0 after:w-full after:h-full after:rounded-xl after:transition-background after:absolute",
37
+ true: [
38
+ "px-2",
39
+ "py-1",
40
+ "hover:after:opacity-100",
41
+ "after:content-['']",
42
+ "after:inset-0",
43
+ "after:opacity-0",
44
+ "after:w-full",
45
+ "after:h-full",
46
+ "after:rounded-xl",
47
+ "after:transition-background",
48
+ "after:absolute"
49
+ ],
31
50
  false: "hover:opacity-80 transition-opacity"
32
51
  },
33
52
  isDisabled: {
@@ -67,13 +86,17 @@ var link = tv({
67
86
  isBlock: true,
68
87
  color: "danger",
69
88
  class: "hover:after:bg-danger/20"
89
+ },
90
+ {
91
+ underline: ["hover", "always", "active", "focus"],
92
+ class: "underline-offset-4"
70
93
  }
71
94
  ],
72
95
  defaultVariants: {
73
96
  color: "primary",
74
97
  size: "md",
75
98
  isBlock: false,
76
- isUnderline: false,
99
+ underline: "none",
77
100
  isDisabled: false,
78
101
  disableAnimation: false
79
102
  }
@@ -62,15 +62,6 @@ module.exports = __toCommonJS(components_exports);
62
62
  var import_tailwind_variants = require("tailwind-variants");
63
63
 
64
64
  // src/utils/classes.ts
65
- var focusVisibleClasses = [
66
- "focus:outline-0",
67
- "focus-visible:ring-2",
68
- "focus-visible:ring-primary",
69
- "focus-visible:ring-offset-2",
70
- "focus-visible:transition-shadow",
71
- "focus-visible:ring-offset-background",
72
- "dark:focus-visible:ring-offset-background-dark"
73
- ];
74
65
  var ringClasses = [
75
66
  "outline-none",
76
67
  "ring-2",
@@ -545,7 +536,15 @@ var card = (0, import_tailwind_variants3.tv)({
545
536
  // src/components/link.ts
546
537
  var import_tailwind_variants4 = require("tailwind-variants");
547
538
  var link = (0, import_tailwind_variants4.tv)({
548
- base: [...focusVisibleClasses, "relative inline-flex items-center [&_svg]:ml-1"],
539
+ base: [
540
+ "relative inline-flex items-center outline-none",
541
+ "data-[focus-visible=true]:outline-none",
542
+ "data-[focus-visible=true]:ring-2",
543
+ "data-[focus-visible=true]:ring-primary",
544
+ "data-[focus-visible=true]:ring-offset-2",
545
+ "data-[focus-visible=true]:ring-offset-background",
546
+ "data-[focus-visible=true]:dark:ring-offset-background-dark"
547
+ ],
549
548
  variants: {
550
549
  size: {
551
550
  xs: "text-xs",
@@ -562,12 +561,27 @@ var link = (0, import_tailwind_variants4.tv)({
562
561
  warning: "text-warning",
563
562
  danger: "text-danger"
564
563
  },
565
- isUnderline: {
566
- true: "hover:underline active:underline focus:underline underline-offset-4",
567
- false: "no-underline"
564
+ underline: {
565
+ none: "no-underline",
566
+ hover: "hover:underline",
567
+ always: "underline",
568
+ active: "active:underline",
569
+ focus: "focus:underline"
568
570
  },
569
571
  isBlock: {
570
- true: "px-2 py-1 hover:after:opacity-100 after:content-[' '] after:inset-0 after:opacity-0 after:w-full after:h-full after:rounded-xl after:transition-background after:absolute",
572
+ true: [
573
+ "px-2",
574
+ "py-1",
575
+ "hover:after:opacity-100",
576
+ "after:content-['']",
577
+ "after:inset-0",
578
+ "after:opacity-0",
579
+ "after:w-full",
580
+ "after:h-full",
581
+ "after:rounded-xl",
582
+ "after:transition-background",
583
+ "after:absolute"
584
+ ],
571
585
  false: "hover:opacity-80 transition-opacity"
572
586
  },
573
587
  isDisabled: {
@@ -607,13 +621,17 @@ var link = (0, import_tailwind_variants4.tv)({
607
621
  isBlock: true,
608
622
  color: "danger",
609
623
  class: "hover:after:bg-danger/20"
624
+ },
625
+ {
626
+ underline: ["hover", "always", "active", "focus"],
627
+ class: "underline-offset-4"
610
628
  }
611
629
  ],
612
630
  defaultVariants: {
613
631
  color: "primary",
614
632
  size: "md",
615
633
  isBlock: false,
616
- isUnderline: false,
634
+ underline: "none",
617
635
  isDisabled: false,
618
636
  disableAnimation: false
619
637
  }
@@ -46,7 +46,7 @@ import {
46
46
  } from "../chunk-DBYBIR6S.mjs";
47
47
  import {
48
48
  link
49
- } from "../chunk-4FNCWRTA.mjs";
49
+ } from "../chunk-XICTHLAR.mjs";
50
50
  import {
51
51
  modal
52
52
  } from "../chunk-YMIOHWCD.mjs";
@@ -24,12 +24,15 @@ declare const link: tailwind_variants.TVReturnType<{
24
24
  warning: string;
25
25
  danger: string;
26
26
  };
27
- isUnderline: {
28
- true: string;
29
- false: string;
27
+ underline: {
28
+ none: string;
29
+ hover: string;
30
+ always: string;
31
+ active: string;
32
+ focus: string;
30
33
  };
31
34
  isBlock: {
32
- true: string;
35
+ true: string[];
33
36
  false: string;
34
37
  };
35
38
  isDisabled: {
@@ -54,12 +57,15 @@ declare const link: tailwind_variants.TVReturnType<{
54
57
  warning: string;
55
58
  danger: string;
56
59
  };
57
- isUnderline: {
58
- true: string;
59
- false: string;
60
+ underline: {
61
+ none: string;
62
+ hover: string;
63
+ always: string;
64
+ active: string;
65
+ focus: string;
60
66
  };
61
67
  isBlock: {
62
- true: string;
68
+ true: string[];
63
69
  false: string;
64
70
  };
65
71
  isDisabled: {
@@ -24,21 +24,16 @@ __export(link_exports, {
24
24
  });
25
25
  module.exports = __toCommonJS(link_exports);
26
26
  var import_tailwind_variants = require("tailwind-variants");
27
-
28
- // src/utils/classes.ts
29
- var focusVisibleClasses = [
30
- "focus:outline-0",
31
- "focus-visible:ring-2",
32
- "focus-visible:ring-primary",
33
- "focus-visible:ring-offset-2",
34
- "focus-visible:transition-shadow",
35
- "focus-visible:ring-offset-background",
36
- "dark:focus-visible:ring-offset-background-dark"
37
- ];
38
-
39
- // src/components/link.ts
40
27
  var link = (0, import_tailwind_variants.tv)({
41
- base: [...focusVisibleClasses, "relative inline-flex items-center [&_svg]:ml-1"],
28
+ base: [
29
+ "relative inline-flex items-center outline-none",
30
+ "data-[focus-visible=true]:outline-none",
31
+ "data-[focus-visible=true]:ring-2",
32
+ "data-[focus-visible=true]:ring-primary",
33
+ "data-[focus-visible=true]:ring-offset-2",
34
+ "data-[focus-visible=true]:ring-offset-background",
35
+ "data-[focus-visible=true]:dark:ring-offset-background-dark"
36
+ ],
42
37
  variants: {
43
38
  size: {
44
39
  xs: "text-xs",
@@ -55,12 +50,27 @@ var link = (0, import_tailwind_variants.tv)({
55
50
  warning: "text-warning",
56
51
  danger: "text-danger"
57
52
  },
58
- isUnderline: {
59
- true: "hover:underline active:underline focus:underline underline-offset-4",
60
- false: "no-underline"
53
+ underline: {
54
+ none: "no-underline",
55
+ hover: "hover:underline",
56
+ always: "underline",
57
+ active: "active:underline",
58
+ focus: "focus:underline"
61
59
  },
62
60
  isBlock: {
63
- true: "px-2 py-1 hover:after:opacity-100 after:content-[' '] after:inset-0 after:opacity-0 after:w-full after:h-full after:rounded-xl after:transition-background after:absolute",
61
+ true: [
62
+ "px-2",
63
+ "py-1",
64
+ "hover:after:opacity-100",
65
+ "after:content-['']",
66
+ "after:inset-0",
67
+ "after:opacity-0",
68
+ "after:w-full",
69
+ "after:h-full",
70
+ "after:rounded-xl",
71
+ "after:transition-background",
72
+ "after:absolute"
73
+ ],
64
74
  false: "hover:opacity-80 transition-opacity"
65
75
  },
66
76
  isDisabled: {
@@ -100,13 +110,17 @@ var link = (0, import_tailwind_variants.tv)({
100
110
  isBlock: true,
101
111
  color: "danger",
102
112
  class: "hover:after:bg-danger/20"
113
+ },
114
+ {
115
+ underline: ["hover", "always", "active", "focus"],
116
+ class: "underline-offset-4"
103
117
  }
104
118
  ],
105
119
  defaultVariants: {
106
120
  color: "primary",
107
121
  size: "md",
108
122
  isBlock: false,
109
- isUnderline: false,
123
+ underline: "none",
110
124
  isDisabled: false,
111
125
  disableAnimation: false
112
126
  }
@@ -1,10 +1,6 @@
1
1
  import {
2
2
  link
3
- } from "../chunk-4FNCWRTA.mjs";
4
- import "../chunk-CMYR6AOY.mjs";
5
- import "../chunk-RO3WUCFF.mjs";
6
- import "../chunk-K7LK7NCE.mjs";
7
- import "../chunk-INZK6TTL.mjs";
3
+ } from "../chunk-XICTHLAR.mjs";
8
4
  export {
9
5
  link
10
6
  };
package/dist/index.js CHANGED
@@ -568,7 +568,15 @@ var card = (0, import_tailwind_variants3.tv)({
568
568
  // src/components/link.ts
569
569
  var import_tailwind_variants4 = require("tailwind-variants");
570
570
  var link = (0, import_tailwind_variants4.tv)({
571
- base: [...focusVisibleClasses, "relative inline-flex items-center [&_svg]:ml-1"],
571
+ base: [
572
+ "relative inline-flex items-center outline-none",
573
+ "data-[focus-visible=true]:outline-none",
574
+ "data-[focus-visible=true]:ring-2",
575
+ "data-[focus-visible=true]:ring-primary",
576
+ "data-[focus-visible=true]:ring-offset-2",
577
+ "data-[focus-visible=true]:ring-offset-background",
578
+ "data-[focus-visible=true]:dark:ring-offset-background-dark"
579
+ ],
572
580
  variants: {
573
581
  size: {
574
582
  xs: "text-xs",
@@ -585,12 +593,27 @@ var link = (0, import_tailwind_variants4.tv)({
585
593
  warning: "text-warning",
586
594
  danger: "text-danger"
587
595
  },
588
- isUnderline: {
589
- true: "hover:underline active:underline focus:underline underline-offset-4",
590
- false: "no-underline"
596
+ underline: {
597
+ none: "no-underline",
598
+ hover: "hover:underline",
599
+ always: "underline",
600
+ active: "active:underline",
601
+ focus: "focus:underline"
591
602
  },
592
603
  isBlock: {
593
- true: "px-2 py-1 hover:after:opacity-100 after:content-[' '] after:inset-0 after:opacity-0 after:w-full after:h-full after:rounded-xl after:transition-background after:absolute",
604
+ true: [
605
+ "px-2",
606
+ "py-1",
607
+ "hover:after:opacity-100",
608
+ "after:content-['']",
609
+ "after:inset-0",
610
+ "after:opacity-0",
611
+ "after:w-full",
612
+ "after:h-full",
613
+ "after:rounded-xl",
614
+ "after:transition-background",
615
+ "after:absolute"
616
+ ],
594
617
  false: "hover:opacity-80 transition-opacity"
595
618
  },
596
619
  isDisabled: {
@@ -630,13 +653,17 @@ var link = (0, import_tailwind_variants4.tv)({
630
653
  isBlock: true,
631
654
  color: "danger",
632
655
  class: "hover:after:bg-danger/20"
656
+ },
657
+ {
658
+ underline: ["hover", "always", "active", "focus"],
659
+ class: "underline-offset-4"
633
660
  }
634
661
  ],
635
662
  defaultVariants: {
636
663
  color: "primary",
637
664
  size: "md",
638
665
  isBlock: false,
639
- isUnderline: false,
666
+ underline: "none",
640
667
  isDisabled: false,
641
668
  disableAnimation: false
642
669
  }
package/dist/index.mjs CHANGED
@@ -46,7 +46,7 @@ import {
46
46
  } from "./chunk-DBYBIR6S.mjs";
47
47
  import {
48
48
  link
49
- } from "./chunk-4FNCWRTA.mjs";
49
+ } from "./chunk-XICTHLAR.mjs";
50
50
  import {
51
51
  modal
52
52
  } from "./chunk-YMIOHWCD.mjs";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nextui-org/theme",
3
- "version": "0.0.0-dev-v2-20230424221531",
3
+ "version": "0.0.0-dev-v2-20230424224035",
4
4
  "description": "The default theme for NextUI components",
5
5
  "keywords": [
6
6
  "theme",