@wise/dynamic-flow-types 0.0.2 → 1.1.0

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/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # @wise/dynamic-flow-types
2
2
 
3
+ ## 1.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 57ab87e: Add support for action.id property
8
+ - 44409c6: Adding support for status-list
9
+
10
+ ## 1.0.0
11
+
12
+ ### Major Changes
13
+
14
+ - 1120e78: TypeScript types extracted from the web client library.
15
+
3
16
  ## 0.0.2
4
17
 
5
18
  ### Patch Changes
package/README.md ADDED
@@ -0,0 +1,3 @@
1
+ # Dynamic Flow TypeScript Types
2
+
3
+ This package contains the Dynamic Flow TypeScript types which are used in @wise/dynamic-flow-client and other packages.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wise/dynamic-flow-types",
3
- "version": "0.0.2",
3
+ "version": "1.1.0",
4
4
  "description": "Dynamic Flow TypeScript Types",
5
5
  "license": "Apache-2.0",
6
6
  "main": "./src/index.ts",
@@ -1,6 +1,10 @@
1
1
  import { HttpMethod } from './core';
2
2
 
3
3
  type CoreAction = {
4
+ id?: string;
5
+ /**
6
+ * @deprecated Please use id instead
7
+ */
4
8
  $id?: string;
5
9
  data?: Record<string, unknown>;
6
10
  exit?: boolean;
@@ -19,7 +19,8 @@ export type LayoutComponent =
19
19
  | LoadingIndicatorLayout
20
20
  | MarkdownLayout
21
21
  | ParagraphLayout
22
- | ReviewLayout;
22
+ | ReviewLayout
23
+ | StatusListLayout;
23
24
 
24
25
  export type AlertLayout = { type: 'alert' } & Alert;
25
26
 
@@ -126,12 +127,16 @@ export type InfoLayout = {
126
127
  align?: Align;
127
128
  };
128
129
 
130
+ /**
131
+ * @deprecated Please use StatusListLayout instead
132
+ */
129
133
  export type ListLayout = {
130
134
  type: 'list';
131
135
  items: ListItem[];
132
136
  title?: string;
133
137
  margin?: Margin;
134
138
  };
139
+
135
140
  type ListItem = {
136
141
  title: string;
137
142
  description?: string;
@@ -139,6 +144,20 @@ type ListItem = {
139
144
  status?: 'positive' | 'neutral' | 'warning';
140
145
  };
141
146
 
147
+ export type StatusListLayout = {
148
+ type: 'status-list';
149
+ items: StatusListItem[];
150
+ title?: string;
151
+ margin?: Margin;
152
+ };
153
+
154
+ type StatusListItem = {
155
+ title: string;
156
+ description?: string;
157
+ icon?: Icon;
158
+ status?: 'done' | 'not-done' | 'pending';
159
+ };
160
+
142
161
  export type LoadingIndicatorLayout = {
143
162
  type: 'loading-indicator';
144
163
  margin?: Margin;