@capgo/capacitor-sheets 8.0.3 → 8.0.4

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.
@@ -768,13 +768,15 @@ var SheetController = class {
768
768
  this.root = root;
769
769
  this.options = readOptionsFromElement(root);
770
770
  this.id = this.options.componentId || root.id || createId("cap-sheet");
771
- if (!root.id) root.id = this.id;
772
771
  }
773
772
  /** Connect the controller to the DOM and initialize current state. */
774
773
  connect() {
775
774
  if (this.connected) return;
776
775
  this.connected = true;
777
- this.configure(readOptionsFromElement(this.root));
776
+ const elementOptions = readOptionsFromElement(this.root);
777
+ this.id = elementOptions.componentId || this.root.id || this.id;
778
+ if (!this.root.id) this.root.id = this.id;
779
+ this.configure(elementOptions);
778
780
  const nextPresented = this.options.presented ?? this.options.defaultPresented ?? false;
779
781
  this.activeDetent = this.resolveInitialDetent();
780
782
  this.presented = nextPresented;