@kirbydesign/designsystem 4.0.21 → 4.0.25

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 (41) hide show
  1. package/bundles/kirbydesign-designsystem-testing-base.umd.js +58 -36
  2. package/bundles/kirbydesign-designsystem-testing-base.umd.js.map +1 -1
  3. package/bundles/kirbydesign-designsystem-testing-base.umd.min.js +1 -1
  4. package/bundles/kirbydesign-designsystem-testing-base.umd.min.js.map +1 -1
  5. package/bundles/kirbydesign-designsystem.umd.js +38 -14
  6. package/bundles/kirbydesign-designsystem.umd.js.map +1 -1
  7. package/bundles/kirbydesign-designsystem.umd.min.js +1 -1
  8. package/bundles/kirbydesign-designsystem.umd.min.js.map +1 -1
  9. package/esm2015/kirbydesign-designsystem.js +11 -10
  10. package/esm2015/kirbydesign-designsystem.metadata.json +1 -1
  11. package/esm2015/lib/components/calendar/calendar.component.js +1 -1
  12. package/esm2015/lib/components/calendar/calendar.component.metadata.json +1 -1
  13. package/esm2015/lib/components/index.js +2 -1
  14. package/esm2015/lib/components/index.metadata.json +1 -1
  15. package/esm2015/lib/components/item/label/label.component.js +1 -1
  16. package/esm2015/lib/components/item/label/label.component.metadata.json +1 -1
  17. package/esm2015/lib/components/item-group/item-group.component.js +17 -0
  18. package/esm2015/lib/components/item-group/item-group.component.metadata.json +1 -0
  19. package/esm2015/lib/components/list/list.component.js +7 -3
  20. package/esm2015/lib/components/list/list.component.metadata.json +1 -1
  21. package/esm2015/lib/kirby.module.js +3 -1
  22. package/esm2015/lib/kirby.module.metadata.json +1 -1
  23. package/esm2015/testing-base/kirbydesign-designsystem-testing-base.js +30 -29
  24. package/esm2015/testing-base/kirbydesign-designsystem-testing-base.metadata.json +1 -1
  25. package/esm2015/testing-base/lib/components/mock.item-group.component.js +19 -0
  26. package/esm2015/testing-base/lib/components/mock.item-group.component.metadata.json +1 -0
  27. package/esm2015/testing-base/lib/mock-components.js +3 -1
  28. package/esm2015/testing-base/lib/mock-components.metadata.json +1 -1
  29. package/fesm2015/kirbydesign-designsystem-testing-base.js +20 -2
  30. package/fesm2015/kirbydesign-designsystem-testing-base.js.map +1 -1
  31. package/fesm2015/kirbydesign-designsystem.js +26 -5
  32. package/fesm2015/kirbydesign-designsystem.js.map +1 -1
  33. package/kirbydesign-designsystem.d.ts +10 -9
  34. package/kirbydesign-designsystem.metadata.json +1 -1
  35. package/lib/components/index.d.ts +1 -0
  36. package/lib/components/item-group/item-group.component.d.ts +3 -0
  37. package/lib/components/list/list.component.d.ts +1 -0
  38. package/package.json +1 -1
  39. package/testing-base/kirbydesign-designsystem-testing-base.d.ts +29 -28
  40. package/testing-base/kirbydesign-designsystem-testing-base.metadata.json +1 -1
  41. package/testing-base/lib/components/mock.item-group.component.d.ts +2 -0
@@ -5161,7 +5161,7 @@
5161
5161
  selector: 'kirby-calendar',
5162
5162
  template: "<div class=\"header\">\n <div class=\"month-navigator\">\n <button [disabled]=\"!_canNavigateBack\" (click)=\"_changeMonth(-1)\">\n <kirby-icon name=\"arrow-back\"></kirby-icon>\n </button>\n\n <div class=\"month-and-year\">\n <span class=\"month\">{{ activeMonthName }}</span\n ><span *ngIf=\"!_hasYearNavigator\" class=\"year\">{{ activeYear }}</span>\n </div>\n\n <button [disabled]=\"!_canNavigateForward\" (click)=\"_changeMonth(1)\">\n <kirby-icon name=\"arrow-more\"></kirby-icon>\n </button>\n </div>\n <kirby-dropdown\n *ngIf=\"_hasYearNavigator\"\n [selectedIndex]=\"navigatedYear\"\n [items]=\"navigableYears\"\n popout=\"left\"\n (change)=\"_changeYear($event)\"\n >\n </kirby-dropdown>\n</div>\n\n<table>\n <thead>\n <tr>\n <th *ngFor=\"let weekDay of _weekDays\">{{ weekDay }}</th>\n </tr>\n </thead>\n\n <tbody>\n <tr *ngFor=\"let week of _month\">\n <td *ngFor=\"let day of week\">\n <div\n (click)=\"_onDateSelected(day)\"\n class=\"{{ day.cssClasses }}\"\n [class.selected]=\"day.isSelected\"\n >\n {{ day.date }}\n </div>\n </td>\n </tr>\n </tbody>\n</table>\n\n<!-- <iframe src=\"kirby/components/calendar/calendar.webview.html\" #calendarContainer style=\"width: 320px; height: 304px; border: 0\"> -->\n",
