@digigov/css 1.2.0-fd2cea11 → 1.2.0-mobile

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.
Files changed (124) hide show
  1. package/defaultTheme/accordion.json +8 -0
  2. package/defaultTheme/brandConfig.json +14 -2
  3. package/defaultTheme/button.json +16 -3
  4. package/defaultTheme/card.json +16 -5
  5. package/defaultTheme/form.json +15 -0
  6. package/defaultTheme/globals.json +11 -1
  7. package/defaultTheme/index.js +1 -1
  8. package/defaultTheme/layout.json +55 -0
  9. package/defaultTheme/misc.json +20 -0
  10. package/defaultTheme/panel.json +5 -0
  11. package/defaultTheme/typography.json +12 -12
  12. package/dist/base/index.css +3 -3
  13. package/dist/base.js +1 -1
  14. package/dist/components.js +1 -1
  15. package/dist/digigov.css +5 -5
  16. package/dist/utilities/index.css +1 -1
  17. package/dist/utilities.js +1 -1
  18. package/package.json +19 -14
  19. package/postcss.config.js +1 -0
  20. package/src/base/base.css +1 -1
  21. package/src/base/index.css +5 -5
  22. package/src/components/accordion.css +76 -73
  23. package/src/components/admin-header.css +7 -24
  24. package/src/components/admin-layout.css +13 -22
  25. package/src/components/autocomplete.css +106 -63
  26. package/src/components/back-to-top.css +7 -8
  27. package/src/components/blockquote.common.css +14 -0
  28. package/src/components/blockquote.css +9 -0
  29. package/src/components/blockquote.native.css +11 -0
  30. package/src/components/bottom-info.css +3 -2
  31. package/src/components/breadcrumbs.css +21 -12
  32. package/src/components/button.common.css +64 -0
  33. package/src/components/button.css +79 -95
  34. package/src/components/button.native.css +42 -0
  35. package/src/components/card.common.css +33 -0
  36. package/src/components/card.css +77 -64
  37. package/src/components/card.native.css +29 -0
  38. package/src/components/checkboxes.css +34 -37
  39. package/src/components/chip.css +36 -37
  40. package/src/components/components.css +2 -2
  41. package/src/components/copy-to-clipboard.css +39 -38
  42. package/src/components/details.common.css +26 -0
  43. package/src/components/details.css +17 -18
  44. package/src/components/details.native.css +26 -0
  45. package/src/components/dev-theme.css +3 -4
  46. package/src/components/drawer.css +58 -59
  47. package/src/components/dropdown.common.css +58 -0
  48. package/src/components/dropdown.css +81 -68
  49. package/src/components/dropdown.native.css +58 -0
  50. package/src/components/experimental.css +18 -18
  51. package/src/components/fillable.css +6 -6
  52. package/src/components/filter.css +58 -63
  53. package/src/components/footer.css +53 -39
  54. package/src/components/form.common.css +49 -0
  55. package/src/components/form.css +125 -113
  56. package/src/components/form.native.css +58 -0
  57. package/src/components/full-page-background.css +2 -2
  58. package/src/components/header.common.css +36 -0
  59. package/src/components/header.css +78 -77
  60. package/src/components/header.native.css +34 -0
  61. package/src/components/hidden.css +23 -23
  62. package/src/components/index.css +48 -47
  63. package/src/components/kitchensink.css +41 -41
  64. package/src/components/layout.common.css +8 -0
  65. package/src/components/layout.css +56 -56
  66. package/src/components/layout.native.css +5 -0
  67. package/src/components/loader.css +31 -31
  68. package/src/components/masthead.css +60 -59
  69. package/src/components/misc.css +43 -21
  70. package/src/components/modal.css +28 -21
  71. package/src/components/nav.common.css +25 -0
  72. package/src/components/nav.css +96 -89
  73. package/src/components/nav.native.css +38 -0
  74. package/src/components/notification-banner.common.css +46 -0
  75. package/src/components/notification-banner.css +32 -28
  76. package/src/components/notification-banner.native.css +42 -0
  77. package/src/components/pagination.css +40 -41
  78. package/src/components/panel.common.css +30 -0
  79. package/src/components/panel.css +12 -20
  80. package/src/components/panel.native.css +20 -0
  81. package/src/components/phase-banner.common.css +23 -0
  82. package/src/components/phase-banner.css +15 -14
  83. package/src/components/phase-banner.native.css +31 -0
  84. package/src/components/radios.css +33 -30
  85. package/src/components/skeleton.css +85 -0
  86. package/src/components/skiplink.css +3 -3
  87. package/src/components/stack.css +64 -64
  88. package/src/components/stepnav.css +68 -64
  89. package/src/components/summary-list.common.css +25 -0
  90. package/src/components/summary-list.css +59 -47
  91. package/src/components/summary-list.native.css +27 -0
  92. package/src/components/svg-icons.common.css +56 -0
  93. package/src/components/svg-icons.css +79 -75
  94. package/src/components/svg-icons.native.css +55 -0
  95. package/src/components/table.css +189 -208
  96. package/src/components/tabs.css +52 -68
  97. package/src/components/task-list.css +31 -31
  98. package/src/components/test.css +7 -0
  99. package/src/components/timeline.css +19 -18
  100. package/src/components/typography.common.css +137 -0
  101. package/src/components/typography.css +159 -226
  102. package/src/components/typography.native.css +93 -0
  103. package/src/components/warning-text.common.css +23 -0
  104. package/src/components/warning-text.css +11 -11
  105. package/src/components/warning-text.native.css +22 -0
  106. package/src/index.native.css +17 -0
  107. package/src/pages/headings/service-heading.js +9 -9
  108. package/src/pages/index.js +201 -201
  109. package/src/utilities/grid.css +221 -0
  110. package/src/utilities/grid.native.css +274 -0
  111. package/src/utilities/index.css +3 -585
  112. package/src/utilities/index.native.css +2 -0
  113. package/src/utilities/print.css +11 -0
  114. package/src/utilities/spacing.css +2133 -0
  115. package/src/utilities/utilities.css +1647 -531
  116. package/tailwind.config.js +2 -2
  117. package/themes.plugin.js +1 -1
  118. package/defaultTheme/footer.json +0 -8
  119. package/src/pages/admin-filtering-data.js +0 -160
  120. package/src/pages/admin.js +0 -61
  121. package/src/pages/dropdown.js +0 -249
  122. package/src/pages/form.js +0 -400
  123. package/src/pages/pagination.js +0 -124
  124. package/src/pages/table.js +0 -308
