@descope/web-components-ui 2.2.15 → 2.2.17

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/index.cjs.js +100 -23
  2. package/dist/cjs/index.cjs.js.map +1 -1
  3. package/dist/index.esm.js +106 -29
  4. package/dist/index.esm.js.map +1 -1
  5. package/dist/umd/DescopeDev.js +1 -1
  6. package/dist/umd/DescopeDev.js.map +1 -1
  7. package/dist/umd/descope-apps-list.js +2 -2
  8. package/dist/umd/descope-apps-list.js.map +1 -1
  9. package/dist/umd/descope-list.js +1 -1
  10. package/dist/umd/descope-list.js.map +1 -1
  11. package/dist/umd/descope-outbound-apps.js +1 -1
  12. package/dist/umd/descope-outbound-apps.js.map +1 -1
  13. package/dist/umd/descope-recovery-codes.js.map +1 -1
  14. package/dist/umd/descope-scopes-list-index-js.js +1 -1
  15. package/dist/umd/descope-scopes-list-index-js.js.map +1 -1
  16. package/dist/umd/descope-trusted-devices.js +1 -1
  17. package/dist/umd/descope-trusted-devices.js.map +1 -1
  18. package/dist/umd/descope-user-attribute-index-js.js +4 -4
  19. package/dist/umd/descope-user-attribute-index-js.js.LICENSE.txt +0 -6
  20. package/dist/umd/descope-user-attribute-index-js.js.map +1 -1
  21. package/dist/umd/descope-user-auth-method-index-js.js +1 -1
  22. package/dist/umd/descope-user-auth-method-index-js.js.map +1 -1
  23. package/dist/umd/index.js +1 -1
  24. package/dist/umd/index.js.map +1 -1
  25. package/package.json +29 -29
  26. package/src/components/descope-user-attribute/UserAttributeClass.js +26 -8
  27. package/src/components/descope-user-attribute/delete.svg +2 -2
  28. package/src/components/descope-user-attribute/edit.svg +2 -2
  29. package/src/components/descope-user-attribute/index.js +1 -1
  30. package/src/components/descope-user-auth-method/UserAuthMethodClass.js +1 -1
@@ -14409,6 +14409,14 @@ const avatar = {
14409
14409
  [compVars$4.hostWidth]: '98px',
14410
14410
  [compVars$4.hostHeight]: '98px',
14411
14411
  },
14412
+ xl: {
14413
+ [compVars$4.hostWidth]: '120px',
14414
+ [compVars$4.hostHeight]: '120px',
14415
+ },
14416
+ '2xl': {
14417
+ [compVars$4.hostWidth]: '140px',
14418
+ [compVars$4.hostHeight]: '140px',
14419
+ },
14412
14420
  },
14413
14421
  };
14414
14422
 
@@ -14632,9 +14640,9 @@ var mappingsField$1 = /*#__PURE__*/Object.freeze({
14632
14640
  vars: vars$x
14633
14641
  });
14634
14642
 
14635
- var deleteIcon = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTQiIGhlaWdodD0iMTgiIHZpZXdCb3g9IjAgMCAxNCAxOCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTEgMTZDMSAxNy4xIDEuOSAxOCAzIDE4SDExQzEyLjEgMTggMTMgMTcuMSAxMyAxNlY0SDFWMTZaTTMgNkgxMVYxNkgzVjZaTTEwLjUgMUw5LjUgMEg0LjVMMy41IDFIMFYzSDE0VjFIMTAuNVoiIGZpbGw9ImN1cnJlbnRjb2xvciIvPgo8L3N2Zz4K";
14643
+ var deleteIcon = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTQiIGhlaWdodD0iMTgiIHZpZXdCb3g9IjAgMCAxNCAxOCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KICA8cGF0aCBkPSJNMSAxNkMxIDE3LjEgMS45IDE4IDMgMThIMTFDMTIuMSAxOCAxMyAxNy4xIDEzIDE2VjRIMVYxNlpNMyA2SDExVjE2SDNWNlpNMTAuNSAxTDkuNSAwSDQuNUwzLjUgMUgwVjNIMTRWMUgxMC41WiIgZmlsbD0iY3VycmVudGNvbG9yIi8+Cjwvc3ZnPg==";
14636
14644
 