5163
5163
  providers: [CalendarHelper],
5164
- styles: ["table{width:100%;border-collapse:collapse;-webkit-user-select:none;user-select:none;margin-bottom:8px}td,th{text-align:center;padding:0}td:first-child,th:first-child{padding-left:8px}td:last-child,th:last-child{padding-right:8px}th{height:50px;border-bottom:1px solid var(--kirby-background-color)}.header,td,th{background-color:transparent}.header{margin:8px 8px 0}.header,.month-navigator{display:flex;justify-content:space-between}.month-navigator{flex-grow:1;align-items:center}.month-navigator button{background-color:transparent;outline:none;border:none;cursor:pointer;height:40px;width:40px;padding:0}.month-navigator button:disabled{opacity:.5;pointer-events:none}.month-and-year{-webkit-user-select:none;user-select:none}.month-and-year .month{font-weight:700;margin-right:8px}:host(.has-year-navigator) .month-navigator{flex-grow:0}:host(.has-year-navigator) .month-and-year{width:80px;margin:0 8px;text-align:center}:host(.has-year-navigator) .month{margin-right:0}.day{display:inline-flex;align-items:center;justify-content:center;border-radius:20px;width:40px;height:40px;margin:4px 0}.day.selectable,.day.selected{cursor:pointer}.day.disabled,.day:not(.selectable){color:var(--kirby-text-color-semi-dark)}.day.today{color:var(--kirby-medium-contrast);background-color:var(--kirby-medium)}.day.selected{color:var(--kirby-black-contrast);background-color:var(--kirby-black)}.day:not(.current-month){visibility:hidden;pointer-events:none}.day.selectable:not(.selected):hover{color:var(--kirby-light-contrast);background-color:var(--kirby-light)}"]
5164
+ styles: ["table{width:100%;border-collapse:collapse;-webkit-user-select:none;user-select:none;margin-bottom:8px}td,th{text-align:center;padding:0}td:first-child,th:first-child{padding-left:8px}td:last-child,th:last-child{padding-right:8px}th{height:50px;border-bottom:1px solid var(--kirby-background-color)}.header,td,th{background-color:transparent}.header{margin:8px 8px 0}.header,.month-navigator{display:flex;justify-content:space-between}.month-navigator{flex-grow:1;align-items:center}.month-navigator button{background-color:transparent;outline:none;border:none;color:inherit;cursor:pointer;height:40px;width:40px;padding:0}.month-navigator button:disabled{opacity:.5;pointer-events:none}.month-and-year{-webkit-user-select:none;user-select:none}.month-and-year .month{font-weight:700;margin-right:8px}:host(.has-year-navigator) .month-navigator{flex-grow:0}:host(.has-year-navigator) .month-and-year{width:80px;margin:0 8px;text-align:center}:host(.has-year-navigator) .month{margin-right:0}.day{display:inline-flex;align-items:center;justify-content:center;border-radius:20px;width:40px;height:40px;margin:4px 0}.day.selectable,.day.selected{cursor:pointer}.day.disabled,.day:not(.selectable){color:var(--kirby-text-color-semi-dark)}.day.today{color:var(--kirby-medium-contrast);background-color:var(--kirby-medium)}.day.selected{color:var(--kirby-black-contrast);background-color:var(--kirby-black)}.day:not(.current-month){visibility:hidden;pointer-events:none}.day.selectable:not(.selected):hover{color:var(--kirby-light-contrast);background-color:var(--kirby-light)}"]
5165
5165
  },] }
5166
5166
  ];
5167
5167
  /** @nocollapse */