@@ -1,61 +1,83 @@
1
- .govgr-tooltip {
2
- @apply
3
- /* inline-block */
1
+ .ds-tooltip {
2
+ @apply /* inline-block */
4
3
  relative m-0 p-0 underline w-min cursor-pointer;
5
4
  text-decoration-style: dotted;
6
5
 
7
- .govgr-tooltiptext {
8
- @apply hidden opacity-0 transition-all text-left;
9
- backdrop-filter: blur(2px);
10
- }
11
-
12
6
  &:hover {
13
7
  &::after {
14
- content: "";
15
8
  @apply top-5 md:-mr-1 border-6 border-base-content opacity-85 absolute;
9
+ @apply md:left-1/2;
10
+ content: '';
16
11
  border-right-color: transparent;
17
12
  border-left-color: transparent;
18
13
  border-top-color: transparent;
19
14
  left: calc(50% - 6px);
20
- @apply md:left-1/2;
21
15
  }
22
16
 
23
- .govgr-tooltiptext {
17
+ .ds-tooltiptext {
24
18
  @apply block opacity-100 absolute md:w-64 md:-ml-32 top-8 md:left-1/2 px-4 py-2 z-1
25
19
  text-base-100 rounded-sm bg-base-content bg-opacity-90 shadow;
26
-
27
20
  }
28
21
  }
22
+
23
+ .ds-tooltiptext {
24
+ @apply hidden opacity-0 transition-all text-left;
25
+ backdrop-filter: blur(2px);
26
+ }
29
27
  }
30
28
 
31
29
  @media (max-width: 767.9px) {
32
- .govgr-tooltip:hover {
33
- .govgr-tooltiptext {
30
+ .ds-tooltip:hover {
31
+ .ds-tooltiptext {
34
32
  width: calc(100vw - 3.5rem);
35
33
  }
36
34
  }
37
35
  }
38
36
 
39
- .govgr-cookie-banner {
37
+ .ds-cookie-banner {
40
38
  @apply bg-base-200;
41
39
  }
42
40
 
43
41
  /* overrides */
44
42
 
45
- div[class*="govgr-grid__col-span"] {
46
- >.govgr-card {
43
+ div[class*='ds-grid__col-span'] {
44
+ > .ds-card {
47
45
  @apply mb-0;
48
46
  }
49
47
  }
50
48
 
51
- .govgr-image-logo {
49
+ .ds-image-logo {
52
50
  @apply h-10;
53
51
  }
54
52
 
55
- .govgr-image-logo--light {
53
+ .ds-image-logo-light {
56
54
  @apply h-10;
57
55
  }
58
56
 
59
- .govgr-image-logo--dark {
57
+ .ds-image-logo-dark {
60
58
  @apply h-10 hidden;
61
- }
59
+ }
60
+
61
+ .ds-test-variant {
62
+ @apply mb-4 mx-2;
63
+ }
64
+
65
+ .ds-test-variant__title {
66
+ @apply font-semibold text-3xl break-all -mb-1;
67
+ color: var(--color-red-300);
68
+ }
69
+
70
+ .ds-test-variant__content {
71
+ border-color: var(--color-red-100);
72
+ border-width: 10px;
73
+
74
+ /* For transparency check:
75
+ padding: 25px;
76
+ background-image:
77
+ linear-gradient(45deg, #ccc 25%, transparent 25%),
78
+ linear-gradient(135deg, #ccc 25%, transparent 25%),
79
+ linear-gradient(45deg, transparent 75%, #ccc 75%),
80
+ linear-gradient(135deg, transparent 75%, #ccc 75%);
81
+ background-size:25px 25px;
82
+ background-position:0 0, 12.5px 0, 12.5px -12.5px, 0px 12.5px; */
83
+ }
@@ -1,38 +1,45 @@
1
- .govgr-modal {
1
+ .ds-modal {
2
2
  @apply hidden justify-center items-center content-center text-left
3
3
  mb-7 text-base-content bg-opacity-50 bg-base-700
4
4
  fixed z-50 left-0 top-0 w-full h-full overflow-auto;
5
- }
6
5
 
7
- .govgr-modal--open {
8
- @apply flex;
6
+ &.ds-modal--open {
7
+ @apply flex;
8
+ }
9
+
10
+ &.ds-modal--dense,
11
+ &.ds-dense & {
12
+ .ds-modal__body {
13
+ @apply px-4 py-0;
14
+ }
15
+ .ds-modal__container {
16
+ @apply gap-4 my-0;
17
+ }
18
+ }
9
19
  }
10
- .govgr-modal__body {
20
+ .ds-modal__body {
11
21
  @apply w-full max-w-md md:max-w-lg lg:max-w-4xl
12
22
  h-fit md:h-auto overflow-y-auto
13
23
  bg-base-100
14
- border border-solid border-base-500;
24
+ border border-solid border-base-500 p-6;
15
25
  max-height: 95vh;
16
26
  }
17
- .govgr-modal__container {
18
- @apply grid p-10 gap-6 px-6 py-2;
27
+ .ds-modal__container {
28
+ @apply grid gap-6 -my-4;
29
+ .ds-modal__action {
30
+ @apply mb-0;
31
+ }
32
+ >.ds-heading-xs, >.ds-heading-sm, >.ds-heading-md, >.ds-heading-lg, >.ds-heading-xl {
33
+ @apply mb-0;
34
+ }
19
35
  }
20
- .govgr-modal__content {
36
+ .ds-modal__content {
21
37
  @apply text-base lg:text-xl text-lg;
22
38
  }
23
- .govgr-modal__action {
39
+ .ds-modal__action {
24
40
  @apply flex flex-wrap items-center gap-4;
25
- }
26
-
27
- .govgr-modal__action {
28
- .govgr-link,
29
- .govgr-btn {
41
+ .ds-link,
42
+ .ds-btn {
30
43
  @apply mb-0;
31
44
  }
32
45
  }
33
-
34
- .govgr-modal--dense, .govgr-dense & {
35
- .govgr-modal__container {
36
- @apply px-4 py-0 gap-4;
37
- }
38
- }
@@ -0,0 +1,25 @@
1
+ @tailwind utilities;
2
+
3
+ @layer utilities {
4
+ .util-nav {
5
+ @apply relative w-full bg-base-100 text-base-content;
6
+ }
7
+
8
+ .util-nav__list {
9
+ @apply w-full m-0 max-w-5xl flex flex-wrap flex-col;
10
+ }
11
+ .util-nav__list--vertical {
12
+
13
+ }
14
+ .util-nav__list--full-width {
15
+ @apply max-w-none;
16
+ }
17
+ .util-nav__list-item-badge {
18
+ @apply items-center justify-center p-1 bg-error relative bottom-1 rounded-3xl;
19
+ min-width: 24px;
20
+ min-height: 24px;
21
+ }
22
+ .util-nav__list-item-badge-text {
23
+ @apply text-white text-xs md:text-xs font-semibold no-underline;
24
+ }
25
+ }
@@ -1,146 +1,153 @@
1
- .govgr-nav {
1
+ .ds-nav {
2
2
  @apply relative block w-full h-auto bg-base-100 text-base-content;
3
- /* .govgr-nav__list {
4
- @apply px-3;
5
- } */
6
- .govgr-nav__list-item-link,
7
- .govgr-nav__list-item-btn {
8
- @apply md:no-underline !important;
3
+ &.ds-nav--hidden {
4
+ @apply hidden;
9
5
  }
10
- }
11
- .govgr-nav--hidden {
12
- @apply hidden;
13
- }
14
- .govgr-nav--drawer {
15
- @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4;
16
- @apply shadow-thick !important;
17
- .govgr-nav__list--horizontal {
18
- @apply px-0;
6
+ &.ds-nav--drawer {
7
+ @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4;
8
+ @apply shadow-thick !important;
9
+ .ds-nav__list--horizontal {
10
+ @apply px-0;
11
+ }
19
12
  }
20
- }
21
- .govgr-nav--drawer-smDown {
22
- @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4
13
+ &.ds-nav--drawer-smDown {
14
+ @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4
23
15
  sm:relative sm:block sm:w-full sm:h-auto sm:z-auto sm:top-auto sm:overflow-visible sm:p-0;
24
- @apply shadow-thick sm:shadow-none !important;
25
- .govgr-nav__list--horizontal {
26
- @apply px-0 sm:px-4;
16
+ @apply shadow-thick sm:shadow-none !important;
17
+ .ds-nav__list--horizontal {
18
+ @apply px-0 sm:px-4;
19
+ }
27
20
  }
28
- }
29
- .govgr-nav--drawer-mdDown {
30
- @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4
21
+ &.ds-nav--drawer-mdDown {
22
+ @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4
31
23
  md:relative md:block md:w-full md:h-auto md:z-auto md:top-auto md:overflow-visible md:p-0;
32
- @apply shadow-thick md:shadow-none !important;
33
- .govgr-nav__list--horizontal {
34
- @apply px-0 md:px-4;
24
+ @apply shadow-thick md:shadow-none !important;
25
+ .ds-nav__list--horizontal {
26
+ @apply px-0 md:px-4;
27
+ }
35
28
  }
36
- }
37
29
 
38
- .govgr-nav--drawer-lgDown {
39
- @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4
30
+ &.ds-nav--drawer-lgDown {
31
+ @apply fixed w-4/5 h-full z-30 right-0 top-0 overflow-x-auto p-4
40
32
  lg:relative lg:block lg:w-full lg:h-auto lg:z-auto lg:top-auto lg:overflow-visible lg:p-0;
41
- @apply shadow-thick lg:shadow-none !important;
42
- .govgr-nav__list--horizontal {
43
- @apply px-0 lg:px-4;
33
+ @apply shadow-thick lg:shadow-none !important;
34
+ .ds-nav__list--horizontal {
35
+ @apply px-0 lg:px-4;
36
+ }
37
+ }
38
+ &.ds-nav--border {
39
+ @apply sm:border-b sm:border-base-400;
40
+ }
41
+ .ds-nav__list-item-link,
42
+ .ds-nav__list-item-btn {
43
+ @apply md:no-underline !important;
44
44
  }
45
45
  }
46
- .govgr-nav--border {
47
- @apply sm:border-b sm:border-base-400;
48
- }
49
- .govgr-nav__list {
46
+ .ds-nav__list {
50
47
  @apply w-full m-0 max-w-5xl static flex flex-wrap flex-col;
51
- }
52
- .govgr-nav__list--horizontal {
53
- @apply sm:mx-auto sm:gap-x-6 sm:py-1 px-4 sm:flex-row;
54
- .govgr-nav__list-item {
55
- @apply sm:gap-x-6;
48
+ &.ds-nav__list--horizontal {
49
+ @apply sm:mx-auto sm:gap-x-6 sm:py-1 px-4 sm:flex-row;
50
+ .ds-nav__list-item {
51
+ @apply sm:gap-x-6;
52
+ }
53
+ }
54
+ &.ds-nav__list--full-width {
55
+ @apply max-w-none;
56
56
  }
57
57
  }
58
- .govgr-nav__list--full-width {
59
- @apply max-w-none;
60
- }
61
- .govgr-nav__list-item {
58
+ .ds-nav__list-item {
62
59
  @apply text-base-content font-normal py-1;
63
60
  }
64
- .govgr-nav__list-item-link,
65
- .govgr-nav__list-item-btn {
61
+ .ds-nav__list-item-link,
62
+ .ds-nav__list-item-btn {
66
63
  @apply text-left;
67
64
  &:focus {
68
65
  @apply bg-focus text-base-content outline-none;
69
- box-shadow: 0 -2px var(--color-focus), 0 4px var(--color-base-content);
66
+ box-shadow:
67
+ 0 -2px var(--color-focus),
68
+ 0 4px var(--color-base-content);
70
69
  }
71
70
  &:hover:not(:focus) {
72
71
  @apply underline !important;
73
72
  }
74
73
  }
75
- .govgr-nav__list-item-link--active,
76
- .govgr-nav__list-item-btn--active {
74
+ .ds-nav__list-item-link--active,
75
+ .ds-nav__list-item-btn--active {
77
76
  @apply text-base-content !important;
78
77
  @apply font-semibold;
79
78
  }
80
79
 
81
- .govgr-nav-menu {
80
+ .ds-nav__list-item-badge {
81
+ @apply inline-flex w-fit items-center justify-center p-1 ml-2
82
+ bg-error text-white text-xs md:text-xs font-semibold no-underline rounded-3xl
83
+ relative bottom-1;
84
+ min-width: 24px;
85
+ min-height: 24px;
86
+ }
87
+ .ds-nav-menu {
82
88
  @apply flex w-full;
83
- }
84
- .govgr-nav-menu--hidden {
85
- @apply hidden;
86
- }
87
- .govgr-nav-menu--horizontal {
88
- @apply sm:order-2 sm:left-0 sm:right-0 sm:relative sm:mt-3 sm:bg-base-100;
89
- .govgr-nav-menu__content-list {
90
- @apply sm:grid-rows-1 sm:grid-cols-3;
91
- }
92
- .govgr-nav-menu__title {
93
- @apply hidden sm:block;
94
- + .govgr-nav-menu__content > .govgr-nav-menu__content-list {
95
- @apply sm:grid-cols-2;
96
- }
97
- }
98
- }
99
- .govgr-nav-menu--vertical {
100
- .govgr-nav-menu__title {
89
+ &.ds-nav-menu--hidden {
101
90
  @apply hidden;
102
91
  }
103
- .govgr-nav-menu__content-list {
104
- @apply py-2 sm:py-4;
92
+ &.ds-nav-menu--horizontal {
93
+ @apply sm:order-2 sm:left-0 sm:right-0 sm:relative sm:mt-3 sm:bg-base-100;
94
+ .ds-nav-menu__content-list {
95
+ @apply sm:grid-rows-1 sm:grid-cols-3;
96
+ }
97
+ .ds-nav-menu__title {
98
+ @apply hidden sm:block;
99
+ + .ds-nav-menu__content > .ds-nav-menu__content-list {
100
+ @apply sm:grid-cols-2;
101
+ }
102
+ }
103
+ }
104
+ &.ds-nav-menu--vertical {
105
+ .ds-nav-menu__title {
106
+ @apply hidden;
107
+ }
108
+ .ds-nav-menu__content-list {
109
+ @apply py-2 sm:py-4;
110
+ }
105
111
  }
106
112
  }
107
- .govgr-nav-menu__content-list {
113
+ .ds-nav-menu__content-list {
108
114
  @apply p-0 grid grid-flow-row grid-cols-1;
109
115
  }
110
- .govgr-nav-menu__content-list-item {
116
+ .ds-nav-menu__content-list-item {
111
117
  @apply relative pt-0 pb-5 pr-3 pl-0 box-border;
112
118
  }
113
119
 
114
120
  /* overrides */
115
121
 
116
- .govgr-nav {
117
- .govgr-close-btn {
122
+ .ds-nav {
123
+ .ds-close-btn {
118
124
  @apply mb-4;
119
125
  }
120
- .govgr-heading-md {
126
+ .ds-heading-md {
121
127
  @apply mb-2 md:mb-0;
122
128
  }
123
129
  }
124
- /* .govgr-nav__list,
125
- .govgr-grid {
126
- .govgr-drawer__heading {
130
+
131
+ /* .ds-nav__list,
132
+ .ds-grid {
133
+ .ds-drawer__heading {
127
134
  @apply flex-row-reverse;
128
135
  }
129
136
  } */
130
- .govgr-nav__list-item-link,
131
- .govgr-nav__list-item-btn {
132
- > .govgr-svg-icon {
137
+ .ds-nav__list-item-link,
138
+ .ds-nav__list-item-btn {
139
+ > .ds-svg-icon {
133
140
  @apply ml-1;
134
141
  }
135
142
  }
136
- .govgr-nav__list-item-link--active,
137
- .govgr-nav__list-item-btn--active {
138
- > .govgr-svg-icon {
143
+ .ds-nav__list-item-link--active,
144
+ .ds-nav__list-item-btn--active {
145
+ > .ds-svg-icon {
139
146
  fill: var(--color-base-content) !important;
140
147
  }
141
148
  }
142
- .govgr-nav-menu--horizontal {
143
- .govgr-grid {
149
+ .ds-nav-menu--horizontal {
150
+ .ds-grid {
144
151
  @apply gap-y-2;
145
152
  }
146
153
  }
@@ -0,0 +1,38 @@
1
+ @import './nav.common.css';
2
+
3
+ .ds-nav {
4
+ @apply util-nav;
5
+ }
6
+ .ds-nav--border {
7
+ @apply xs:border-b xs:border-base-400;
8
+ }
9
+
10
+
11
+ .ds-nav__list {
12
+ @apply util-nav__list;
13
+ }
14
+ .ds-nav__list--vertical {
15
+ @apply util-nav__list--vertical;
16
+ }
17
+ .ds-nav__list--horizontal {
18
+ @apply xs:mx-auto xs:gap-x-6 xs:py-1 px-4 xs:flex-row items-center;
19
+ }
20
+ .ds-nav__list--full-width {
21
+ @apply util-nav__list--full-width;
22
+
23
+ }
24
+
25
+
26
+ .ds-nav__list-item-badge {
27
+ @apply util-nav__list-item-badge -ml-5;
28
+ }
29
+ .ds-nav__list-item-badge__text {
30
+ @apply util-nav__list-item-badge-text;
31
+ }
32
+
33
+ /* EXTRA CLASS */
34
+
35
+ .ds-nav__list-item-link__text {
36
+ line-height: 1.2rem;
37
+ color: var(--link-color);
38
+ }
@@ -0,0 +1,46 @@
1
+ /* stylelint-disable declaration-block-no-redundant-longhand-properties */
2
+ /* stylelint-disable digigov/nest-related-rules */
3
+ /* stylelint-disable digigov/enforce-class-selector-namespace */
4
+ @tailwind utilities;
5
+
6
+ @layer utilities {
7
+ .util-notification-banner {
8
+ @apply border-5 mb-6 md:mb-8 print:bg-white;
9
+
10
+ /* border-radius: var(--notification-banner-border-radius); */
11
+ }
12
+ .util-notification-banner-text {
13
+ @apply font-normal;
14
+ }
15
+ .util-notification-banner--info {
16
+ @apply bg-info border-info;
17
+ }
18
+ .util-notification-banner--success {
19
+ @apply bg-success border-success;
20
+ }
21
+ .util-notification-banner--error {
22
+ @apply bg-error border-error;
23
+ }
24
+ .util-notification-banner__header {
25
+ @apply print:border-b print:border-base-400 print:text-base-content print:pt-2;
26
+ }
27
+ .util-notification-banner__title-text {
28
+ @apply pb-2 m-0 text-white text-base md:text-lg
29
+ print:text-base-content print:pt-2;
30
+ }
31
+ .util-notification-banner__content {
32
+ @apply bg-base-100 p-4 md:p-5;
33
+ }
34
+ .util-notification-banner__content-text {
35
+ @apply text-base-content;
36
+ }
37
+ .util-notification-banner_link-text {
38
+ @apply underline text-base md:text-lg text-link;
39
+ }
40
+ .util-notification-banner_link--success-text {
41
+ @apply text-success;
42
+ }
43
+ .util-notification-banner_link--error-text {
44
+ @apply text-error;
45
+ }
46
+ }
@@ -1,43 +1,47 @@
1
- .govgr-notification-banner {
2
- @apply border-5 mb-6 md:mb-8 font-normal print:bg-white;
3
- &.govgr-notification-banner--dense, .govgr-dense & {
1
+ @import './notification-banner.common.css';
2
+
3
+ .ds-notification-banner {
4
+ @apply util-notification-banner util-notification-banner-text ;
5
+ border-radius: var(--notification-banner-border-radius);
6
+ &.ds-notification-banner--dense,
7
+ .ds-dense & {
4
8
  @apply border-4 mb-4 md:mb-5;
5
- .govgr-notification-banner__title {
9
+ .ds-notification-banner__title {
6
10
  @apply px-2 sm:px-3 pb-1;
7
11
  }
8
- .govgr-notification-banner__content {
12
+ .ds-notification-banner__content {
9
13
  @apply p-3 md:p-4;
10
14
  }
11
15
  }
12
- }
13
- .govgr-notification-banner--info {
14
- @apply bg-info border-info;
15
- }
16
- .govgr-notification-banner--success {
17
- @apply bg-success border-success;
18
- .govgr-notification-banner__link {
19
- &:link:not(:focus) {
20
- @apply text-success;
16
+ &.ds-notification-banner--info {
17
+ @apply util-notification-banner--info;
18
+ }
19
+ &.ds-notification-banner--success {
20
+ @apply util-notification-banner--success;
21
+ .ds-notification-banner__link {
22
+ &:link:not(:focus) {
23
+ @apply text-success;
24
+ }
21
25
  }
22
26
  }
23
- }
24
- .govgr-notification-banner--error {
25
- @apply bg-error border-error;
26
- .govgr-notification-banner__link {
27
- &:link:not(:focus) {
28
- @apply text-error;
27
+ &.ds-notification-banner--error {
28
+ @apply util-notification-banner--error;
29
+ .ds-notification-banner__link {
30
+ &:link:not(:focus) {
31
+ @apply text-error;
32
+ }
29
33
  }
30
34
  }
31
35
  }
32
- .govgr-notification-banner__header {
36
+ .ds-notification-banner__header {
33
37
  @apply text-white p-0 m-0 text-base md:text-lg
34
- print:border-b print:border-base-400 print:text-base-content print:pt-2;
38
+ util-notification-banner__header;
35
39
  }
36
- .govgr-notification-banner__title {
40
+ .ds-notification-banner__title {
37
41
  @apply border-b border-transparent pt-1 px-4 sm:px-5 pb-2 font-bold;
38
42
  }
39
- .govgr-notification-banner__content {
40
- @apply bg-base-100 text-base-content p-4 md:p-5;
43
+ .ds-notification-banner__content {
44
+ @apply util-notification-banner__content util-notification-banner__content-text;
41
45
  & > * {
42
46
  @apply box-border max-w-xl;
43
47
  }
@@ -45,7 +49,7 @@
45
49
  @apply mb-0;
46
50
  }
47
51
  }
48
- .govgr-notification-banner__link {
52
+ .ds-notification-banner__link {
49
53
  @apply underline text-base md:text-lg;
50
54
  &:link {
51
55
  @apply text-link;
@@ -62,8 +66,8 @@
62
66
  outline: none;
63
67
  }
64
68
  }
65
- .govgr-notification-banner__heading {
66
- .govgr-notification-banner__link {
69
+ .ds-notification-banner__heading {
70
+ .ds-notification-banner__link {
67
71
  font-size: inherit;
68
72
  }
69
73
  }
@@ -0,0 +1,42 @@
1
+ /* stylelint-disable declaration-block-no-redundant-longhand-properties */
2
+ /* stylelint-disable digigov/nest-related-rules */
3
+ @import './notification-banner.common.css';
4
+
5
+ .ds-notification-banner {
6
+ @apply util-notification-banner;
7
+ }
8
+ .ds-notification-banner__text {
9
+ @apply util-notification-banner-text;
10
+ }
11
+ .ds-notification-banner--info {
12
+ @apply util-notification-banner--info;
13
+ }
14
+ .ds-notification-banner--error {
15
+ @apply util-notification-banner--error;
16
+ }
17
+ .ds-notification-banner--success {
18
+ @apply util-notification-banner--success;
19
+ }
20
+
21
+ .ds-notification-banner__header {
22
+ @apply util-notification-banner__header;
23
+ }
24
+ .ds-notification-banner__title__text {
25
+ @apply util-notification-banner__title-text px-2 font-bold;
26
+ @apply mb-0 !important;
27
+ }
28
+ .ds-notification-banner__content {
29
+ @apply util-notification-banner__content;
30
+ }
31
+ .ds-notification-banner__content__text {
32
+ @apply util-notification-banner__content-text;
33
+ }
34
+ .ds-notification-banner__link__text {
35
+ @apply util-notification-banner_link-text;
36
+ }
37
+ .ds-notification-banner__link--success__text {
38
+ @apply util-notification-banner_link--success-text;
39
+ }
40
+ .ds-notification-banner__link--error__text {
41
+ @apply util-notification-banner_link--error-text;
42
+ }