14637
- var editIcon = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTUiIGhlaWdodD0iMTUiIHZpZXdC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MDgyIDExLjAwODIgMTUuMDA4MkgzLjAxNjE5QzEuMzM2MTkgMTUuMDA4MiAtMC4wMDc4MTI1IDEzLjY2NDIgLTAuMDA3ODEyNSAxMS45ODQyVjMuOTkyMTVDLTAuMDA3ODEyNSAyLjMzNjE1IDEuMzM2MTkgMC45OTIxNDkgMy4wMTYxOSAwLjk5MjE0OUgxMC4wMDAyWk0xMS4yNzIyIDIuNjI0MTVMMTIuNjE2MiA0LjExMjE1TDcuNzIwMTkgOS42ODAxNkM3LjUwNDE5IDkuOTIwMTYgNi44MzIxOSAxMC4yMzIyIDUuNjgwMTkgMTAuNjE2MkM1LjY1NjE5IDEwLjY0MDIgNS42MDgxOSAxMC42NDAyIDUuNTYwMTkgMTAuNjE2MkM1LjQ2NDE5IDEwLjU5MjIgNS4zOTIxOSAxMC40NzIyIDUuNDQwMTkgMTAuMzc2MkM1Ljc1MjE5IDkuMjQ4MTYgNi4wNDAxOSA4LjU1MjE2IDYuMjU2MTkgOC4zMTIxNkwxMS4yNzIyIDIuNjI0MTVaTTExLjkyMDIgMS44NTYxNUwxMy4yODgyIDAuMzIwMTQ5QzEzLjY0ODIgLTAuMDg3ODUxNiAxNC4yNzIyIC0wLjExMTg1MiAxNC42ODAyIDAuMjcyMTQ5QzE1LjA4ODIgMC42MzIxNDkgMTUuMTEyMiAxLjI4MDE1IDE0Ljc1MjIgMS42ODgxNUwxMy4yNjQyIDMuMzY4MTVMMTEuOTIwMiAxLjg1NjE1WiIgZmlsbD0iY3VycmVudGNvbG9yIi8+Cjwvc3ZnPgo=";
14638
14646
 
14639
14647
  const componentName$x = getComponentName$1('user-attribute');
