@doubao-dev/template 0.5.0 → 0.5.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.
@@ -1,8 +1,8 @@
1
1
  import { Button, useTheme, useThemeClassName } from "@byted-doubao-apps/components";
2
- import { useHostCardStyle } from "@byted-doubao-apps/framework";
3
2
  import { createEvent } from "@byted-doubao-apps/framework/api";
4
3
  import { clsx } from "clsx";
5
4
  import { useEffect } from "react";
5
+ import { useHostCardStyle } from "../utils/use-host-card-style.js";
6
6
  import { reportAskHumanCardClick, reportAskHumanCardShow } from "./report.js";
7
7
  import "./styles.css";
8
8
  const onShow = createEvent('onShow');
@@ -1,9 +1,9 @@
1
1
  import { useThemeClassName } from "@byted-doubao-apps/components";
2
- import { useHostCardStyle } from "@byted-doubao-apps/framework";
3
2
  import { TemplateCardFooter } from "../components/footer/index.js";
4
3
  import { TemplateCardHeader } from "../components/header/index.js";
5
4
  import { TemplateInfoSection } from "../components/info-section/index.js";
6
5
  import { TemplateProductSummary } from "../components/product-summary/index.js";
6
+ import { useHostCardStyle } from "../utils/use-host-card-style.js";
7
7
  import "./styles.css";
8
8
  function isCheckoutCardTextEmpty(content) {
9
9
  return null == content || '' === content;
@@ -1,10 +1,10 @@
1
1
  import { useThemeClassName } from "@byted-doubao-apps/components";
2
- import { useHostCardStyle } from "@byted-doubao-apps/framework";
3
2
  import { TemplateCardFooter } from "../components/footer/index.js";
4
3
  import { TemplateCardHeader } from "../components/header/index.js";
5
4
  import { ContentCardContent } from "../content-card/index.js";
6
5
  import { OptionGroup } from "../primitives/option-group/index.js";
7
6
  import { TransitCardContent } from "../transit-card/content.js";
7
+ import { useHostCardStyle } from "../utils/use-host-card-style.js";
8
8
  import "./styles.css";
9
9
  function isCompositeCardSectionVisible(section) {
10
10
  switch(section.type){
@@ -1,9 +1,9 @@
1
1
  import { useThemeClassName } from "@byted-doubao-apps/components";
2
- import { useHostCardStyle } from "@byted-doubao-apps/framework";
3
2
  import { clsx } from "clsx";
4
3
  import { renderTemplateExtraAction, stopTemplateExtraActionTap } from "../components/extra-action/index.js";
5
4
  import { TemplateCardFooter } from "../components/footer/index.js";
6
5
  import { TemplateCardHeader } from "../components/header/index.js";
6
+ import { useHostCardStyle } from "../utils/use-host-card-style.js";
7
7
  import "./styles.css";
8
8
  function isContentCardNodeEmpty(content) {
9
9
  return null == content || 'boolean' == typeof content || '' === content;
@@ -1,9 +1,9 @@
1
1
  import { Button, Map, useThemeClassName } from "@byted-doubao-apps/components";
2
- import { useHostCardStyle } from "@byted-doubao-apps/framework";
3
2
  import { clsx } from "clsx";
4
3
  import { forwardRef } from "react";
5
4
  import { TemplateCardFooter } from "../components/footer/index.js";
6
5
  import { Title } from "../primitives/title/index.js";
6
+ import { useHostCardStyle } from "../utils/use-host-card-style.js";
7
7
  import "./styles.css";
8
8
  function hasTemplateText(value) {
9
9
  return void 0 !== value && '' !== value;
@@ -1,9 +1,9 @@
1
1
  import { Button, useThemeClassName } from "@byted-doubao-apps/components";
2
- import { useHostCardStyle } from "@byted-doubao-apps/framework";
3
2
  import { clsx } from "clsx";
4
3
  import { TemplateCardFooter } from "../components/footer/index.js";
5
4
  import { TemplateCardHeader } from "../components/header/index.js";
6
5
  import { Price } from "../primitives/price/index.js";
6
+ import { useHostCardStyle } from "../utils/use-host-card-style.js";
7
7
  import "./styles.css";
8
8
  const PRICE_ACTION_CARD_INFO_ROW_LIMIT = 2;
9
9
  const PRICE_ACTION_CARD_CURRENCY_PATTERN = /^([¥¥$€£])(.+)$/;
@@ -1,7 +1,7 @@
1
1
  import { useThemeClassName } from "@byted-doubao-apps/components";
2
- import { useHostCardStyle } from "@byted-doubao-apps/framework";
3
2
  import { TemplateCardFooter } from "../components/footer/index.js";
4
3
  import { TemplateCardHeader } from "../components/header/index.js";
4
+ import { useHostCardStyle } from "../utils/use-host-card-style.js";
5
5
  import { TransitCardContent } from "./content.js";
6
6
  function TransitCard(props) {
7
7
  const { header, items = [], footer, onClick } = props;
@@ -0,0 +1,3 @@
1
+ import * as framework from '@byted-doubao-apps/framework';
2
+ export declare const useHostCardStyle: typeof framework.useHostCardStyle;
3
+ //# sourceMappingURL=use-host-card-style.d.ts.map
@@ -0,0 +1,3 @@
1
+ import * as __rspack_external__byted_doubao_apps_framework_46608841 from "@byted-doubao-apps/framework";
2
+ const useHostCardStyle = 'function' == typeof __rspack_external__byted_doubao_apps_framework_46608841.useHostCardStyle ? __rspack_external__byted_doubao_apps_framework_46608841.useHostCardStyle : ()=>void 0;
3
+ export { useHostCardStyle };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@doubao-dev/template",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {