Structurally implements PhoenixKitCatalogue.Extension — the catalogue
item/category form "extension slot" (spec §2 principle 8). phoenix_kit_catalogue
is an optional dependency, so this module does NOT declare @behaviour PhoenixKitCatalogue.Extension; that would force it to be loaded at
compile time. Discovery is duck-typed, the same pattern as
PhoenixKitEcommerce.AITranslatable / ai_translatables/0: catalogue
finds this module via PhoenixKitEcommerce.catalogue_extensions/0 and is
responsible for checking it is actually usable before calling it.
Summary
Functions
Validates and shapes category["ecommerce"] — see CategoryCommerce.cast/2.
Validates and shapes item["ecommerce"] — see ItemCommerce.cast/2.
Renders the Shop section inside the catalogue category form.
Whether the Shop section should be shown / absorbed.
Renders the Shop section inside the catalogue item form.
Namespace under data this extension owns.
Functions
Validates and shapes category["ecommerce"] — see CategoryCommerce.cast/2.
Validates and shapes item["ecommerce"] — see ItemCommerce.cast/2.
@spec category_section(map()) :: Phoenix.LiveView.Rendered.t()
Renders the Shop section inside the catalogue category form.
@spec enabled?() :: boolean()
Whether the Shop section should be shown / absorbed.
@spec item_section(map()) :: Phoenix.LiveView.Rendered.t()
Renders the Shop section inside the catalogue item form.
@spec key() :: String.t()
Namespace under data this extension owns.