@airtable/blocks 1.11.0 → 1.12.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/dist/cjs/error_utils.js +9 -17
- package/dist/cjs/global_config.js +3 -3
- package/dist/cjs/models/base.js +10 -10
- package/dist/cjs/models/cursor.js +4 -6
- package/dist/cjs/models/field.js +3 -3
- package/dist/cjs/models/record_query_result.js +1 -1
- package/dist/cjs/models/record_store.js +74 -18
- package/dist/cjs/models/session.js +3 -3
- package/dist/cjs/models/table.js +25 -25
- package/dist/cjs/sdk.js +1 -1
- package/dist/cjs/settings_button.js +1 -1
- package/dist/cjs/ui/expand_record_picker_async.js +1 -1
- package/dist/cjs/ui/icon_config.js +4 -2
- package/dist/cjs/ui/initialize_block.js +3 -3
- package/dist/cjs/ui/use_global_config.js +1 -1
- package/dist/cjs/ui/use_loadable.js +3 -3
- package/dist/cjs/ui/use_record_action_data.js +11 -11
- package/dist/cjs/ui/use_settings_button.js +1 -1
- package/dist/cjs/ui/viewport_constraint.js +1 -1
- package/dist/cjs/viewport.js +9 -9
- package/dist/types/src/error_utils.d.ts +4 -2
- package/dist/types/src/error_utils.d.ts.map +1 -1
- package/dist/types/src/global_config.d.ts +3 -3
- package/dist/types/src/models/base.d.ts +9 -9
- package/dist/types/src/models/cursor.d.ts +4 -6
- package/dist/types/src/models/cursor.d.ts.map +1 -1
- package/dist/types/src/models/field.d.ts +3 -3
- package/dist/types/src/models/record_query_result.d.ts +2 -2
- package/dist/types/src/models/session.d.ts +3 -3
- package/dist/types/src/models/table.d.ts +25 -25
- package/dist/types/src/settings_button.d.ts +1 -1
- package/dist/types/src/ui/expand_record_picker_async.d.ts +1 -1
- package/dist/types/src/ui/icon_config.d.ts +5 -3
- package/dist/types/src/ui/icon_config.d.ts.map +1 -1
- package/dist/types/src/ui/initialize_block.d.ts +1 -1
- package/dist/types/src/ui/use_global_config.d.ts +1 -1
- package/dist/types/src/ui/use_loadable.d.ts +2 -2
- package/dist/types/src/ui/use_record_action_data.d.ts +11 -11
- package/dist/types/src/ui/use_settings_button.d.ts +1 -1
- package/dist/types/src/ui/viewport_constraint.d.ts +3 -3
- package/dist/types/src/ui/viewport_constraint.d.ts.map +1 -1
- package/dist/types/src/viewport.d.ts +9 -9
- package/package.json +1 -1
|
@@ -148,8 +148,8 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
148
148
|
* The field matching the given ID or name. Returns `null` if no matching field exists within
|
|
149
149
|
* this table.
|
|
150
150
|
*
|
|
151
|
-
* This method is convenient when building an
|
|
152
|
-
*
|
|
151
|
+
* This method is convenient when building an extension for a specific base, but for more generic
|
|
152
|
+
* extensions the best practice is to use the {@link getFieldByIdIfExists} or
|
|
153
153
|
* {@link getFieldByNameIfExists} methods instead.
|
|
154
154
|
*
|
|
155
155
|
* @param fieldIdOrName The ID or name of the field you're looking for.
|
|
@@ -160,8 +160,8 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
160
160
|
* Use {@link getFieldIfExists} instead if you are unsure whether a field exists with the given
|
|
161
161
|
* name/ID.
|
|
162
162
|
*
|
|
163
|
-
* This method is convenient when building an
|
|
164
|
-
*
|
|
163
|
+
* This method is convenient when building an extension for a specific base, but for more generic
|
|
164
|
+
* extensions the best practice is to use the {@link getFieldById} or {@link getFieldByName} methods
|
|
165
165
|
* instead.
|
|
166
166
|
*
|
|
167
167
|
* @param fieldIdOrName The ID or name of the field you're looking for.
|
|
@@ -242,8 +242,8 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
242
242
|
* The view matching the given ID or name. Returns `null` if no matching view exists within
|
|
243
243
|
* this table.
|
|
244
244
|
*
|
|
245
|
-
* This method is convenient when building an
|
|
246
|
-
*
|
|
245
|
+
* This method is convenient when building an extension for a specific base, but for more generic
|
|
246
|
+
* extensions the best practice is to use the {@link getViewByIdIfExists} or
|
|
247
247
|
* {@link getViewByNameIfExists} methods instead.
|
|
248
248
|
*
|
|
249
249
|
* @param viewIdOrName The ID or name of the view you're looking for.
|
|
@@ -254,8 +254,8 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
254
254
|
* Use {@link getViewIfExists} instead if you are unsure whether a view exists with the given
|
|
255
255
|
* name/ID.
|
|
256
256
|
*
|
|
257
|
-
* This method is convenient when building an
|
|
258
|
-
*
|
|
257
|
+
* This method is convenient when building an extension for a specific base, but for more generic
|
|
258
|
+
* extensions the best practice is to use the {@link getViewById} or {@link getViewByName} methods
|
|
259
259
|
* instead.
|
|
260
260
|
*
|
|
261
261
|
* @param viewIdOrName The ID or name of the view you're looking for.
|
|
@@ -346,7 +346,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
346
346
|
*
|
|
347
347
|
* This action is asynchronous: `await` the returned promise if you wish to wait for the updated
|
|
348
348
|
* cell values to be persisted to Airtable servers.
|
|
349
|
-
* Updates are applied optimistically locally, so your changes will be reflected in your
|
|
349
|
+
* Updates are applied optimistically locally, so your changes will be reflected in your extension
|
|
350
350
|
* before the promise resolves.
|
|
351
351
|
*
|
|
352
352
|
* @param recordOrRecordId the record to update
|
|
@@ -357,7 +357,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
357
357
|
* if (table.hasPermissionToUpdateRecord(record, recordFields)) {
|
|
358
358
|
* table.updateRecordAsync(record, recordFields);
|
|
359
359
|
* }
|
|
360
|
-
* // The updated values will now show in your
|
|
360
|
+
* // The updated values will now show in your extension (eg in
|
|
361
361
|
* // `table.selectRecords()` result) but are still being saved to Airtable
|
|
362
362
|
* // servers (e.g. other users may not be able to see them yet).
|
|
363
363
|
* }
|
|
@@ -430,7 +430,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
430
430
|
*
|
|
431
431
|
* // Check if user could update specific fields, when you don't know the
|
|
432
432
|
* // specific record that will be updated yet. (for example, if the field is
|
|
433
|
-
* // selected by the user and you want to check if your
|
|
433
|
+
* // selected by the user and you want to check if your extension can write to it).
|
|
434
434
|
* const updateUnknownRecordCheckResult =
|
|
435
435
|
* table.checkPermissionsForUpdateRecord(undefined, {
|
|
436
436
|
* 'My field name': 'updated value',
|
|
@@ -441,7 +441,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
441
441
|
*
|
|
442
442
|
* // Check if user could perform updates within the table, without knowing the
|
|
443
443
|
* // specific record or fields that will be updated yet (e.g., to render your
|
|
444
|
-
* //
|
|
444
|
+
* // extension in "read only" mode).
|
|
445
445
|
* const updateUnknownRecordAndFieldsCheckResult =
|
|
446
446
|
* table.checkPermissionsForUpdateRecord();
|
|
447
447
|
* ```
|
|
@@ -482,7 +482,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
482
482
|
*
|
|
483
483
|
* // Check if user could update specific fields, when you don't know the
|
|
484
484
|
* // specific record that will be updated yet (e.g. if the field is selected
|
|
485
|
-
* // by the user and you want to check if your
|
|
485
|
+
* // by the user and you want to check if your extension can write to it).
|
|
486
486
|
* const canUpdateUnknownRecord =
|
|
487
487
|
* table.hasPermissionToUpdateRecord(undefined, {
|
|
488
488
|
* 'My field name': 'updated value',
|
|
@@ -493,7 +493,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
493
493
|
*
|
|
494
494
|
* // Check if user could perform updates within the table, without knowing the
|
|
495
495
|
* // specific record or fields that will be updated yet. (for example, to
|
|
496
|
-
* // render your
|
|
496
|
+
* // render your extension in "read only" mode)
|
|
497
497
|
* const canUpdateUnknownRecordAndFields = table.hasPermissionToUpdateRecord();
|
|
498
498
|
* ```
|
|
499
499
|
*/
|
|
@@ -512,7 +512,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
512
512
|
*
|
|
513
513
|
* This action is asynchronous: `await` the returned promise if you wish to wait for the
|
|
514
514
|
* updates to be persisted to Airtable servers.
|
|
515
|
-
* Updates are applied optimistically locally, so your changes will be reflected in your
|
|
515
|
+
* Updates are applied optimistically locally, so your changes will be reflected in your extension
|
|
516
516
|
* before the promise resolves.
|
|
517
517
|
*
|
|
518
518
|
* @param records Array of objects containing recordId and fields/cellValues to update for that record (specified as an object mapping `FieldId` or field name to cell value)
|
|
@@ -559,7 +559,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
559
559
|
* if (table.hasPermissionToUpdateRecords(recordsToUpdate)) {
|
|
560
560
|
* table.updateRecordsAsync(recordsToUpdate);
|
|
561
561
|
* }
|
|
562
|
-
* // The records are now updated within your
|
|
562
|
+
* // The records are now updated within your extension (eg will be reflected in
|
|
563
563
|
* // `table.selectRecords()`) but are still being saved to Airtable servers
|
|
564
564
|
* // (e.g. they may not be updated for other users yet).
|
|
565
565
|
* }
|
|
@@ -707,7 +707,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
707
707
|
*
|
|
708
708
|
* This action is asynchronous: `await` the returned promise if you wish to wait for the
|
|
709
709
|
* delete to be persisted to Airtable servers.
|
|
710
|
-
* Updates are applied optimistically locally, so your changes will be reflected in your
|
|
710
|
+
* Updates are applied optimistically locally, so your changes will be reflected in your extension
|
|
711
711
|
* before the promise resolves.
|
|
712
712
|
*
|
|
713
713
|
* @param recordOrRecordId the record to be deleted
|
|
@@ -717,7 +717,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
717
717
|
* if (table.hasPermissionToDeleteRecord(record)) {
|
|
718
718
|
* table.deleteRecordAsync(record);
|
|
719
719
|
* }
|
|
720
|
-
* // The record is now deleted within your
|
|
720
|
+
* // The record is now deleted within your extension (eg will not be returned
|
|
721
721
|
* // in `table.selectRecords`) but it is still being saved to Airtable
|
|
722
722
|
* // servers (e.g. it may not look deleted to other users yet).
|
|
723
723
|
* }
|
|
@@ -795,7 +795,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
795
795
|
*
|
|
796
796
|
* This action is asynchronous: `await` the returned promise if you wish to wait for the
|
|
797
797
|
* delete to be persisted to Airtable servers.
|
|
798
|
-
* Updates are applied optimistically locally, so your changes will be reflected in your
|
|
798
|
+
* Updates are applied optimistically locally, so your changes will be reflected in your extension
|
|
799
799
|
* before the promise resolves.
|
|
800
800
|
*
|
|
801
801
|
* @param recordsOrRecordIds Array of Records and RecordIds
|
|
@@ -806,7 +806,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
806
806
|
* if (table.hasPermissionToDeleteRecords(records)) {
|
|
807
807
|
* table.deleteRecordsAsync(records);
|
|
808
808
|
* }
|
|
809
|
-
* // The records are now deleted within your
|
|
809
|
+
* // The records are now deleted within your extension (eg will not be
|
|
810
810
|
* // returned in `table.selectRecords()`) but are still being saved to
|
|
811
811
|
* // Airtable servers (e.g. they may not look deleted to other users yet).
|
|
812
812
|
* }
|
|
@@ -886,7 +886,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
886
886
|
*
|
|
887
887
|
* This action is asynchronous: `await` the returned promise if you wish to wait for the new
|
|
888
888
|
* record to be persisted to Airtable servers.
|
|
889
|
-
* Updates are applied optimistically locally, so your changes will be reflected in your
|
|
889
|
+
* Updates are applied optimistically locally, so your changes will be reflected in your extension
|
|
890
890
|
* before the promise resolves.
|
|
891
891
|
*
|
|
892
892
|
* The returned promise will resolve to the RecordId of the new record once it is persisted.
|
|
@@ -898,7 +898,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
898
898
|
* if (table.hasPermissionToCreateRecord(recordFields)) {
|
|
899
899
|
* table.createRecordAsync(recordFields);
|
|
900
900
|
* }
|
|
901
|
-
* // You can now access the new record in your
|
|
901
|
+
* // You can now access the new record in your extension (eg
|
|
902
902
|
* // `table.selectRecords()`) but it is still being saved to Airtable
|
|
903
903
|
* // servers (e.g. other users may not be able to see it yet).
|
|
904
904
|
* }
|
|
@@ -1018,7 +1018,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
1018
1018
|
*
|
|
1019
1019
|
* This action is asynchronous: `await` the returned promise if you wish to wait for the new
|
|
1020
1020
|
* record to be persisted to Airtable servers.
|
|
1021
|
-
* Updates are applied optimistically locally, so your changes will be reflected in your
|
|
1021
|
+
* Updates are applied optimistically locally, so your changes will be reflected in your extension
|
|
1022
1022
|
* before the promise resolves.
|
|
1023
1023
|
*
|
|
1024
1024
|
* The returned promise will resolve to an array of RecordIds of the new records once the new
|
|
@@ -1062,7 +1062,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
1062
1062
|
* if (table.hasPermissionToCreateRecords(recordDefs)) {
|
|
1063
1063
|
* table.createRecordsAsync(recordDefs);
|
|
1064
1064
|
* }
|
|
1065
|
-
* // You can now access the new records in your
|
|
1065
|
+
* // You can now access the new records in your extension (e.g.
|
|
1066
1066
|
* // `table.selectRecords()`) but they are still being saved to Airtable
|
|
1067
1067
|
* // servers (e.g. other users may not be able to see them yet.)
|
|
1068
1068
|
* }
|
|
@@ -1228,7 +1228,7 @@ declare class Table extends AbstractModel<TableData, WatchableTableKey> {
|
|
|
1228
1228
|
*
|
|
1229
1229
|
* This action is asynchronous. Unlike new records, new fields are **not** created
|
|
1230
1230
|
* optimistically locally. You must `await` the returned promise before using the new
|
|
1231
|
-
* field in your
|
|
1231
|
+
* field in your extension.
|
|
1232
1232
|
*
|
|
1233
1233
|
* @param name name for the field. must be case-insensitive unique
|
|
1234
1234
|
* @param type type for the field
|
|
@@ -12,7 +12,7 @@ declare const WatchableSettingsButtonKeys: Readonly<{
|
|
|
12
12
|
*/
|
|
13
13
|
declare type WatchableSettingsButtonKey = ObjectValues<typeof WatchableSettingsButtonKeys>;
|
|
14
14
|
/**
|
|
15
|
-
* Interface to the settings button that lives outside the
|
|
15
|
+
* Interface to the settings button that lives outside the extension's viewport.
|
|
16
16
|
*
|
|
17
17
|
* The {@link useSettingsButton} hook is the recommended way to use the settings button, but you can
|
|
18
18
|
* also use it with {@link useWatchable} if you want more granular control (for example, to only
|
|
@@ -11,7 +11,7 @@ interface ExpandRecordPickerOpts {
|
|
|
11
11
|
}
|
|
12
12
|
/**
|
|
13
13
|
* Expands a list of records in the Airtable UI, and prompts the user to pick
|
|
14
|
-
* one. The selected record is returned to the
|
|
14
|
+
* one. The selected record is returned to the extension, and the modal is
|
|
15
15
|
* automatically closed.
|
|
16
16
|
*
|
|
17
17
|
* If the user dismisses the modal, or another one is opened before this one
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { EnumType, ObjectMap } from '../private_utils';
|
|
2
|
-
export declare const iconNamesArray: readonly ["android", "apple", "apps", "ascending", "attachment", "automations", "autonumber", "barcode", "bell", "blocks", "bold", "bolt", "boltList", "book", "calendar", "calendarDay", "caret", "chart", "chat", "check", "checkbox", "checkboxChecked", "checkboxUnchecked", "checklist", "chevronDown", "chevronLeft", "chevronRight", "chevronUp", "clipboard", "code", "cog", "collapse", "collapseSidebar", "contacts", "count", "count1", "cube", "cursor", "day", "dayAuto", "dedent", "descending", "dollar", "down", "download", "dragHandle", "drive", "duplicate", "edit", "envelope", "envelope1", "expand", "expand1", "expandSidebar", "feed", "file", "filter", "flag", "form", "formula", "fullscreen", "gallery", "gantt", "gift", "grid", "grid1", "group", "heart", "help", "hide", "hide1", "history", "home", "hyperlink", "hyperlinkCancel", "indent", "info", "italic", "kanban", "laptop", "left", "lightbulb", "link", "link1", "lock", "logout", "lookup", "mapPin", "markdown", "megaphone", "menu", "minus", "mobile", "multicollaborator", "multiselect", "number", "ol", "overflow", "paint", "paragraph", "paragraph1", "pause", "percent", "personal", "personalAuto", "phone", "pivot", "play", "plus", "plusFilled", "premium", "print", "public", "publish", "quote", "quote1", "radio", "radioSelected", "redo", "redo1", "richText", "right", "rollup", "rollup1", "rowHeightSmall", "rowHeightMedium", "rowHeightLarge", "rowHeightExtraLarge", "search", "select", "selectCaret", "settings", "shapes", "share", "share1", "shareWithBolt", "show", "show1", "slack", "smiley", "sort", "stack", "star", "strikethrough", "switcher", "tabs", "team", "teamLocked", "text", "thumbsUp", "time", "timeline", "toggle", "trash", "twitter", "ul", "underline", "undo", "up", "upload", "video", "view", "warning", "windows", "x"];
|
|
2
|
+
export declare const iconNamesArray: readonly ["android", "apple", "apps", "ascending", "attachment", "automations", "autonumber", "barcode", "bell", "blocks", "bold", "bolt", "boltList", "book", "calendar", "calendarDay", "caret", "chart", "chat", "check", "checkbox", "checkboxChecked", "checkboxUnchecked", "checklist", "chevronDown", "chevronLeft", "chevronRight", "chevronUp", "clipboard", "code", "cog", "collapse", "collapseSidebar", "contacts", "count", "count1", "cube", "cursor", "day", "dayAuto", "dedent", "descending", "dollar", "down", "download", "dragHandle", "drive", "duplicate", "edit", "envelope", "envelope1", "expand", "expand1", "expandSidebar", "feed", "file", "filter", "flag", "form", "formula", "fullscreen", "gallery", "gantt", "gift", "grid", "grid1", "group", "heart", "help", "hide", "hide1", "history", "home", "hyperlink", "hyperlinkCancel", "indent", "info", "italic", "kanban", "laptop", "left", "lightbulb", "link", "link1", "lock", "logout", "lookup", "mapPin", "markdown", "megaphone", "menu", "minus", "mobile", "multicollaborator", "multiselect", "number", "ol", "overflow", "overlay", "paint", "paragraph", "paragraph1", "pause", "percent", "personal", "personalAuto", "phone", "pivot", "play", "plus", "plusFilled", "premium", "print", "public", "publish", "quote", "quote1", "radio", "radioSelected", "redo", "redo1", "richText", "right", "rollup", "rollup1", "rowHeightSmall", "rowHeightMedium", "rowHeightLarge", "rowHeightExtraLarge", "search", "select", "selectCaret", "settings", "shapes", "share", "share1", "shareWithBolt", "show", "show1", "slack", "smiley", "sort", "stack", "star", "strikethrough", "switcher", "tabs", "team", "teamLocked", "text", "thumbsUp", "time", "timeline", "toggle", "trash", "twitter", "ul", "underline", "undo", "up", "upload", "video", "view", "warning", "windows", "x"];
|
|
3
3
|
export declare const iconNames: {
|
|
4
4
|
number: "number";
|
|
5
5
|
search: "search";
|
|
@@ -32,6 +32,7 @@ export declare const iconNames: {
|
|
|
32
32
|
group: "group";
|
|
33
33
|
checkbox: "checkbox";
|
|
34
34
|
radio: "radio";
|
|
35
|
+
overlay: "overlay";
|
|
35
36
|
collapse: "collapse";
|
|
36
37
|
paint: "paint";
|
|
37
38
|
help: "help";
|
|
@@ -174,7 +175,7 @@ export declare const deprecatedIconNameToReplacementName: Map<string, string>;
|
|
|
174
175
|
* [[ Story id="icon--example" title="Icon example" height="576px"]]
|
|
175
176
|
*/
|
|
176
177
|
export declare type IconName = EnumType<typeof iconNames>;
|
|
177
|
-
export declare const iconNamePropType: import("prop-types").Requireable<"number" | "search" | "bold" | "link" | "left" | "right" | "clipboard" | "show" | "hide" | "public" | "code" | "form" | "menu" | "ol" | "select" | "time" | "ul" | "video" | "filter" | "text" | "view" | "pause" | "play" | "toggle" | "up" | "down" | "day" | "lookup" | "group" | "checkbox" | "radio" | "collapse" | "paint" | "help" | "grid" | "italic" | "x" | "underline" | "caret" | "cursor" | "overflow" | "ascending" | "descending" | "edit" | "check" | "star" | "heart" | "thumbsUp" | "flag" | "lock" | "download" | "android" | "apple" | "apps" | "attachment" | "automations" | "autonumber" | "barcode" | "bell" | "blocks" | "bolt" | "boltList" | "book" | "calendar" | "calendarDay" | "chart" | "chat" | "checkboxChecked" | "checkboxUnchecked" | "checklist" | "chevronDown" | "chevronLeft" | "chevronRight" | "chevronUp" | "cog" | "collapseSidebar" | "contacts" | "count" | "count1" | "cube" | "dayAuto" | "dedent" | "dollar" | "dragHandle" | "drive" | "duplicate" | "envelope" | "envelope1" | "expand" | "expand1" | "expandSidebar" | "feed" | "file" | "formula" | "fullscreen" | "gallery" | "gantt" | "gift" | "grid1" | "hide1" | "history" | "home" | "hyperlink" | "hyperlinkCancel" | "indent" | "info" | "kanban" | "laptop" | "lightbulb" | "link1" | "logout" | "mapPin" | "markdown" | "megaphone" | "minus" | "mobile" | "multicollaborator" | "multiselect" | "paragraph" | "paragraph1" | "percent" | "personal" | "personalAuto" | "phone" | "pivot" | "plus" | "plusFilled" | "premium" | "print" | "publish" | "quote" | "quote1" | "radioSelected" | "redo" | "redo1" | "richText" | "rollup" | "rollup1" | "rowHeightSmall" | "rowHeightMedium" | "rowHeightLarge" | "rowHeightExtraLarge" | "selectCaret" | "settings" | "shapes" | "share" | "share1" | "shareWithBolt" | "show1" | "slack" | "smiley" | "sort" | "stack" | "strikethrough" | "switcher" | "tabs" | "team" | "teamLocked" | "timeline" | "trash" | "twitter" | "undo" | "upload" | "warning" | "windows">;
|
|
178
|
+
export declare const iconNamePropType: import("prop-types").Requireable<"number" | "search" | "bold" | "link" | "left" | "right" | "clipboard" | "show" | "hide" | "public" | "code" | "form" | "menu" | "ol" | "select" | "time" | "ul" | "video" | "filter" | "text" | "view" | "pause" | "play" | "toggle" | "up" | "down" | "day" | "lookup" | "group" | "checkbox" | "radio" | "overlay" | "collapse" | "paint" | "help" | "grid" | "italic" | "x" | "underline" | "caret" | "cursor" | "overflow" | "ascending" | "descending" | "edit" | "check" | "star" | "heart" | "thumbsUp" | "flag" | "lock" | "download" | "android" | "apple" | "apps" | "attachment" | "automations" | "autonumber" | "barcode" | "bell" | "blocks" | "bolt" | "boltList" | "book" | "calendar" | "calendarDay" | "chart" | "chat" | "checkboxChecked" | "checkboxUnchecked" | "checklist" | "chevronDown" | "chevronLeft" | "chevronRight" | "chevronUp" | "cog" | "collapseSidebar" | "contacts" | "count" | "count1" | "cube" | "dayAuto" | "dedent" | "dollar" | "dragHandle" | "drive" | "duplicate" | "envelope" | "envelope1" | "expand" | "expand1" | "expandSidebar" | "feed" | "file" | "formula" | "fullscreen" | "gallery" | "gantt" | "gift" | "grid1" | "hide1" | "history" | "home" | "hyperlink" | "hyperlinkCancel" | "indent" | "info" | "kanban" | "laptop" | "lightbulb" | "link1" | "logout" | "mapPin" | "markdown" | "megaphone" | "minus" | "mobile" | "multicollaborator" | "multiselect" | "paragraph" | "paragraph1" | "percent" | "personal" | "personalAuto" | "phone" | "pivot" | "plus" | "plusFilled" | "premium" | "print" | "publish" | "quote" | "quote1" | "radioSelected" | "redo" | "redo1" | "richText" | "rollup" | "rollup1" | "rowHeightSmall" | "rowHeightMedium" | "rowHeightLarge" | "rowHeightExtraLarge" | "selectCaret" | "settings" | "shapes" | "share" | "share1" | "shareWithBolt" | "show1" | "slack" | "smiley" | "sort" | "stack" | "strikethrough" | "switcher" | "tabs" | "team" | "teamLocked" | "timeline" | "trash" | "twitter" | "undo" | "upload" | "warning" | "windows">;
|
|
178
179
|
export declare const microIconNames: {
|
|
179
180
|
androidMicro: "androidMicro";
|
|
180
181
|
appleMicro: "appleMicro";
|
|
@@ -274,6 +275,7 @@ export declare const microIconNames: {
|
|
|
274
275
|
numberMicro: "numberMicro";
|
|
275
276
|
olMicro: "olMicro";
|
|
276
277
|
overflowMicro: "overflowMicro";
|
|
278
|
+
overlayMicro: "overlayMicro";
|
|
277
279
|
paintMicro: "paintMicro";
|
|
278
280
|
paragraphMicro: "paragraphMicro";
|
|
279
281
|
paragraph1Micro: "paragraph1Micro";
|
|
@@ -343,7 +345,7 @@ export declare const microIconNames: {
|
|
|
343
345
|
};
|
|
344
346
|
/** @hidden */
|
|
345
347
|
export declare type MicroIconName = EnumType<typeof microIconNames>;
|
|
346
|
-
export declare const microIconNamePropType: import("prop-types").Requireable<"androidMicro" | "appleMicro" | "appsMicro" | "ascendingMicro" | "attachmentMicro" | "automationsMicro" | "autonumberMicro" | "barcodeMicro" | "bellMicro" | "blocksMicro" | "boldMicro" | "boltMicro" | "boltListMicro" | "bookMicro" | "calendarMicro" | "calendarDayMicro" | "caretMicro" | "chartMicro" | "chatMicro" | "checkMicro" | "checkboxCheckedMicro" | "checkboxMicro" | "checkboxUncheckedMicro" | "checklistMicro" | "chevronDownMicro" | "chevronLeftMicro" | "chevronRightMicro" | "chevronUpMicro" | "clipboardMicro" | "codeMicro" | "cogMicro" | "collapseMicro" | "collapseSidebarMicro" | "contactsMicro" | "countMicro" | "count1Micro" | "cubeMicro" | "cursorMicro" | "dayMicro" | "dayAutoMicro" | "dedentMicro" | "descendingMicro" | "dollarMicro" | "downMicro" | "downloadMicro" | "dragHandleMicro" | "driveMicro" | "duplicateMicro" | "editMicro" | "envelopeMicro" | "envelope1Micro" | "expandMicro" | "expand1Micro" | "expandSidebarMicro" | "feedMicro" | "fileMicro" | "filterMicro" | "flagMicro" | "formMicro" | "formulaMicro" | "fullscreenMicro" | "galleryMicro" | "ganttMicro" | "giftMicro" | "gridMicro" | "grid1Micro" | "groupMicro" | "heartMicro" | "helpMicro" | "hideMicro" | "hide1Micro" | "historyMicro" | "homeMicro" | "hyperlinkMicro" | "hyperlinkCancelMicro" | "indentMicro" | "infoMicro" | "italicMicro" | "kanbanMicro" | "laptopMicro" | "leftMicro" | "lightbulbMicro" | "link1Micro" | "linkMicro" | "lockMicro" | "logoutMicro" | "lookupMicro" | "mapPinMicro" | "markdownMicro" | "megaphoneMicro" | "menuMicro" | "minusMicro" | "mobileMicro" | "multicollaboratorMicro" | "multiselectMicro" | "numberMicro" | "olMicro" | "overflowMicro" | "paintMicro" | "paragraphMicro" | "paragraph1Micro" | "pauseMicro" | "percentMicro" | "personalMicro" | "personalAutoMicro" | "phoneMicro" | "pivotMicro" | "playMicro" | "plusFilledMicro" | "plusMicro" | "premiumMicro" | "printMicro" | "publicMicro" | "publishMicro" | "quoteMicro" | "quote1Micro" | "radioMicro" | "radioSelectedMicro" | "redoMicro" | "redo1Micro" | "richTextMicro" | "rightMicro" | "rollupMicro" | "rollup1Micro" | "rowHeightSmallMicro" | "rowHeightMediumMicro" | "rowHeightLargeMicro" | "rowHeightExtraLargeMicro" | "searchMicro" | "selectMicro" | "selectCaretMicro" | "settingsMicro" | "shapesMicro" | "share1Micro" | "shareMicro" | "showMicro" | "show1Micro" | "slackMicro" | "smileyMicro" | "sortMicro" | "stackMicro" | "starMicro" | "strikethroughMicro" | "switcherMicro" | "tabsMicro" | "teamMicro" | "teamLockedMicro" | "textMicro" | "thumbsUpMicro" | "timeMicro" | "timelineMicro" | "toggleMicro" | "trashMicro" | "twitterMicro" | "ulMicro" | "underlineMicro" | "undoMicro" | "upMicro" | "uploadMicro" | "videoMicro" | "viewMicro" | "warningMicro" | "windowsMicro" | "xMicro">;
|
|
348
|
+
export declare const microIconNamePropType: import("prop-types").Requireable<"androidMicro" | "appleMicro" | "appsMicro" | "ascendingMicro" | "attachmentMicro" | "automationsMicro" | "autonumberMicro" | "barcodeMicro" | "bellMicro" | "blocksMicro" | "boldMicro" | "boltMicro" | "boltListMicro" | "bookMicro" | "calendarMicro" | "calendarDayMicro" | "caretMicro" | "chartMicro" | "chatMicro" | "checkMicro" | "checkboxCheckedMicro" | "checkboxMicro" | "checkboxUncheckedMicro" | "checklistMicro" | "chevronDownMicro" | "chevronLeftMicro" | "chevronRightMicro" | "chevronUpMicro" | "clipboardMicro" | "codeMicro" | "cogMicro" | "collapseMicro" | "collapseSidebarMicro" | "contactsMicro" | "countMicro" | "count1Micro" | "cubeMicro" | "cursorMicro" | "dayMicro" | "dayAutoMicro" | "dedentMicro" | "descendingMicro" | "dollarMicro" | "downMicro" | "downloadMicro" | "dragHandleMicro" | "driveMicro" | "duplicateMicro" | "editMicro" | "envelopeMicro" | "envelope1Micro" | "expandMicro" | "expand1Micro" | "expandSidebarMicro" | "feedMicro" | "fileMicro" | "filterMicro" | "flagMicro" | "formMicro" | "formulaMicro" | "fullscreenMicro" | "galleryMicro" | "ganttMicro" | "giftMicro" | "gridMicro" | "grid1Micro" | "groupMicro" | "heartMicro" | "helpMicro" | "hideMicro" | "hide1Micro" | "historyMicro" | "homeMicro" | "hyperlinkMicro" | "hyperlinkCancelMicro" | "indentMicro" | "infoMicro" | "italicMicro" | "kanbanMicro" | "laptopMicro" | "leftMicro" | "lightbulbMicro" | "link1Micro" | "linkMicro" | "lockMicro" | "logoutMicro" | "lookupMicro" | "mapPinMicro" | "markdownMicro" | "megaphoneMicro" | "menuMicro" | "minusMicro" | "mobileMicro" | "multicollaboratorMicro" | "multiselectMicro" | "numberMicro" | "olMicro" | "overflowMicro" | "overlayMicro" | "paintMicro" | "paragraphMicro" | "paragraph1Micro" | "pauseMicro" | "percentMicro" | "personalMicro" | "personalAutoMicro" | "phoneMicro" | "pivotMicro" | "playMicro" | "plusFilledMicro" | "plusMicro" | "premiumMicro" | "printMicro" | "publicMicro" | "publishMicro" | "quoteMicro" | "quote1Micro" | "radioMicro" | "radioSelectedMicro" | "redoMicro" | "redo1Micro" | "richTextMicro" | "rightMicro" | "rollupMicro" | "rollup1Micro" | "rowHeightSmallMicro" | "rowHeightMediumMicro" | "rowHeightLargeMicro" | "rowHeightExtraLargeMicro" | "searchMicro" | "selectMicro" | "selectCaretMicro" | "settingsMicro" | "shapesMicro" | "share1Micro" | "shareMicro" | "showMicro" | "show1Micro" | "slackMicro" | "smileyMicro" | "sortMicro" | "stackMicro" | "starMicro" | "strikethroughMicro" | "switcherMicro" | "tabsMicro" | "teamMicro" | "teamLockedMicro" | "textMicro" | "thumbsUpMicro" | "timeMicro" | "timelineMicro" | "toggleMicro" | "trashMicro" | "twitterMicro" | "ulMicro" | "underlineMicro" | "undoMicro" | "upMicro" | "uploadMicro" | "videoMicro" | "viewMicro" | "warningMicro" | "windowsMicro" | "xMicro">;
|
|
347
349
|
/** @hidden */
|
|
348
350
|
export declare type AllIconName = IconName & MicroIconName;
|
|
349
351
|
export declare const allIconPaths: ObjectMap<AllIconName, string>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icon_config.d.ts","sourceRoot":"","sources":["../../../../src/ui/icon_config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,QAAQ,EAA0B,SAAS,EAAC,MAAM,kBAAkB,CAAC;AAMzF,eAAO,MAAM,cAAc,
|
|
1
|
+
{"version":3,"file":"icon_config.d.ts","sourceRoot":"","sources":["../../../../src/ui/icon_config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,QAAQ,EAA0B,SAAS,EAAC,MAAM,kBAAkB,CAAC;AAMzF,eAAO,MAAM,cAAc,uxDAuKjB,CAAC;AACX,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAgC,CAAC;AACvD,eAAO,MAAM,mCAAmC,qBAAgC,CAAC;AACjF;;;;GAIG;AACH,oBAAY,QAAQ,GAAG,QAAQ,CAAC,OAAO,SAAS,CAAC,CAAC;AAClD,eAAO,MAAM,gBAAgB,m9DAAoC,CAAC;AAyKlE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAqC,CAAC;AACjE,cAAc;AACd,oBAAY,aAAa,GAAG,QAAQ,CAAC,OAAO,cAAc,CAAC,CAAC;AAC5D,eAAO,MAAM,qBAAqB,0vFAAyC,CAAC;AA8pB5E,cAAc;AACd,oBAAY,WAAW,GAAG,QAAQ,GAAG,aAAa,CAAC;AACnD,eAAO,MAAM,YAAY,EAAE,SAAS,CAAC,WAAW,EAAE,MAAM,CAG7C,CAAC"}
|
|
@@ -18,7 +18,7 @@ interface EntryPoints {
|
|
|
18
18
|
/** @hidden */
|
|
19
19
|
declare type DashboardOrEntryPoints = DashboardEntryElementFunction | EntryPoints;
|
|
20
20
|
/**
|
|
21
|
-
* `initializeBlock` takes the top-level React component in your tree and renders it. It is conceptually similar to `ReactDOM.render`, but takes care of some
|
|
21
|
+
* `initializeBlock` takes the top-level React component in your tree and renders it. It is conceptually similar to `ReactDOM.render`, but takes care of some Extensions-specific things.
|
|
22
22
|
*
|
|
23
23
|
* @param getEntryElement A function that returns your React Node.
|
|
24
24
|
*
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/** @module @airtable/blocks/ui: useGlobalConfig */ /** */
|
|
2
2
|
import GlobalConfig from '../global_config';
|
|
3
3
|
/**
|
|
4
|
-
* Returns the
|
|
4
|
+
* Returns the extension's {@link GlobalConfig} and updates whenever any key in {@link GlobalConfig}
|
|
5
5
|
* changes.
|
|
6
6
|
*
|
|
7
7
|
* @example
|
|
@@ -22,7 +22,7 @@ interface UseLoadableOpts {
|
|
|
22
22
|
shouldSuspend?: boolean;
|
|
23
23
|
}
|
|
24
24
|
/**
|
|
25
|
-
* When you're writing an
|
|
25
|
+
* When you're writing an extension, not all of the data in your base is available to work with straight
|
|
26
26
|
* away. We need to load it from Airtable first. This hook is a low-level tool for managing that.
|
|
27
27
|
* You might not need to use it directly though - if you're working with a {@link RecordQueryResult}, try
|
|
28
28
|
* {@link useRecords}, {@link useRecordIds}, or {@link useRecordById} first.
|
|
@@ -31,7 +31,7 @@ interface UseLoadableOpts {
|
|
|
31
31
|
* loaded when your component mounts, and unloaded when your component unmounts. By default, you
|
|
32
32
|
* don't need to worry about waiting for the data to load - the hook uses React Suspense to make
|
|
33
33
|
* sure the rest of your component doesn't run until the data is loaded. Whilst the data is
|
|
34
|
-
* loading, the entire
|
|
34
|
+
* loading, the entire extension will show a loading indicator. If you want to change where that
|
|
35
35
|
* indicator shows or how it looks, use [`<React.Suspense />`](https://reactjs.org/docs/react-api.html#reactsuspense|)
|
|
36
36
|
* around the component that uses the hook.
|
|
37
37
|
*
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
/** @module @airtable/blocks/ui: useRecordActionData */ /** */
|
|
2
2
|
import { RecordActionData } from '../types/record_action_data';
|
|
3
3
|
/**
|
|
4
|
-
* A hook to watch "open
|
|
4
|
+
* A hook to watch "open extension" / "perform record action" events (from button field). Returns
|
|
5
5
|
* the data corresponding to the latest action, or `null` if no actions have occurred yet. If there
|
|
6
|
-
* was a pending event for the
|
|
7
|
-
* clicked while the
|
|
6
|
+
* was a pending event for the extension (for example, because a button that opens this extension was
|
|
7
|
+
* clicked while the extensions dashboard was closed) it will be returned as the initial value.
|
|
8
8
|
*
|
|
9
|
-
* Like {@link useLoadable}, this hook puts the
|
|
9
|
+
* Like {@link useLoadable}, this hook puts the extension in suspense while subscribing to events and
|
|
10
10
|
* fetching the initial data.
|
|
11
11
|
*
|
|
12
12
|
* Also see {@link registerRecordActionDataCallback}, which subscribes to the same events in an
|
|
13
13
|
* asynchronous (callback based) way. An advantage of using this hook over the callback is that you
|
|
14
|
-
* immediately can handle any pending events when your
|
|
14
|
+
* immediately can handle any pending events when your extension opens - with a callback, your extension
|
|
15
15
|
* will finish it's initial render before handling the event.
|
|
16
16
|
*
|
|
17
|
-
* Like {@link registerRecordActionDataCallback}, your
|
|
17
|
+
* Like {@link registerRecordActionDataCallback}, your extension won't receive events until this hook is
|
|
18
18
|
* used for the first time. Because of that, we recommend only using this hook once, in the top
|
|
19
|
-
* level component of your
|
|
19
|
+
* level component of your extension. Similarly, using both `registerRecordActionDataCallback` and
|
|
20
20
|
* `useRecordActionData` is not supported.
|
|
21
21
|
*
|
|
22
|
-
* You can test your
|
|
23
|
-
* in the "Advanced" panel of the
|
|
22
|
+
* You can test your extension in development by sending "perform record action" events to your extension
|
|
23
|
+
* in the "Advanced" panel of the extension developer tools.
|
|
24
24
|
*
|
|
25
|
-
* After releasing your
|
|
26
|
-
*
|
|
25
|
+
* After releasing your extension, you can use it with a button field by choosing the "Open custom
|
|
26
|
+
* extension" action and selecting your extension.
|
|
27
27
|
*
|
|
28
28
|
* @example
|
|
29
29
|
* ```js
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FlowAnyFunction } from '../private_utils';
|
|
2
2
|
/**
|
|
3
|
-
* A hook for using the settings button that lives outside the
|
|
3
|
+
* A hook for using the settings button that lives outside the extension's viewport. It will show
|
|
4
4
|
* the settings button (hidden by default) and call the provided callback whenever the settings
|
|
5
5
|
* button is clicked. It will also re-render your component when the settings button is clicked.
|
|
6
6
|
*
|
|
@@ -13,16 +13,16 @@ declare type ViewportSizeConstraintProp = Partial<ViewportSizeConstraint>;
|
|
|
13
13
|
* @docsPath UI/components/ViewportConstraint
|
|
14
14
|
*/
|
|
15
15
|
interface ViewportConstraintProps {
|
|
16
|
-
/** The minimum viewport size of the
|
|
16
|
+
/** The minimum viewport size of the extension. */
|
|
17
17
|
minSize?: ViewportSizeConstraintProp;
|
|
18
|
-
/** The maximum viewport size of the
|
|
18
|
+
/** The maximum viewport size of the extension when it is in fullscreen mode. */
|
|
19
19
|
maxFullscreenSize?: ViewportSizeConstraintProp;
|
|
20
20
|
/** The contents of the viewport constraint. */
|
|
21
21
|
children?: React.ReactNode;
|
|
22
22
|
}
|
|
23
23
|
/**
|
|
24
24
|
* When mounted, this wrapper component applies size constraints to the {@link Viewport}.
|
|
25
|
-
* Like {@link addMinSize}, this will fullscreen the
|
|
25
|
+
* Like {@link addMinSize}, this will fullscreen the extension if necessary and possible when
|
|
26
26
|
* `minSize` is updated.
|
|
27
27
|
*
|
|
28
28
|
* @example
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"viewport_constraint.d.ts","sourceRoot":"","sources":["../../../../src/ui/viewport_constraint.tsx"],"names":[],"mappings":"AAAA;;;GAGG,CAAC,MAAM;AACV,OAAO,SAAS,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAC,sBAAsB,EAAC,MAAM,mBAAmB,CAAC;AAKzD,2EAA2E;AAC3E,aAAK,0BAA0B,GAAG,OAAO,CAAC,sBAAsB,CAAC,CAAC;AAElE;;;;GAIG;AACH,UAAU,uBAAuB;IAC7B,
|
|
1
|
+
{"version":3,"file":"viewport_constraint.d.ts","sourceRoot":"","sources":["../../../../src/ui/viewport_constraint.tsx"],"names":[],"mappings":"AAAA;;;GAGG,CAAC,MAAM;AACV,OAAO,SAAS,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAC,sBAAsB,EAAC,MAAM,mBAAmB,CAAC;AAKzD,2EAA2E;AAC3E,aAAK,0BAA0B,GAAG,OAAO,CAAC,sBAAsB,CAAC,CAAC;AAElE;;;;GAIG;AACH,UAAU,uBAAuB;IAC7B,kDAAkD;IAClD,OAAO,CAAC,EAAE,0BAA0B,CAAC;IACrC,gFAAgF;IAChF,iBAAiB,CAAC,EAAE,0BAA0B,CAAC;IAC/C,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAG9B;AASD;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,cAAM,kBAAmB,SAAQ,KAAK,CAAC,SAAS,CAAC,uBAAuB,CAAC;IACrE,cAAc;IACd,MAAM,CAAC,SAAS;;;;;;;;;;MAUd;IAOF,cAAc;IACd,iBAAiB;IAKjB,cAAc;IACd,qBAAqB,CAAC,SAAS,EAAE,uBAAuB;IAQxD,cAAc;IACd,kBAAkB,CAAC,SAAS,EAAE,uBAAuB;IASrD,cAAc;IACd,oBAAoB;IAyCpB,cAAc;IACd,MAAM;CAGT;;AAED,wBAOE"}
|
|
@@ -34,7 +34,7 @@ declare class Viewport extends Watchable<WatchableViewportKey> {
|
|
|
34
34
|
/**
|
|
35
35
|
* Request to enter fullscreen mode.
|
|
36
36
|
*
|
|
37
|
-
* May fail if another
|
|
37
|
+
* May fail if another extension is fullscreen or this extension doesn't have
|
|
38
38
|
* permission to fullscreen itself. Watch `isFullscreen` to know if the
|
|
39
39
|
* request succeeded.
|
|
40
40
|
*/
|
|
@@ -42,7 +42,7 @@ declare class Viewport extends Watchable<WatchableViewportKey> {
|
|
|
42
42
|
/** Request to exit fullscreen mode */
|
|
43
43
|
exitFullscreen(): void;
|
|
44
44
|
/**
|
|
45
|
-
* The maximum dimensions of the
|
|
45
|
+
* The maximum dimensions of the extension when it is in
|
|
46
46
|
* fullscreen mode. Returns the smallest set of dimensions added with
|
|
47
47
|
* {@link addMaxFullscreenSize}.
|
|
48
48
|
*
|
|
@@ -63,8 +63,8 @@ declare class Viewport extends Watchable<WatchableViewportKey> {
|
|
|
63
63
|
*/
|
|
64
64
|
addMaxFullscreenSize(sizeConstraint: Partial<ViewportSizeConstraint>): UnsetFn;
|
|
65
65
|
/**
|
|
66
|
-
* The minimum dimensions of the
|
|
67
|
-
* size, an overlay will be shown asking the user to resize the
|
|
66
|
+
* The minimum dimensions of the extension - if the viewport gets smaller than this
|
|
67
|
+
* size, an overlay will be shown asking the user to resize the extension to be bigger.
|
|
68
68
|
*
|
|
69
69
|
* The largest set of dimensions added with addMinSize. If `width` or `height` is null, it means
|
|
70
70
|
* there is no minSize constraint on that dimension.
|
|
@@ -74,8 +74,8 @@ declare class Viewport extends Watchable<WatchableViewportKey> {
|
|
|
74
74
|
* Add a minimum frame size constraint. Use `.minSize`` to get the aggregate
|
|
75
75
|
* of all added constraints.
|
|
76
76
|
*
|
|
77
|
-
* Upon adding a constraint, if the
|
|
78
|
-
* minimum size, the
|
|
77
|
+
* Upon adding a constraint, if the extension is focused and the frame is smaller than the
|
|
78
|
+
* minimum size, the extension will enter fullscreen mode.
|
|
79
79
|
*
|
|
80
80
|
* Returns a function that can be called to remove the size constraint that was added.
|
|
81
81
|
*
|
|
@@ -85,15 +85,15 @@ declare class Viewport extends Watchable<WatchableViewportKey> {
|
|
|
85
85
|
*/
|
|
86
86
|
addMinSize(sizeConstraint: Partial<ViewportSizeConstraint>): UnsetFn;
|
|
87
87
|
/**
|
|
88
|
-
* `true` if the
|
|
88
|
+
* `true` if the extension frame is smaller than `minSize`, `false` otherwise.
|
|
89
89
|
*/
|
|
90
90
|
get isSmallerThanMinSize(): boolean;
|
|
91
91
|
/**
|
|
92
|
-
* `true` if the
|
|
92
|
+
* `true` if the extension is fullscreen, `false` otherwise.
|
|
93
93
|
*/
|
|
94
94
|
get isFullscreen(): boolean;
|
|
95
95
|
/**
|
|
96
|
-
* The current size of the
|
|
96
|
+
* The current size of the extension frame.
|
|
97
97
|
*
|
|
98
98
|
* Can be watched.
|
|
99
99
|
*/
|