vira 31.10.2 → 31.11.1

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.
@@ -45,12 +45,12 @@ export const ViraCheckbox = defineViraElement()({
45
45
  }
46
46
 
47
47
  label {
48
- &:hover .custom-checkbox.checked {
48
+ &:not(.disabled):hover .custom-checkbox.checked {
49
49
  background-color: ${viraFormCssVars['vira-form-accent-primary-hover-color']
50
50
  .value};
51
51
  }
52
52
 
53
- &:active .custom-checkbox.checked {
53
+ &:not(.disabled):active .custom-checkbox.checked {
54
54
  background-color: ${viraFormCssVars['vira-form-accent-primary-active-color']
55
55
  .value};
56
56
  }
@@ -63,11 +63,11 @@ export const ViraCheckbox = defineViraElement()({
63
63
  }
64
64
 
65
65
  label {
66
- &:hover .custom-checkbox:not(.checked) {
66
+ &:not(.disabled):hover .custom-checkbox:not(.checked) {
67
67
  background-color: ${viraFormCssVars['vira-form-error-hover-color'].value};
68
68
  }
69
69
 
70
- &:active .custom-checkbox:not(.checked) {
70
+ &:not(.disabled):active .custom-checkbox:not(.checked) {
71
71
  background-color: ${viraFormCssVars['vira-form-error-active-color'].value};
72
72
  }
73
73
  }
@@ -88,10 +88,10 @@ export const ViraCheckbox = defineViraElement()({
88
88
  font-weight: ${viraFormCssVars['vira-form-label-font-weight'].value};
89
89
  }
90
90
 
91
- &:hover .custom-checkbox {
91
+ &:not(.disabled):hover .custom-checkbox {
92
92
  background-color: ${viraFormCssVars['vira-form-selection-hover-color'].value};
93
93
  }
94
- &:active .custom-checkbox {
94
+ &:not(.disabled):active .custom-checkbox {
95
95
  background-color: ${viraFormCssVars['vira-form-selection-active-color'].value};
96
96
  }
97
97
  }
@@ -127,8 +127,12 @@ export const ViraCheckbox = defineViraElement()({
127
127
 
128
128
  ${hostClasses['vira-checkbox-horizontal'].selector} label {
129
129
  flex-direction: row-reverse;
130
- align-items: center;
130
+ align-items: flex-start;
131
131
  gap: 8px;
132
+
133
+ & .label-text {
134
+ padding-block: calc((24px - 1em) / 2);
135
+ }
132
136
  }
133
137
  `,
134
138
  events: {
@@ -9,6 +9,7 @@ export declare const ViraDrawer: import("element-vir").DeclarativeElementDefinit
9
9
  } & PartialWithUndefined<{
10
10
  /** If this isn't set, make sure to use the drawer title slot to fill it in. */
11
11
  drawerTitle: string;
12
+ noContentPadding: boolean;
12
13
  }>, {
13
14
  dialogElement: HTMLDialogElement | undefined;
14
15
  contentElement: HTMLDivElement | undefined;
@@ -20,4 +21,4 @@ export declare const ViraDrawer: import("element-vir").DeclarativeElementDefinit
20
21
  dragCurrentY: number;
21
22
  }, {
22
23
  drawerClose: import("element-vir").DefineEvent<void>;
23
- }, "vira-drawer-dragging", "vira-drawer-backdrop-filter" | "vira-drawer-max-height", readonly ["drawerTitle"], readonly []>;
24
+ }, "vira-drawer-dragging" | "vira-drawer-no-content-padding", "vira-drawer-backdrop-filter" | "vira-drawer-max-height", readonly ["drawerTitle"], readonly []>;
@@ -46,6 +46,7 @@ export const ViraDrawer = defineViraElement()({
46
46
  },
47
47
  hostClasses: {
48
48
  'vira-drawer-dragging': ({ state }) => state.isDragging,
49
+ 'vira-drawer-no-content-padding': ({ inputs }) => !!inputs.noContentPadding,
49
50
  },
50
51
  slotNames: ['drawerTitle'],
51
52
  cssVars: {
@@ -161,6 +162,12 @@ export const ViraDrawer = defineViraElement()({
161
162
  }
162
163
  }
163
164
  }
165
+
166
+ ${hostClasses['vira-drawer-no-content-padding'].selector} {
167
+ & dialog .drawer-content-wrapper .body {
168
+ padding: 0;
169
+ }
170
+ }
164
171
  `,
165
172
  render({ inputs, state, updateState, events, dispatch, slotNames }) {
166
173
  if (state.dialogElement && inputs.open !== state.dialogElement.open) {
@@ -28,6 +28,7 @@ export declare const ViraModal: import("element-vir").DeclarativeElementDefiniti
28
28
  blockLightDismissal: boolean;
29
29
  modalSubtitle: string;
30
30
  isMobileSize: boolean;
31
+ noContentPadding: boolean;
31
32
  }>, {
32
33
  dialogElement: HTMLDialogElement | undefined;
33
34
  contentElement: HTMLDivElement | undefined;
@@ -36,4 +37,4 @@ export declare const ViraModal: import("element-vir").DeclarativeElementDefiniti
36
37
  cleanupListeners: undefined | (() => void);
37
38
  }, {
38
39
  modalClose: import("element-vir").DefineEvent<void>;
39
- }, "vira-modal-phone-size", "vira-modal-backdrop-filter", readonly ["modalTitle"], readonly []>;
40
+ }, "vira-modal-phone-size" | "vira-modal-no-content-padding", "vira-modal-backdrop-filter", readonly ["modalTitle"], readonly []>;
@@ -40,6 +40,7 @@ export const ViraModal = defineViraElement()({
40
40
  },
41
41
  hostClasses: {
42
42
  'vira-modal-phone-size': ({ inputs }) => !!inputs.isMobileSize,
43
+ 'vira-modal-no-content-padding': ({ inputs }) => !!inputs.noContentPadding,
43
44
  },
44
45
  slotNames: ['modalTitle'],
45
46
  cssVars: {
@@ -131,6 +132,12 @@ export const ViraModal = defineViraElement()({
131
132
  }
132
133
  }
133
134
 
135
+ ${hostClasses['vira-modal-no-content-padding'].selector} {
136
+ & dialog .modal-content-wrapper .body {
137
+ padding: 0;
138
+ }
139
+ }
140
+
134
141
  ${hostClasses['vira-modal-phone-size'].selector} {
135
142
  & dialog {
136
143
  width: 100dvw;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vira",
3
- "version": "31.10.2",
3
+ "version": "31.11.1",
4
4
  "description": "A simple and highly versatile design system using element-vir.",
5
5
  "keywords": [
6
6
  "design",