@genesislcap/foundation-layout 14.225.3-alpha-31011b5.0 → 14.225.4-alpha-9342136.0
Sign up to get free protection for your applications and to get access to all the features.
@@ -232,542 +232,542 @@ export declare class FoundationLayout extends FoundationElement implements Layou
|
|
232
232
|
* @param handleMissingItem - what to do if the layout contains items that are not currently registered with the layout system. Defaults to 'error' which will throw an error. If set to 'placeholder' then any missing items will be replaced with a placeholder element. You can control the text of the placeholder element with {@link FoundationLayout.missingItemPlaceholder}.
|
233
233
|
* @param disableCache - if set to true then the layout will give you a new instance of every item, even if it has a currently cached item to use. Using this will not stop you from saving and loading state via the {@link LayoutComponentWithState} interface. Defaults to false.
|
234
234
|
* @throws {@link LayoutUsageError} if you attempt to load a layout with registered items that are not currently registered with the layout system, and handleMissingItem is set to 'error' (default).
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
|
329
|
-
|
330
|
-
|
331
|
-
|
332
|
-
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
}
|
235
|
+
* @throws various errors if the layout string is malformed and cannot be parsed
|
236
|
+
*/
|
237
|
+
loadLayout(layout: SerialisedLayout, handleMissingItem?: 'placeholder' | 'error', disableCache?: boolean): void;
|
238
|
+
/**
|
239
|
+
* @public
|
240
|
+
* Dynamically add a new item to the layout. The user can move the new plane to whenever they want once it has been added.
|
241
|
+
* @remarks
|
242
|
+
* Adding new items invokes the registration previously made explicitly via {@link FoundationLayout.registerItem | registerItem()} or implicitly via the html declarative API.
|
243
|
+
*
|
244
|
+
* The elements added onto the new pane are copies using `element.cloneNode()` of the original element references used during registration.
|
245
|
+
*
|
246
|
+
* @param config - {@link RegisteredElementConfig} configuration items for the new items(s). Pass an array of {@link RegisteredElementConfig} to add multiple items at once.
|
247
|
+
* @param placement - where and how to add the new items to the layout. For more info and defaults see {@link Placement}.
|
248
|
+
* @throws {@link LayoutRegistrationError} if you attempt to add an item before it has been registered
|
249
|
+
*/
|
250
|
+
addItem(config: RegisteredElementConfig | RegisteredElementConfig[], placement?: Placement): void;
|
251
|
+
/**
|
252
|
+
* @public
|
253
|
+
* Removes all instances of a specified registered item from the layout.
|
254
|
+
* @param registration - string of the registration ID
|
255
|
+
* @param force - if set to true then the item will be removed even if it is not closable. Defaults to false, which is the same behaviour as the close button on the header.
|
256
|
+
* @returns number of items removed
|
257
|
+
* @remarks
|
258
|
+
* Does not remove the registration from the layout system.
|
259
|
+
* Has a side affect of setting all tab views to be viewing the first tab in the stack.
|
260
|
+
*/
|
261
|
+
removeItems(registration: string, force?: boolean): number;
|
262
|
+
/**
|
263
|
+
* @public
|
264
|
+
* Register a collection of `Element` and associate them with an `ID` with the layout system for later use.
|
265
|
+
* @remarks
|
266
|
+
* You would use this to register elements that you later want to load when using {@link FoundationLayout.loadLayout}.
|
267
|
+
* Use {@link FoundationLayout.layoutRequiredRegistrations} to see what components need to be registered for a certain config
|
268
|
+
* and then register them using this function before calling {@link FoundationLayout.loadLayout}.
|
269
|
+
*
|
270
|
+
* When registering an element it is moved by reference into the internals of the layout, so if you pass elements already in the DOM then they will disappear. If you want to avoid this you can pass copies using `element.cloneNode(true)`.
|
271
|
+
*
|
272
|
+
* @param registration - string of the registration ID
|
273
|
+
* @param elements - Elements[] containing the reference to the elements to register for later usage
|
274
|
+
* @throws {@link LayoutUsageError} if you attempt to add an item before the layout has been initialised.
|
275
|
+
* @throws {@link LayoutRegistrationError} if you attempt to use a `registration` name which is already in use (declarative html API and JavaScript API registrations use the same "pool" of registration names).
|
276
|
+
* @returns - string defining the name of the registered item with the layout system (config.id if set).
|
277
|
+
*/
|
278
|
+
registerItem(registration: string, elements: Element[]): string;
|
279
|
+
/**
|
280
|
+
* Internal APIs
|
281
|
+
*/
|
282
|
+
/**
|
283
|
+
* The `LifecycleMixin` can use the lifecycleUpdateToken to determine if it needs to gate
|
284
|
+
* lifecycle methods from running when other items have been added or deleted.
|
285
|
+
* This key is updated every time one of these actions are performed, so you can check if the key has changed and know you potentially need to gate some of your lifecycle functionality.
|
286
|
+
* This method should be called whenever we are about to perform an action which will cause a lifecycle update, should as adding or removing an item from the layout
|
287
|
+
*/
|
288
|
+
private updateLifecycleToken;
|
289
|
+
/**
|
290
|
+
* Request to reload the layout using the private member config. Debounced using the time set
|
291
|
+
* in this.reloadBuffer
|
292
|
+
* @internal
|
293
|
+
*/
|
294
|
+
requestLayoutReload(): void;
|
295
|
+
/**
|
296
|
+
* Adds a config item into the root config and returns a link to the new config in the tree
|
297
|
+
* @typeParam T - RowOrColumnItemConfig | StackItemConfig | ComponentItemConfig;
|
298
|
+
* @param item - T to add as the root element of the layout
|
299
|
+
* @returns T the reference to the added item in the whole item config
|
300
|
+
* @throws {@link LayoutUsageError} if you try and add an item when a root has already been set (this happens if you have multiple direct children of this html element which is an incorrect usage)
|
301
|
+
* @internal
|
302
|
+
*/
|
303
|
+
addItemFromChild<T extends RootItemConfig>(item: T): T;
|
304
|
+
/**
|
305
|
+
* Registers a function with golden layout to create a pane
|
306
|
+
* @param elements - Elements[] to add to new new pane
|
307
|
+
* @param id - optional string which is used to register the new function with golden layout. Defaults to sequentially setting the IDs for default items
|
308
|
+
* @returns - string which is the registered ID
|
309
|
+
* @throws - {@link LayoutRegistrationError} if the id is already in use
|
310
|
+
* @internal
|
311
|
+
*/
|
312
|
+
cacheElementsAndRegister({ elements, id }: RegistrationConfig): string;
|
313
|
+
/**
|
314
|
+
* Sets up the event listeners for the layout receive events
|
315
|
+
* @internal
|
316
|
+
*/
|
317
|
+
private setupLayoutReceiveEvents;
|
318
|
+
/**
|
319
|
+
* Saves the stored layout config according to the Golden Layout provider.
|
320
|
+
* And caches the layout in local storage if {@link FoundationLayout.autoSaveKey} is set.
|
321
|
+
* @internal
|
322
|
+
* @remarks
|
323
|
+
* This will also normalise the config. E.g. over time when adding and deleting items from
|
324
|
+
* the layout, the layout config can become deeply nested but only have one item in it.
|
325
|
+
* `fromResolved()` function will remove all of the unnecessary nesting.
|
326
|
+
* */
|
327
|
+
private cacheAndSaveLayout;
|
328
|
+
/**
|
329
|
+
* Used when we are trying to load a layout with missing registrations and we want to add placeholder items
|
330
|
+
* @remarks
|
331
|
+
* This function will register the items with placeholder text, and set them to be closeable if they were not already
|
332
|
+
* As config is passed by reference it is updated directly
|
333
|
+
* @param config - The layout config to update
|
334
|
+
* @param missingRegisteredItems - The items which were missing from the registrations
|
335
|
+
* @internal
|
336
|
+
*/
|
337
|
+
private registerPlaceholdersAndSetClosable;
|
338
|
+
/**
|
339
|
+
* Loads the provided config into Golden Layout and does other setup
|
340
|
+
* @remarks
|
341
|
+
* Loads the config into Golden Layout, and then sets up the event listeners for the layout
|
342
|
+
* When loading the layout the visual configuration is loaded
|
343
|
+
* Event listeners are added to the drag handles to emulate resizing events
|
344
|
+
*
|
345
|
+
* Visual config can be overridden by the `dimensions-config` attribute.
|
346
|
+
*
|
347
|
+
* **This is the only function which should call this.layout.loadLayout() directly.**
|
348
|
+
* @internal
|
349
|
+
*/
|
350
|
+
private loadGLConfigAndSetup;
|
351
|
+
/**
|
352
|
+
* Handles adding the drag event listeners onto the golden layout drag handles
|
353
|
+
* @remarks
|
354
|
+
* If we only add the event listeners once then once the user drags items around the layout and creates
|
355
|
+
* new drag handles, they will not have the event listeners attached. This function will add the event listeners
|
356
|
+
* but also ensure that old listeners are cleaned up. To be able to clean up the event we need a reference
|
357
|
+
* rather than an anonymous function so we store the bound function in a private variable.
|
358
|
+
* @internal
|
359
|
+
*/
|
360
|
+
private attatchResizeEvents;
|
361
|
+
/**
|
362
|
+
* If the user has provided any custom buttons, register a callback with golden layout to add them to any new items
|
363
|
+
* @internal
|
364
|
+
*/
|
365
|
+
private setupCustomButtons;
|
366
|
+
/**
|
367
|
+
* Return an array of each contained items in the layout.
|
368
|
+
* @internal
|
369
|
+
*/
|
370
|
+
private getLayoutComponents;
|
371
|
+
/**
|
372
|
+
* Recursively remove the instance key from the config which will mean that when the config is loaded it will instantiate a new instance for every item, even if they're in the cache.
|
373
|
+
* @internal
|
374
|
+
*/
|
375
|
+
private removeConfigCacheInformation;
|
376
|
+
/**
|
377
|
+
* Configures pop-out mode if {@link FoundationLayout.popoutConfig} is set
|
378
|
+
* @internal
|
379
|
+
*/
|
380
|
+
private initPopoutModeIfEnabled;
|
381
|
+
}
|
382
382
|
|
383
|
-
/**
|
384
|
-
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
|
396
|
-
|
397
|
-
export declare const foundationLayoutComponents: {
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
403
|
-
|
404
|
-
|
405
|
-
|
406
|
-
|
407
|
-
|
408
|
-
|
409
|
-
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
};
|
383
|
+
/**
|
384
|
+
* Registration object to register the layout with your design system.
|
385
|
+
*
|
386
|
+
* @remarks
|
387
|
+
* Registers the three layout component types with the design system.
|
388
|
+
* You require to use the prefix of the design system with each tag.
|
389
|
+
* If you wish to alternate the styles of the layout you only need to compose your own custom
|
390
|
+
* version of {@link FoundationLayout} as this contains the styles for the entire layout.
|
391
|
+
*
|
392
|
+
* @example
|
393
|
+
* `<zero-layout></zero-layout>` if you are using the layout with the `zero` design-system.
|
394
|
+
*
|
395
|
+
* @public
|
396
|
+
*/
|
397
|
+
export declare const foundationLayoutComponents: {
|
398
|
+
foundationLayout: (overrideDefinition?: OverrideFoundationElementDefinition< {
|
399
|
+
baseName: string;
|
400
|
+
styles: ElementStyles;
|
401
|
+
template: ViewTemplate<FoundationLayout, any>;
|
402
|
+
}>) => FoundationElementRegistry< {
|
403
|
+
baseName: string;
|
404
|
+
styles: ElementStyles;
|
405
|
+
template: ViewTemplate<FoundationLayout, any>;
|
406
|
+
}, FoundationLayout>;
|
407
|
+
foundationLayoutRegion: (overrideDefinition?: OverrideFoundationElementDefinition< {
|
408
|
+
baseName: string;
|
409
|
+
template: ViewTemplate<any, any>;
|
410
|
+
}>) => FoundationElementRegistry< {
|
411
|
+
baseName: string;
|
412
|
+
template: ViewTemplate<any, any>;
|
413
|
+
}, FoundationLayoutRegion>;
|
414
|
+
foundationLayoutItem: (overrideDefinition?: OverrideFoundationElementDefinition< {
|
415
|
+
baseName: string;
|
416
|
+
template: ViewTemplate<any, any>;
|
417
|
+
}>) => FoundationElementRegistry< {
|
418
|
+
baseName: string;
|
419
|
+
template: ViewTemplate<any, any>;
|
420
|
+
}, FoundationLayoutItem>;
|
421
|
+
register(container?: Container, ...rest: any[]): void;
|
422
|
+
};
|
423
423
|
|
424
|
-
/**
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
|
432
|
-
|
433
|
-
export declare class FoundationLayoutItem extends FoundationElement implements LayoutComponent {
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
438
|
-
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
444
|
-
|
445
|
-
|
446
|
-
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
}
|
424
|
+
/**
|
425
|
+
* @public
|
426
|
+
* `FoundationLayoutItem` is a custom element that represents an item in the layout.
|
427
|
+
* @remarks
|
428
|
+
* This element is used to wrap html elements and configure their layout settings as part of the layout system.
|
429
|
+
*
|
430
|
+
* This is a simple component which is only used to define the layout splits; any JavaScript API interactions or custom styling is used via {@link FoundationLayout}.
|
431
|
+
* @tagname %%prefix%%-layout-item
|
432
|
+
*/
|
433
|
+
export declare class FoundationLayoutItem extends FoundationElement implements LayoutComponent {
|
434
|
+
/**
|
435
|
+
* Sets the title of the item which is displayed on the tab.
|
436
|
+
* @remarks
|
437
|
+
* Defaults to `Item ` + {@link FoundationLayoutItem.registration}
|
438
|
+
* @public
|
439
|
+
*/
|
440
|
+
title: string;
|
441
|
+
/**
|
442
|
+
* Boolean attribute controls whether the window can be closed in the GUI.
|
443
|
+
* Defaults to `false`.
|
444
|
+
* @public
|
445
|
+
*/
|
446
|
+
closable: boolean;
|
447
|
+
/**
|
448
|
+
* optional string describing the size of the new item (see the written documentation for more info)
|
449
|
+
* @public
|
450
|
+
*/
|
451
|
+
size: string;
|
452
|
+
/**
|
453
|
+
* Sets the registration name for the item, which can be used later to add the item via the JavaScript API using {@link FoundationLayout.addItem}.
|
454
|
+
* @remarks
|
455
|
+
* Items added via the JavaScript API and HTML API share the same pool of registration names.
|
456
|
+
* Using a duplicate registration name is a runtime error.
|
457
|
+
* This registration name defaults to the number of the window it is.
|
458
|
+
* It is highly recommended if you are using the JavaScript API that you set a registration name here manually.
|
459
|
+
* @public
|
460
|
+
*/
|
461
|
+
registration: string;
|
462
|
+
/** @internal */
|
463
|
+
[componentType]: "item";
|
464
|
+
/** @internal */
|
465
|
+
private slottedElements;
|
466
|
+
/** @internal */
|
467
|
+
connectedCallback(): void;
|
468
|
+
/** @internal */
|
469
|
+
private getParentLayoutComponent;
|
470
|
+
/** @internal */
|
471
|
+
requestLayoutReload(): void;
|
472
|
+
/** @internal */
|
473
|
+
cacheElementsAndRegister(config: RegistrationConfig): string;
|
474
|
+
}
|
475
475
|
|
476
|
-
/**
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
export declare class FoundationLayoutRegion extends FoundationElement implements LayoutComponent {
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
|
501
|
-
|
502
|
-
|
503
|
-
|
504
|
-
|
505
|
-
|
506
|
-
|
507
|
-
|
508
|
-
|
509
|
-
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
|
514
|
-
|
515
|
-
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
|
523
|
-
|
524
|
-
|
525
|
-
}
|
476
|
+
/**
|
477
|
+
* @public
|
478
|
+
* `FoundationLayoutRegion` is a custom element that represents a region in the layout.
|
479
|
+
* @remarks
|
480
|
+
* This element is used to create a region in the layout. It can be used to create a horizontal or vertical split, or a tabbed region.
|
481
|
+
*
|
482
|
+
* This is a simple component which is only used to define the layout splits; any JavaScript API interactions or custom styling is used via {@link FoundationLayout}.
|
483
|
+
* @tagname %%prefix%%-layout-region
|
484
|
+
*/
|
485
|
+
export declare class FoundationLayoutRegion extends FoundationElement implements LayoutComponent {
|
486
|
+
/**
|
487
|
+
* optional string describing the size of the new item (see the written documentation for more info)
|
488
|
+
* @public
|
489
|
+
*/
|
490
|
+
size: string;
|
491
|
+
/**
|
492
|
+
* Defines the {@link LayoutRegionType | type} of the region.
|
493
|
+
* Defaults to `horizontal`.
|
494
|
+
* @public
|
495
|
+
*/
|
496
|
+
type: LayoutRegionType;
|
497
|
+
/** @internal */
|
498
|
+
[componentType]: LayoutRegionType;
|
499
|
+
/**
|
500
|
+
* Reference to the config in the whole layout config for this
|
501
|
+
* specific region.
|
502
|
+
* @internal
|
503
|
+
*/
|
504
|
+
private layoutConfig;
|
505
|
+
/** @internal */
|
506
|
+
connectedCallback(): void;
|
507
|
+
/**
|
508
|
+
* Gets the layout config for this region using {@link FoundationLayoutRegion.constructLayoutConfig} and adds it into the main config tree via the parents. It saves a reference to the this config so a child can add its config in later.
|
509
|
+
* @internal
|
510
|
+
*/
|
511
|
+
private setupLayoutRegion;
|
512
|
+
/**
|
513
|
+
* Creates a golden layout config for this object.
|
514
|
+
* @internal
|
515
|
+
*/
|
516
|
+
private constructLayoutConfig;
|
517
|
+
/** @internal */
|
518
|
+
private getParentLayoutComponent;
|
519
|
+
/** @internal */
|
520
|
+
addItemFromChild<T extends RootItemConfig>(item: T): T;
|
521
|
+
/** @internal */
|
522
|
+
requestLayoutReload(): void;
|
523
|
+
/** @internal */
|
524
|
+
cacheElementsAndRegister(config: RegistrationConfig): string;
|
525
|
+
}
|
526
526
|
|
527
|
-
/**
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
export declare const LAYOUT_ICONS: {
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
};
|
527
|
+
/**
|
528
|
+
* A collection of SVG icons in base64 format.
|
529
|
+
* @remarks
|
530
|
+
* These icons are used by the layout manager for the UI buttons. You can use these as examples for your own custom icons when creating a custom button.
|
531
|
+
* @example
|
532
|
+
* ```
|
533
|
+
* export const layoutCustomButtons: CustomButton[] = [
|
534
|
+
* { svg: LAYOUT_ICONS.renameSVG, onClick: (button: HTMLElement, elem: HTMLElement) => {} },
|
535
|
+
* ];
|
536
|
+
* ```
|
537
|
+
*
|
538
|
+
* @public
|
539
|
+
*/
|
540
|
+
export declare const LAYOUT_ICONS: {
|
541
|
+
readonly renameSVG: "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiIHdpZHRoPSI0NTAiIGhlaWdodD0iNDUwIiB2aWV3Qm94PSIwIDAgNDUwIDQ1MCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+PGcgdHJhbnNmb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DA7IHN0cm9rZS1saW5lam9pbjogbWl0ZXI7IHN0cm9rZS1taXRlcmxpbWl0OiA0OyBpcy1jdXN0b20tZm9udDogbm9uZTsgZm9udC1maWxlLXVybDogbm9uZTsgZmlsbDogcmdiKDAsMCwwKTsgZmlsbC1vcGFjaXR5OiAwOyBmaWxsLXJ1bGU6IG5vbnplcm87IG9wYWNpdHk6IDE7IiB4PSItMTgiIHk9Ii0xOCIgcng9IjAiIHJ5PSIwIiB3aWR0aD0iMzYiIGhlaWdodD0iMzYiLz4gPC9nPiA8L2c+IDwvZz4gPC9zdmc+Cg==";
|
547
|
+
};
|
548
548
|
|
549
|
-
/**
|
550
|
-
|
551
|
-
|
552
|
-
|
553
|
-
|
554
|
-
|
555
|
-
export declare const LAYOUT_POPOUT_CONTAINER_CLASS = "f-layout-popout";
|
549
|
+
/**
|
550
|
+
* Put this classname on an element which is a DOM parent of the layout, and
|
551
|
+
* if the layout goes into popout mode then it will place itself as the only child
|
552
|
+
* for the popout container you set.
|
553
|
+
* @beta
|
554
|
+
*/
|
555
|
+
export declare const LAYOUT_POPOUT_CONTAINER_CLASS = "f-layout-popout";
|
556
556
|
|
557
|
-
/** @internal */
|
558
|
-
declare interface LayoutComponent {
|
559
|
-
|
560
|
-
|
561
|
-
|
562
|
-
}
|
557
|
+
/** @internal */
|
558
|
+
declare interface LayoutComponent {
|
559
|
+
[componentType]: ComponentTypes;
|
560
|
+
cacheElementsAndRegister(config: RegistrationConfig): string;
|
561
|
+
requestLayoutReload(): void;
|
562
|
+
}
|
563
563
|
|
564
|
-
/**
|
565
|
-
|
566
|
-
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
|
572
|
-
|
573
|
-
|
574
|
-
|
575
|
-
|
576
|
-
|
577
|
-
|
578
|
-
|
579
|
-
|
580
|
-
|
581
|
-
|
582
|
-
|
583
|
-
|
584
|
-
|
585
|
-
|
586
|
-
|
587
|
-
|
588
|
-
|
589
|
-
|
590
|
-
|
591
|
-
|
592
|
-
|
593
|
-
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
|
598
|
-
|
599
|
-
|
600
|
-
|
601
|
-
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
611
|
-
|
612
|
-
|
613
|
-
|
614
|
-
|
615
|
-
|
616
|
-
|
617
|
-
export declare interface LayoutComponentWithState<T> {
|
618
|
-
|
619
|
-
|
620
|
-
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
626
|
-
}
|
564
|
+
/**
|
565
|
+
* Interface to implement on an item which is a component of the layout and you wish to serialise state with. This is saved separately for each instance of the component, which allows you to restore multiple instances of the same component with different state.
|
566
|
+
* @typeParam T - the type of the state object you wish to serialise with the component.
|
567
|
+
* @remarks
|
568
|
+
* When the layout is saved either via the autosave functionality or manually calling {@link FoundationLayout.getLayout}, all contained components will be requested to provide state if they wish.
|
569
|
+
*
|
570
|
+
* Any state which is provided will be saved as part of the layout config and will be passed back to the component when the layout is loaded with {@link FoundationLayout.loadLayout} (or via autoloading). The state will be applied to the component via `applyState`, this may be before or after the component has been placed on the DOM, so you'll need to handle either scenario. The state is `null` when the instance is first created.
|
571
|
+
*
|
572
|
+
* See the written documentation for some error scenarios to consider about when implementing this interface.
|
573
|
+
*
|
574
|
+
* @example
|
575
|
+
* ```
|
576
|
+
* type ComponentState = {
|
577
|
+
* foo: string;
|
578
|
+
* }
|
579
|
+
* \@customElement({ name: 'my-component' })
|
580
|
+
* export class MyComponent extends FASTElement implements LayoutComponentWithState<ComponentState> {
|
581
|
+
* \@observable foo: string;
|
582
|
+
* private fooCache: ComponentState | null;
|
583
|
+
*
|
584
|
+
* getCurrentState(): ComponentState {
|
585
|
+
* if (!this.foo) return null;
|
586
|
+
* return {
|
587
|
+
* foo: this.foo;
|
588
|
+
* }
|
589
|
+
* }
|
590
|
+
*
|
591
|
+
* applyState(state: ComponentState | null) {
|
592
|
+
* this.fooCache = state;
|
593
|
+
* }
|
594
|
+
*
|
595
|
+
* connectedCallback() {
|
596
|
+
* // do other required setup
|
597
|
+
* if (this.fooCache) {
|
598
|
+
* this.foo = this.fooCache.foo;
|
599
|
+
* }
|
600
|
+
* }
|
601
|
+
* }
|
602
|
+
* ```
|
603
|
+
*
|
604
|
+
* @example
|
605
|
+
* If you are using the autosave functionality you should inform the layout system when you update the state of a component, otherwise the state will only be updated when the user performs an action such as resizing an item. Use the {@link LayoutReceiveEvents} `autosave` event.
|
606
|
+
* ```
|
607
|
+
* // Same component as above
|
608
|
+
* export class MyComponent extends FASTElement implements LayoutComponentWithState<ComponentState> {
|
609
|
+
* // can use xChanged pattern as `foo` was declared observable
|
610
|
+
* fooChanged() {
|
611
|
+
* this.$emit(LayoutReceiveEvents.autosave);
|
612
|
+
* }
|
613
|
+
* }
|
614
|
+
* ```
|
615
|
+
* @public
|
616
|
+
* */
|
617
|
+
export declare interface LayoutComponentWithState<T> {
|
618
|
+
/**
|
619
|
+
* Provide the state you wish to save. It is recommended if the component which implements this interface has not fully initialised at the point this is called that you return `null` as the state, following the pattern of `null` being set as the initial state.
|
620
|
+
*/
|
621
|
+
getCurrentState(): T;
|
622
|
+
/**
|
623
|
+
* Handle any state that has been saved previously for this instance of this component. It is not deterministic to know whether this is called before the component is appended to the DOM.
|
624
|
+
*/
|
625
|
+
applyState(state: T | null): void;
|
626
|
+
}
|
627
627
|
|
628
|
-
/**
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
633
|
-
|
634
|
-
|
635
|
-
|
636
|
-
|
637
|
-
|
638
|
-
|
639
|
-
|
640
|
-
|
641
|
-
export declare const LayoutEmitEvents: {
|
642
|
-
|
643
|
-
|
644
|
-
|
645
|
-
|
646
|
-
};
|
628
|
+
/**
|
629
|
+
* Defines events that the layout system emits
|
630
|
+
*
|
631
|
+
* 'firstLoaded' - emitted when the layout has finished loading the first time
|
632
|
+
* using the declarative API after {@link DEFAULT_RELOAD_BUFFER} ms.
|
633
|
+
* <br/>
|
634
|
+
* 'itemAdded' - emitted when an item is added to the layout'
|
635
|
+
* <br/>
|
636
|
+
* 'itemRemoved' - emitted when an item is removed from the layout'
|
637
|
+
* <br/>
|
638
|
+
* 'itemResized' - emitted when the user drags the divider to resize elements
|
639
|
+
* @public
|
640
|
+
*/
|
641
|
+
export declare const LayoutEmitEvents: {
|
642
|
+
readonly firstLoaded: "first-loaded";
|
643
|
+
readonly itemAdded: "item-added";
|
644
|
+
readonly itemRemoved: "item-removed";
|
645
|
+
readonly itemResized: "item-resized";
|
646
|
+
};
|
647
647
|
|
648
|
-
/**
|
649
|
-
|
650
|
-
|
651
|
-
|
652
|
-
|
653
|
-
|
654
|
-
|
655
|
-
export declare const LayoutReceiveEvents: {
|
656
|
-
|
657
|
-
|
658
|
-
};
|
648
|
+
/**
|
649
|
+
* Defines events that the layout system listens for
|
650
|
+
*
|
651
|
+
* 'changeTitle' - emit this from a contained item to update the title of the window that contains it.
|
652
|
+
* 'autosave' - emit this from a contained item to hint to the layout system that it should autosave the layout. A contained item should do this if it has just changed some state it would like to persist. See {@link LayoutComponentWithState}.
|
653
|
+
* @public
|
654
|
+
*/
|
655
|
+
export declare const LayoutReceiveEvents: {
|
656
|
+
readonly changeTitle: "change-title";
|
657
|
+
readonly autosave: "autosave";
|
658
|
+
};
|
659
659
|
|
660
|
-
/**
|
661
|
-
|
662
|
-
|
663
|
-
|
664
|
-
|
665
|
-
|
666
|
-
|
667
|
-
export declare type LayoutReceiveEventsDetail = {
|
668
|
-
|
669
|
-
|
670
|
-
|
671
|
-
|
672
|
-
|
673
|
-
};
|
660
|
+
/**
|
661
|
+
* Defines the shape of the detail that the layout listens works with for events it listens on
|
662
|
+
*
|
663
|
+
* 'changeTitle' - `title` is the string you want to set. For `mode`: `replace` will set the title to be `title`, `suffix` will append `title` to the end of the existing title.
|
664
|
+
* 'autosave' - no other parameters.
|
665
|
+
* @public
|
666
|
+
*/
|
667
|
+
export declare type LayoutReceiveEventsDetail = {
|
668
|
+
changeTitle: {
|
669
|
+
title: string;
|
670
|
+
mode: 'replace' | 'suffix';
|
671
|
+
};
|
672
|
+
autosave: void;
|
673
|
+
};
|
674
674
|
|
675
|
-
/**
|
676
|
-
|
677
|
-
|
678
|
-
|
679
|
-
|
680
|
-
export declare type LayoutRegionType = (typeof layoutRegionValue)[number];
|
675
|
+
/**
|
676
|
+
* @public
|
677
|
+
* Union type describing the three different types of region splits.
|
678
|
+
* Set on the `type` attribute on {@link FoundationLayoutRegion}.
|
679
|
+
*/
|
680
|
+
export declare type LayoutRegionType = (typeof layoutRegionValue)[number];
|
681
681
|
|
682
|
-
/** @internal */
|
683
|
-
declare const layoutRegionValue: readonly ["horizontal", "vertical", "tabs"];
|
682
|
+
/** @internal */
|
683
|
+
declare const layoutRegionValue: readonly ["horizontal", "vertical", "tabs"];
|
684
684
|
|
685
|
-
/**
|
686
|
-
|
687
|
-
|
688
|
-
export declare class LayoutRegistrationError extends Error {
|
689
|
-
|
690
|
-
}
|
685
|
+
/**
|
686
|
+
* @public
|
687
|
+
*/
|
688
|
+
export declare class LayoutRegistrationError extends Error {
|
689
|
+
constructor(message: string);
|
690
|
+
}
|
691
691
|
|
692
|
-
/**
|
693
|
-
|
694
|
-
|
695
|
-
|
696
|
-
|
697
|
-
|
698
|
-
export declare const layoutStyles: ElementStyles;
|
692
|
+
/**
|
693
|
+
* `ElementStyles` which defines the css for {@link FoundationLayout}.
|
694
|
+
* @remarks
|
695
|
+
* Can be used in a composition to customise the styles of the layout.
|
696
|
+
* @public
|
697
|
+
*/
|
698
|
+
export declare const layoutStyles: ElementStyles;
|
699
699
|
|
700
|
-
/**
|
701
|
-
|
702
|
-
|
703
|
-
|
704
|
-
|
705
|
-
|
706
|
-
export declare const layoutTemplate: ViewTemplate<FoundationLayout, any>;
|
700
|
+
/**
|
701
|
+
* `ViewTemplate` which defines the html for {@link FoundationLayout}.
|
702
|
+
* @remarks
|
703
|
+
* Can be used in a composition to customise the styles of the layout.
|
704
|
+
* @public
|
705
|
+
*/
|
706
|
+
export declare const layoutTemplate: ViewTemplate<FoundationLayout, any>;
|
707
707
|
|
708
|
-
/**
|
709
|
-
|
710
|
-
|
711
|
-
export declare class LayoutUsageError extends Error {
|
712
|
-
|
713
|
-
}
|
708
|
+
/**
|
709
|
+
* @public
|
710
|
+
*/
|
711
|
+
export declare class LayoutUsageError extends Error {
|
712
|
+
constructor(message: string);
|
713
|
+
}
|
714
714
|
|
715
|
-
/**
|
716
|
-
|
717
|
-
|
718
|
-
|
719
|
-
|
720
|
-
|
721
|
-
|
722
|
-
|
723
|
-
|
724
|
-
|
725
|
-
export declare type Placement = {
|
726
|
-
|
727
|
-
|
728
|
-
|
729
|
-
|
730
|
-
|
731
|
-
};
|
715
|
+
/**
|
716
|
+
* @public
|
717
|
+
* Where to and how to add the new item(s) into the layout when using the {@link FoundationLayout.addItem} API.
|
718
|
+
* @remarks
|
719
|
+
* `area` dictates what part of the layout the new item(s) will be added to.
|
720
|
+
* `multiple` is optional and is defaulted to `type=horizontal` and `size=50%` if not defined. `multiple` config only affects the placement if multiple items are specified to be added.
|
721
|
+
* `multiple.type` sets the group type of the new items, whether they are horizontal, vertical, or in tabs.
|
722
|
+
* `multiple.size` - optional string describing the size of the new item (see the written documentation for more info).
|
723
|
+
* `multiple.size` specifies the size of the new group to be added and then the `size` config of the new items are the sizes relative to this new multiple group. If you only specify one new item then the `size` of that will be used as the size and will override `multiple.size`.
|
724
|
+
*/
|
725
|
+
export declare type Placement = {
|
726
|
+
area: 'top' | 'left' | 'bottom' | 'right';
|
727
|
+
multiple?: {
|
728
|
+
type: LayoutRegionType;
|
729
|
+
size?: string;
|
730
|
+
};
|
731
|
+
};
|
732
732
|
|
733
|
-
/**
|
734
|
-
|
735
|
-
|
736
|
-
|
737
|
-
|
738
|
-
|
739
|
-
|
740
|
-
|
741
|
-
|
742
|
-
|
743
|
-
|
744
|
-
export declare interface RegisteredElementConfig {
|
745
|
-
|
746
|
-
|
747
|
-
|
748
|
-
|
749
|
-
}
|
733
|
+
/**
|
734
|
+
* @public
|
735
|
+
* The parameters that can be set on a new item when being added by the {@link FoundationLayout.addItem} API
|
736
|
+
*
|
737
|
+
* @remarks
|
738
|
+
* `elements` - array of Elements that are the content of the new item
|
739
|
+
* `title` - optional string which is used as the new title of the tab (defaults to be the registered name)
|
740
|
+
* `closable` - optional boolean which allows the item to be closed with the X button if set and true
|
741
|
+
* `size` - optional string describing the size of the new item (see the written documentation for more info)
|
742
|
+
* `registration` - optional string configuring the registration ID of the new item (defaults to sequential IDs)
|
743
|
+
*/
|
744
|
+
export declare interface RegisteredElementConfig {
|
745
|
+
registration: string;
|
746
|
+
title?: string;
|
747
|
+
closable?: boolean;
|
748
|
+
size?: string;
|
749
|
+
}
|
750
750
|
|
751
|
-
/** @internal */
|
752
|
-
export declare interface RegistrationConfig {
|
753
|
-
|
754
|
-
|
755
|
-
}
|
751
|
+
/** @internal */
|
752
|
+
export declare interface RegistrationConfig {
|
753
|
+
elements: Element[];
|
754
|
+
id?: string;
|
755
|
+
}
|
756
756
|
|
757
|
-
/**
|
758
|
-
|
759
|
-
|
760
|
-
|
761
|
-
|
762
|
-
|
763
|
-
|
764
|
-
|
765
|
-
|
766
|
-
|
767
|
-
|
768
|
-
export declare type SerialisedLayout = {
|
769
|
-
|
770
|
-
|
771
|
-
};
|
757
|
+
/**
|
758
|
+
* @public
|
759
|
+
* Versioned layout config objects. `v` is the version and `c` contains the layout config.
|
760
|
+
* @remarks
|
761
|
+
* Versioning the layout config in this way allows changes to the config schema while
|
762
|
+
* remaining backwards compatible with any existing client/user configurations. When loading an
|
763
|
+
* older version of the configurations the version can be used to lookup and apply transformer functions
|
764
|
+
* to get the newest version of the config from it.
|
765
|
+
*
|
766
|
+
* As more versions of configurations are added this type will have extra union types as part of SerialisedLayout.
|
767
|
+
*/
|
768
|
+
export declare type SerialisedLayout = {
|
769
|
+
v: '1';
|
770
|
+
c: ResolvedLayoutConfig;
|
771
|
+
};
|
772
772
|
|
773
|
-
export { }
|
773
|
+
export { }
|
package/dist/tsdoc-metadata.json
CHANGED
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@genesislcap/foundation-layout",
|
3
3
|
"description": "Genesis Foundation UI App Layout",
|
4
|
-
"version": "14.225.
|
4
|
+
"version": "14.225.4-alpha-9342136.0",
|
5
5
|
"license": "SEE LICENSE IN license.txt",
|
6
6
|
"main": "dist/esm/index.js",
|
7
7
|
"types": "dist/foundation-layout.d.ts",
|
@@ -36,24 +36,24 @@
|
|
36
36
|
}
|
37
37
|
},
|
38
38
|
"devDependencies": {
|
39
|
-
"@genesislcap/foundation-testing": "14.225.
|
40
|
-
"@genesislcap/genx": "14.225.
|
41
|
-
"@genesislcap/rollup-builder": "14.225.
|
42
|
-
"@genesislcap/ts-builder": "14.225.
|
43
|
-
"@genesislcap/uvu-playwright-builder": "14.225.
|
44
|
-
"@genesislcap/vite-builder": "14.225.
|
45
|
-
"@genesislcap/webpack-builder": "14.225.
|
39
|
+
"@genesislcap/foundation-testing": "14.225.4-alpha-9342136.0",
|
40
|
+
"@genesislcap/genx": "14.225.4-alpha-9342136.0",
|
41
|
+
"@genesislcap/rollup-builder": "14.225.4-alpha-9342136.0",
|
42
|
+
"@genesislcap/ts-builder": "14.225.4-alpha-9342136.0",
|
43
|
+
"@genesislcap/uvu-playwright-builder": "14.225.4-alpha-9342136.0",
|
44
|
+
"@genesislcap/vite-builder": "14.225.4-alpha-9342136.0",
|
45
|
+
"@genesislcap/webpack-builder": "14.225.4-alpha-9342136.0",
|
46
46
|
"rimraf": "^5.0.0"
|
47
47
|
},
|
48
48
|
"dependencies": {
|
49
49
|
"@genesis-community/golden-layout": "^2.11.0",
|
50
|
-
"@genesislcap/foundation-comms": "14.225.
|
51
|
-
"@genesislcap/foundation-logger": "14.225.
|
52
|
-
"@genesislcap/foundation-utils": "14.225.
|
50
|
+
"@genesislcap/foundation-comms": "14.225.4-alpha-9342136.0",
|
51
|
+
"@genesislcap/foundation-logger": "14.225.4-alpha-9342136.0",
|
52
|
+
"@genesislcap/foundation-utils": "14.225.4-alpha-9342136.0",
|
53
53
|
"@microsoft/fast-components": "2.30.6",
|
54
54
|
"@microsoft/fast-element": "1.14.0",
|
55
55
|
"@microsoft/fast-foundation": "2.49.6",
|
56
|
-
"tslib": "
|
56
|
+
"tslib": "2.8.1"
|
57
57
|
},
|
58
58
|
"repository": {
|
59
59
|
"type": "git",
|
@@ -64,5 +64,5 @@
|
|
64
64
|
"access": "public"
|
65
65
|
},
|
66
66
|
"customElements": "dist/custom-elements.json",
|
67
|
-
"gitHead": "
|
67
|
+
"gitHead": "fc6d550b6235df216dc52fc120675e1a0cde3d1e"
|
68
68
|
}
|
File without changes
|