capacitor-extended-dialog 0.0.13 → 0.0.14

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.
@@ -11,7 +11,7 @@ Pod::Spec.new do |s|
11
11
  s.author = package['author']
12
12
  s.source = { :git => package['repository']['url'], :tag => s.version.to_s }
13
13
  s.source_files = 'ios/Sources/**/*.{swift,h,m,c,cc,mm,cpp}'
14
- s.ios.deployment_target = '14.0'
14
+ s.ios.deployment_target = '15.0'
15
15
  s.dependency 'Capacitor'
16
16
  s.swift_version = '5.1'
17
17
  end
package/README.md CHANGED
@@ -38,7 +38,7 @@ npx cap sync
38
38
  ### alert(...)
39
39
 
40
40
  ```typescript
41
- alert(options: AlertOptions) => any
41
+ alert(options: AlertOptions) => Promise<void>
42
42
  ```
43
43
 
44
44
  Show an alert dialog with a single dismiss button.
@@ -47,15 +47,13 @@ Show an alert dialog with a single dismiss button.
47
47
  | ------------- | ----------------------------------------------------- | ------------------------------ |
48
48
  | **`options`** | <code><a href="#alertoptions">AlertOptions</a></code> | - Alert configuration options. |
49
49
 
50
- **Returns:** <code>any</code>
51
-
52
50
  --------------------
53
51
 
54
52
 
55
53
  ### confirm(...)
56
54
 
57
55
  ```typescript
58
- confirm(options: ConfirmOptions) => any
56
+ confirm(options: ConfirmOptions) => Promise<ConfirmResult>
59
57
  ```
60
58
 
61
59
  Show a confirmation dialog with OK and Cancel buttons.
@@ -64,7 +62,7 @@ Show a confirmation dialog with OK and Cancel buttons.
64
62
  | ------------- | --------------------------------------------------------- | -------------------------------- |
65
63
  | **`options`** | <code><a href="#confirmoptions">ConfirmOptions</a></code> | - Confirm configuration options. |
66
64
 
67
- **Returns:** <code>any</code>
65
+ **Returns:** <code>Promise&lt;<a href="#confirmresult">ConfirmResult</a>&gt;</code>
68
66
 
69
67
  --------------------
70
68
 
@@ -72,7 +70,7 @@ Show a confirmation dialog with OK and Cancel buttons.
72
70
  ### prompt(...)
73
71
 
74
72
  ```typescript
75
- prompt(options: PromptOptions) => any
73
+ prompt(options: PromptOptions) => Promise<PromptResult>
76
74
  ```
77
75
 
78
76
  Show a prompt dialog with a text input field.
@@ -81,7 +79,7 @@ Show a prompt dialog with a text input field.
81
79
  | ------------- | ------------------------------------------------------- | ------------------------------- |
82
80
  | **`options`** | <code><a href="#promptoptions">PromptOptions</a></code> | - Prompt configuration options. |
83
81
 
84
- **Returns:** <code>any</code>
82
+ **Returns:** <code>Promise&lt;<a href="#promptresult">PromptResult</a>&gt;</code>
85
83
 
86
84
  --------------------
87
85
 
@@ -89,7 +87,7 @@ Show a prompt dialog with a text input field.
89
87
  ### singleSelect(...)
90
88
 
91
89
  ```typescript
92
- singleSelect(options: SingleSelectOptions) => any
90
+ singleSelect(options: SingleSelectOptions) => Promise<SingleSelectResult>
93
91
  ```
94
92
 
95
93
  Show a single-select dialog where the user picks one option.
@@ -98,7 +96,7 @@ Show a single-select dialog where the user picks one option.
98
96
  | ------------- | ------------------------------------------------------------------- | -------------------------------------- |
99
97
  | **`options`** | <code><a href="#singleselectoptions">SingleSelectOptions</a></code> | - Single select configuration options. |
100
98
 
101
- **Returns:** <code>any</code>
99
+ **Returns:** <code>Promise&lt;<a href="#singleselectresult">SingleSelectResult</a>&gt;</code>
102
100
 
103
101
  --------------------
104
102
 
@@ -106,7 +104,7 @@ Show a single-select dialog where the user picks one option.
106
104
  ### multiSelect(...)
107
105
 
108
106
  ```typescript
109
- multiSelect(options: MultiSelectOptions) => any
107
+ multiSelect(options: MultiSelectOptions) => Promise<MultiSelectResult>
110
108
  ```
111
109
 
112
110
  Show a multi-select dialog where the user picks one or more options.
@@ -115,7 +113,7 @@ Show a multi-select dialog where the user picks one or more options.
115
113
  | ------------- | ----------------------------------------------------------------- | ------------------------------------- |
116
114
  | **`options`** | <code><a href="#multiselectoptions">MultiSelectOptions</a></code> | - Multi select configuration options. |
117
115
 
118
- **Returns:** <code>any</code>
116
+ **Returns:** <code>Promise&lt;<a href="#multiselectresult">MultiSelectResult</a>&gt;</code>
119
117
 
120
118
  --------------------
121
119
 
@@ -123,7 +121,7 @@ Show a multi-select dialog where the user picks one or more options.
123
121
  ### sheet(...)
124
122
 
125
123
  ```typescript
126
- sheet(options: SheetOptions) => any
124
+ sheet(options: SheetOptions) => Promise<SheetResult>
127
125
  ```
128
126
 
129
127
  Show a sheet dialog with a header, title, and structured data rows.
@@ -132,7 +130,7 @@ Show a sheet dialog with a header, title, and structured data rows.
132
130
  | ------------- | ----------------------------------------------------- | ------------------------------ |
133
131
  | **`options`** | <code><a href="#sheetoptions">SheetOptions</a></code> | - Sheet configuration options. |
134
132
 
135
- **Returns:** <code>any</code>
133
+ **Returns:** <code>Promise&lt;<a href="#sheetresult">SheetResult</a>&gt;</code>
136
134
 
137
135
  --------------------
138
136
 
@@ -140,7 +138,7 @@ Show a sheet dialog with a header, title, and structured data rows.
140
138
  ### messageSheet(...)
141
139
 
142
140
  ```typescript
143
- messageSheet(options: MessageSheetOptions) => any
141
+ messageSheet(options: MessageSheetOptions) => Promise<MessageSheetResult>
144
142
  ```
145
143
 
146
144
  Show a message sheet dialog with an optional header logo, title, and message.
@@ -149,7 +147,7 @@ Show a message sheet dialog with an optional header logo, title, and message.
149
147
  | ------------- | ------------------------------------------------------------------- | -------------------------------------- |
150
148
  | **`options`** | <code><a href="#messagesheetoptions">MessageSheetOptions</a></code> | - Message sheet configuration options. |
151
149
 
152
- **Returns:** <code>any</code>
150
+ **Returns:** <code>Promise&lt;<a href="#messagesheetresult">MessageSheetResult</a>&gt;</code>
153
151
 
154
152
  --------------------
155
153
 
@@ -164,6 +162,13 @@ Show a message sheet dialog with an optional header logo, title, and message.
164
162
  | **`buttonTitle`** | <code>string</code> | Title for the dismiss button. | <code>"OK"</code> |
165
163
 
166
164
 
165
+ #### ConfirmResult
166
+
167
+ | Prop | Type | Description |
168
+ | ----------- | -------------------- | ----------------------------------------------------------- |
169
+ | **`value`** | <code>boolean</code> | Whether the user confirmed (`true`) or cancelled (`false`). |
170
+
171
+
167
172
  #### ConfirmOptions
168
173
 
169
174
  | Prop | Type | Description | Default |
@@ -172,11 +177,12 @@ Show a message sheet dialog with an optional header logo, title, and message.
172
177
  | **`cancelButtonTitle`** | <code>string</code> | Title for the cancel button. | <code>"Cancel"</code> |
173
178
 
174
179
 
175
- #### ConfirmResult
180
+ #### PromptResult
176
181
 
177
- | Prop | Type | Description |
178
- | ----------- | -------------------- | ----------------------------------------------------------- |
179
- | **`value`** | <code>boolean</code> | Whether the user confirmed (`true`) or cancelled (`false`). |
182
+ | Prop | Type | Description |
183
+ | --------------- | -------------------- | -------------------------------------------------------- |
184
+ | **`value`** | <code>string</code> | The text entered by the user. Empty string if cancelled. |
185
+ | **`cancelled`** | <code>boolean</code> | Whether the user cancelled the dialog. |
180
186
 