14640
14648
  class RawUserAttribute extends createBaseClass({
@@ -14652,10 +14660,10 @@ class RawUserAttribute extends createBaseClass({
14652
14660
  <div class="btn-wrapper">
14653
14661
  <descope-badge mode="default" bordered="true" size="xs"></descope-badge>
14654
14662
  <descope-button size="xs" data-id="edit-btn" square="true" variant="link" mode="primary">
14655
- <vaadin-icon src=${editIcon}></vaadin-icon>
14663
+ <slot name="edit-icon"></slot>
14656
14664
  </descope-button>
14657
14665
  <descope-button size="xs" data-id="delete-btn" square="true" variant="link" mode="primary">
14658
- <vaadin-icon src=${deleteIcon}></vaadin-icon>
14666
+ <slot name="delete-icon"></slot>
14659
14667
  </descope-button>
14660
14668
  </div>
14661
14669
  </div>
@@ -14669,16 +14677,18 @@ class RawUserAttribute extends createBaseClass({
14669
14677
  container-type: inline-size;
14670
14678
  }
14671
14679
 
14672
- vaadin-icon {
14673
- color: currentcolor;
14674
- }
14675
-
14676
14680
  .root {
14677
14681
  display: flex;
14678
14682
  width: 100%;
14679
14683
  height: 100%;
14680
14684
  align-items: center;
14681
14685
  }
14686
+
14687
+ ::slotted(*) {
14688
+ display: flex;
14689
+ align-items: center;
14690
+ justify-content: center;
14691
+ }
14682
14692
 
14683
14693
  @container (max-width: 529px) {
14684
14694
  .root {
@@ -14818,6 +14828,22 @@ class RawUserAttribute extends createBaseClass({
14818
14828
  this.editButton.addEventListener('click', () =>
14819
14829
  this.dispatchEvent(new CustomEvent('edit-clicked', { bubbles: true, composed: true }))
14820
14830
  );
14831
+
14832
+ this.setDefaultChildren();
14833
+ }
14834
+
14835
+ #addIcon(src, slotName) {
14836
+ const icon = document.createElement('descope-icon');
14837
+ icon.setAttribute('src', src);
14838
+ icon.setAttribute('src-dark', src);
14839
+ icon.setAttribute('slot', slotName);
14840
+ this.appendChild(icon);
14841
+ }
14842
+
14843
+ setDefaultChildren() {
14844
+ if (this.children.length) return;
14845
+ this.#addIcon(deleteIcon, 'delete-icon');
14846
+ this.#addIcon(editIcon, 'edit-icon');
14821
14847
  }
14822
14848
 
14823
14849
  static get observedAttributes() {
@@ -18461,6 +18487,9 @@ const ListClass = compose(
18461
18487
  selector: () => '::slotted(:not([slot]))',
18462
18488
  property: 'min-width',
18463
18489
  },
18490
+ maxRowItems: {
18491
+ property: 'max-row-items',
18492
+ },
18464
18493
  itemsHorizontalAlign: {
18465
18494
  selector: () => '::slotted(*)',
18466
18495
  property: 'justify-self',
@@ -18482,7 +18511,7 @@ const ListClass = compose(
18482
18511
  const componentName$m = getComponentName('apps-list');
18483
18512
 
18484
18513
  const itemRenderer$4 = ({ name, icon, url }, _, ref) => `
18485
- <a ${url ? `href="${url}" title="${url}"` : ''} target="_blank">
18514
+ <a ${url ? `href="${url}" title="${url}"` : ''} ${ref.openInSameWindow ? '' : 'target="_blank"'}>
18486
18515
  <descope-list-item>
18487
18516
  <div class="avatar-wrapper">
18488
18517
  <descope-avatar
@@ -18513,6 +18542,10 @@ const customMixin$2 = (superclass) =>
18513
18542
  get logoSize() {
18514
18543
  return this.getAttribute('logo-size');
18515
18544
  }
18545
+
18546
+ get openInSameWindow() {
18547
+ return this.getAttribute('open-in-same-window') === 'true';
18548
+ }
18516
18549
  };
18517
18550
 
18518
18551
  const AppsListClass = compose(
@@ -18521,6 +18554,14 @@ const AppsListClass = compose(
18521
18554
  maxHeight: { selector: () => ':host' },
18522
18555
  minHeight: { selector: () => ':host' },
18523
18556
  hostDirection: { selector: () => ':host', property: 'direction' },
18557
+ gap: {
18558
+ selector: ListClass.componentName,
18559
+ property: ListClass.cssVarList.gap,
18560
+ },
18561
+ maxRowItems: {
18562
+ selector: ListClass.componentName,
18563
+ property: ListClass.cssVarList.maxRowItems,
18564
+ },
18524
18565
  itemsFontWeight: {
18525
18566
  selector: TextClass.componentName,
18526
18567
  property: TextClass.cssVarList.fontWeightOverride,
@@ -18537,6 +18578,10 @@ const AppsListClass = compose(
18537
18578
  selector: ListItemClass.componentName,
18538
18579
  property: ListItemClass.cssVarList.backgroundColor,
18539
18580
  },
18581
+ itemHoverBackgroundColor: {
18582
+ selector: `${ListItemClass.componentName}:hover`,
18583
+ property: ListItemClass.cssVarList.backgroundColor,
18584
+ },
18540
18585
  backgroundColor: {
18541
18586
  selector: ListClass.componentName,
18542
18587
  property: ListClass.cssVarList.backgroundColorOverride,
@@ -18563,14 +18608,25 @@ const AppsListClass = compose(
18563
18608
  },
18564
18609
  itemAlignment: [
18565
18610
  { selector: () => '.avatar-wrapper', property: 'text-align' },
18566
- { selector: TextClass.componentName, property: TextClass.cssVarList.textAlign },
18567
- ]
18611
+ {
18612
+ selector: TextClass.componentName,
18613
+ property: TextClass.cssVarList.textAlign,
18614
+ },
18615
+ ],
18568
18616
  },
18569
18617
  }),
18570
- createDynamicDataMixin$1({ itemRenderer: itemRenderer$4, rerenderAttrsList: ['size', 'item-text-variant', 'logo-size'] }),
18618
+ createDynamicDataMixin$1({
18619
+ itemRenderer: itemRenderer$4,
18620
+ rerenderAttrsList: [
18621
+ 'size',
18622
+ 'item-text-variant',
18623
+ 'logo-size',
18624
+ 'open-in-same-window',
18625
+ ],
18626
+ }),
18571
18627
  draggableMixin$1,
18572
18628
  componentNameValidationMixin$1,
18573
- customMixin$2
18629
+ customMixin$2,
18574
18630
  )(
18575
18631
  createProxy$1({
18576
18632
  slots: ['empty-state'],
@@ -18608,7 +18664,7 @@ const AppsListClass = compose(
18608
18664
  width: 100%;
18609
18665
  }
18610
18666
  `,
18611
- })
18667
+ }),
18612
18668
  );
18613
18669
 
18614
18670
  const vars$l = AppsListClass.cssVarList;
@@ -18620,6 +18676,7 @@ const appsList = {
18620
18676
  [vars$l.itemsTextAlign]: 'start',
18621
18677
  [vars$l.hostDirection]: globalRefs$b.direction,
18622
18678
  [vars$l.maxHeight]: defaultHeight,
18679
+ [vars$l.itemHoverBackgroundColor]: globalRefs$b.colors.surface.highlight,
18623
18680
 
18624
18681
  _empty: {
18625
18682
  [vars$l.minHeight]: defaultHeight,
@@ -18680,7 +18737,7 @@ const compVars$3 = ListClass.cssVarList;
18680
18737
 
18681
18738
  const [helperTheme$2, helperRefs$2, helperVars$2] = createHelperVars$1(
18682
18739
  { shadowColor: '#00000020' },
18683
- componentName$n
18740
+ componentName$n,
18684
18741
  );
18685
18742
 
18686
18743
  const { shadowColor: shadowColor$2 } = helperRefs$2;
@@ -18702,6 +18759,7 @@ const list = {
18702
18759
  [compVars$3.maxHeight]: '100%',
18703
18760
  [compVars$3.hostDirection]: globalRefs$a.direction,
18704
18761
  [compVars$3.minItemsWidth]: '150px',
18762
+ [compVars$3.maxRowItems]: '1000', // effectively no limit
18705
18763
 
18706
18764
  _empty: {
18707
18765
  [compVars$3.minHeight]: '150px',
@@ -18711,13 +18769,33 @@ const list = {
18711
18769
 
18712
18770
  variant: {
18713
18771
  tiles: {
18714
- [compVars$3.gridTemplateColumns]: `repeat(auto-fit, minmax(min(${useVar$1(
18715
- compVars$3.minItemsWidth
18716
- )}, 100%), 1fr))`,
18772
+ [compVars$3.gridTemplateColumns]: `repeat(auto-fit, minmax(
18773
+ max(
18774
+ min(${useVar$1(compVars$3.minItemsWidth)}, 100%),
18775
+ calc((100% - (${useVar$1(compVars$3.maxRowItems)} - 1) * ${useVar$1(compVars$3.gap)}) / ${useVar$1(compVars$3.maxRowItems)})),
18776
+ 1fr))`,
18717
18777
  [compVars$3.maxItemsWidth]: '200px',
18718
18778
  [compVars$3.itemsHorizontalAlign]: 'center',
18719
18779
  },
18720
18780
  },
18781
+
18782
+ gap: {
18783
+ xs: {
18784
+ [compVars$3.gap]: globalRefs$a.spacing.xs,
18785
+ },
18786
+ sm: {
18787
+ [compVars$3.gap]: globalRefs$a.spacing.sm,
18788
+ },
18789
+ md: {
18790
+ [compVars$3.gap]: globalRefs$a.spacing.md,
18791
+ },
18792
+ lg: {
18793
+ [compVars$3.gap]: globalRefs$a.spacing.lg,
18794
+ },
18795
+ xl: {
18796
+ [compVars$3.gap]: globalRefs$a.spacing.xl,
18797
+ },
18798
+ },
18721
18799
  };
18722
18800
 
18723
18801
  const vars$k = {
@@ -22145,7 +22223,6 @@ class RawRecoveryCodes extends createBaseClass$1({
22145
22223
  init() {
22146
22224
  super.init();
22147
22225
 
22148
-
22149
22226
  this.icon.addEventListener('click', this.onCopy.bind(this));
22150
22227
 
22151
22228
  forwardAttrs(this, this.iconWrapper, { includeAttrs: ['variant', 'mode'] });
@@ -22170,7 +22247,7 @@ class RawRecoveryCodes extends createBaseClass$1({
22170
22247
  onReadOnly(isReadOnly) {
22171
22248
  this.icon.classList.toggle('readonly', isReadOnly);
22172
22249
  }
22173
-
22250
+
22174
22251
  attributeChangedCallback(attrName, oldValue, newValue) {
22175
22252
  super.attributeChangedCallback?.(attrName, oldValue, newValue);
22176
22253
 
@@ -22191,20 +22268,20 @@ const RecoveryCodesClass = compose(
22191
22268
  { selector: () => ':host', property: 'direction' },
22192
22269
  {
22193
22270
  selector: () => TextClass.componentName,
22194
- property: TextClass.cssVarList.hostDirection
22271
+ property: TextClass.cssVarList.hostDirection,
22195
22272
  },
22196
22273
  ],
22197
22274
  textAlign: { selector: () => '.list', property: 'align-items' },
22198
22275
  iconColor: { selector: () => 'vaadin-icon', property: 'color' },
22199
22276
  iconSize: { selector: () => 'vaadin-icon', property: 'font-size' },
22200
22277
  iconGap: { selector: () => '.wrapper', property: 'gap' },
22201
- bulletGap: { selector: () => 'descope-text span', property: 'gap' }
22278
+ bulletGap: { selector: () => 'descope-text span', property: 'gap' },
22202
22279
  },
22203
22280
  }),
22204
22281
  createDynamicDataMixin$1({
22205
22282
  itemRenderer: itemRenderer$2,
22206
22283
  rerenderAttrsList: ['variant', 'mode'],
22207
- targetSelector: '.list'
22284
+ targetSelector: '.list',
22208
22285
  }),
22209
22286
  draggableMixin$1,
22210
22287
  componentNameValidationMixin$1,