@limetech/lime-elements 34.1.0-next.24 → 34.1.0-next.28

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 (30) hide show
  1. package/dist/cjs/limel-color-picker-palette_2.cjs.entry.js +1 -1
  2. package/dist/cjs/limel-color-picker.cjs.entry.js +1 -1
  3. package/dist/cjs/limel-grid.cjs.entry.js +1 -1
  4. package/dist/cjs/limel-list_3.cjs.entry.js +18 -1
  5. package/dist/cjs/limel-menu-list.cjs.entry.js +1 -1
  6. package/dist/collection/components/color-picker/color-picker-palette.css +5 -1
  7. package/dist/collection/components/color-picker/color-picker.css +4 -0
  8. package/dist/collection/components/grid/grid.css +1 -1
  9. package/dist/collection/components/list/list-renderer.js +17 -0
  10. package/dist/collection/components/list/list.css +323 -1
  11. package/dist/collection/components/list/list.js +1 -0
  12. package/dist/collection/components/menu-list/menu-list.css +323 -1
  13. package/dist/esm/limel-color-picker-palette_2.entry.js +1 -1
  14. package/dist/esm/limel-color-picker.entry.js +1 -1
  15. package/dist/esm/limel-grid.entry.js +1 -1
  16. package/dist/esm/limel-list_3.entry.js +18 -1
  17. package/dist/esm/limel-menu-list.entry.js +1 -1
  18. package/dist/lime-elements/lime-elements.esm.js +1 -1
  19. package/dist/lime-elements/p-1876a96a.entry.js +1 -0
  20. package/dist/lime-elements/p-6003f817.entry.js +1 -0
  21. package/dist/lime-elements/{p-b386bfeb.entry.js → p-a2cf74c1.entry.js} +1 -1
  22. package/dist/lime-elements/p-b6908630.entry.js +1 -0
  23. package/dist/lime-elements/{p-a8404021.entry.js → p-ef321d94.entry.js} +4 -4
  24. package/dist/types/components/list/list-item.types.d.ts +14 -0
  25. package/dist/types/components/list/list-renderer.d.ts +2 -0
  26. package/dist/types/components/list/list.d.ts +1 -0
  27. package/package.json +1 -1
  28. package/dist/lime-elements/p-bc8c777b.entry.js +0 -1
  29. package/dist/lime-elements/p-f5a3e526.entry.js +0 -1
  30. package/dist/lime-elements/p-f8a2dc0e.entry.js +0 -1
@@ -6,7 +6,7 @@
6
6
  */