@@ -7181,7 +7181,7 @@
7181
7181
  { type: i0.Component, args: [{
7182
7182
  selector: 'kirby-label',
7183
7183
  template: "<ion-label>\n <ng-content></ng-content>\n</ion-label>\n",
7184
- styles: [":host.horizontal ion-label{display:flex;flex-direction:row;justify-content:space-between;align-items:center}:host.horizontal ion-label ::ng-deep>:not(:first-child){margin-left:12px}:host-context(kirby-item) ion-label ::ng-deep>data,:host-context(kirby-item) ion-label ::ng-deep>h1,:host-context(kirby-item) ion-label ::ng-deep>h2,:host-context(kirby-item) ion-label ::ng-deep>h3,:host-context(kirby-item) ion-label ::ng-deep>h4,:host-context(kirby-item) ion-label ::ng-deep>h5,:host-context(kirby-item) ion-label ::ng-deep>h6,:host-context(kirby-item) ion-label ::ng-deep>p{font-size:16px;line-height:24px;color:var(--kirby-text-color-black);display:block;margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-weight:400}:host-context(kirby-item) ion-label ::ng-deep>data.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h1.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h2.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h3.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h4.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h5.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h6.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>p.kirby-text-bold{font-weight:700}:host-context(kirby-item) ion-label ::ng-deep>p{font-size:14px}:host-context(kirby-item) ion-label ::ng-deep>[detail],:host-context(kirby-item) ion-label ::ng-deep>[subtitle]{font-size:12px;line-height:16px}:host-context(kirby-item) ion-label ::ng-deep>[subtitle]:not(:last-child){margin-bottom:4px}:host-context(kirby-item) ion-label ::ng-deep>[detail]{color:var(--kirby-text-color-semi-dark)}:host([slot=end]) ion-label ::ng-deep>[detail],:host([slot=end]) ion-label ::ng-deep>data{margin-inline-start:16px}:host-context(kirby-item.selected) ion-label ::ng-deep>data,:host-context(kirby-item.selected) ion-label ::ng-deep>h1,:host-context(kirby-item.selected) ion-label ::ng-deep>h2,:host-context(kirby-item.selected) ion-label ::ng-deep>h3,:host-context(kirby-item.selected) ion-label ::ng-deep>h4,:host-context(kirby-item.selected) ion-label ::ng-deep>h5,:host-context(kirby-item.selected) ion-label ::ng-deep>h6,:host-context(kirby-item.selected) ion-label ::ng-deep>p{font-weight:700}"]
7184
+ styles: [":host.horizontal ion-label{display:flex;flex-direction:row;justify-content:space-between;align-items:center}:host.horizontal ion-label ::ng-deep>:not(:first-child){margin-left:12px}:host-context(kirby-item) ion-label ::ng-deep>data,:host-context(kirby-item) ion-label ::ng-deep>h1,:host-context(kirby-item) ion-label ::ng-deep>h2,:host-context(kirby-item) ion-label ::ng-deep>h3,:host-context(kirby-item) ion-label ::ng-deep>h4,:host-context(kirby-item) ion-label ::ng-deep>h5,:host-context(kirby-item) ion-label ::ng-deep>h6,:host-context(kirby-item) ion-label ::ng-deep>p{font-size:16px;line-height:24px;color:var(--kirby-text-color-black);display:block;margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-weight:400}:host-context(kirby-item) ion-label ::ng-deep>data.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h1.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h2.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h3.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h4.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h5.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>h6.kirby-text-bold,:host-context(kirby-item) ion-label ::ng-deep>p.kirby-text-bold{font-weight:700}:host-context(kirby-item) ion-label ::ng-deep>p{font-size:14px}:host-context(kirby-item) ion-label ::ng-deep>[detail],:host-context(kirby-item) ion-label ::ng-deep>[subtitle]{font-size:12px;line-height:16px}:host-context(kirby-item) ion-label ::ng-deep>[subtitle]:not(:last-child){margin-bottom:4px}:host-context(kirby-item) ion-label ::ng-deep>[detail]{color:var(--kirby-text-color-semi-dark)}:host([slot=end]) ion-label ::ng-deep>[detail],:host([slot=end]) ion-label ::ng-deep>data{margin-inline-start:16px}:host-context(kirby-item.selected) ion-label ::ng-deep>data:not([detail]),:host-context(kirby-item.selected) ion-label ::ng-deep>h1,:host-context(kirby-item.selected) ion-label ::ng-deep>h2,:host-context(kirby-item.selected) ion-label ::ng-deep>h3,:host-context(kirby-item.selected) ion-label ::ng-deep>h4,:host-context(kirby-item.selected) ion-label ::ng-deep>h5,:host-context(kirby-item.selected) ion-label ::ng-deep>h6,:host-context(kirby-item.selected) ion-label ::ng-deep>p:not([detail]){font-weight:700}"]
7185
7185
  },] }
7186
7186
  ];
7187
7187
  LabelComponent.propDecorators = {
@@ -7202,6 +7202,23 @@
7202
7202
  },] }
7203
7203
  ];
7204
7204
 
