@garagem-ai/site-sdk 0.6.0 → 0.6.1

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/dist/index.d.mts CHANGED
@@ -604,11 +604,13 @@ declare const STUDIO_SDK_CONTRACT: {
604
604
  * Exact pin for generated Studio sites. Must match a tarball already on
605
605
  * npm — v0 installs this version. After a later changeset publishes, bump
606
606
  * this and move that release's names from `optionalReactExports` /
607
- * `unpublishedSearchExports` into the prompt-safe lists. Do not bump here
608
- * until that tarball is on npm. Headless SearchPage already shipped in
609
- * 0.4.12 (`visibleSearchFilters` / `toolbarFilterIds` are on that pin).
607
+ * `unpublishedSearchExports` / `unpublishedPhoneExports` into the
608
+ * prompt-safe lists. Do not bump here until that tarball is on npm.
609
+ * Phone mask helpers shipped in 0.6.0. Search filter helpers
610
+ * (`visibleSearchFilters` / `toolbarFilterIds`) shipped in 0.4.12 and
611
+ * remain on this pin.
610
612
  */
611
- readonly minNpmVersion: "0.4.12";
613
+ readonly minNpmVersion: "0.6.0";
612
614
  /** Historical: older tarballs inject card CSS when those components mount. */
613
615
  readonly selfInjectSince: "0.4.2";
614
616
  readonly chromeStrategy: "app-owned";
@@ -635,24 +637,22 @@ declare const STUDIO_SDK_CONTRACT: {
635
637
  /** Main-package card helpers — markup stays in the generated app. */
636
638
  readonly listingCardExports: readonly ["toListingCardModel", "listingPublicPath", "formatAreaM2", "listingBusinessLabel", "formatListingPrice"];
637
639
  /**
638
- * Prompt-safe phone helpers on `minNpmVersion`. Empty until a published
639
- * tarball exports them and this pin bumps — then move names here from
640
- * `unpublishedPhoneExports`.
640
+ * Prompt-safe phone helpers on `minNpmVersion` (published in 0.6.0).
641
641
  */
642
- readonly phoneExports: readonly [];
642
+ readonly phoneExports: readonly ["PHONE_COUNTRIES", "formatPhoneNational", "toE164", "isValidPhone", "parsePhoneInput", "phoneCountrySearchValue", "findPhoneCountry", "remaskPhoneForCountry"];
643
643
  /**
644
- * Headless phone mask helpers in git / newer tarballs but not on
645
- * `minNpmVersion` (0.4.12). Prompts, completeness, and repair text must
646
- * not mention these until the pin bumps — v0 installs the pin and the
647
- * ESM loader throws on missing named exports.
644
+ * Headless phone helpers in git but not on `minNpmVersion`. Prompts,
645
+ * completeness, and repair text must not mention these until the pin
646
+ * bumps — v0 installs the pin and the ESM loader throws on missing
647
+ * named exports.
648
648
  */
649
- readonly unpublishedPhoneExports: readonly ["PHONE_COUNTRIES", "formatPhoneNational", "toE164", "isValidPhone", "parsePhoneInput", "phoneCountrySearchValue", "findPhoneCountry", "remaskPhoneForCountry"];
649
+ readonly unpublishedPhoneExports: readonly [];
650
650
  readonly amenityExports: readonly ["listingAmenityGroups"];
651
651
  /**
652
- * Names already on the pinned npm tarball (`minNpmVersion` / 0.4.12) —
653
- * safe for Studio prompts and completeness. Includes
654
- * `visibleSearchFilters` + `toolbarFilterIds` (shipped in 0.4.12). Do not
655
- * confuse with `unpublishedSearchExports` (`searchChromeModel`, …).
652
+ * Names already on the pinned npm tarball (`minNpmVersion`) — safe for
653
+ * Studio prompts and completeness. Includes `visibleSearchFilters` +
654
+ * `toolbarFilterIds` (shipped in 0.4.12). Do not confuse with
655
+ * `unpublishedSearchExports` (`searchChromeModel`, …).
656
656
  */
657
657
  readonly searchExports: readonly ["searchResultsHeading", "searchSortOptions", "visibleSearchFilters", "toolbarFilterIds", "paginationPages", "hrefWithExplicitPage"];
658
658
  /**
package/dist/index.d.ts CHANGED
@@ -604,11 +604,13 @@ declare const STUDIO_SDK_CONTRACT: {
604
604
  * Exact pin for generated Studio sites. Must match a tarball already on
605
605
  * npm — v0 installs this version. After a later changeset publishes, bump
606
606
  * this and move that release's names from `optionalReactExports` /
607
- * `unpublishedSearchExports` into the prompt-safe lists. Do not bump here
608
- * until that tarball is on npm. Headless SearchPage already shipped in
609
- * 0.4.12 (`visibleSearchFilters` / `toolbarFilterIds` are on that pin).
607
+ * `unpublishedSearchExports` / `unpublishedPhoneExports` into the
608
+ * prompt-safe lists. Do not bump here until that tarball is on npm.
609
+ * Phone mask helpers shipped in 0.6.0. Search filter helpers
610
+ * (`visibleSearchFilters` / `toolbarFilterIds`) shipped in 0.4.12 and
611
+ * remain on this pin.
610
612
  */
611
- readonly minNpmVersion: "0.4.12";
613
+ readonly minNpmVersion: "0.6.0";
612
614
  /** Historical: older tarballs inject card CSS when those components mount. */
613
615
  readonly selfInjectSince: "0.4.2";
614
616
  readonly chromeStrategy: "app-owned";
@@ -635,24 +637,22 @@ declare const STUDIO_SDK_CONTRACT: {
635
637
  /** Main-package card helpers — markup stays in the generated app. */
636
638
  readonly listingCardExports: readonly ["toListingCardModel", "listingPublicPath", "formatAreaM2", "listingBusinessLabel", "formatListingPrice"];
637
639
  /**
638
- * Prompt-safe phone helpers on `minNpmVersion`. Empty until a published
639
- * tarball exports them and this pin bumps — then move names here from
640
- * `unpublishedPhoneExports`.
640
+ * Prompt-safe phone helpers on `minNpmVersion` (published in 0.6.0).
641
641
  */
642
- readonly phoneExports: readonly [];
642
+ readonly phoneExports: readonly ["PHONE_COUNTRIES", "formatPhoneNational", "toE164", "isValidPhone", "parsePhoneInput", "phoneCountrySearchValue", "findPhoneCountry", "remaskPhoneForCountry"];
643
643
  /**
644
- * Headless phone mask helpers in git / newer tarballs but not on
645
- * `minNpmVersion` (0.4.12). Prompts, completeness, and repair text must
646
- * not mention these until the pin bumps — v0 installs the pin and the
647
- * ESM loader throws on missing named exports.
644
+ * Headless phone helpers in git but not on `minNpmVersion`. Prompts,
645
+ * completeness, and repair text must not mention these until the pin
646
+ * bumps — v0 installs the pin and the ESM loader throws on missing
647
+ * named exports.
648
648
  */
649
- readonly unpublishedPhoneExports: readonly ["PHONE_COUNTRIES", "formatPhoneNational", "toE164", "isValidPhone", "parsePhoneInput", "phoneCountrySearchValue", "findPhoneCountry", "remaskPhoneForCountry"];
649
+ readonly unpublishedPhoneExports: readonly [];
650
650
  readonly amenityExports: readonly ["listingAmenityGroups"];
651
651
  /**
652
- * Names already on the pinned npm tarball (`minNpmVersion` / 0.4.12) —
653
- * safe for Studio prompts and completeness. Includes
654
- * `visibleSearchFilters` + `toolbarFilterIds` (shipped in 0.4.12). Do not
655
- * confuse with `unpublishedSearchExports` (`searchChromeModel`, …).
652
+ * Names already on the pinned npm tarball (`minNpmVersion`) — safe for
653
+ * Studio prompts and completeness. Includes `visibleSearchFilters` +
654
+ * `toolbarFilterIds` (shipped in 0.4.12). Do not confuse with
655
+ * `unpublishedSearchExports` (`searchChromeModel`, …).
656
656
  */
657
657
  readonly searchExports: readonly ["searchResultsHeading", "searchSortOptions", "visibleSearchFilters", "toolbarFilterIds", "paginationPages", "hrefWithExplicitPage"];
658
658
  /**
package/dist/index.js CHANGED
@@ -2733,11 +2733,13 @@ var STUDIO_SDK_CONTRACT = {
2733
2733
  * Exact pin for generated Studio sites. Must match a tarball already on
2734
2734
  * npm — v0 installs this version. After a later changeset publishes, bump
2735
2735
  * this and move that release's names from `optionalReactExports` /
2736
- * `unpublishedSearchExports` into the prompt-safe lists. Do not bump here
2737
- * until that tarball is on npm. Headless SearchPage already shipped in
2738
- * 0.4.12 (`visibleSearchFilters` / `toolbarFilterIds` are on that pin).
2736
+ * `unpublishedSearchExports` / `unpublishedPhoneExports` into the
2737
+ * prompt-safe lists. Do not bump here until that tarball is on npm.
2738
+ * Phone mask helpers shipped in 0.6.0. Search filter helpers
2739
+ * (`visibleSearchFilters` / `toolbarFilterIds`) shipped in 0.4.12 and
2740
+ * remain on this pin.
2739
2741
  */
2740
- minNpmVersion: "0.4.12",
2742
+ minNpmVersion: "0.6.0",
2741
2743
  /** Historical: older tarballs inject card CSS when those components mount. */
2742
2744
  selfInjectSince: "0.4.2",
2743
2745
  chromeStrategy: "app-owned",
@@ -2790,18 +2792,9 @@ var STUDIO_SDK_CONTRACT = {
2790
2792
  "formatListingPrice"
2791
2793
  ],
2792
2794
  /**
2793
- * Prompt-safe phone helpers on `minNpmVersion`. Empty until a published
2794
- * tarball exports them and this pin bumps — then move names here from
2795
- * `unpublishedPhoneExports`.
2795
+ * Prompt-safe phone helpers on `minNpmVersion` (published in 0.6.0).
2796
2796
  */
2797
- phoneExports: [],
2798
- /**
2799
- * Headless phone mask helpers in git / newer tarballs but not on
2800
- * `minNpmVersion` (0.4.12). Prompts, completeness, and repair text must
2801
- * not mention these until the pin bumps — v0 installs the pin and the
2802
- * ESM loader throws on missing named exports.
2803
- */
2804
- unpublishedPhoneExports: [
2797
+ phoneExports: [
2805
2798
  "PHONE_COUNTRIES",
2806
2799
  "formatPhoneNational",
2807
2800
  "toE164",
@@ -2811,12 +2804,19 @@ var STUDIO_SDK_CONTRACT = {
2811
2804
  "findPhoneCountry",
2812
2805
  "remaskPhoneForCountry"
2813
2806
  ],
2807
+ /**
2808
+ * Headless phone helpers in git but not on `minNpmVersion`. Prompts,
2809
+ * completeness, and repair text must not mention these until the pin
2810
+ * bumps — v0 installs the pin and the ESM loader throws on missing
2811
+ * named exports.
2812
+ */
2813
+ unpublishedPhoneExports: [],
2814
2814
  amenityExports: ["listingAmenityGroups"],
2815
2815
  /**
2816
- * Names already on the pinned npm tarball (`minNpmVersion` / 0.4.12) —
2817
- * safe for Studio prompts and completeness. Includes
2818
- * `visibleSearchFilters` + `toolbarFilterIds` (shipped in 0.4.12). Do not
2819
- * confuse with `unpublishedSearchExports` (`searchChromeModel`, …).
2816
+ * Names already on the pinned npm tarball (`minNpmVersion`) — safe for
2817
+ * Studio prompts and completeness. Includes `visibleSearchFilters` +
2818
+ * `toolbarFilterIds` (shipped in 0.4.12). Do not confuse with
2819
+ * `unpublishedSearchExports` (`searchChromeModel`, …).
2820
2820
  */
2821
2821
  searchExports: [
2822
2822
  "searchResultsHeading",
@@ -2927,7 +2927,8 @@ function studioSdkPinInstruction() {
2927
2927
  }
2928
2928
  function studioLeadInstruction() {
2929
2929
  const names = STUDIO_SDK_CONTRACT.leadExports.join(", ");
2930
- return `Listing-detail visit/contact leads: import ${names} from \`${STUDIO_SDK_PACKAGE}\` (the main package, not \`/react\`). Call \`submitVisitLead\` / \`submitContactLead\` \u2014 never concatenate a leads webhook URL and never POST the Showcase demo leads route. Phone fields use a national mask with a country picker and submit E.164 \u2014 do not invent a second mask and do not import \`@garagem/ui\` PhoneInput.`;
2930
+ const phone = STUDIO_SDK_CONTRACT.phoneExports.join(", ");
2931
+ return `Listing-detail visit/contact leads: import ${names} from \`${STUDIO_SDK_PACKAGE}\` (the main package, not \`/react\`). Call \`submitVisitLead\` / \`submitContactLead\` \u2014 never concatenate a leads webhook URL and never POST the Showcase demo leads route. Phone fields: import ${phone} from the same package. Display draft is \`formatPhoneNational\` (default country \`BR\`); changing country calls \`remaskPhoneForCountry\`; submit \`toE164\` and require \`isValidPhone\`. Do not invent a second mask and do not import \`@garagem/ui\` PhoneInput.`;
2931
2932
  }
2932
2933
  function studioListingCardInstruction() {
2933
2934
  const names = STUDIO_SDK_CONTRACT.listingCardExports.join(", ");