7
7
  .color-palette {
8
8
  display: grid;
9
- grid-gap: 0.25rem;
9
+ gap: 0.25rem;
10
10
  grid-auto-flow: column;
11
11
  margin: 0.75rem auto 1.25rem auto;
12
12
  padding: 1.25rem 0.75rem;
@@ -1089,6 +1089,10 @@
1089
1089
  * Nothing in this file may output any CSS
1090
1090
  * without being explicitly called by outside code.
1091
1091
  */
1092
+ .picker-trigger[style="--background:lime-magenta;"]:after,
1093
+ .chosen-color-preview[style="--background:lime-magenta;"]:after {
1094
+ background-color: var(--lime-magenta);
1095
+ }
1092
1096
  .picker-trigger[style="--background:lime-blue;"]:after,
1093
1097
  .chosen-color-preview[style="--background:lime-blue;"]:after {
1094
1098
  background-color: var(--lime-blue);
@@ -4,6 +4,10 @@
4
4
  * Nothing in this file may output any CSS
5
5
  * without being explicitly called by outside code.
6
6
  */
7
+ .picker-trigger[style="--background:lime-magenta;"]:after,
8
+ .chosen-color-preview[style="--background:lime-magenta;"]:after {
9
+ background-color: var(--lime-magenta);
10
+ }
7
11
  .picker-trigger[style="--background:lime-blue;"]:after,
8
12
  .chosen-color-preview[style="--background:lime-blue;"]:after {
9
13
  background-color: var(--lime-blue);
@@ -23,7 +23,7 @@ slot {
23
23
  display: grid;
24
24
  grid-template-areas: var(--lime-grid-area, "");
25
25
  grid-template-columns: repeat(var(--lime-grid-columns, 4), minmax(0, 1fr));
26
- grid-gap: var(--lime-grid-gutter, 1rem);
26
+ gap: var(--lime-grid-gutter, 1rem);
27
27
  grid-auto-flow: row dense;
28
28
  grid-auto-rows: var(--lime-grid-cell-height, 2.5rem);
29
29
  margin: 0;
@@ -55,6 +55,7 @@ export class ListRenderer {
55
55
  'mdc-deprecated-list-item': true,
56
56
  'mdc-deprecated-list-item--disabled': item.disabled,
57
57
  'mdc-deprecated-list-item--selected': item.selected,
58
+ 'has-primary-component': this.hasPrimaryComponent(item),
58
59
  };
59
60
  const attributes = {};
60
61
  if (index === this.applyTabIndexToItemAtIndex) {
@@ -62,10 +63,15 @@ export class ListRenderer {
62
63
  }
63
64
  return (h("li", Object.assign({ class: classNames, "aria-disabled": item.disabled ? 'true' : 'false', "aria-selected": item.selected ? 'true' : 'false', "data-index": index }, attributes),
64
65
  item.icon ? this.renderIcon(this.config, item) : null,
66
+ this.getPrimaryComponent(item),
65
67
  this.renderText(item),
66
68
  this.twoLines && this.avatarList ? this.renderDivider() : null,
67
69
  this.renderActionMenu(item.actions)));
68
70
  };
71
+ this.hasPrimaryComponent = (item) => {
72
+ var _a;
73
+ return !!((_a = item === null || item === void 0 ? void 0 : item.primaryComponent) === null || _a === void 0 ? void 0 : _a.name);
74
+ };
69
75
  /**
70
76
  * Render the text of the list item
71
77
  *
@@ -135,6 +141,7 @@ export class ListRenderer {
135
141
  'mdc-deprecated-list-item': true,
136
142
  'mdc-deprecated-list-item--disabled': item.disabled,
137
143
  'mdc-deprecated-list-item__text': !item.secondaryText,
144
+ 'has-primary-component': this.hasPrimaryComponent(item),
138
145
  };
139
146
  const attributes = {};
140
147
  if (index === this.applyTabIndexToItemAtIndex) {
@@ -146,12 +153,14 @@ export class ListRenderer {
146
153
  if (this.hasIcons) {
147
154
  return [
148
155
  item.icon ? this.renderIcon(config, item) : null,
156
+ this.getPrimaryComponent(item),
149
157
  this.renderText(item),
150
158
  h("div", { class: "mdc-deprecated-list-item__meta" }, itemTemplate),
151
159
  ];
152
160
  }
153
161
  return [
154
162
  h("div", { class: "mdc-deprecated-list-item__graphic" }, itemTemplate),
163
+ this.getPrimaryComponent(item),
155
164
  this.renderText(item),
156
165
  ];
157
166
  };
@@ -191,4 +200,12 @@ export class ListRenderer {
191
200
  };
192
201
  return (h("ul", { class: classNames, role: role, "aria-orientation": "vertical" }, items.map(this.renderListItem)));
193
202
  }
203
+ getPrimaryComponent(item) {
204
+ if (!this.hasPrimaryComponent(item)) {
205
+ return;
206
+ }
207
+ const PrimaryComponent = item.primaryComponent.name;
208
+ const props = item.primaryComponent.props;
209
+ return h(PrimaryComponent, Object.assign({}, props));
210
+ }
194
211
  }
@@ -3085,6 +3085,9 @@ a.mdc-list-item {
3085
3085
  line-height: 100%;
3086
3086
  margin-right: -0.5rem;
3087
3087
  }
3088
+ .mdc-deprecated-list .mdc-deprecated-list-item__graphic {
3089
+ margin-right: 0.5rem;
3090
+ }
3088
3091
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list {
3089
3092
  position: relative;
3090
3093
  }
@@ -3146,6 +3149,9 @@ a.mdc-list-item {
3146
3149
  align-self: center;
3147
3150
  width: 100%;
3148
3151
  }
3152
+ .mdc-deprecated-list .has-primary-component .mdc-deprecated-list-item__text {
3153
+ margin-left: 0.5rem;
3154
+ }
3149
3155
  .mdc-deprecated-list .mdc-deprecated-list-item__primary-command-text {
3150
3156
  display: flex;
3151
3157
  flex-direction: row;
@@ -4064,6 +4070,322 @@ a.mdc-list-item {
4064
4070
  opacity: 0;
4065
4071
  }
4066
4072
  }
4073
+ .mdc-radio {
4074
+ padding: 10px;
4075
+ display: inline-block;
4076
+ position: relative;
4077
+ flex: 0 0 auto;
4078
+ box-sizing: content-box;
4079
+ width: 20px;
4080
+ height: 20px;
4081
+ cursor: pointer;
4082
+ /* @alternate */
4083
+ will-change: opacity, transform, border-color, color;
4084
+ }
4085
+
4086
+ .mdc-radio .mdc-radio__native-control:enabled:not(:checked) + .mdc-radio__background .mdc-radio__outer-circle {
4087
+ border-color: rgba(0, 0, 0, 0.54);
4088
+ }
4089
+
4090
+ .mdc-radio .mdc-radio__native-control:enabled:checked + .mdc-radio__background .mdc-radio__outer-circle {
4091
+ border-color: #575756;
4092
+ /* @alternate */
4093
+ border-color: var(--mdc-theme-secondary, #575756);
4094
+ }
4095
+
4096
+ .mdc-radio .mdc-radio__native-control:enabled + .mdc-radio__background .mdc-radio__inner-circle {
4097
+ border-color: #575756;
4098
+ /* @alternate */
4099
+ border-color: var(--mdc-theme-secondary, #575756);
4100
+ }
4101
+
4102
+ .mdc-radio [aria-disabled=true] .mdc-radio__native-control:not(:checked) + .mdc-radio__background .mdc-radio__outer-circle,
4103
+ .mdc-radio .mdc-radio__native-control:disabled:not(:checked) + .mdc-radio__background .mdc-radio__outer-circle {
4104
+ border-color: rgba(0, 0, 0, 0.38);
4105
+ }
4106
+
4107
+ .mdc-radio [aria-disabled=true] .mdc-radio__native-control:checked + .mdc-radio__background .mdc-radio__outer-circle,
4108
+ .mdc-radio .mdc-radio__native-control:disabled:checked + .mdc-radio__background .mdc-radio__outer-circle {
4109
+ border-color: rgba(0, 0, 0, 0.38);
4110
+ }
4111
+
4112
+ .mdc-radio [aria-disabled=true] .mdc-radio__native-control + .mdc-radio__background .mdc-radio__inner-circle,
4113
+ .mdc-radio .mdc-radio__native-control:disabled + .mdc-radio__background .mdc-radio__inner-circle {
4114
+ border-color: rgba(0, 0, 0, 0.38);
4115
+ }
4116
+
4117
+ .mdc-radio .mdc-radio__background::before {
4118
+ background-color: #575756;
4119
+ /* @alternate */
4120
+ background-color: var(--mdc-theme-secondary, #575756);
4121
+ }
4122
+
4123
+ .mdc-radio .mdc-radio__background::before {
4124
+ top: -10px;
4125
+ left: -10px;
4126
+ width: 40px;
4127
+ height: 40px;
4128
+ }
4129
+
4130
+ .mdc-radio .mdc-radio__native-control {
4131
+ top: 0px;
4132
+ right: 0px;
4133
+ left: 0px;
4134
+ width: 40px;
4135
+ height: 40px;
4136
+ }
4137
+
4138
+ @media screen and (-ms-high-contrast: active) {
4139
+ .mdc-radio [aria-disabled=true] .mdc-radio__native-control:not(:checked) + .mdc-radio__background .mdc-radio__outer-circle,
4140
+ .mdc-radio .mdc-radio__native-control:disabled:not(:checked) + .mdc-radio__background .mdc-radio__outer-circle {
4141
+ border-color: GrayText;
4142
+ }
4143
+
4144
+ .mdc-radio [aria-disabled=true] .mdc-radio__native-control:checked + .mdc-radio__background .mdc-radio__outer-circle,
4145
+ .mdc-radio .mdc-radio__native-control:disabled:checked + .mdc-radio__background .mdc-radio__outer-circle {
4146
+ border-color: GrayText;
4147
+ }
4148
+
4149
+ .mdc-radio [aria-disabled=true] .mdc-radio__native-control + .mdc-radio__background .mdc-radio__inner-circle,
4150
+ .mdc-radio .mdc-radio__native-control:disabled + .mdc-radio__background .mdc-radio__inner-circle {
4151
+ border-color: GrayText;
4152
+ }
4153
+ }
4154
+ .mdc-radio__background {
4155
+ display: inline-block;
4156
+ position: relative;
4157
+ box-sizing: border-box;
4158
+ width: 20px;
4159
+ height: 20px;
4160
+ }
4161
+
4162
+ .mdc-radio__background::before {
4163
+ position: absolute;
4164
+ transform: scale(0, 0);
4165
+ border-radius: 50%;
4166
+ opacity: 0;
4167
+ pointer-events: none;
4168
+ content: "";
4169
+ transition: opacity 120ms 0ms cubic-bezier(0.4, 0, 0.6, 1), transform 120ms 0ms cubic-bezier(0.4, 0, 0.6, 1);
4170
+ }
4171
+
4172
+ .mdc-radio__outer-circle {
4173
+ position: absolute;
4174
+ top: 0;
4175
+ left: 0;
4176
+ box-sizing: border-box;
4177
+ width: 100%;
4178
+ height: 100%;
4179
+ border-width: 2px;
4180
+ border-style: solid;
4181
+ border-radius: 50%;
4182
+ transition: border-color 120ms 0ms cubic-bezier(0.4, 0, 0.6, 1);
4183
+ }
4184
+
4185
+ .mdc-radio__inner-circle {
4186
+ position: absolute;
4187
+ top: 0;
4188
+ left: 0;
4189
+ box-sizing: border-box;
4190
+ width: 100%;
4191
+ height: 100%;
4192
+ transform: scale(0, 0);
4193
+ border-width: 10px;
4194
+ border-style: solid;
4195
+ border-radius: 50%;
4196
+ transition: transform 120ms 0ms cubic-bezier(0.4, 0, 0.6, 1), border-color 120ms 0ms cubic-bezier(0.4, 0, 0.6, 1);
4197
+ }
4198
+
4199
+ .mdc-radio__native-control {
4200
+ position: absolute;
4201
+ margin: 0;
4202
+ padding: 0;
4203
+ opacity: 0;
4204
+ cursor: inherit;
4205
+ z-index: 1;
4206
+ }
4207
+
4208
+ .mdc-radio--touch {
4209
+ margin-top: 4px;
4210
+ margin-bottom: 4px;
4211
+ margin-right: 4px;
4212
+ margin-left: 4px;
4213
+ }
4214
+
4215
+ .mdc-radio--touch .mdc-radio__native-control {
4216
+ top: -4px;
4217
+ right: -4px;
4218
+ left: -4px;
4219
+ width: 48px;
4220
+ height: 48px;
4221
+ }
4222
+
4223
+ .mdc-radio__native-control:checked + .mdc-radio__background,
4224
+ .mdc-radio__native-control:disabled + .mdc-radio__background {
4225
+ transition: opacity 120ms 0ms cubic-bezier(0, 0, 0.2, 1), transform 120ms 0ms cubic-bezier(0, 0, 0.2, 1);
4226
+ }
4227
+
4228
+ .mdc-radio__native-control:checked + .mdc-radio__background .mdc-radio__outer-circle,
4229
+ .mdc-radio__native-control:disabled + .mdc-radio__background .mdc-radio__outer-circle {
4230
+ transition: border-color 120ms 0ms cubic-bezier(0, 0, 0.2, 1);
4231
+ }
4232
+
4233
+ .mdc-radio__native-control:checked + .mdc-radio__background .mdc-radio__inner-circle,
4234
+ .mdc-radio__native-control:disabled + .mdc-radio__background .mdc-radio__inner-circle {
4235
+ transition: transform 120ms 0ms cubic-bezier(0, 0, 0.2, 1), border-color 120ms 0ms cubic-bezier(0, 0, 0.2, 1);
4236
+ }
4237
+
4238
+ .mdc-radio--disabled {
4239
+ cursor: default;
4240
+ pointer-events: none;
4241
+ }
4242
+
4243
+ .mdc-radio__native-control:checked + .mdc-radio__background .mdc-radio__inner-circle {
4244
+ transform: scale(0.5);
4245
+ transition: transform 120ms 0ms cubic-bezier(0, 0, 0.2, 1), border-color 120ms 0ms cubic-bezier(0, 0, 0.2, 1);
4246
+ }
4247
+
4248
+ .mdc-radio__native-control:disabled + .mdc-radio__background,
4249
+ [aria-disabled=true] .mdc-radio__native-control + .mdc-radio__background {
4250
+ cursor: default;
4251
+ }
4252
+
4253
+ .mdc-radio__native-control:focus + .mdc-radio__background::before {
4254
+ transform: scale(1);
4255
+ opacity: 0.12;
4256
+ transition: opacity 120ms 0ms cubic-bezier(0, 0, 0.2, 1), transform 120ms 0ms cubic-bezier(0, 0, 0.2, 1);
4257
+ }
4258
+
4259
+ .mdc-radio {
4260
+ --mdc-ripple-fg-size: 0;
4261
+ --mdc-ripple-left: 0;
4262
+ --mdc-ripple-top: 0;
4263
+ --mdc-ripple-fg-scale: 1;
4264
+ --mdc-ripple-fg-translate-end: 0;
4265
+ --mdc-ripple-fg-translate-start: 0;
4266
+ -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
4267
+ will-change: transform, opacity;
4268
+ }
4269
+
4270
+ .mdc-radio .mdc-radio__ripple::before,
4271
+ .mdc-radio .mdc-radio__ripple::after {
4272
+ position: absolute;
4273
+ border-radius: 50%;
4274
+ opacity: 0;
4275
+ pointer-events: none;
4276
+ content: "";
4277
+ }
4278
+
4279
+ .mdc-radio .mdc-radio__ripple::before {
4280
+ transition: opacity 15ms linear, background-color 15ms linear;
4281
+ z-index: 1;
4282
+ /* @alternate */
4283
+ z-index: var(--mdc-ripple-z-index, 1);
4284
+ }
4285
+
4286
+ .mdc-radio .mdc-radio__ripple::after {
4287
+ z-index: 0;
4288
+ /* @alternate */
4289
+ z-index: var(--mdc-ripple-z-index, 0);
4290
+ }
4291
+
4292
+ .mdc-radio.mdc-ripple-upgraded .mdc-radio__ripple::before {
4293
+ transform: scale(var(--mdc-ripple-fg-scale, 1));
4294
+ }
4295
+
4296
+ .mdc-radio.mdc-ripple-upgraded .mdc-radio__ripple::after {
4297
+ top: 0;
4298
+ /* @noflip */
4299
+ left: 0;
4300
+ transform: scale(0);
4301
+ transform-origin: center center;
4302
+ }
4303
+
4304
+ .mdc-radio.mdc-ripple-upgraded--unbounded .mdc-radio__ripple::after {
4305
+ top: var(--mdc-ripple-top, 0);
4306
+ /* @noflip */
4307
+ left: var(--mdc-ripple-left, 0);
4308
+ }
4309
+
4310
+ .mdc-radio.mdc-ripple-upgraded--foreground-activation .mdc-radio__ripple::after {
4311
+ animation: mdc-ripple-fg-radius-in 225ms forwards, mdc-ripple-fg-opacity-in 75ms forwards;
4312
+ }
4313
+
4314
+ .mdc-radio.mdc-ripple-upgraded--foreground-deactivation .mdc-radio__ripple::after {
4315
+ animation: mdc-ripple-fg-opacity-out 150ms;
4316
+ transform: translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1));
4317
+ }
4318
+
4319
+ .mdc-radio .mdc-radio__ripple::before,
4320
+ .mdc-radio .mdc-radio__ripple::after {
4321
+ top: calc(50% - 50%);
4322
+ /* @noflip */
4323
+ left: calc(50% - 50%);
4324
+ width: 100%;
4325
+ height: 100%;
4326
+ }
4327
+
4328
+ .mdc-radio.mdc-ripple-upgraded .mdc-radio__ripple::before,
4329
+ .mdc-radio.mdc-ripple-upgraded .mdc-radio__ripple::after {
4330
+ top: var(--mdc-ripple-top, calc(50% - 50%));
4331
+ /* @noflip */
4332
+ left: var(--mdc-ripple-left, calc(50% - 50%));
4333
+ width: var(--mdc-ripple-fg-size, 100%);
4334
+ height: var(--mdc-ripple-fg-size, 100%);
4335
+ }
4336
+
4337
+ .mdc-radio.mdc-ripple-upgraded .mdc-radio__ripple::after {
4338
+ width: var(--mdc-ripple-fg-size, 100%);
4339
+ height: var(--mdc-ripple-fg-size, 100%);
4340
+ }
4341
+
4342
+ .mdc-radio .mdc-radio__ripple::before, .mdc-radio .mdc-radio__ripple::after {
4343
+ background-color: #575756;
4344
+ /* @alternate */
4345
+ background-color: var(--mdc-ripple-color, var(--mdc-theme-secondary, #575756));
4346
+ }
4347
+
4348
+ .mdc-radio:hover .mdc-radio__ripple::before, .mdc-radio.mdc-ripple-surface--hover .mdc-radio__ripple::before {
4349
+ opacity: 0.04;
4350
+ /* @alternate */
4351
+ opacity: var(--mdc-ripple-hover-opacity, 0.04);
4352
+ }
4353
+
4354
+ .mdc-radio.mdc-ripple-upgraded--background-focused .mdc-radio__ripple::before, .mdc-radio:not(.mdc-ripple-upgraded):focus .mdc-radio__ripple::before {
4355
+ transition-duration: 75ms;
4356
+ opacity: 0.12;
4357
+ /* @alternate */
4358
+ opacity: var(--mdc-ripple-focus-opacity, 0.12);
4359
+ }
4360
+
4361
+ .mdc-radio:not(.mdc-ripple-upgraded) .mdc-radio__ripple::after {
4362
+ transition: opacity 150ms linear;
4363
+ }
4364
+
4365
+ .mdc-radio:not(.mdc-ripple-upgraded):active .mdc-radio__ripple::after {
4366
+ transition-duration: 75ms;
4367
+ opacity: 0.12;
4368
+ /* @alternate */
4369
+ opacity: var(--mdc-ripple-press-opacity, 0.12);
4370
+ }
4371
+
4372
+ .mdc-radio.mdc-ripple-upgraded {
4373
+ --mdc-ripple-fg-opacity: var(--mdc-ripple-press-opacity, 0.12);
4374
+ }
4375
+
4376
+ .mdc-radio.mdc-ripple-upgraded .mdc-radio__background::before, .mdc-radio.mdc-ripple-upgraded--background-focused .mdc-radio__background::before {
4377
+ content: none;
4378
+ }
4379
+
4380
+ .mdc-radio__ripple {
4381
+ position: absolute;
4382
+ top: 0;
4383
+ left: 0;
4384
+ width: 100%;
4385
+ height: 100%;
4386
+ pointer-events: none;
4387
+ }
4388
+
4067
4389
  .mdc-form-field {
4068
4390
  -moz-osx-font-smoothing: grayscale;
4069
4391
  -webkit-font-smoothing: antialiased;
@@ -4225,7 +4547,7 @@ a.mdc-list-item {
4225
4547
  }
4226
4548
  :host(.has-grid-layout) .mdc-deprecated-list {
4227
4549
  display: grid;
4228
- grid-gap: var(--gap);
4550
+ gap: var(--gap);
4229
4551
  grid-template-columns: repeat(auto-fit, minmax(min(100%, max(calc(var(--list-grid-item-max-width, 10rem) - var(--gap)), var(--list-grid-item-min-width, 7.5rem))), 1fr));
4230
4552
  max-width: var(--list-grid-max-width, 100%);
4231
4553
  }
@@ -18,6 +18,7 @@ const { ACTION_EVENT } = listStrings;
18
18
  * @exampleComponent limel-example-list-striped
19
19
  * @exampleComponent limel-example-list-badge-icons-with-multiple-lines
20
20
  * @exampleComponent limel-example-list-grid
21
+ * @exampleComponent limel-example-list-primary-component
21
22
  */
22
23
  export class List {
23
24
  constructor() {