@prokodo/ui 0.1.9 → 0.1.10

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.
@@ -20,9 +20,11 @@ function AvatarView({
20
20
  { [variant]: true, [`has-size-${size}`]: true },
21
21
  className
22
22
  );
23
+ const defaultSide = getIconSize(size);
23
24
  const inner = /* @__PURE__ */ jsx("div", { ...rest, className: rootClass, tabIndex: -1, children: image ? /* @__PURE__ */ jsx(
24
25
  Image,
25
26
  {
27
+ fill: true,
26
28
  ...image,
27
29
  className: bem("image", void 0, image.className),
28
30
  tabIndex: 0
@@ -33,7 +35,7 @@ function AvatarView({
33
35
  className: bem("icon", { [variant]: true }),
34
36
  color: !["inherit", "white"].includes(variant) ? "white" : void 0,
35
37
  name: "UserIcon",
36
- size: getIconSize(size)
38
+ size: defaultSide
37
39
  }
38
40
  ) });
39
41
  return redirect ? /* @__PURE__ */ jsx(
@@ -142,7 +142,7 @@
142
142
  }
143
143
  .prokodo-Card {
144
144
  position: relative;
145
- color: var(--color-white);
145
+ color: var(--color-grey-900);
146
146
  background-color: var(--color-white);
147
147
  border-radius: 2rem;
148
148
  /* keep the gradient *class hooks*, but DO NOT include animated keyframes here */
@@ -168,12 +168,13 @@ html[data-theme=dark] .prokodo-Card--white {
168
168
  position: absolute;
169
169
  top: 0;
170
170
  left: 0;
171
- z-index: 1;
172
171
  width: 100%;
173
172
  height: 100%;
174
173
  background-repeat: no-repeat;
175
174
  background-position: center;
176
175
  background-size: cover;
176
+ border-radius: 2rem;
177
+ z-index: 1;
177
178
  }
178
179
  html[data-theme=dark] .prokodo-Card__background {
179
180
  opacity: 0.7;
@@ -188,7 +189,7 @@ html[data-theme=dark] .prokodo-Card__background {
188
189
  position: relative;
189
190
  z-index: 2;
190
191
  padding: 1.5rem;
191
- color: var(--color-grey-500);
192
+ color: var(--color-grey-900);
192
193
  }
193
194
  .prokodo-Card__content--has-link {
194
195
  cursor: pointer;
@@ -243,7 +244,7 @@ html[data-theme=dark] .prokodo-Card__background {
243
244
  position: relative;
244
245
  }
245
246
  .prokodo-Card--has-gradiant, .prokodo-Card--has-background {
246
- color: var(--color-white);
247
+ color: var(--color-grey-900);
247
248
  }
248
249
  .prokodo-Card--has-shadow {
249
250
  box-shadow: var(--elevation-1);
@@ -142,7 +142,7 @@
142
142
  }
143
143
  .prokodo-Card {
144
144
  position: relative;
145
- color: var(--color-white);
145
+ color: var(--color-grey-900);
146
146
  background-color: var(--color-white);
147
147
  border-radius: 2rem;
148
148
  /* keep the gradient *class hooks*, but DO NOT include animated keyframes here */
@@ -168,12 +168,13 @@ html[data-theme=dark] .prokodo-Card--white {
168
168
  position: absolute;
169
169
  top: 0;
170
170
  left: 0;
171
- z-index: 1;
172
171
  width: 100%;
173
172
  height: 100%;
174
173
  background-repeat: no-repeat;
175
174
  background-position: center;
176
175
  background-size: cover;
176
+ border-radius: 2rem;
177
+ z-index: 1;
177
178
  }
178
179
  html[data-theme=dark] .prokodo-Card__background {
179
180
  opacity: 0.7;
@@ -188,7 +189,7 @@ html[data-theme=dark] .prokodo-Card__background {
188
189
  position: relative;
189
190
  z-index: 2;
190
191
  padding: 1.5rem;
191
- color: var(--color-grey-500);
192
+ color: var(--color-grey-900);
192
193
  }
193
194
  .prokodo-Card__content--has-link {
194
195
  cursor: pointer;
@@ -243,7 +244,7 @@ html[data-theme=dark] .prokodo-Card__background {
243
244
  position: relative;
244
245
  }
245
246
  .prokodo-Card--has-gradiant, .prokodo-Card--has-background {
246
- color: var(--color-white);
247
+ color: var(--color-grey-900);
247
248
  }
248
249
  .prokodo-Card--has-shadow {
249
250
  box-shadow: var(--elevation-1);
@@ -134,7 +134,7 @@
134
134
  /* Alignment */
135
135
  }
136
136
  .prokodo-Headline--inherit {
137
- color: var(--color-grey-700);
137
+ color: var(--color-grey-900);
138
138
  }
139
139
  .prokodo-Headline--primary {
140
140
  color: var(--color-primary-500);
@@ -134,7 +134,7 @@
134
134
  /* Alignment */
135
135
  }
136
136
  .prokodo-Headline--inherit {
137
- color: var(--color-grey-700);
137
+ color: var(--color-grey-900);
138
138
  }
139
139
  .prokodo-Headline--primary {
140
140
  color: var(--color-primary-500);
@@ -12,7 +12,7 @@ function LinkView({
12
12
  style,
13
13
  target,
14
14
  itemProp,
15
- hasBackground,
15
+ hasBackground = false,
16
16
  ariaLabel,
17
17
  LinkTag,
18
18
  hasHandlers,
@@ -161,37 +161,6 @@
161
161
  .prokodo-SideNav--collapsed {
162
162
  width: 56px;
163
163
  }
164
- .prokodo-SideNav__collape__label {
165
- font-weight: 400;
166
- font-size: 1rem;
167
- font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
168
- font-style: normal;
169
- line-height: 1.45;
170
- letter-spacing: 0.03em;
171
- text-transform: none;
172
- text-align: left;
173
- text-decoration: none;
174
- }
175
- @media screen and (min-width: 480px) {
176
- .prokodo-SideNav__collape__label {
177
- font-size: 0.875rem;
178
- line-height: 1.4;
179
- }
180
- }
181
- @media screen and (min-width: 960px) {
182
- .prokodo-SideNav__collape__label {
183
- font-size: 0.875rem;
184
- line-height: 1.4;
185
- }
186
- }
187
- .prokodo-SideNav__collape__label--is-hidden {
188
- position: absolute;
189
- top: auto;
190
- left: -99999px;
191
- width: 0;
192
- height: 0;
193
- text-indent: -99999px;
194
- }
195
164
  .prokodo-SideNav__toggle {
196
165
  position: relative;
197
166
  display: flex;
@@ -236,7 +205,7 @@
236
205
  }
237
206
  .prokodo-SideNav__link--is-active, .prokodo-SideNav__link:hover {
238
207
  text-decoration: none;
239
- background: var(--color-grey-50);
208
+ background: var(--color-primary-100);
240
209
  }
241
210
  .prokodo-SideNav__link--is-active > div:first-of-type, .prokodo-SideNav__link:hover > div:first-of-type {
242
211
  position: relative;
@@ -255,6 +224,9 @@
255
224
  .prokodo-SideNav__link[aria-current=page] {
256
225
  background: var(--color-primary-50);
257
226
  }
227
+ .prokodo-SideNav__icon {
228
+ color: var(--color-grey-900);
229
+ }
258
230
  .prokodo-SideNav__icon__wrapper {
259
231
  display: flex;
260
232
  align-items: center;
@@ -263,7 +235,43 @@
263
235
  background: var(--color-grey-50);
264
236
  border-radius: 13px;
265
237
  }
238
+ .prokodo-SideNav__collapse__icon {
239
+ color: var(--color-grey-700);
240
+ }
241
+ .prokodo-SideNav__collapse__label {
242
+ color: var(--color-grey-700);
243
+ font-weight: 400;
244
+ font-size: 1rem;
245
+ font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
246
+ font-style: normal;
247
+ line-height: 1.45;
248
+ letter-spacing: 0.03em;
249
+ text-transform: none;
250
+ text-align: left;
251
+ text-decoration: none;
252
+ }
253
+ @media screen and (min-width: 480px) {
254
+ .prokodo-SideNav__collapse__label {
255
+ font-size: 0.875rem;
256
+ line-height: 1.4;
257
+ }
258
+ }
259
+ @media screen and (min-width: 960px) {
260
+ .prokodo-SideNav__collapse__label {
261
+ font-size: 0.875rem;
262
+ line-height: 1.4;
263
+ }
264
+ }
265
+ .prokodo-SideNav__collapse__label--is-hidden {
266
+ position: absolute;
267
+ top: auto;
268
+ left: -99999px;
269
+ width: 0;
270
+ height: 0;
271
+ text-indent: -99999px;
272
+ }
266
273
  .prokodo-SideNav__label {
274
+ color: var(--color-grey-900);
267
275
  animation: label-in 150ms ease forwards;
268
276
  font-weight: 400;
269
277
  font-size: 1.125rem;
@@ -161,37 +161,6 @@
161
161
  .prokodo-SideNav--collapsed {
162
162
  width: 56px;
163
163
  }
164
- .prokodo-SideNav__collape__label {
165
- font-weight: 400;
166
- font-size: 1rem;
167
- font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
168
- font-style: normal;
169
- line-height: 1.45;
170
- letter-spacing: 0.03em;
171
- text-transform: none;
172
- text-align: left;
173
- text-decoration: none;
174
- }
175
- @media screen and (min-width: 480px) {
176
- .prokodo-SideNav__collape__label {
177
- font-size: 0.875rem;
178
- line-height: 1.4;
179
- }
180
- }
181
- @media screen and (min-width: 960px) {
182
- .prokodo-SideNav__collape__label {
183
- font-size: 0.875rem;
184
- line-height: 1.4;
185
- }
186
- }
187
- .prokodo-SideNav__collape__label--is-hidden {
188
- position: absolute;
189
- top: auto;
190
- left: -99999px;
191
- width: 0;
192
- height: 0;
193
- text-indent: -99999px;
194
- }
195
164
  .prokodo-SideNav__toggle {
196
165
  position: relative;
197
166
  display: flex;
@@ -236,7 +205,7 @@
236
205
  }
237
206
  .prokodo-SideNav__link--is-active, .prokodo-SideNav__link:hover {
238
207
  text-decoration: none;
239
- background: var(--color-grey-50);
208
+ background: var(--color-primary-100);
240
209
  }
241
210
  .prokodo-SideNav__link--is-active > div:first-of-type, .prokodo-SideNav__link:hover > div:first-of-type {
242
211
  position: relative;
@@ -255,6 +224,9 @@
255
224
  .prokodo-SideNav__link[aria-current=page] {
256
225
  background: var(--color-primary-50);
257
226
  }
227
+ .prokodo-SideNav__icon {
228
+ color: var(--color-grey-900);
229
+ }
258
230
  .prokodo-SideNav__icon__wrapper {
259
231
  display: flex;
260
232
  align-items: center;
@@ -263,7 +235,43 @@
263
235
  background: var(--color-grey-50);
264
236
  border-radius: 13px;
265
237
  }
238
+ .prokodo-SideNav__collapse__icon {
239
+ color: var(--color-grey-700);
240
+ }
241
+ .prokodo-SideNav__collapse__label {
242
+ color: var(--color-grey-700);
243
+ font-weight: 400;
244
+ font-size: 1rem;
245
+ font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
246
+ font-style: normal;
247
+ line-height: 1.45;
248
+ letter-spacing: 0.03em;
249
+ text-transform: none;
250
+ text-align: left;
251
+ text-decoration: none;
252
+ }
253
+ @media screen and (min-width: 480px) {
254
+ .prokodo-SideNav__collapse__label {
255
+ font-size: 0.875rem;
256
+ line-height: 1.4;
257
+ }
258
+ }
259
+ @media screen and (min-width: 960px) {
260
+ .prokodo-SideNav__collapse__label {
261
+ font-size: 0.875rem;
262
+ line-height: 1.4;
263
+ }
264
+ }
265
+ .prokodo-SideNav__collapse__label--is-hidden {
266
+ position: absolute;
267
+ top: auto;
268
+ left: -99999px;
269
+ width: 0;
270
+ height: 0;
271
+ text-indent: -99999px;
272
+ }
266
273
  .prokodo-SideNav__label {
274
+ color: var(--color-grey-900);
267
275
  animation: label-in 150ms ease forwards;
268
276
  font-weight: 400;
269
277
  font-size: 1.125rem;
@@ -1,13 +1,15 @@
1
1
  const styles = {
2
2
  "prokodo-SideNav": "prokodo-SideNav",
3
3
  "prokodo-SideNav--collapsed": "prokodo-SideNav--collapsed",
4
- "prokodo-SideNav__collape__label": "prokodo-SideNav__collape__label",
5
- "prokodo-SideNav__collape__label--is-hidden": "prokodo-SideNav__collape__label--is-hidden",
6
4
  "prokodo-SideNav__toggle": "prokodo-SideNav__toggle",
7
5
  "prokodo-SideNav__list": "prokodo-SideNav__list",
8
6
  "prokodo-SideNav__link": "prokodo-SideNav__link",
9
7
  "prokodo-SideNav__link--is-active": "prokodo-SideNav__link--is-active",
8
+ "prokodo-SideNav__icon": "prokodo-SideNav__icon",
10
9
  "prokodo-SideNav__icon__wrapper": "prokodo-SideNav__icon__wrapper",
10
+ "prokodo-SideNav__collapse__icon": "prokodo-SideNav__collapse__icon",
11
+ "prokodo-SideNav__collapse__label": "prokodo-SideNav__collapse__label",
12
+ "prokodo-SideNav__collapse__label--is-hidden": "prokodo-SideNav__collapse__label--is-hidden",
11
13
  "prokodo-SideNav__label": "prokodo-SideNav__label",
12
14
  "label-in": "label-in",
13
15
  "prokodo-SideNav__label--collapsed": "prokodo-SideNav__label--collapsed",
@@ -17,7 +17,8 @@ function SideNavView({
17
17
  onToggle,
18
18
  interactive = true,
19
19
  ariaLabel = "Main navigation",
20
- className
20
+ className,
21
+ renderFooter
21
22
  }) {
22
23
  const renderItem = /* @__PURE__ */ __name((icon, label) => /* @__PURE__ */ jsxs(Fragment, { children: [
23
24
  /* @__PURE__ */ jsx("div", { className: bem("icon__wrapper"), children: /* @__PURE__ */ jsx(
@@ -50,10 +51,11 @@ function SideNavView({
50
51
  {
51
52
  size: "md",
52
53
  ...iconProps,
54
+ className: bem("collapse__icon", void 0, iconProps == null ? void 0 : iconProps.className),
53
55
  name: collapsed ? collapsedIcon : unCollapsedIcon
54
56
  }
55
57
  ),
56
- /* @__PURE__ */ jsx("span", { className: bem("collape__label", { "is-hidden": collapsed }), children: collapsed ? collapsedLabel : unCollapsedLabel })
58
+ /* @__PURE__ */ jsx("span", { className: bem("collapse__label", { "is-hidden": collapsed }), children: collapsed ? collapsedLabel : unCollapsedLabel })
57
59
  ]
58
60
  }
59
61
  ),
@@ -69,7 +71,8 @@ function SideNavView({
69
71
  ),
70
72
  children: renderItem(icon, label)
71
73
  }
72
- ) : /* @__PURE__ */ jsx(Fragment, { children: renderItem(icon, label) }) }, label)) }) })
74
+ ) : /* @__PURE__ */ jsx(Fragment, { children: renderItem(icon, label) }) }, label)) }) }),
75
+ renderFooter !== void 0 && !collapsed && renderFooter()
73
76
  ]
74
77
  }
75
78
  );
@@ -150,7 +150,7 @@
150
150
  }
151
151
  .prokodo-Skeleton {
152
152
  display: inline-block;
153
- background-color: rgba(var(--color-black), 0.11);
153
+ background-color: rgba(255, 255, 255, 0.11);
154
154
  border-radius: 4px;
155
155
  position: relative;
156
156
  overflow: hidden;
@@ -158,13 +158,20 @@
158
158
  /* variants */
159
159
  /* animation hooks (keyframes live in effects sheet) */
160
160
  }
161
+ html[data-theme=dark] .prokodo-Skeleton {
162
+ background-color: rgba(30, 48, 79, 0.11);
163
+ }
161
164
  .prokodo-Skeleton::after {
162
165
  content: "";
163
166
  display: block;
164
167
  position: absolute;
165
168
  inset: 0;
166
169
  left: -100%;
167
- background: linear-gradient(90deg, transparent, rgba(var(--color-white), 0.6), transparent);
170
+ background: linear-gradient(90deg, transparent, var(--color-white), transparent);
171
+ opacity: 0.6;
172
+ }
173
+ html[data-theme=dark] .prokodo-Skeleton::after {
174
+ background: linear-gradient(90deg, transparent, var(--color-primary-50), transparent);
168
175
  }
169
176
  .prokodo-Skeleton--text {
170
177
  height: 1em;
@@ -150,7 +150,7 @@
150
150
  }
151
151
  .prokodo-Skeleton {
152
152
  display: inline-block;
153
- background-color: rgba(var(--color-black), 0.11);
153
+ background-color: rgba(255, 255, 255, 0.11);
154
154
  border-radius: 4px;
155
155
  position: relative;
156
156
  overflow: hidden;
@@ -158,13 +158,20 @@
158
158
  /* variants */
159
159
  /* animation hooks (keyframes live in effects sheet) */
160
160
  }
161
+ html[data-theme=dark] .prokodo-Skeleton {
162
+ background-color: rgba(30, 48, 79, 0.11);
163
+ }
161
164
  .prokodo-Skeleton::after {
162
165
  content: "";
163
166
  display: block;
164
167
  position: absolute;
165
168
  inset: 0;
166
169
  left: -100%;
167
- background: linear-gradient(90deg, transparent, rgba(var(--color-white), 0.6), transparent);
170
+ background: linear-gradient(90deg, transparent, var(--color-white), transparent);
171
+ opacity: 0.6;
172
+ }
173
+ html[data-theme=dark] .prokodo-Skeleton::after {
174
+ background: linear-gradient(90deg, transparent, var(--color-primary-50), transparent);
168
175
  }
169
176
  .prokodo-Skeleton--text {
170
177
  height: 1em;
@@ -178,10 +178,10 @@
178
178
  border-bottom: 1px solid var(--color-grey-200);
179
179
  }
180
180
  .prokodo-Table__body__row--has-link:hover {
181
- background: var(--color-grey-50);
181
+ background: var(--color-primary-20);
182
182
  }
183
183
  .prokodo-Table__body__row--has-link:focus {
184
- background: var(--color-grey-50);
184
+ background: var(--color-primary-20);
185
185
  }
186
186
  .prokodo-Table__caption {
187
187
  color: var(--color-grey-300);
@@ -220,6 +220,7 @@
220
220
  justify-content: center;
221
221
  align-items: center;
222
222
  padding: 1.5rem 0.5rem;
223
+ color: var(--color-grey-900);
223
224
  font-weight: 400;
224
225
  font-size: 1.125rem;
225
226
  font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
@@ -12,6 +12,7 @@ import { RichText } from "../rich-text/RichText.js";
12
12
  const bem = create(styles, "Table");
13
13
  const Table = /* @__PURE__ */ __name(({
14
14
  id,
15
+ containerClassName,
15
16
  title,
16
17
  titleProps,
17
18
  content,
@@ -23,7 +24,7 @@ const Table = /* @__PURE__ */ __name(({
23
24
  ...props
24
25
  }) => {
25
26
  const ariaLabelId = `Table-${id}`;
26
- return /* @__PURE__ */ jsxs("div", { className: bem(), children: [
27
+ return /* @__PURE__ */ jsxs("div", { className: bem(void 0, void 0, containerClassName), children: [
27
28
  isString(title) && /* @__PURE__ */ jsx(Animated, { animation: "left-right", className: bem("header"), children: /* @__PURE__ */ jsx(
28
29
  Headline,
29
30
  {
@@ -178,10 +178,10 @@
178
178
  border-bottom: 1px solid var(--color-grey-200);
179
179
  }
180
180
  .prokodo-Table__body__row--has-link:hover {
181
- background: var(--color-grey-50);
181
+ background: var(--color-primary-20);
182
182
  }
183
183
  .prokodo-Table__body__row--has-link:focus {
184
- background: var(--color-grey-50);
184
+ background: var(--color-primary-20);
185
185
  }
186
186
  .prokodo-Table__caption {
187
187
  color: var(--color-grey-300);
@@ -220,6 +220,7 @@
220
220
  justify-content: center;
221
221
  align-items: center;
222
222
  padding: 1.5rem 0.5rem;
223
+ color: var(--color-grey-900);
223
224
  font-weight: 400;
224
225
  font-size: 1.125rem;
225
226
  font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
@@ -1,4 +1,4 @@
1
- const PROKODO_UI_VERSION = "0.1.9";
1
+ const PROKODO_UI_VERSION = "0.1.10";
2
2
  export {
3
3
  PROKODO_UI_VERSION
4
4
  };