7205
+ var ItemGroupComponent = /** @class */ (function () {
7206
+ function ItemGroupComponent() {
7207
+ this.role = 'group';
7208
+ }
7209
+ return ItemGroupComponent;
7210
+ }());
7211
+ ItemGroupComponent.decorators = [
7212
+ { type: i0.Component, args: [{
7213
+ selector: 'kirby-item-group',
7214
+ template: "<ng-content></ng-content>\n",
7215
+ styles: [":host{display:block}"]
7216
+ },] }
7217
+ ];
7218
+ ItemGroupComponent.propDecorators = {
7219
+ role: [{ type: i0.HostBinding, args: ['attr.role',] }]
7220
+ };
7221
+
7205
7222
  var SpinnerComponent = /** @class */ (function () {
7206
7223
  function SpinnerComponent() {
7207
7224
  }
@@ -7535,6 +7552,7 @@
7535
7552
  * Emitting event when an item is selected (tapped on mobile, clicked on web)
7536
7553
  */
7537
7554
  this.itemSelect = new i0.EventEmitter();
7555
+ this.disableSelectionHighlight = false;
7538
7556
  }
7539
7557
  Object.defineProperty(ListComponent.prototype, "isShapeRounded", {
7540
7558
  get: function () {
@@ -7582,8 +7600,10 @@
7582
7600
  return section.name;
7583
7601
  };
7584
7602
  ListComponent.prototype.onItemSelect = function (item) {
7585
- this._selectedItem = item;
7586
- this.itemSelect.emit(this._selectedItem);
7603
+ if (!this.disableSelectionHighlight) {
7604
+ this._selectedItem = item;
7605
+ }
7606
+ this.itemSelect.emit(item);
7587
7607
  };
7588
7608
  ListComponent.prototype.onSwipeActionSelect = function (args) {
7589
7609
  args.swipeAction.onSelected(args.item);
@@ -7631,6 +7651,7 @@
7631
7651
  loadOnDemand: [{ type: i0.Output }],
7632
7652
  swipeActions: [{ type: i0.Input }],
7633
7653
  itemSelect: [{ type: i0.Output }],
7654
+ disableSelectionHighlight: [{ type: i0.Input }],
7634
7655
  kirbyItems: [{ type: i0.ContentChildren, args: [ItemComponent,] }],
7635
7656
  headerTemplate: [{ type: i0.ContentChild, args: [ListHeaderDirective, { static: false, read: i0.TemplateRef },] }],
7636
7657
  sectionHeaderTemplate: [{ type: i0.ContentChild, args: [ListSectionHeaderDirective, { static: false, read: i0.TemplateRef },] }],
@@ -9815,6 +9836,7 @@
9815
9836
  RadioGroupComponent,
9816
9837
  RangeComponent,
9817
9838
  ElementAsButtonDirective,
9839
+ ItemGroupComponent,
9818
9840
  ];
9819
9841
  var declarations$1 = __spread(exportedDeclarations$1, [
9820
9842
  KeyHandlerDirective,
@@ -9997,6 +10019,7 @@
9997
10019
  exports.InputComponent = InputComponent;
9998
10020
  exports.InputCounterComponent = InputCounterComponent;
9999
10021
  exports.ItemComponent = ItemComponent;
10022
+ exports.ItemGroupComponent = ItemGroupComponent;
10000
10023
  exports.ItemModule = ItemModule;
10001
10024
  exports.KeyHandlerDirective = KeyHandlerDirective;
10002
10025
  exports.KirbyModule = KirbyModule;
@@ -10162,17 +10185,18 @@
10162
10185
  exports.ɵeo = AccordionItemComponent;
10163
10186
  exports.ɵep = RangeComponent;
10164
10187
  exports.ɵeq = ElementAsButtonDirective;
10165
- exports.ɵer = KeyHandlerDirective;
10166
- exports.ɵes = FormFieldMessageComponent;
10167
- exports.ɵet = AlertComponent;
10168
- exports.ɵeu = ModalCompactWrapperComponent;
10169
- exports.ɵev = ProgressCircleRingComponent;
10170
- exports.ɵew = ToastHelper;
10171
- exports.ɵex = ToastController;
10172
- exports.ɵey = LoadingOverlayService;
10173
- exports.ɵez = appInitialize;
10188
+ exports.ɵer = ItemGroupComponent;
10189
+ exports.ɵes = KeyHandlerDirective;
10190
+ exports.ɵet = FormFieldMessageComponent;
10191
+ exports.ɵeu = AlertComponent;
10192
+ exports.ɵev = ModalCompactWrapperComponent;
10193
+ exports.ɵew = ProgressCircleRingComponent;
10194
+ exports.ɵex = ToastHelper;
10195
+ exports.ɵey = ToastController;
10196
+ exports.ɵez = LoadingOverlayService;
10174
10197
  exports.ɵf = ModalHelper;
10175
- exports.ɵfa = customElementsInitializer;
10198
+ exports.ɵfa = appInitialize;
10199
+ exports.ɵfb = customElementsInitializer;
10176
10200
  exports.ɵg = ModalAnimationBuilderService;
10177
10201
  exports.ɵh = PlatformService;
10178
10202
  exports.ɵi = WindowRef;