@descope/web-components-ui 1.112.0 → 1.114.0

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.
@@ -1848,7 +1848,7 @@ const inputEventsDispatchingMixin$1 = (superclass) =>
1848
1848
  }
1849
1849
  };
1850
1850
 
1851
- const observedAttributes$7 = ['required', 'pattern'];
1851
+ const observedAttributes$6 = ['required', 'pattern'];
1852
1852
 
1853
1853
  const errorAttributes$1 = {
1854
1854
  valueMissing: 'data-errormessage-value-missing',
@@ -1867,7 +1867,7 @@ const inputValidationMixin$1 = (superclass) =>
1867
1867
  #validationTarget = validationTargetSymbol$1;
1868
1868
 
1869
1869
  static get observedAttributes() {
1870
- return [...(superclass.observedAttributes || []), ...observedAttributes$7];
1870
+ return [...(superclass.observedAttributes || []), ...observedAttributes$6];
1871
1871
  }
1872
1872
 
1873
1873
  static get formAssociated() {
@@ -2070,7 +2070,7 @@ const inputValidationMixin$1 = (superclass) =>
2070
2070
  attributeChangedCallback(attrName, oldValue, newValue) {
2071
2071
  super.attributeChangedCallback?.(attrName, oldValue, newValue);
2072
2072
 
2073
- if (observedAttributes$7.includes(attrName)) {
2073
+ if (observedAttributes$6.includes(attrName)) {
2074
2074
  this.#setValidity();
2075
2075
  }
2076
2076
  }
@@ -3790,7 +3790,7 @@ const createProxy = ({
3790
3790
  return ProxyClass;
3791
3791
  };
3792
3792
 
3793
- const observedAttributes$6 = ['required', 'pattern'];
3793
+ const observedAttributes$5 = ['required', 'pattern'];
3794
3794
 
3795
3795
  const errorAttributes = {
3796
3796
  valueMissing: 'data-errormessage-value-missing',
@@ -3809,7 +3809,7 @@ const inputValidationMixin = (superclass) =>
3809
3809
  #validationTarget = validationTargetSymbol;
3810
3810
 
3811
3811
  static get observedAttributes() {
3812
- return [...(superclass.observedAttributes || []), ...observedAttributes$6];
3812
+ return [...(superclass.observedAttributes || []), ...observedAttributes$5];
3813
3813
  }
3814
3814
 
3815
3815
  static get formAssociated() {
@@ -3987,7 +3987,7 @@ const inputValidationMixin = (superclass) =>
3987
3987
  attributeChangedCallback(attrName, oldValue, newValue) {
3988
3988
  super.attributeChangedCallback?.(attrName, oldValue, newValue);
3989
3989
 
3990
- if (observedAttributes$6.includes(attrName)) {
3990
+ if (observedAttributes$5.includes(attrName)) {
3991
3991
  this.#setValidity();
3992
3992
  }
3993
3993
  }
@@ -7596,12 +7596,12 @@ const LoaderRadialClass = compose$1(
7596
7596
 
7597
7597
  const componentName$T = getComponentName$1('passcode');
7598
7598
 
7599
- const observedAttributes$5 = ['digits'];
7599
+ const observedAttributes$4 = ['digits'];
7600
7600
 
7601
7601
  const customMixin$b = (superclass) =>
7602
7602
  class PasscodeMixinClass extends superclass {
7603
7603
  static get observedAttributes() {
7604
- return observedAttributes$5.concat(superclass.observedAttributes || []);
7604
+ return observedAttributes$4.concat(superclass.observedAttributes || []);
7605
7605
  }
7606
7606
 
7607
7607
  get digits() {
@@ -11321,7 +11321,7 @@ const getFilename = (fileObj) => {
11321
11321
 
11322
11322
  const componentName$I = getComponentName$1('upload-file');
11323
11323
 
11324
- const observedAttributes$4 = [
11324
+ const observedAttributes$3 = [
11325
11325
  'title',
11326
11326
  'description',
11327
11327
  'button-label',
@@ -11338,7 +11338,7 @@ const BaseInputClass$4 = createBaseInputClass({ componentName: componentName$I,
11338
11338
 
11339
11339
  class RawUploadFile extends BaseInputClass$4 {
11340
11340
  static get observedAttributes() {
11341
- return observedAttributes$4.concat(BaseInputClass$4.observedAttributes || []);
11341
+ return observedAttributes$3.concat(BaseInputClass$4.observedAttributes || []);
11342
11342
  }
11343
11343
 
11344
11344
  constructor() {
@@ -19860,12 +19860,12 @@ var alert$1 = /*#__PURE__*/Object.freeze({
19860
19860
 
19861
19861
  const componentName$c = getComponentName$1('hcaptcha');
19862
19862
 
19863
- const observedAttributes$3 = ['enabled', 'site-key'];
19863
+ const observedAttributes$2 = ['enabled', 'site-key'];
19864
19864
 
19865
19865
  const BaseInputClass$1 = createBaseInputClass({ componentName: componentName$c, baseSelector: ':host > div' });
19866
19866
  class RawHcaptcha extends BaseInputClass$1 {
19867
19867
  static get observedAttributes() {
19868
- return observedAttributes$3.concat(BaseInputClass$1.observedAttributes || []);
19868
+ return observedAttributes$2.concat(BaseInputClass$1.observedAttributes || []);
19869
19869
  }
19870
19870
 
19871
19871
  attributeChangedCallback(attrName, oldValue, newValue) {
@@ -20703,7 +20703,7 @@ const formatTime = (ms = 0) => {
20703
20703
 
20704
20704
  const componentName$7 = getComponentName('timer');
20705
20705
 
20706
- const observedAttributes$2 = ['seconds', 'hide-icon', 'paused'];
20706
+ const observedAttributes$1 = ['seconds', 'hide-icon', 'paused'];
20707
20707
 
20708
20708
  const BaseClass$3 = createBaseClass$1({
20709
20709
  componentName: componentName$7,
@@ -20718,7 +20718,7 @@ class RawTimer extends BaseClass$3 {
20718
20718
  #intervalId;
20719
20719
 
20720
20720
  static get observedAttributes() {
20721
- return observedAttributes$2.concat(BaseClass$3.observedAttributes || []);
20721
+ return observedAttributes$1.concat(BaseClass$3.observedAttributes || []);
20722
20722
  }
20723
20723
 
20724
20724
  constructor() {
@@ -21824,8 +21824,6 @@ var recoveryCodes$1 = /*#__PURE__*/Object.freeze({
21824
21824
 
21825
21825
  const componentName$2 = getComponentName('outbound-apps');
21826
21826
 
21827
- const observedAttributes$1 = ['connect-button-label', 'disconnect-button-label', 'data'];
21828
-
21829
21827
  const itemRenderer = (
21830
21828
  { name, description, logo, appId, isConnected },
21831
21829
  _,
@@ -21838,24 +21836,24 @@ const itemRenderer = (
21838
21836
  ${logo ? `img="${logo}"` : ''}
21839
21837
  ${name ? `display-name="${name}" abbr=${limitAbbreviation(name)}` : ''}
21840
21838
  size=${ref.size}
21839
+ ${logo ? 'st-avatar-background-color="none"' : ''}
21841
21840
  class="app-logo"
21842
21841
  ></descope-avatar>
21843
- <div class="content">
21844
- <div class="app-title">
21842
+
21843
+ <div class="content">
21845
21844
  <descope-text
21845
+ class="app-title"
21846
21846
  variant="subtitle1"
21847
21847
  mode="primary"
21848
21848
  >${name}</descope-text>
21849
- </div>
21850
21849
  ${
21851
21850
  description
21852
21851
  ? `
21853
- <div class="app-description">
21854
21852
  <descope-text
21853
+ class="app-description"
21855
21854
  variant="body2"
21856
21855
  mode="primary"
21857
21856
  >${description}</descope-text>
21858
- </div>
21859
21857
  `
21860
21858
  : ''
21861
21859
  }
@@ -21875,15 +21873,13 @@ const BaseClass$1 = createBaseClass$1({
21875
21873
  });
21876
21874
 
21877
21875
  class RawOutboundAppsClass extends BaseClass$1 {
21878
- static get observedAttributes() {
21879
- return observedAttributes$1;
21880
- }
21881
-
21882
21876
  constructor() {
21883
21877
  super();
21884
21878
 
21885
21879
  this.attachShadow({ mode: 'open' }).innerHTML = `
21886
- <descope-list></descope-list>
21880
+ <descope-list>
21881
+ <slot name="empty-state" slot="empty-state"></slot>
21882
+ </descope-list>
21887
21883
  `;
21888
21884
 
21889
21885
  this.appsList = this.shadowRoot.querySelector('descope-list');
@@ -21900,6 +21896,13 @@ class RawOutboundAppsClass extends BaseClass$1 {
21900
21896
  }
21901
21897
  .content {
21902
21898
  flex-grow: 1;
21899
+ display: flex;
21900
+ flex-direction: column;
21901
+ }
21902
+ .app-title,
21903
+ .app-description {
21904
+ display: flex;
21905
+ direction: inherit;
21903
21906
  }
21904
21907
  descope-list {
21905
21908
  display: block;
@@ -21917,11 +21920,17 @@ class RawOutboundAppsClass extends BaseClass$1 {
21917
21920
  this.appsList.addEventListener('click', this.onAppsListClick.bind(this));
21918
21921
  }
21919
21922
 
21923
+ get readonly() {
21924
+ return this.getAttribute('readonly') === 'true';
21925
+ }
21926
+
21920
21927
  onAppsListClick(e) {
21921
- const id = e.srcElement.getAttribute('data-outbound-app-id');
21922
- const action = e.srcElement.getAttribute('data-action');
21923
- if (id && action) {
21924
- this.dispatchEvent(new CustomEvent(`${action}-clicked`, { bubbles: true, detail: { id, action } }));
21928
+ if (!this.readonly) {
21929
+ const id = e.srcElement.getAttribute('data-outbound-app-id');
21930
+ const action = e.srcElement.getAttribute('data-action');
21931
+ if (id && action) {
21932
+ this.dispatchEvent(new CustomEvent(`${action}-clicked`, { bubbles: true, detail: { id, action } }));
21933
+ }
21925
21934
  }
21926
21935
  }
21927
21936
 
@@ -21964,14 +21973,14 @@ const OutboundAppsClass = compose(
21964
21973
  selector: TextClass.componentName,
21965
21974
  property: TextClass.cssVarList.fontSize,
21966
21975
  },
21967
- appLogoBackgroundColor: {
21968
- selector: AvatarClass.componentName,
21969
- property: AvatarClass.cssVarList.avatarBackgroundColor,
21970
- },
21971
21976
  appLogoGap: {
21972
21977
  selector: () => ' .app-logo',
21973
21978
  property: 'margin-inline-end'
21974
21979
  },
21980
+ contentGap: {
21981
+ selector: () => ' .content',
21982
+ property: 'gap'
21983
+ },
21975
21984
  itemsTextAlign: {
21976
21985
  selector: TextClass.componentName,
21977
21986
  property: TextClass.cssVarList.textAlign,
@@ -22029,6 +22038,7 @@ const outboundApps = {
22029
22038
 
22030
22039
  [vars$1.appLogoBackgroundColor]: 'none',
22031
22040
  [vars$1.appLogoGap]: globals.spacing.md,
22041
+ [vars$1.contentGap]: globals.spacing.xs,
22032
22042
 
22033
22043
  // list-item overrides
22034
22044
  [vars$1.itemCursor]: 'default',
@@ -22613,7 +22623,6 @@ exports.genColors = genColors;
22613
22623
  exports.getThemeRefs = getThemeRefs;
22614
22624
  exports.getThemeVars = getThemeVars;
22615
22625
  exports.globalsThemeToStyle = globalsThemeToStyle;
22616
- exports.observedAttributes = observedAttributes$1;
22617
22626
  exports.themeToCSSVarsObj = themeToCSSVarsObj;
22618
22627
  exports.themeToStyle = themeToStyle;
22619
22628
  exports.themeVars = themeVars;