181
187
 
182
188
  #### PromptOptions
@@ -190,22 +196,22 @@ Show a message sheet dialog with an optional header logo, title, and message.
190
196
  | **`focusInput`** | <code>boolean</code> | Whether to automatically focus the input field and open the keyboard when the dialog appears. Note: On iOS, basic (non-fullscreen) dialogs always auto-focus the input field due to UIAlertController's built-in behavior. This option only takes effect on iOS when using fullscreen mode (`mode: 'fullscreen'`). On Android and web, this works for all modes. | <code>false</code> |
191
197
 
192
198
 
193
- #### PromptResult
199
+ #### SingleSelectResult
194
200
 
195
- | Prop | Type | Description |
196
- | --------------- | -------------------- | -------------------------------------------------------- |
197
- | **`value`** | <code>string</code> | The text entered by the user. Empty string if cancelled. |
198
- | **`cancelled`** | <code>boolean</code> | Whether the user cancelled the dialog. |
201
+ | Prop | Type | Description |
202
+ | --------------- | --------------------------- | --------------------------------------------------------- |
203
+ | **`value`** | <code>string \| null</code> | The value of the selected option, or `null` if cancelled. |
204
+ | **`cancelled`** | <code>boolean</code> | Whether the user cancelled the dialog. |
199
205
 
200
206
 
201
207
  #### SingleSelectOptions
202
208
 
203
- | Prop | Type | Description | Default |
204
- | ----------------------- | ------------------- | ----------------------------------------- | --------------------- |
205
- | **`options`** | <code>{}</code> | List of options to display for selection. | |
206
- | **`selectedValue`** | <code>string</code> | Value of the initially selected option. | |
207
- | **`okButtonTitle`** | <code>string</code> | Title for the confirmation button. | <code>"OK"</code> |
208
- | **`cancelButtonTitle`** | <code>string</code> | Title for the cancel button. | <code>"Cancel"</code> |
209
+ | Prop | Type | Description | Default |
210
+ | ----------------------- | --------------------------- | ----------------------------------------- | --------------------- |
211
+ | **`options`** | <code>SelectOption[]</code> | List of options to display for selection. | |
212
+ | **`selectedValue`** | <code>string</code> | Value of the initially selected option. | |
213
+ | **`okButtonTitle`** | <code>string</code> | Title for the confirmation button. | <code>"OK"</code> |
214
+ | **`cancelButtonTitle`** | <code>string</code> | Title for the cancel button. | <code>"Cancel"</code> |
209
215
 
210
216
 
211
217
  #### SelectOption
@@ -216,30 +222,29 @@ Show a message sheet dialog with an optional header logo, title, and message.
216
222
  | **`value`** | <code>string</code> | Value returned when the option is selected. |
217
223
 
218
224
 
219
- #### SingleSelectResult
225
+ #### MultiSelectResult
220
226
 
221
- | Prop | Type | Description |
222
- | --------------- | --------------------------- | --------------------------------------------------------- |
223
- | **`value`** | <code>string \| null</code> | The value of the selected option, or `null` if cancelled. |
224
- | **`cancelled`** | <code>boolean</code> | Whether the user cancelled the dialog. |
227
+ | Prop | Type | Description |
228
+ | --------------- | --------------------- | ------------------------------------------------------------- |
229
+ | **`values`** | <code>string[]</code> | The values of the selected options. Empty array if cancelled. |
230
+ | **`cancelled`** | <code>boolean</code> | Whether the user cancelled the dialog. |
225
231
 
226
232
 
227
233
  #### MultiSelectOptions
228
234
 
229
- | Prop | Type | Description | Default |
230
- | ----------------------- | ------------------- | ----------------------------------------- | --------------------- |
231
- | **`options`** | <code>{}</code> | List of options to display for selection. | |
232
- | **`selectedValues`** | <code>{}</code> | Values of the initially selected options. | |
233
- | **`okButtonTitle`** | <code>string</code> | Title for the confirmation button. | <code>"OK"</code> |
234
- | **`cancelButtonTitle`** | <code>string</code> | Title for the cancel button. | <code>"Cancel"</code> |
235
+ | Prop | Type | Description | Default |
236
+ | ----------------------- | --------------------------- | ----------------------------------------- | --------------------- |
237
+ | **`options`** | <code>SelectOption[]</code> | List of options to display for selection. | |
238
+ | **`selectedValues`** | <code>string[]</code> | Values of the initially selected options. | |
239
+ | **`okButtonTitle`** | <code>string</code> | Title for the confirmation button. | <code>"OK"</code> |
240
+ | **`cancelButtonTitle`** | <code>string</code> | Title for the cancel button. | <code>"Cancel"</code> |
235
241
 
236
242
 
237
- #### MultiSelectResult
243
+ #### SheetResult
238
244
 
239
- | Prop | Type | Description |
240
- | --------------- | -------------------- | ------------------------------------------------------------- |
241
- | **`values`** | <code>{}</code> | The values of the selected options. Empty array if cancelled. |
242
- | **`cancelled`** | <code>boolean</code> | Whether the user cancelled the dialog. |
245
+ | Prop | Type | Description |
246
+ | --------------- | -------------------- | ------------------------------------- |
247
+ | **`confirmed`** | <code>boolean</code> | True if confirmed, false if cancelled |
243
248
 
244
249
 
245
250
  #### SheetOptions
@@ -249,7 +254,7 @@ Show a message sheet dialog with an optional header logo, title, and message.
249
254
  | **`headerLogo`** | <code>string</code> | Header logo - supports base64 data URL or HTTP/HTTPS URL |
250
255
  | **`title`** | <code>string</code> | Sheet title |
251
256
  | **`subtitle`** | <code>string</code> | Optional subtitle displayed between title and rows |
252
- | **`rows`** | <code>{}</code> | Description rows |
257
+ | **`rows`** | <code>SheetRow[]</code> | Description rows |
253
258
  | **`confirmButtonTitle`** | <code>string</code> | Confirm button title |
254
259
  | **`cancelButtonTitle`** | <code>string</code> | Cancel button title |
255
260
  | **`mode`** | <code><a href="#dialogmode">DialogMode</a></code> | Dialog mode |
@@ -264,7 +269,7 @@ Show a message sheet dialog with an optional header logo, title, and message.
264
269
  | **`value`** | <code>string</code> | Optional value displayed on the right |
265
270
 
266
271
 
267
- #### SheetResult
272
+ #### MessageSheetResult
268
273
 
269
274
  | Prop | Type | Description |
270
275
  | --------------- | -------------------- | ------------------------------------- |
@@ -284,13 +289,6 @@ Show a message sheet dialog with an optional header logo, title, and message.
284
289
  | **`mode`** | <code><a href="#dialogmode">DialogMode</a></code> | Dialog mode |
285
290
 
286
291
 
287
- #### MessageSheetResult
288
-
289
- | Prop | Type | Description |
290
- | --------------- | -------------------- | ------------------------------------- |
291
- | **`confirmed`** | <code>boolean</code> | True if confirmed, false if cancelled |
292
-
293
-
294
292
  ### Type Aliases
295
293
 
296
294
 
@@ -1,8 +1,8 @@
1
1
  ext {
2
2
  junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
3
- androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.7.0'
4
- androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.2.1'
5
- androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.6.1'
3
+ androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.7.1'
4
+ androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.3.0'
5
+ androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.7.0'
6
6
  }
7
7
 
8
8
  buildscript {
@@ -11,18 +11,18 @@ buildscript {
11
11
  mavenCentral()
12
12
  }
13
13
  dependencies {
14
- classpath 'com.android.tools.build:gradle:8.7.2'
14
+ classpath 'com.android.tools.build:gradle:8.13.0'
15
15
  }
16
16
  }
17
17
 
18
18
  apply plugin: 'com.android.library'
19
19
 
