@apps-in-toss/web-framework 0.0.32 → 0.0.34

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.
@@ -0,0 +1,6 @@
1
+ import { createRequire } from 'module'; const require = createRequire(import.meta.url);
2
+ import {
3
+ require_typescript
4
+ } from "./chunk-RUDG2MMT.js";
5
+ import "./chunk-HDRFXOPA.js";
6
+ export default require_typescript();
@@ -0,0 +1,6 @@
1
+ import { createRequire } from 'module'; const require = createRequire(import.meta.url);
2
+ import {
3
+ require_typescript
4
+ } from "./chunk-34QS4NNF.js";
5
+ import "./chunk-AZQN2M6D.js";
6
+ export default require_typescript();
@@ -5,6 +5,20 @@ type DeepRequiredKeysOnly<T> = {
5
5
  [K in keyof T]-?: T[K] extends object ? (T[K] extends F ? T[K] : DeepRequiredKeysOnly<T[K]>) : T[K];
6
6
  };
7
7
 
8
+ type Icon = {
9
+ source: {
10
+ uri: string;
11
+ };
12
+ name?: never;
13
+ } | {
14
+ name: string;
15
+ source?: never;
16
+ };
17
+ interface InitialAccessoryButton {
18
+ id: string;
19
+ title: string;
20
+ icon: Icon;
21
+ }
8
22
  interface AppsInTossWebConfig extends AppsInTossPluginOptions {
9
23
  appName: string;
10
24
  web: {
@@ -33,6 +47,23 @@ interface AppsInTossWebConfig extends AppsInTossPluginOptions {
33
47
  * Defaults to `true` when type is 'partner', `false` when type is 'external'
34
48
  */
35
49
  withBackButton?: boolean;
50
+ /**
51
+ * @default []
52
+ *
53
+ * @example
54
+ * ```ts
55
+ * [
56
+ * {
57
+ * title: '버튼 이름',
58
+ * icon: {
59
+ * name: 'icon-name',
60
+ * source: 'icon-source',
61
+ * },
62
+ * },
63
+ * ]
64
+ * ```
65
+ */
66
+ initialAccessoryButtons?: InitialAccessoryButton[];
36
67
  };
37
68
  /**
38
69
  *
@@ -87,4 +118,4 @@ interface AppsInTossWebConfig extends AppsInTossPluginOptions {
87
118
  type AppsInTossWebConfigResponse = DeepRequiredKeysOnly<AppsInTossWebConfig>;
88
119
  declare const defineConfig: (config: AppsInTossWebConfig) => AppsInTossWebConfigResponse;
89
120
 
90
- export { type AppsInTossWebConfig, type AppsInTossWebConfigResponse, defineConfig };
121
+ export { type AppsInTossWebConfig, type AppsInTossWebConfigResponse, type InitialAccessoryButton, defineConfig };
@@ -51,7 +51,11 @@ var defineConfig = (config) => {
51
51
  bounces: true,
52
52
  allowsBackForwardNavigationGestures: true,
53
53
  pullToRefreshEnabled: true,
54
- overScrollMode: "always"
54
+ overScrollMode: "always",
55
+ header: {
56
+ withBackButton: true,
57
+ initialAccessoryButtons: []
58
+ }
55
59
  }
56
60
  };
57
61
  return merge(defaultConfig, config);