@easemate/web-kit 0.5.1 → 0.5.3

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.
package/build/react.cjs CHANGED
@@ -15312,20 +15312,27 @@ var init_panel = __esm({
15312
15312
  tag: "ease-panel",
15313
15313
  shadowMode: "open",
15314
15314
  styles: `
15315
- @property --top-fade {
15315
+ :host {
15316
+ display: block;
15317
+ box-sizing: border-box;
15318
+ }
15319
+
15320
+ @property --ease-panel-top-fade {
15316
15321
  syntax: "<length>";
15317
15322
  inherits: false;
15318
15323
  initial-value: 0px;
15319
15324
  }
15320
15325
 
15321
- @property --bottom-fade {
15326
+ @property --ease-panel-bottom-fade {
15322
15327
  syntax: "<length>";
15323
15328
  inherits: false;
15324
15329
  initial-value: 0px;
15325
15330
  }
15326
15331
 
15327
15332
  [part="section"] {
15328
- display: block;
15333
+ display: flex;
15334
+ flex-direction: column;
15335
+ max-height: inherit;
15329
15336
  width: 100%;
15330
15337
  max-width: var(--ease-panel-max-width);
15331
15338
  border-radius: var(--ease-panel-radius);
@@ -15462,9 +15469,10 @@ var init_panel = __esm({
15462
15469
 
15463
15470
  [part="content"] {
15464
15471
  display: block;
15472
+ flex: 1 1 auto;
15473
+ min-height: 0;
15465
15474
  width: 100%;
15466
15475
  box-sizing: border-box;
15467
- margin: auto;
15468
15476
  overflow: hidden;
15469
15477
  }
15470
15478
 
@@ -15473,18 +15481,10 @@ var init_panel = __esm({
15473
15481
  }
15474
15482
 
15475
15483
  [part="body"] {
15484
+ display: block;
15485
+ height: 100%;
15476
15486
  width: 100%;
15477
15487
  position: relative;
15478
- overflow-y: auto;
15479
- mask-image: linear-gradient(to bottom, #0000, #ffff var(--top-fade) calc(100% - var(--bottom-fade)), #0000);
15480
- animation-name: scroll-fade;
15481
- animation-timeline: scroll(self y);
15482
- scroll-snap-type: y mandatory;
15483
- scrollbar-width: none;
15484
-
15485
- &::-webkit-scrollbar {
15486
- display: none;
15487
- }
15488
15488
  }
15489
15489
 
15490
15490
  @keyframes scroll-fade {
@@ -15510,6 +15510,7 @@ var init_panel = __esm({
15510
15510
 
15511
15511
  [part="tab-panel"][data-state="active"] {
15512
15512
  display: block;
15513
+ height: 100%;
15513
15514
  pointer-events: auto;
15514
15515
  }
15515
15516
 
@@ -15537,6 +15538,17 @@ var init_panel = __esm({
15537
15538
  grid-gap: var(--ease-panel-gap);
15538
15539
  box-sizing: border-box;
15539
15540
  width: 100%;
15541
+ max-height: 100%;
15542
+ overflow-y: auto;
15543
+ mask-image: linear-gradient(to bottom, #0000, #ffff var(--top-fade) calc(100% - var(--bottom-fade)), #0000);
15544
+ animation-name: scroll-fade;
15545
+ animation-timeline: scroll(self y);
15546
+ scroll-snap-type: y mandatory;
15547
+ scrollbar-width: none;
15548
+
15549
+ &::-webkit-scrollbar {
15550
+ display: none;
15551
+ }
15540
15552
  }
15541
15553
  `
15542
15554
  }), _dec121 = Prop({
@@ -15679,8 +15691,8 @@ var init_panel = __esm({
15679
15691
  </div>
15680
15692
  </div>
15681
15693
  <div part="content">
15682
- <div part="body" style=${this.maxHeight ? `max-height: ${this.maxHeight};` : ""}>
15683
- ${hasTabs ? this.#renderTabPanels() : import_lit_html22.html`<div part="items"><slot></slot></div>`}
15694
+ <div part="body">
15695
+ ${hasTabs ? this.#renderTabPanels() : import_lit_html22.html`<div part="items" style=${this.maxHeight ? `max-height: ${this.maxHeight}` : import_lit_html22.nothing}><slot></slot></div>`}
15684
15696
  </div>
15685
15697
  </div>
15686
15698
  <div part="footer">
@@ -15722,7 +15734,7 @@ var init_panel = __esm({
15722
15734
  data-state=${index === this.activeTab ? "active" : "hidden"}
15723
15735
  data-index=${index}
15724
15736
  >
15725
- <div part="items">
15737
+ <div part="items" style=${this.maxHeight ? `max-height: ${this.maxHeight}` : import_lit_html22.nothing}>
15726
15738
  <slot name=${`tab-${tab.id}`}></slot>
15727
15739
  </div>
15728
15740
  </div>
@@ -15817,12 +15829,15 @@ var init_panel = __esm({
15817
15829
  } catch {
15818
15830
  }
15819
15831
  fromPanel.setAttribute("data-state", "hidden");
15832
+ content.style.height = "auto";
15820
15833
  const previousToState = toPanel.getAttribute("data-state");
15821
15834
  toPanel.style.display = "block";
15822
15835
  toPanel.style.visibility = "hidden";
15823
15836
  toPanel.style.opacity = "0";
15824
- void toPanel.offsetHeight;
15825
- const endHeight = toPanel.getBoundingClientRect().height;
15837
+ void content.offsetHeight;
15838
+ const endHeight = content.getBoundingClientRect().height;
15839
+ content.style.height = `${startHeight}px`;
15840
+ void content.offsetHeight;
15826
15841
  if (startHeight !== endHeight) {
15827
15842
  content.setAttribute("data-animating", "true");
15828
15843
  void content.offsetHeight;