20
20
  android {
21
- namespace "com.albermonte.extendeddialog"
22
- compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 35
21
+ namespace = "com.albermonte.extendeddialog"
22
+ compileSdk = project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 36
23
23
  defaultConfig {
24
- minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 23
25
- targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 35
24
+ minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 24
25
+ targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 36
26
26
  versionCode 1
27
27
  versionName "1.0"
28
28
  testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
@@ -34,7 +34,7 @@ android {
34
34
  }
35
35
  }
36
36
  lintOptions {
37
- abortOnError false
37
+ abortOnError = false
38
38
  }
39
39
  compileOptions {
40
40
  sourceCompatibility JavaVersion.VERSION_21
package/dist/docs.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "methods": [
8
8
  {
9
9
  "name": "alert",
10
- "signature": "(options: AlertOptions) => any",
10
+ "signature": "(options: AlertOptions) => Promise<void>",
11
11
  "parameters": [
12
12
  {
13
13
  "name": "options",
@@ -15,7 +15,7 @@
15
15
  "type": "AlertOptions"
16
16
  }
17
17
  ],
18
- "returns": "any",
18
+ "returns": "Promise<void>",
19
19
  "tags": [
20
20
  {
21
21
  "name": "param",
@@ -30,7 +30,7 @@
30
30
  },
31
31
  {
32
32
  "name": "confirm",
33
- "signature": "(options: ConfirmOptions) => any",
33
+ "signature": "(options: ConfirmOptions) => Promise<ConfirmResult>",
34
34
  "parameters": [
35
35
  {
36
36
  "name": "options",
@@ -38,7 +38,7 @@
38
38
  "type": "ConfirmOptions"
39
39
  }
40
40
  ],
41
- "returns": "any",
41
+ "returns": "Promise<ConfirmResult>",
42
42
  "tags": [
43
43
  {
44
44
  "name": "param",
@@ -51,14 +51,14 @@
51
51
  ],
52
52
  "docs": "Show a confirmation dialog with OK and Cancel buttons.",
53
53
  "complexTypes": [
54
- "ConfirmOptions",
55
- "ConfirmResult"
54
+ "ConfirmResult",
55
+ "ConfirmOptions"
56
56
  ],
57
57
  "slug": "confirm"
58
58
  },
59
59
  {
60
60
  "name": "prompt",
61
- "signature": "(options: PromptOptions) => any",
61
+ "signature": "(options: PromptOptions) => Promise<PromptResult>",
62
62
  "parameters": [
63
63
  {
64
64
  "name": "options",
@@ -66,7 +66,7 @@
66
66
  "type": "PromptOptions"
67
67
  }
68
68
  ],
69
- "returns": "any",
69
+ "returns": "Promise<PromptResult>",
70
70
  "tags": [
71
71
  {
72
72
  "name": "param",
@@ -79,14 +79,14 @@
79
79
  ],
80
80
  "docs": "Show a prompt dialog with a text input field.",
81
81
  "complexTypes": [
82
- "PromptOptions",
83
- "PromptResult"
82
+ "PromptResult",
83
+ "PromptOptions"
84
84
  ],
85
85
  "slug": "prompt"
86
86
  },
87
87
  {
88
88
  "name": "singleSelect",
89
- "signature": "(options: SingleSelectOptions) => any",
89
+ "signature": "(options: SingleSelectOptions) => Promise<SingleSelectResult>",
90
90
  "parameters": [
91
91
  {
92
92
  "name": "options",
@@ -94,7 +94,7 @@
94
94
  "type": "SingleSelectOptions"
95
95
  }
96
96
  ],
97
- "returns": "any",
97
+ "returns": "Promise<SingleSelectResult>",
98
98
  "tags": [
99
99
  {
100
100
  "name": "param",
@@ -107,14 +107,14 @@
107
107
  ],
108
108
  "docs": "Show a single-select dialog where the user picks one option.",
109
109
  "complexTypes": [
110
- "SingleSelectOptions",
111
- "SingleSelectResult"
110
+ "SingleSelectResult",
111
+ "SingleSelectOptions"
112
112
  ],
113
113
  "slug": "singleselect"
114
114
  },
115
115
  {
116
116
  "name": "multiSelect",
117
- "signature": "(options: MultiSelectOptions) => any",
117
+ "signature": "(options: MultiSelectOptions) => Promise<MultiSelectResult>",
118
118
  "parameters": [
119
119
  {
120
120
  "name": "options",
@@ -122,7 +122,7 @@
122
122
  "type": "MultiSelectOptions"
123
123
  }
124
124
  ],
125
- "returns": "any",
125
+ "returns": "Promise<MultiSelectResult>",
126
126
  "tags": [
127
127
  {
128
128
  "name": "param",
@@ -135,14 +135,14 @@
135
135
  ],
136
136
  "docs": "Show a multi-select dialog where the user picks one or more options.",
137
137
  "complexTypes": [
138
- "MultiSelectOptions",
139
- "MultiSelectResult"
138
+ "MultiSelectResult",
139
+ "MultiSelectOptions"
140
140
  ],
141
141
  "slug": "multiselect"
142
142
  },
143
143
  {
144
144
  "name": "sheet",
145
- "signature": "(options: SheetOptions) => any",
145
+ "signature": "(options: SheetOptions) => Promise<SheetResult>",
146
146
  "parameters": [
147
147
  {
148
148
  "name": "options",
@@ -150,7 +150,7 @@
150
150
  "type": "SheetOptions"
151
151
  }
152
152
  ],
153
- "returns": "any",
153
+ "returns": "Promise<SheetResult>",
154
154
  "tags": [
155
155
  {
156
156
  "name": "param",
@@ -163,14 +163,14 @@
163
163
  ],
164
164
  "docs": "Show a sheet dialog with a header, title, and structured data rows.",
165
165
  "complexTypes": [
166
- "SheetOptions",
167
- "SheetResult"
166
+ "SheetResult",
167
+ "SheetOptions"
168
168
  ],
169
169
  "slug": "sheet"
170
170
  },
171
171
  {
172
172
  "name": "messageSheet",
173
- "signature": "(options: MessageSheetOptions) => any",
173
+ "signature": "(options: MessageSheetOptions) => Promise<MessageSheetResult>",
174
174
  "parameters": [
175
175
  {
176
176
  "name": "options",
@@ -178,7 +178,7 @@
178
178
  "type": "MessageSheetOptions"
179
179
  }
180
180
  ],
181
- "returns": "any",
181
+ "returns": "Promise<MessageSheetResult>",
182
182
  "tags": [
183
183
  {
184
184
  "name": "param",
@@ -191,8 +191,8 @@
191
191
  ],
192
192
  "docs": "Show a message sheet dialog with an optional header logo, title, and message.",
193
193
  "complexTypes": [
194
- "MessageSheetOptions",
195
- "MessageSheetResult"
194
+ "MessageSheetResult",
195
+ "MessageSheetOptions"
196
196
  ],
197
197
  "slug": "messagesheet"
198
198
  }
@@ -221,6 +221,22 @@
221
221
  }
222
222
  ]
223
223
  },
224
+ {
225
+ "name": "ConfirmResult",
226
+ "slug": "confirmresult",
227
+ "docs": "",
228
+ "tags": [],
229
+ "methods": [],
230
+ "properties": [
231
+ {
232
+ "name": "value",
233
+ "tags": [],
234
+ "docs": "Whether the user confirmed (`true`) or cancelled (`false`).",
235
+ "complexTypes": [],
236
+ "type": "boolean"
237
+ }
238
+ ]
239
+ },
224
240
  {
225
241
  "name": "ConfirmOptions",
226
242
  "slug": "confirmoptions",
@@ -255,8 +271,8 @@
255
271
  ]
256
272
  },
257
273
  {
258
- "name": "ConfirmResult",
259
- "slug": "confirmresult",
274
+ "name": "PromptResult",
275
+ "slug": "promptresult",
260
276
  "docs": "",
261
277
  "tags": [],
262
278
  "methods": [],
@@ -264,7 +280,14 @@
264
280
  {
265
281
  "name": "value",
266
282
  "tags": [],
267
- "docs": "Whether the user confirmed (`true`) or cancelled (`false`).",
283
+ "docs": "The text entered by the user. Empty string if cancelled.",
284
+ "complexTypes": [],
285
+ "type": "string"
286
+ },
287
+ {
288
+ "name": "cancelled",
289
+ "tags": [],
290
+ "docs": "Whether the user cancelled the dialog.",
268
291
  "complexTypes": [],
269
292
  "type": "boolean"
270
293
  }
@@ -330,8 +353,8 @@
330
353
  ]
331
354
  },
332
355
  {
333
- "name": "PromptResult",
334
- "slug": "promptresult",
356
+ "name": "SingleSelectResult",
357
+ "slug": "singleselectresult",
335
358
  "docs": "",
336
359
  "tags": [],
337
360
  "methods": [],
@@ -339,9 +362,9 @@
339
362
  {
340
363
  "name": "value",
341
364
  "tags": [],
342
- "docs": "The text entered by the user. Empty string if cancelled.",
365
+ "docs": "The value of the selected option, or `null` if cancelled.",
343
366
  "complexTypes": [],
344
- "type": "string"
367
+ "type": "string | null"
345
368
  },
346
369
  {
347
370
  "name": "cancelled",
@@ -366,7 +389,7 @@
366
389
  "complexTypes": [
367
390
  "SelectOption"
368
391
  ],
369
- "type": "{}"
392
+ "type": "SelectOption[]"
370
393
  },
371
394
  {
372
395
  "name": "selectedValue",
@@ -425,18 +448,18 @@
425
448
  ]
426
449
  },
427
450
  {
428
- "name": "SingleSelectResult",
429
- "slug": "singleselectresult",
451
+ "name": "MultiSelectResult",
452
+ "slug": "multiselectresult",
430
453
  "docs": "",
431
454
  "tags": [],
432
455
  "methods": [],
433
456
  "properties": [
434
457
  {
435
- "name": "value",
458
+ "name": "values",
436
459
  "tags": [],
437
- "docs": "The value of the selected option, or `null` if cancelled.",
460
+ "docs": "The values of the selected options. Empty array if cancelled.",
438
461
  "complexTypes": [],
439
- "type": "string | null"
462
+ "type": "string[]"
440
463
  },
441
464
  {
442
465
  "name": "cancelled",
@@ -461,14 +484,14 @@
461
484
  "complexTypes": [
462
485
  "SelectOption"
463
486
  ],
464
- "type": "{}"
487
+ "type": "SelectOption[]"
465
488
  },
466
489
  {
467
490
  "name": "selectedValues",
468
491
  "tags": [],
469
492
  "docs": "Values of the initially selected options.",
470
493
  "complexTypes": [],
471
- "type": "{} | undefined"
494
+ "type": "string[] | undefined"
472
495
  },
473
496
  {
474
497
  "name": "okButtonTitle",
@@ -497,23 +520,16 @@
497
520
  ]
498
521
  },
499
522
  {
500
- "name": "MultiSelectResult",
501
- "slug": "multiselectresult",
523
+ "name": "SheetResult",
524
+ "slug": "sheetresult",
502
525
  "docs": "",
503
526
  "tags": [],
504
527
  "methods": [],
505
528
  "properties": [
506
529
  {
507
- "name": "values",
508
- "tags": [],
509
- "docs": "The values of the selected options. Empty array if cancelled.",
510
- "complexTypes": [],
511
- "type": "{}"
512
- },
513
- {
514
- "name": "cancelled",
530
+ "name": "confirmed",
515
531
  "tags": [],
516
- "docs": "Whether the user cancelled the dialog.",
532
+ "docs": "True if confirmed, false if cancelled",
517
533
  "complexTypes": [],
518
534
  "type": "boolean"
519
535
  }
@@ -554,7 +570,7 @@
554
570
  "complexTypes": [
555
571
  "SheetRow"
556
572
  ],
557
- "type": "{}"
573
+ "type": "SheetRow[]"
558
574
  },
559
575
  {
560
576
  "name": "confirmButtonTitle",
@@ -612,8 +628,8 @@
612
628
  ]
613
629
  },
614
630
  {
615
- "name": "SheetResult",
616
- "slug": "sheetresult",
631
+ "name": "MessageSheetResult",
632
+ "slug": "messagesheetresult",
617
633
  "docs": "",
618
634
  "tags": [],
619
635
  "methods": [],
@@ -686,22 +702,6 @@
686
702
  "type": "DialogMode"
687
703
  }
688
704
  ]
689
- },
690
- {
691
- "name": "MessageSheetResult",
692
- "slug": "messagesheetresult",
693
- "docs": "",
694
- "tags": [],
695
- "methods": [],
696
- "properties": [
697
- {
698
- "name": "confirmed",
699
- "tags": [],
700
- "docs": "True if confirmed, false if cancelled",
701
- "complexTypes": [],
702
- "type": "boolean"
703
- }
704
- ]
705
705
  }
706
706
  ],
707
707
  "enums": [],
@@ -4,7 +4,7 @@
4
4
  * - `'basic'` — Standard modal dialog (default)
5
5
  * - `'fullscreen'` — Full-screen dialog presentation
6
6
  */
7
- export declare type DialogMode = 'basic' | 'fullscreen';
7
+ export type DialogMode = 'basic' | 'fullscreen';
8
8
  export interface DialogStyleOptions {
9
9
  /**
10
10
  * Color for the OK/primary button (hex format, e.g., "#FF5722")
@@ -1 +1 @@
1
- {"version":3,"file":"web.js","sourceRoot":"","sources":["../../src/web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAoB5C,MAAM,OAAO,iBAAkB,SAAQ,SAAS;IAC9C,KAAK,CAAC,KAAK,CAAC,OAAqB;QAC/B,MAAM,OAAO,GAAG,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,KAAK,OAAO,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;QAC3F,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IACxB,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,OAAuB;QACnC,MAAM,OAAO,GAAG,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,KAAK,OAAO,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;QAC3F,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACvC,OAAO,EAAE,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CAAC,OAAO,GAAG;oBACP,OAAO;uBACJ,YAAY,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM;;eAEnC,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,kBAAkB;gBACzC,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM;oBAC1B,YAAY,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM;;;oBAG/B,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,+BAA+B;KACtE,CAAC;QACF,OAAO,MAAM,CAAC;IAChB,CAAC;CACF","sourcesContent":["import { WebPlugin } from '@capacitor/core';\n\nimport type {\n ExtendedDialogPlugin,\n AlertOptions,\n ConfirmOptions,\n ConfirmResult,\n PromptOptions,\n PromptResult,\n SingleSelectOptions,\n SingleSelectResult,\n MultiSelectOptions,\n MultiSelectResult,\n SheetOptions,\n SheetResult,\n MessageSheetOptions,\n MessageSheetResult,\n DialogStyleOptions,\n} from './definitions';\n\nexport class ExtendedDialogWeb extends WebPlugin implements ExtendedDialogPlugin {\n async alert(options: AlertOptions): Promise<void> {\n const message = options.title ? `${options.title}\\n\\n${options.message}` : options.message;\n window.alert(message);\n }\n\n async confirm(options: ConfirmOptions): Promise<ConfirmResult> {\n const message = options.title ? `${options.title}\\n\\n${options.message}` : options.message;\n const result = window.confirm(message);\n return { value: result };\n }\n\n async prompt(options: PromptOptions): Promise<PromptResult> {\n // Note: focusInput option is ignored on web as window.prompt() handles focus automatically\n // and does not provide programmatic control over keyboard/focus behavior\n const message = options.title ? `${options.title}\\n\\n${options.message}` : options.message;\n const result = window.prompt(message, options.inputText ?? '');\n return {\n value: result ?? '',\n cancelled: result === null,\n };\n }\n\n async singleSelect(options: SingleSelectOptions): Promise<SingleSelectResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createDialogContainer(options.title, options.message, options);\n\n const optionsContainer = document.createElement('div');\n optionsContainer.style.cssText = 'max-height: 300px; overflow-y: auto; margin: 16px 0;';\n\n let selectedValue = options.selectedValue ?? null;\n\n options.options.forEach((option) => {\n const label = document.createElement('label');\n label.style.cssText =\n 'display: flex; align-items: center; padding: 12px 0; cursor: pointer; border-bottom: 1px solid #e0e0e0;';\n\n const radio = document.createElement('input');\n radio.type = 'radio';\n radio.name = 'singleSelect';\n radio.value = option.value;\n radio.checked = option.value === selectedValue;\n radio.style.cssText = 'margin-right: 12px; width: 20px; height: 20px;';\n radio.addEventListener('change', () => {\n selectedValue = option.value;\n });\n\n const text = document.createElement('span');\n text.textContent = option.label;\n text.style.cssText = 'font-size: 16px;';\n\n label.appendChild(radio);\n label.appendChild(text);\n optionsContainer.appendChild(label);\n });\n\n dialog.appendChild(optionsContainer);\n\n const buttonContainer = this.createButtonContainer(options.contentButtonSpacing);\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ value: null, cancelled: true });\n },\n options,\n );\n\n const okButton = this.createButton(\n options.okButtonTitle ?? 'OK',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ value: selectedValue, cancelled: false });\n },\n options,\n );\n\n buttonContainer.appendChild(cancelButton);\n buttonContainer.appendChild(okButton);\n dialog.appendChild(buttonContainer);\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n async multiSelect(options: MultiSelectOptions): Promise<MultiSelectResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createDialogContainer(options.title, options.message, options);\n\n const optionsContainer = document.createElement('div');\n optionsContainer.style.cssText = 'max-height: 300px; overflow-y: auto; margin: 16px 0;';\n\n const selectedValues = new Set(options.selectedValues ?? []);\n\n options.options.forEach((option) => {\n const label = document.createElement('label');\n label.style.cssText =\n 'display: flex; align-items: center; padding: 12px 0; cursor: pointer; border-bottom: 1px solid #e0e0e0;';\n\n const checkbox = document.createElement('input');\n checkbox.type = 'checkbox';\n checkbox.value = option.value;\n checkbox.checked = selectedValues.has(option.value);\n checkbox.style.cssText = 'margin-right: 12px; width: 20px; height: 20px;';\n checkbox.addEventListener('change', () => {\n if (checkbox.checked) {\n selectedValues.add(option.value);\n } else {\n selectedValues.delete(option.value);\n }\n });\n\n const text = document.createElement('span');\n text.textContent = option.label;\n text.style.cssText = 'font-size: 16px;';\n\n label.appendChild(checkbox);\n label.appendChild(text);\n optionsContainer.appendChild(label);\n });\n\n dialog.appendChild(optionsContainer);\n\n const buttonContainer = this.createButtonContainer(options.contentButtonSpacing);\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ values: [], cancelled: true });\n },\n options,\n );\n\n const okButton = this.createButton(\n options.okButtonTitle ?? 'OK',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ values: Array.from(selectedValues), cancelled: false });\n },\n options,\n );\n\n buttonContainer.appendChild(cancelButton);\n buttonContainer.appendChild(okButton);\n dialog.appendChild(buttonContainer);\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n private createOverlay(): HTMLDivElement {\n const overlay = document.createElement('div');\n overlay.style.cssText = `\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 999999;\n `;\n return overlay;\n }\n\n private createDialogContainer(title?: string, message?: string, styleOptions?: DialogStyleOptions): HTMLDivElement {\n const dialog = document.createElement('div');\n const bgColor = styleOptions?.backgroundColor ?? 'white';\n dialog.style.cssText = `\n background: ${bgColor};\n border-radius: 16px;\n padding: 24px;\n min-width: 300px;\n max-width: 400px;\n max-height: 80vh;\n overflow-y: auto;\n box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);\n `;\n\n if (title) {\n const titleEl = document.createElement('h2');\n titleEl.textContent = title;\n const titleFontSize = styleOptions?.titleFontSize ?? 20;\n const titleColor = styleOptions?.titleColor ?? 'inherit';\n titleEl.style.cssText = `margin: 0 0 8px 0; font-size: ${titleFontSize}px; font-weight: 600; color: ${titleColor};`;\n dialog.appendChild(titleEl);\n }\n\n if (message) {\n const messageEl = document.createElement('p');\n messageEl.textContent = message;\n const messageFontSize = styleOptions?.messageFontSize ?? 14;\n const messageColor = styleOptions?.messageColor ?? '#666';\n messageEl.style.cssText = `margin: 0; font-size: ${messageFontSize}px; color: ${messageColor};`;\n dialog.appendChild(messageEl);\n }\n\n return dialog;\n }\n\n private createButtonContainer(contentButtonSpacing?: number): HTMLDivElement {\n const container = document.createElement('div');\n const spacing = contentButtonSpacing ?? 24;\n container.style.cssText = `display: flex; justify-content: flex-end; gap: 8px; margin-top: ${spacing}px;`;\n return container;\n }\n\n private createButton(\n text: string,\n primary: boolean,\n onClick: () => void,\n styleOptions?: DialogStyleOptions,\n ): HTMLButtonElement {\n const button = document.createElement('button');\n button.textContent = text;\n const fontSize = styleOptions?.buttonFontSize ?? 14;\n const primaryColor = styleOptions?.buttonColor ?? '#6750A4';\n const cancelColor = styleOptions?.cancelButtonColor ?? '#6750A4';\n button.style.cssText = `\n padding: 10px 24px;\n border-radius: 8px;\n font-size: ${fontSize}px;\n font-weight: 500;\n cursor: pointer;\n border: none;\n ${primary ? `background: ${primaryColor}; color: white;` : `background: transparent; color: ${cancelColor};`}\n `;\n button.addEventListener('click', onClick);\n return button;\n }\n\n private removeOverlay(overlay: HTMLDivElement): void {\n overlay.remove();\n }\n\n async sheet(options: SheetOptions): Promise<SheetResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createSheetDialogContainer(options);\n\n // Header section with logo and title\n const headerSection = document.createElement('div');\n headerSection.style.cssText = 'display: flex; flex-direction: column; align-items: center; margin-bottom: 24px;';\n\n if (options.headerLogo) {\n const headerLogo = document.createElement('img');\n headerLogo.src = options.headerLogo;\n // Apply corner radius (default 8px, -1 for circle)\n const radiusPx = options.headerLogoCornerRadius;\n let borderRadius: string;\n if (radiusPx !== undefined && radiusPx < 0) {\n // -1 means full circle\n borderRadius = '50%';\n } else {\n borderRadius = `${radiusPx ?? 8}px`;\n }\n headerLogo.style.cssText = `width: 48px; height: 48px; object-fit: contain; margin-bottom: 12px; border-radius: ${borderRadius};`;\n headerLogo.onerror = () => {\n headerLogo.style.display = 'none';\n };\n headerSection.appendChild(headerLogo);\n }\n\n const titleEl = document.createElement('h2');\n titleEl.textContent = options.title;\n const titleFontSize = options.titleFontSize ?? 20;\n const titleColor = options.titleColor ?? 'inherit';\n titleEl.style.cssText = `margin: 0; font-size: ${titleFontSize}px; font-weight: 600; color: ${titleColor}; text-align: center;`;\n headerSection.appendChild(titleEl);\n\n if (options.subtitle) {\n const subtitleEl = document.createElement('p');\n subtitleEl.textContent = options.subtitle;\n const subtitleFontSize = options.messageFontSize ?? 14;\n const subtitleColor = options.messageColor ?? '#666';\n subtitleEl.style.cssText = `margin: 4px 0 0 0; font-size: ${subtitleFontSize}px; font-weight: 400; color: ${subtitleColor}; text-align: center;`;\n headerSection.appendChild(subtitleEl);\n }\n\n dialog.appendChild(headerSection);\n\n // Rows container\n const rowsContainer = document.createElement('div');\n rowsContainer.style.cssText = 'display: flex; flex-direction: column; gap: 0; margin-bottom: 24px;';\n\n options.rows.forEach((row, index) => {\n const rowEl = document.createElement('div');\n rowEl.style.cssText = `\n display: flex;\n align-items: center;\n padding: 16px 0;\n ${index < options.rows.length - 1 ? 'border-bottom: 1px solid #e0e0e0;' : ''}\n `;\n\n if (row.logo) {\n const rowLogo = document.createElement('img');\n rowLogo.src = row.logo;\n rowLogo.style.cssText =\n 'width: 24px; height: 24px; object-fit: contain; margin-right: 12px; border-radius: 4px; flex-shrink: 0;';\n rowLogo.onerror = () => {\n rowLogo.style.display = 'none';\n };\n rowEl.appendChild(rowLogo);\n }\n\n const rowTitle = document.createElement('span');\n rowTitle.textContent = row.title;\n const messageFontSize = options.messageFontSize ?? 16;\n const messageColor = options.messageColor ?? '#333';\n rowTitle.style.cssText = `font-size: ${messageFontSize}px; color: ${messageColor}; flex: 1;`;\n rowEl.appendChild(rowTitle);\n\n if (row.value) {\n const rowValue = document.createElement('span');\n rowValue.textContent = row.value;\n rowValue.style.cssText = `font-size: ${messageFontSize}px; color: #666; text-align: right; margin-left: 12px;`;\n rowEl.appendChild(rowValue);\n }\n\n rowsContainer.appendChild(rowEl);\n });\n\n dialog.appendChild(rowsContainer);\n\n // For sheets with ≤4 rows and no explicit spacing, add extra spacing to reach ~50% viewport height\n let sheetSpacing = options.contentButtonSpacing;\n if (sheetSpacing === undefined && options.rows.length <= 4) {\n const targetHeight = window.innerHeight * 0.5;\n // Estimate content: padding(48) + header(~80) + rows(~49 each) + buttons(~44) + default spacing(24)\n const estimatedHeight = 48 + 80 + options.rows.length * 49 + 44 + 24;\n if (targetHeight > estimatedHeight) {\n sheetSpacing = 24 + (targetHeight - estimatedHeight);\n }\n }\n\n // Button container\n const buttonContainer = this.createButtonContainer(sheetSpacing);\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: false });\n },\n options,\n );\n\n const confirmButton = this.createButton(\n options.confirmButtonTitle ?? 'Confirm',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: true });\n },\n options,\n );\n\n buttonContainer.appendChild(cancelButton);\n buttonContainer.appendChild(confirmButton);\n dialog.appendChild(buttonContainer);\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n async messageSheet(options: MessageSheetOptions): Promise<MessageSheetResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createMessageSheetDialogContainer(options);\n\n const content = document.createElement('div');\n content.style.cssText = 'display: flex; flex-direction: column; flex: 1 1 auto; overflow-y: auto;';\n\n if (options.headerLogo) {\n const headerLogo = document.createElement('img');\n headerLogo.src = options.headerLogo;\n const logoSize = options.mode === 'fullscreen' ? 64 : 48;\n // Apply corner radius (default 8px, -1 for circle)\n const radiusPx = options.headerLogoCornerRadius;\n let borderRadius: string;\n if (radiusPx !== undefined && radiusPx < 0) {\n // -1 means full circle\n borderRadius = '50%';\n } else {\n borderRadius = `${radiusPx ?? 8}px`;\n }\n headerLogo.style.cssText = `width: ${logoSize}px; height: ${logoSize}px; object-fit: contain; margin: 0 auto 16px auto; border-radius: ${borderRadius};`;\n headerLogo.onerror = () => {\n headerLogo.style.display = 'none';\n };\n content.appendChild(headerLogo);\n }\n\n const titleEl = document.createElement('h2');\n titleEl.textContent = options.title;\n const titleFontSize = options.titleFontSize ?? 20;\n const titleColor = options.titleColor ?? 'inherit';\n titleEl.style.cssText = `margin: 0 0 ${options.subtitle ? '4px' : '16px'} 0; font-size: ${titleFontSize}px; font-weight: 600; color: ${titleColor}; text-align: center;`;\n content.appendChild(titleEl);\n\n if (options.subtitle) {\n const subtitleEl = document.createElement('p');\n subtitleEl.textContent = options.subtitle;\n const subtitleFontSize = options.messageFontSize ?? 14;\n const subtitleColor = options.messageColor ?? '#666';\n subtitleEl.style.cssText = `margin: 0 0 16px 0; font-size: ${subtitleFontSize}px; font-weight: 400; color: ${subtitleColor}; text-align: center;`;\n content.appendChild(subtitleEl);\n }\n\n const messageEl = document.createElement('p');\n messageEl.textContent = options.message;\n const messageFontSize = options.messageFontSize ?? 16;\n const messageColor = options.messageColor ?? '#666';\n messageEl.style.cssText = `margin: 0; font-size: ${messageFontSize}px; color: ${messageColor}; white-space: pre-wrap; word-break: break-word;`;\n\n const messageContainer = document.createElement('div');\n messageContainer.style.cssText = 'background: #E5E5EA; border-radius: 12px; padding: 16px; margin: 0;';\n messageContainer.appendChild(messageEl);\n content.appendChild(messageContainer);\n\n dialog.appendChild(content);\n\n const spacing = options.contentButtonSpacing ?? 24;\n const buttonContainer = document.createElement('div');\n buttonContainer.style.cssText = `display: flex; flex-direction: column; gap: 12px; margin-top: ${spacing}px;`;\n\n const confirmButton = this.createButton(\n options.confirmButtonTitle ?? 'Confirm',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: true });\n },\n options,\n );\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: false });\n },\n options,\n );\n\n buttonContainer.appendChild(confirmButton);\n buttonContainer.appendChild(cancelButton);\n dialog.appendChild(buttonContainer);\n\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n private createSheetDialogContainer(options: SheetOptions): HTMLDivElement {\n const dialog = document.createElement('div');\n const bgColor = options.backgroundColor ?? 'white';\n dialog.style.cssText = `\n background: ${bgColor};\n border-radius: 16px;\n padding: 24px;\n min-width: 320px;\n max-width: 420px;\n max-height: 80vh;\n overflow-y: auto;\n box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);\n `;\n return dialog;\n }\n\n private createMessageSheetDialogContainer(options: MessageSheetOptions): HTMLDivElement {\n const dialog = document.createElement('div');\n const bgColor = options.backgroundColor ?? 'white';\n const isFullscreen = options.mode === 'fullscreen';\n dialog.style.cssText = `\n background: ${bgColor};\n border-radius: ${isFullscreen ? '0' : '16px'};\n padding: 24px;\n width: ${isFullscreen ? '100%' : 'min(90vw, 420px)'};\n height: ${isFullscreen ? '100%' : 'auto'};\n max-height: ${isFullscreen ? '100vh' : '80vh'};\n display: flex;\n flex-direction: column;\n box-shadow: ${isFullscreen ? 'none' : '0 4px 24px rgba(0, 0, 0, 0.2)'};\n `;\n return dialog;\n }\n}\n"]}
1
+ {"version":3,"file":"web.js","sourceRoot":"","sources":["../../src/web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAoB5C,MAAM,OAAO,iBAAkB,SAAQ,SAAS;IAC9C,KAAK,CAAC,KAAK,CAAC,OAAqB;QAC/B,MAAM,OAAO,GAAG,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,KAAK,OAAO,OAAO,CAAC,OAAO,EAAE,CAAC,CAA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ertOptions,\n ConfirmOptions,\n ConfirmResult,\n PromptOptions,\n PromptResult,\n SingleSelectOptions,\n SingleSelectResult,\n MultiSelectOptions,\n MultiSelectResult,\n SheetOptions,\n SheetResult,\n MessageSheetOptions,\n MessageSheetResult,\n DialogStyleOptions,\n} from './definitions';\n\nexport class ExtendedDialogWeb extends WebPlugin implements ExtendedDialogPlugin {\n async alert(options: AlertOptions): Promise<void> {\n const message = options.title ? `${options.title}\\n\\n${options.message}` : options.message;\n window.alert(message);\n }\n\n async confirm(options: ConfirmOptions): Promise<ConfirmResult> {\n const message = options.title ? `${options.title}\\n\\n${options.message}` : options.message;\n const result = window.confirm(message);\n return { value: result };\n }\n\n async prompt(options: PromptOptions): Promise<PromptResult> {\n // Note: focusInput option is ignored on web as window.prompt() handles focus automatically\n // and does not provide programmatic control over keyboard/focus behavior\n const message = options.title ? `${options.title}\\n\\n${options.message}` : options.message;\n const result = window.prompt(message, options.inputText ?? '');\n return {\n value: result ?? '',\n cancelled: result === null,\n };\n }\n\n async singleSelect(options: SingleSelectOptions): Promise<SingleSelectResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createDialogContainer(options.title, options.message, options);\n\n const optionsContainer = document.createElement('div');\n optionsContainer.style.cssText = 'max-height: 300px; overflow-y: auto; margin: 16px 0;';\n\n let selectedValue = options.selectedValue ?? null;\n\n options.options.forEach((option) => {\n const label = document.createElement('label');\n label.style.cssText =\n 'display: flex; align-items: center; padding: 12px 0; cursor: pointer; border-bottom: 1px solid #e0e0e0;';\n\n const radio = document.createElement('input');\n radio.type = 'radio';\n radio.name = 'singleSelect';\n radio.value = option.value;\n radio.checked = option.value === selectedValue;\n radio.style.cssText = 'margin-right: 12px; width: 20px; height: 20px;';\n radio.addEventListener('change', () => {\n selectedValue = option.value;\n });\n\n const text = document.createElement('span');\n text.textContent = option.label;\n text.style.cssText = 'font-size: 16px;';\n\n label.appendChild(radio);\n label.appendChild(text);\n optionsContainer.appendChild(label);\n });\n\n dialog.appendChild(optionsContainer);\n\n const buttonContainer = this.createButtonContainer(options.contentButtonSpacing);\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ value: null, cancelled: true });\n },\n options,\n );\n\n const okButton = this.createButton(\n options.okButtonTitle ?? 'OK',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ value: selectedValue, cancelled: false });\n },\n options,\n );\n\n buttonContainer.appendChild(cancelButton);\n buttonContainer.appendChild(okButton);\n dialog.appendChild(buttonContainer);\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n async multiSelect(options: MultiSelectOptions): Promise<MultiSelectResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createDialogContainer(options.title, options.message, options);\n\n const optionsContainer = document.createElement('div');\n optionsContainer.style.cssText = 'max-height: 300px; overflow-y: auto; margin: 16px 0;';\n\n const selectedValues = new Set(options.selectedValues ?? []);\n\n options.options.forEach((option) => {\n const label = document.createElement('label');\n label.style.cssText =\n 'display: flex; align-items: center; padding: 12px 0; cursor: pointer; border-bottom: 1px solid #e0e0e0;';\n\n const checkbox = document.createElement('input');\n checkbox.type = 'checkbox';\n checkbox.value = option.value;\n checkbox.checked = selectedValues.has(option.value);\n checkbox.style.cssText = 'margin-right: 12px; width: 20px; height: 20px;';\n checkbox.addEventListener('change', () => {\n if (checkbox.checked) {\n selectedValues.add(option.value);\n } else {\n selectedValues.delete(option.value);\n }\n });\n\n const text = document.createElement('span');\n text.textContent = option.label;\n text.style.cssText = 'font-size: 16px;';\n\n label.appendChild(checkbox);\n label.appendChild(text);\n optionsContainer.appendChild(label);\n });\n\n dialog.appendChild(optionsContainer);\n\n const buttonContainer = this.createButtonContainer(options.contentButtonSpacing);\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ values: [], cancelled: true });\n },\n options,\n );\n\n const okButton = this.createButton(\n options.okButtonTitle ?? 'OK',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ values: Array.from(selectedValues), cancelled: false });\n },\n options,\n );\n\n buttonContainer.appendChild(cancelButton);\n buttonContainer.appendChild(okButton);\n dialog.appendChild(buttonContainer);\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n private createOverlay(): HTMLDivElement {\n const overlay = document.createElement('div');\n overlay.style.cssText = `\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 999999;\n `;\n return overlay;\n }\n\n private createDialogContainer(title?: string, message?: string, styleOptions?: DialogStyleOptions): HTMLDivElement {\n const dialog = document.createElement('div');\n const bgColor = styleOptions?.backgroundColor ?? 'white';\n dialog.style.cssText = `\n background: ${bgColor};\n border-radius: 16px;\n padding: 24px;\n min-width: 300px;\n max-width: 400px;\n max-height: 80vh;\n overflow-y: auto;\n box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);\n `;\n\n if (title) {\n const titleEl = document.createElement('h2');\n titleEl.textContent = title;\n const titleFontSize = styleOptions?.titleFontSize ?? 20;\n const titleColor = styleOptions?.titleColor ?? 'inherit';\n titleEl.style.cssText = `margin: 0 0 8px 0; font-size: ${titleFontSize}px; font-weight: 600; color: ${titleColor};`;\n dialog.appendChild(titleEl);\n }\n\n if (message) {\n const messageEl = document.createElement('p');\n messageEl.textContent = message;\n const messageFontSize = styleOptions?.messageFontSize ?? 14;\n const messageColor = styleOptions?.messageColor ?? '#666';\n messageEl.style.cssText = `margin: 0; font-size: ${messageFontSize}px; color: ${messageColor};`;\n dialog.appendChild(messageEl);\n }\n\n return dialog;\n }\n\n private createButtonContainer(contentButtonSpacing?: number): HTMLDivElement {\n const container = document.createElement('div');\n const spacing = contentButtonSpacing ?? 24;\n container.style.cssText = `display: flex; justify-content: flex-end; gap: 8px; margin-top: ${spacing}px;`;\n return container;\n }\n\n private createButton(\n text: string,\n primary: boolean,\n onClick: () => void,\n styleOptions?: DialogStyleOptions,\n ): HTMLButtonElement {\n const button = document.createElement('button');\n button.textContent = text;\n const fontSize = styleOptions?.buttonFontSize ?? 14;\n const primaryColor = styleOptions?.buttonColor ?? '#6750A4';\n const cancelColor = styleOptions?.cancelButtonColor ?? '#6750A4';\n button.style.cssText = `\n padding: 10px 24px;\n border-radius: 8px;\n font-size: ${fontSize}px;\n font-weight: 500;\n cursor: pointer;\n border: none;\n ${primary ? `background: ${primaryColor}; color: white;` : `background: transparent; color: ${cancelColor};`}\n `;\n button.addEventListener('click', onClick);\n return button;\n }\n\n private removeOverlay(overlay: HTMLDivElement): void {\n overlay.remove();\n }\n\n async sheet(options: SheetOptions): Promise<SheetResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createSheetDialogContainer(options);\n\n // Header section with logo and title\n const headerSection = document.createElement('div');\n headerSection.style.cssText = 'display: flex; flex-direction: column; align-items: center; margin-bottom: 24px;';\n\n if (options.headerLogo) {\n const headerLogo = document.createElement('img');\n headerLogo.src = options.headerLogo;\n // Apply corner radius (default 8px, -1 for circle)\n const radiusPx = options.headerLogoCornerRadius;\n let borderRadius: string;\n if (radiusPx !== undefined && radiusPx < 0) {\n // -1 means full circle\n borderRadius = '50%';\n } else {\n borderRadius = `${radiusPx ?? 8}px`;\n }\n headerLogo.style.cssText = `width: 48px; height: 48px; object-fit: contain; margin-bottom: 12px; border-radius: ${borderRadius};`;\n headerLogo.onerror = () => {\n headerLogo.style.display = 'none';\n };\n headerSection.appendChild(headerLogo);\n }\n\n const titleEl = document.createElement('h2');\n titleEl.textContent = options.title;\n const titleFontSize = options.titleFontSize ?? 20;\n const titleColor = options.titleColor ?? 'inherit';\n titleEl.style.cssText = `margin: 0; font-size: ${titleFontSize}px; font-weight: 600; color: ${titleColor}; text-align: center;`;\n headerSection.appendChild(titleEl);\n\n if (options.subtitle) {\n const subtitleEl = document.createElement('p');\n subtitleEl.textContent = options.subtitle;\n const subtitleFontSize = options.messageFontSize ?? 14;\n const subtitleColor = options.messageColor ?? '#666';\n subtitleEl.style.cssText = `margin: 4px 0 0 0; font-size: ${subtitleFontSize}px; font-weight: 400; color: ${subtitleColor}; text-align: center;`;\n headerSection.appendChild(subtitleEl);\n }\n\n dialog.appendChild(headerSection);\n\n // Rows container\n const rowsContainer = document.createElement('div');\n rowsContainer.style.cssText = 'display: flex; flex-direction: column; gap: 0; margin-bottom: 24px;';\n\n options.rows.forEach((row, index) => {\n const rowEl = document.createElement('div');\n rowEl.style.cssText = `\n display: flex;\n align-items: center;\n padding: 16px 0;\n ${index < options.rows.length - 1 ? 'border-bottom: 1px solid #e0e0e0;' : ''}\n `;\n\n if (row.logo) {\n const rowLogo = document.createElement('img');\n rowLogo.src = row.logo;\n rowLogo.style.cssText =\n 'width: 24px; height: 24px; object-fit: contain; margin-right: 12px; border-radius: 4px; flex-shrink: 0;';\n rowLogo.onerror = () => {\n rowLogo.style.display = 'none';\n };\n rowEl.appendChild(rowLogo);\n }\n\n const rowTitle = document.createElement('span');\n rowTitle.textContent = row.title;\n const messageFontSize = options.messageFontSize ?? 16;\n const messageColor = options.messageColor ?? '#333';\n rowTitle.style.cssText = `font-size: ${messageFontSize}px; color: ${messageColor}; flex: 1;`;\n rowEl.appendChild(rowTitle);\n\n if (row.value) {\n const rowValue = document.createElement('span');\n rowValue.textContent = row.value;\n rowValue.style.cssText = `font-size: ${messageFontSize}px; color: #666; text-align: right; margin-left: 12px;`;\n rowEl.appendChild(rowValue);\n }\n\n rowsContainer.appendChild(rowEl);\n });\n\n dialog.appendChild(rowsContainer);\n\n // For sheets with ≤4 rows and no explicit spacing, add extra spacing to reach ~50% viewport height\n let sheetSpacing = options.contentButtonSpacing;\n if (sheetSpacing === undefined && options.rows.length <= 4) {\n const targetHeight = window.innerHeight * 0.5;\n // Estimate content: padding(48) + header(~80) + rows(~49 each) + buttons(~44) + default spacing(24)\n const estimatedHeight = 48 + 80 + options.rows.length * 49 + 44 + 24;\n if (targetHeight > estimatedHeight) {\n sheetSpacing = 24 + (targetHeight - estimatedHeight);\n }\n }\n\n // Button container\n const buttonContainer = this.createButtonContainer(sheetSpacing);\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: false });\n },\n options,\n );\n\n const confirmButton = this.createButton(\n options.confirmButtonTitle ?? 'Confirm',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: true });\n },\n options,\n );\n\n buttonContainer.appendChild(cancelButton);\n buttonContainer.appendChild(confirmButton);\n dialog.appendChild(buttonContainer);\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n async messageSheet(options: MessageSheetOptions): Promise<MessageSheetResult> {\n return new Promise((resolve) => {\n const overlay = this.createOverlay();\n const dialog = this.createMessageSheetDialogContainer(options);\n\n const content = document.createElement('div');\n content.style.cssText = 'display: flex; flex-direction: column; flex: 1 1 auto; overflow-y: auto;';\n\n if (options.headerLogo) {\n const headerLogo = document.createElement('img');\n headerLogo.src = options.headerLogo;\n const logoSize = options.mode === 'fullscreen' ? 64 : 48;\n // Apply corner radius (default 8px, -1 for circle)\n const radiusPx = options.headerLogoCornerRadius;\n let borderRadius: string;\n if (radiusPx !== undefined && radiusPx < 0) {\n // -1 means full circle\n borderRadius = '50%';\n } else {\n borderRadius = `${radiusPx ?? 8}px`;\n }\n headerLogo.style.cssText = `width: ${logoSize}px; height: ${logoSize}px; object-fit: contain; margin: 0 auto 16px auto; border-radius: ${borderRadius};`;\n headerLogo.onerror = () => {\n headerLogo.style.display = 'none';\n };\n content.appendChild(headerLogo);\n }\n\n const titleEl = document.createElement('h2');\n titleEl.textContent = options.title;\n const titleFontSize = options.titleFontSize ?? 20;\n const titleColor = options.titleColor ?? 'inherit';\n titleEl.style.cssText = `margin: 0 0 ${options.subtitle ? '4px' : '16px'} 0; font-size: ${titleFontSize}px; font-weight: 600; color: ${titleColor}; text-align: center;`;\n content.appendChild(titleEl);\n\n if (options.subtitle) {\n const subtitleEl = document.createElement('p');\n subtitleEl.textContent = options.subtitle;\n const subtitleFontSize = options.messageFontSize ?? 14;\n const subtitleColor = options.messageColor ?? '#666';\n subtitleEl.style.cssText = `margin: 0 0 16px 0; font-size: ${subtitleFontSize}px; font-weight: 400; color: ${subtitleColor}; text-align: center;`;\n content.appendChild(subtitleEl);\n }\n\n const messageEl = document.createElement('p');\n messageEl.textContent = options.message;\n const messageFontSize = options.messageFontSize ?? 16;\n const messageColor = options.messageColor ?? '#666';\n messageEl.style.cssText = `margin: 0; font-size: ${messageFontSize}px; color: ${messageColor}; white-space: pre-wrap; word-break: break-word;`;\n\n const messageContainer = document.createElement('div');\n messageContainer.style.cssText = 'background: #E5E5EA; border-radius: 12px; padding: 16px; margin: 0;';\n messageContainer.appendChild(messageEl);\n content.appendChild(messageContainer);\n\n dialog.appendChild(content);\n\n const spacing = options.contentButtonSpacing ?? 24;\n const buttonContainer = document.createElement('div');\n buttonContainer.style.cssText = `display: flex; flex-direction: column; gap: 12px; margin-top: ${spacing}px;`;\n\n const confirmButton = this.createButton(\n options.confirmButtonTitle ?? 'Confirm',\n true,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: true });\n },\n options,\n );\n\n const cancelButton = this.createButton(\n options.cancelButtonTitle ?? 'Cancel',\n false,\n () => {\n this.removeOverlay(overlay);\n resolve({ confirmed: false });\n },\n options,\n );\n\n buttonContainer.appendChild(confirmButton);\n buttonContainer.appendChild(cancelButton);\n dialog.appendChild(buttonContainer);\n\n overlay.appendChild(dialog);\n document.body.appendChild(overlay);\n });\n }\n\n private createSheetDialogContainer(options: SheetOptions): HTMLDivElement {\n const dialog = document.createElement('div');\n const bgColor = options.backgroundColor ?? 'white';\n dialog.style.cssText = `\n background: ${bgColor};\n border-radius: 16px;\n padding: 24px;\n min-width: 320px;\n max-width: 420px;\n max-height: 80vh;\n overflow-y: auto;\n box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);\n `;\n return dialog;\n }\n\n private createMessageSheetDialogContainer(options: MessageSheetOptions): HTMLDivElement {\n const dialog = document.createElement('div');\n const bgColor = options.backgroundColor ?? 'white';\n const isFullscreen = options.mode === 'fullscreen';\n dialog.style.cssText = `\n background: ${bgColor};\n border-radius: ${isFullscreen ? '0' : '16px'};\n padding: 24px;\n width: ${isFullscreen ? '100%' : 'min(90vw, 420px)'};\n height: ${isFullscreen ? '100%' : 'auto'};\n max-height: ${isFullscreen ? '100vh' : '80vh'};\n display: flex;\n flex-direction: column;\n box-shadow: ${isFullscreen ? 'none' : '0 4px 24px rgba(0, 0, 0, 0.2)'};\n `;\n return dialog;\n }\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "capacitor-extended-dialog",
3
- "version": "0.0.13",
3
+ "version": "0.0.14",
4
4
  "description": "Show native dialogs and sheets in Capacitor with Material 3 and Liquid Glass UI",
5
5
  "main": "dist/plugin.cjs.js",
6
6
  "module": "dist/esm/index.js",
@@ -46,23 +46,23 @@
46
46
  "prepublishOnly": "npm run build"
47
47
  },
48
48
  "devDependencies": {
49
- "@capacitor/android": "^7.0.0",
50
- "@capacitor/core": "^7.0.0",
51
- "@capacitor/docgen": "^0.3.0",
52
- "@capacitor/ios": "^7.0.0",
49
+ "@capacitor/android": "^8.0.0",
50
+ "@capacitor/core": "^8.0.0",
51
+ "@capacitor/docgen": "^0.3.1",
52
+ "@capacitor/ios": "^8.0.0",
53
53
  "@ionic/eslint-config": "^0.4.0",
54
54
  "@ionic/prettier-config": "^4.0.0",
55
55
  "@ionic/swiftlint-config": "^2.0.0",
56
- "eslint": "^8.57.0",
57
- "prettier": "^3.4.2",
58
- "prettier-plugin-java": "^2.6.6",
59
- "rimraf": "^6.0.1",
60
- "rollup": "^4.30.1",
56
+ "eslint": "^8.57.1",
57
+ "prettier": "^3.6.2",
58
+ "prettier-plugin-java": "^2.7.7",
59
+ "rimraf": "^6.1.0",
60
+ "rollup": "^4.53.2",
61
61
  "swiftlint": "^2.0.0",
62
- "typescript": "~4.1.5"
62
+ "typescript": "^5.9.3"
63
63
  },
64
64
  "peerDependencies": {
65
- "@capacitor/core": ">=7.0.0"
65
+ "@capacitor/core": ">=8.0.0"
66
66
  },
67
67
  "prettier": "@ionic/prettier-config",
68
68
  "swiftlint": "@ionic/swiftlint-config",