@websolutespa/payload-plugin-bowl 1.3.5 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # @websolutespa/payload-plugin-bowl
2
2
 
3
+ ## 1.6.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 6707ca2: Upgrading Payload 2.11.2
8
+
9
+ ### Patch Changes
10
+
11
+ - f664993: Added: useLivePreview
12
+ - Updated dependencies [6cbf4cb]
13
+ - @websolutespa/bom-core@0.6.7
14
+
15
+ ## 1.3.6
16
+
17
+ ### Patch Changes
18
+
19
+ - Fixing: afterPageReadHook
20
+
3
21
  ## 1.3.5
4
22
 
5
23
  ### Patch Changes
package/dist/index.css CHANGED
@@ -1,24 +1,3 @@
1
- /* src/components/Category/CategoryList.scss */
2
- .category-list__actions {
3
- position: sticky;
4
- top: 0;
5
- display: flex;
6
- align-items: center;
7
- justify-content: flex-end;
8
- column-gap: 10px;
9
- padding: 10px;
10
- z-index: 30;
11
- border-bottom: 1px solid var(--theme-elevation-100);
12
- background: var(--theme-elevation-0);
13
- }
14
- .category-list__actions .btn {
15
- margin: 0;
16
- padding: 1px 6px;
17
- }
18
- .category-list .eyebrow {
19
- top: 48px;
20
- }
21
-
22
1
  /* src/components/DataTree/DataTree.scss */
23
2
  :root {
24
3
  --rct-item-height: 32px;
@@ -311,10 +290,11 @@ html[data-theme=dark],
311
290
  align-items: center;
312
291
  justify-content: flex-end;
313
292
  column-gap: 10px;
314
- padding: 10px;
293
+ padding: 13.5px 18.75px;
315
294
  }
316
295
  .category-tree__actions .btn {
317
296
  margin: 0;
297
+ background-color: var(--theme-elevation-200);
318
298
  }
319
299
  .category-tree__foot {
320
300
  display: flex;
@@ -374,6 +354,23 @@ html[data-theme=dark],
374
354
  min-height: 0;
375
355
  height: auto;
376
356
  }
357
+ .category-edit__modal .collection-edit__header {
358
+ width: 100%;
359
+ }
360
+ .category-edit__modal .collection-edit__header-content {
361
+ display: flex;
362
+ justify-content: space-between;
363
+ width: 100%;
364
+ align-items: center;
365
+ margin: 0 0 2rem;
366
+ }
367
+ .category-edit__modal .collection-edit__header-content h2 {
368
+ margin: 0;
369
+ }
370
+ .category-edit__modal .collection-edit__header-content .icon--x {
371
+ width: 44px;
372
+ height: 44px;
373
+ }
377
374
  .category-edit__modal .collection-edit__edit {
378
375
  padding: 0;
379
376
  margin: 0;
@@ -384,6 +381,7 @@ html[data-theme=dark],
384
381
  .category-edit__modal .collection-edit__form {
385
382
  width: 100%;
386
383
  height: auto;
384
+ z-index: 1000;
387
385
  }
388
386
  .category-edit__header {
389
387
  width: 100%;
@@ -521,6 +519,7 @@ html[data-theme=dark],
521
519
  .import-modal__dropzone {
522
520
  text-align: center;
523
521
  padding: 20px;
522
+ margin-top: var(--base);
524
523
  border: 3px #2f2f2f dashed;
525
524
  width: 100%;
526
525
  height: 150px;
@@ -597,6 +596,9 @@ html[data-theme=dark],
597
596
  .custom-color-picker__input:not(:disabled):focus {
598
597
  box-shadow: 0 2px 3px 0 rgba(0, 2, 4, 0.16), 0 6px 4px -4px rgba(0, 2, 4, 0.13);
599
598
  }
599
+ .custom-color-picker__input[data-rtl=true] {
600
+ direction: rtl;
601
+ }
600
602
  .custom-color-picker__input::-webkit-input-placeholder {
601
603
  color: var(--theme-elevation-400);
602
604
  font-weight: normal;
package/dist/index.d.ts CHANGED
@@ -1,20 +1,19 @@
1
1
  import { Resource } from 'i18next';
2
- import { Endpoint, AdminRoute, Config } from 'payload/config';
3
- import * as payload_dist_fields_config_types from 'payload/dist/fields/config/types';
2
+ import { Endpoint, AdminView, Locale as Locale$1, Config } from 'payload/config';
4
3
  import { Field, FieldBase, Tab, JSONField, Block as Block$1, FieldAffectingData, HookName, FieldHook as FieldHook$1, UIField as UIField$1 } from 'payload/dist/fields/config/types';
5
4
  import * as payload_types from 'payload/types';
6
- import { PayloadRequest, CollectionAfterChangeHook, CollectionAfterDeleteHook, CollectionConfig, Block, GlobalConfig, RichTextField, RelationshipField, CheckboxField, BlockField, DateField, TextField, GroupField, Field as Field$1, UploadField, ArrayField, NumberField, FieldHook, SelectField, CollapsibleField, RowField, TabsField, UIField, EmailField, TextareaField, RadioField, CodeField, PointField, SanitizedCollectionConfig } from 'payload/types';
5
+ import { PayloadRequest, CollectionAfterChangeHook, CollectionAfterDeleteHook, TypeWithID, CollectionConfig, Block, GlobalConfig, RichTextField, RelationshipField, CheckboxField, BlockField, DateField, TextField, GroupField, Field as Field$1, UploadField, ArrayField, NumberField, FieldHook, SelectField, CollapsibleField, RowField, TabsField, UIField, EmailField, TextareaField, RadioField, CodeField, PointField, SanitizedCollectionConfig } from 'payload/types';
7
6
  import { IEntity, ILocale, ILocalizable, IEquatable, IMedia, ICategory, IPageRelation, IRoute, IMenu, IMenuItem, ICategorized, IMarket, IMemoryStore, ISchema } from '@websolutespa/bom-core';
8
7
  import * as payload_dist_admin_components_forms_FieldDescription_types from 'payload/dist/admin/components/forms/FieldDescription/types';
9
8
  import * as React from 'react';
10
9
  import React__default, { ReactNode } from 'react';
11
- import { Props as Props$4 } from 'payload/dist/admin/components/views/collections/List/types';
10
+ import { DocumentDrawerProps } from 'payload/dist/admin/components/elements/DocumentDrawer/types';
12
11
  import * as react_jsx_runtime from 'react/jsx-runtime';
13
12
  import { TreeItemIndex, TreeItem, TreeItemRenderContext, TreeInformation, TreeDataProvider, Disposable } from 'react-complex-tree';
14
- import { IndexProps } from 'payload/dist/admin/components/views/collections/Edit/types';
13
+ import { Props as Props$4 } from 'payload/dist/admin/components/views/collections/List/types';
15
14
  import { User } from 'payload/dist/auth';
16
- import { TypeWithID } from 'payload/dist/collections/config/types';
17
- import { PaginatedDocs } from 'payload/dist/mongoose/types';
15
+ import { PaginatedDocs } from 'payload/database';
16
+ import { ContextType } from 'payload/dist/admin/components/utilities/DocumentInfo/types';
18
17
  import { Props as Props$2 } from 'payload/components/views/Cell';
19
18
  import { Props as Props$3 } from 'payload/components/fields/Text';
20
19
  import { FieldTypes } from 'payload/dist/admin/components/forms/field-types';
@@ -61,8 +60,8 @@ declare const afterCategoryChangeHook: CollectionAfterChangeHook;
61
60
  declare const afterCategoryDeleteHook: CollectionAfterDeleteHook;
62
61
 
63
62
  declare function parseDepth(depth?: unknown): number;
64
- declare function getCollectionItems<T extends TypeWithID = any>(req: PayloadRequest, slug: string, depth?: number): Promise<T[]>;
65
- declare function getCollectionItem<T extends TypeWithID = any>(req: PayloadRequest, slug: string, id: string, depth?: number): Promise<T>;
63
+ declare function getCollectionItems<T extends TypeWithID & Record<string, unknown>>(req: PayloadRequest, slug: string, depth?: number): Promise<T[]>;
64
+ declare function getCollectionItem<T extends TypeWithID & Record<string, unknown>>(req: PayloadRequest, slug: string, id: string, depth?: number): Promise<T>;
66
65
  declare function getGlobalItems<T extends TypeWithID = any>(req: PayloadRequest, slug: string, depth?: number): Promise<T[]>;
67
66
  /**
68
67
  * Rest api collection index get handler.
@@ -83,6 +82,7 @@ type IBulkRecord = {
83
82
  declare const collectionBulkPatch: ((slug: string) => Endpoint);
84
83
  /**
85
84
  * Rest api collection update patch handler.
85
+ * known issue: collectionUpdatePatch() does not work, needs to be fixed
86
86
  */
87
87
  declare const collectionUpdatePatch: ((slug: string) => Endpoint);
88
88
  /**
@@ -183,7 +183,6 @@ type IUndecoratedMenu = {
183
183
  updatedAt: Date;
184
184
  };
185
185
  type MixerContext = {
186
- slug?: string;
187
186
  market?: string;
188
187
  locale?: string;
189
188
  routes?: IRoute[];
@@ -223,7 +222,7 @@ declare const pageIndexGet: ((slug: string) => Endpoint);
223
222
  /**
224
223
  * Decorate record for Mixer when queried by market and locale.
225
224
  */
226
- declare const afterPageReadHook: CollectionConfig['hooks']['afterRead'][number];
225
+ declare const afterPageReadHook: (slug: string) => CollectionConfig['hooks']['afterRead'][number];
227
226
  /**
228
227
  * Create a record of the pages collection related to the created document.
229
228
  */
@@ -276,7 +275,12 @@ declare function getStringParam(value: unknown): string | undefined;
276
275
 
277
276
  type WithActionProps = (Omit<CollectionConfig, 'fields'> & {
278
277
  fields: BowlField[];
279
- routes?: AdminRoute[];
278
+ views?: Record<string, AdminView>;
279
+ custom?: {
280
+ updateEndUser?: boolean;
281
+ createCredentials?: boolean;
282
+ [key: string]: unknown;
283
+ };
280
284
  });
281
285
  type WithAction = WithActionProps & {
282
286
  type: 'withAction';
@@ -304,7 +308,7 @@ declare const withBlock: (options: BowlBlock) => Block;
304
308
 
305
309
  type WithCollectionProps = (Omit<CollectionConfig, 'fields'> & {
306
310
  fields: BowlField[];
307
- routes?: AdminRoute[];
311
+ views?: Record<string, AdminView>;
308
312
  });
309
313
  type WithCollection = WithCollectionProps & {
310
314
  type: 'withCollection';
@@ -319,7 +323,7 @@ declare const withCollection: (config: WithCollectionProps) => CollectionConfig;
319
323
 
320
324
  type WithGlobalProps = (Omit<GlobalConfig, 'fields'> & {
321
325
  fields: BowlField[];
322
- routes?: AdminRoute[];
326
+ views?: Record<string, AdminView>;
323
327
  });
324
328
  type WithGlobal = WithGlobalProps & {
325
329
  type: 'withGlobal';
@@ -334,7 +338,7 @@ declare const withGlobal: (config: WithGlobalProps) => GlobalConfig;
334
338
 
335
339
  type WithMenuProps = (Omit<CollectionConfig, 'fields'> & {
336
340
  fields: BowlField[];
337
- routes?: AdminRoute[];
341
+ views?: Record<string, AdminView>;
338
342
  });
339
343
  type WithMenu = WithMenuProps & {
340
344
  type: 'withMenu';
@@ -343,7 +347,7 @@ declare const withMenu: (config: WithMenuProps) => CollectionConfig;
343
347
 
344
348
  type WithPageProps = (Omit<CollectionConfig, 'fields'> & {
345
349
  fields: BowlField[];
346
- routes?: AdminRoute[];
350
+ views?: Record<string, AdminView>;
347
351
  });
348
352
  type WithPage = WithPageProps & {
349
353
  type: 'withPage';
@@ -358,7 +362,7 @@ declare const withPage: (config: CollectionConfig) => CollectionConfig;
358
362
 
359
363
  type WithStaticProps = (Omit<CollectionConfig, 'fields'> & StaticCollectionConfig & {
360
364
  fields: BowlField[];
361
- routes?: AdminRoute[];
365
+ views?: Record<string, AdminView>;
362
366
  });
363
367
  type WithStatic = WithStaticProps & {
364
368
  type: 'withStatic';
@@ -391,15 +395,15 @@ declare const StaticCollectionDefault: Partial<CollectionConfig>;
391
395
  */
392
396
  declare const withStaticCollection: ({ src, map, duration, ...config }: WithStaticProps) => CollectionConfig;
393
397
 
394
- declare function decorateHref_<T extends ISchema = ISchema>(item: T, slug: string, market: string, locale: string, categories: ICategory[], routes: IRoute[]): Promise<T & {
398
+ declare function decorateHref_<T extends ISchema = ISchema>(item: T, slug: string, context: MixerContext): Promise<T & {
395
399
  href: string | null;
396
400
  }>;
397
- declare function decorateHrefs_<T extends ISchema = ISchema>(items: T[], slug: string, market: string, locale: string, categories: ICategory[], routes: IRoute[]): Promise<(T & {
401
+ declare function decorateHrefs_<T extends ISchema = ISchema>(items: T[], slug: string, context: MixerContext): Promise<(T & {
398
402
  href: string | null;
399
403
  })[]>;
400
404
 
401
- declare function decorateNav_<T extends ISchema = ISchema>(item: T, slug: string, market: string, locale: string, categories: ICategory[], routes: IRoute[]): Promise<T>;
402
- declare function decorateNavs_<T extends ISchema = ISchema>(items: T[], slug: string, market: string, locale: string, categories: ICategory[], routes: IRoute[]): Promise<T[]>;
405
+ declare function decorateNav_<T extends ISchema = ISchema>(item: T, slug: string, context: MixerContext): Promise<T>;
406
+ declare function decorateNavs_<T extends ISchema = ISchema>(items: T[], slug: string, context: MixerContext): Promise<T[]>;
403
407
  declare function isUndecoratedMenuItem(item: unknown): item is IUndecoratedMenuItem;
404
408
  declare function isRelation(item: unknown): item is IRelation;
405
409
  type IRelation = {
@@ -407,10 +411,10 @@ type IRelation = {
407
411
  value: IEntity | IEntity[];
408
412
  };
409
413
 
410
- declare function decorateSchema_<T extends ISchema = ISchema>(item: T, slug: string, market: string, locale: string, categories: ICategory[], routes: IRoute[]): Promise<T & {
414
+ declare function decorateSchema_<T extends ISchema = ISchema>(item: T, slug: string, context: MixerContext): Promise<T & {
411
415
  schema: string;
412
416
  }>;
413
- declare function decorateSchemas_<T extends ISchema = ISchema>(items: T[], slug: string, market: string, locale: string, categories: ICategory[], routes: IRoute[]): Promise<(T & {
417
+ declare function decorateSchemas_<T extends ISchema = ISchema>(items: T[], slug: string, context: MixerContext): Promise<(T & {
414
418
  schema: string;
415
419
  })[]>;
416
420
 
@@ -474,7 +478,7 @@ type WithDescription = WithDescriptionProps & {
474
478
  declare const withDescription: (options?: WithDescriptionProps) => RichTextField;
475
479
  declare const withDescriptionRequired: (options?: WithDescriptionProps) => RichTextField;
476
480
 
477
- type WithIdProps = (Omit<TextField, 'type' | 'name'> & {
481
+ type WithIdProps = (Omit<TextField, 'type' | 'name' | 'hasMany'> & {
478
482
  name?: string;
479
483
  });
480
484
  type WithId = WithIdProps & {
@@ -523,29 +527,29 @@ declare const appearanceOptions: {
523
527
  value: string;
524
528
  };
525
529
  };
526
- declare const withLink: ({ appearances, disableLabel, ...props }?: WithLinkProps) => Omit<payload_dist_fields_config_types.FieldBase, "required" | "validation"> & {
527
- type: "group";
528
- fields: Field$1[];
530
+ declare const withLink: ({ appearances, disableLabel, ...props }?: WithLinkProps) => Omit<payload_types.FieldBase, "required" | "validation"> & {
529
531
  admin?: {
530
- position?: "sidebar";
531
- width?: string;
532
- style?: React.CSSProperties;
533
532
  className?: string;
534
- readOnly?: boolean;
535
- disabled?: boolean;
536
- condition?: payload_dist_fields_config_types.Condition<any, any>;
537
- description?: payload_dist_admin_components_forms_FieldDescription_types.Description;
538
533
  components?: {
539
- Filter?: React.ComponentType<any>;
540
534
  Cell?: React.ComponentType<any>;
541
535
  Field?: React.ComponentType<any>;
536
+ Filter?: React.ComponentType<any>;
542
537
  };
538
+ condition?: payload_types.Condition<any, any>;
539
+ description?: payload_dist_admin_components_forms_FieldDescription_types.Description;
543
540
  disableBulkEdit?: boolean;
541
+ disabled?: boolean;
544
542
  hidden?: boolean;
543
+ position?: "sidebar";
544
+ readOnly?: boolean;
545
+ style?: React.CSSProperties;
546
+ width?: string;
545
547
  } & {
546
548
  hideGutter?: boolean;
547
549
  };
550
+ fields: Field$1[];
548
551
  interfaceName?: string;
552
+ type: "group";
549
553
  };
550
554
 
551
555
  type WithMarketsProps = (Omit<RelationshipField, 'type' | 'name' | 'relationTo'> & {
@@ -578,7 +582,7 @@ declare const MediasDefaults: ArrayField;
578
582
  declare const withMedias: (options?: WithMediasProps) => ArrayField;
579
583
  declare const withMediasRequired: (options?: WithMediasProps) => ArrayField;
580
584
 
581
- type WithNameProps = (Omit<TextField, 'type' | 'name'> & {
585
+ type WithNameProps = (Omit<TextField, 'type' | 'name' | 'hasMany'> & {
582
586
  name?: string;
583
587
  });
584
588
  type WithName = WithNameProps & {
@@ -621,6 +625,16 @@ declare const withRichText: (options?: Partial<RichTextField>) => RichTextField;
621
625
  declare const withRichTextRequired: (options?: Partial<RichTextField>) => RichTextField;
622
626
  declare function richTextSerialize(children?: any[]): string;
623
627
 
628
+ type WithRolesProps = (Omit<SelectField, 'type' | 'name' | 'options'> & {
629
+ name?: string;
630
+ roles?: BowlRole[];
631
+ });
632
+ type WithRoles = WithRolesProps & {
633
+ type: 'withRoles';
634
+ };
635
+ declare const UserRolesDefaults: SelectField;
636
+ declare const withRoles: ({ roles, ...fieldOptions }?: WithRolesProps) => SelectField;
637
+
624
638
  type WithSelectProps = (Omit<SelectField, 'type' | 'name'> & {
625
639
  name?: string;
626
640
  });
@@ -631,7 +645,7 @@ declare const SelectDefaults: SelectField;
631
645
  declare const withSelect: (options?: Partial<SelectField>) => SelectField;
632
646
  declare const withSelectRequired: (options?: Partial<SelectField>) => SelectField;
633
647
 
634
- type WithSlugProps = (Omit<TextField, 'type' | 'name'> & {
648
+ type WithSlugProps = (Omit<TextField, 'type' | 'name' | 'hasMany'> & {
635
649
  fieldToUse: string;
636
650
  });
637
651
  type WithSlug = WithSlugProps & {
@@ -650,7 +664,7 @@ declare const TemplateDefaults: RelationshipField;
650
664
  declare const withTemplate: ({ slugToUse, ...options }: WithTemplateProps) => RelationshipField;
651
665
  declare const withTemplateRequired: ({ slugToUse, ...options }: WithTemplateProps) => RelationshipField;
652
666
 
653
- type WithTextProps = (Omit<TextField, 'type' | 'name'> & {
667
+ type WithTextProps = (Omit<TextField, 'type' | 'name' | 'hasMany'> & {
654
668
  name?: string;
655
669
  });
656
670
  type WithText = WithTextProps & {
@@ -660,7 +674,7 @@ declare const TextDefaults: TextField;
660
674
  declare const withText: (options?: WithTextProps) => TextField;
661
675
  declare const withTextRequired: (options?: WithTextProps) => TextField;
662
676
 
663
- type WithTitleProps = (Omit<TextField, 'type' | 'name'> & {
677
+ type WithTitleProps = (Omit<TextField, 'type' | 'name' | 'hasMany'> & {
664
678
  name?: string;
665
679
  });
666
680
  type WithTitle = WithTitleProps & {
@@ -669,26 +683,10 @@ type WithTitle = WithTitleProps & {
669
683
  declare const withTitle: (options?: WithTitleProps) => TextField;
670
684
  declare const withTitleRequired: (options?: WithTitleProps) => TextField;
671
685
 
672
- type WithUserRolesProps = (Omit<SelectField, 'type' | 'name' | 'options'> & {
673
- name?: string;
674
- });
675
- type WithUserRoles = WithUserRolesProps & {
676
- type: 'withUserRoles';
677
- };
678
- declare const UserRolesDefaults: SelectField;
679
- declare const withUserRoles: (srcOptions?: Partial<SelectField>) => SelectField;
680
-
681
686
  declare function log(...rest: unknown[]): void;
682
687
 
683
- declare const defaultSlug: BowlSlug;
684
- declare const defaultGroup: BowlGroup;
685
- declare const defaultLocales: string[];
686
- declare const defaultLocale: string;
687
- declare const defaultMarket: string;
688
- declare const options: BowlOptions;
689
- declare const internalSlugs: string[];
690
-
691
- type Locale = typeof options.locales[number];
688
+ declare const locales: any[];
689
+ type Locale = typeof locales[number];
692
690
  type LocalizedText = {
693
691
  [key in Locale]?: string;
694
692
  };
@@ -705,7 +703,7 @@ declare function translateTab(tab: Tab): Tab;
705
703
  declare function translateTabs(tabs: Tab[]): Tab[];
706
704
  declare function translateBlock(block: Block): Block;
707
705
  declare function translateBlocks(blocks: Block[]): Block[];
708
- declare function translateField(field: Field$1): payload_types.TextField | payload_types.NumberField | payload_types.EmailField | payload_types.TextareaField | payload_types.CheckboxField | payload_types.DateField | BlockField | payload_types.GroupField | payload_types.RadioField | payload_types.RelationshipField | payload_types.ArrayField | payload_types.RichTextField | payload_types.SelectField | payload_types.UploadField | payload_types.CodeField | payload_dist_fields_config_types.JSONField | payload_types.PointField | payload_types.RowField | payload_types.CollapsibleField | payload_types.TabsField | payload_types.UIField;
706
+ declare function translateField(field: Field$1): payload_types.CollapsibleField | payload_types.RowField | payload_types.TabsField | payload_types.UIField | payload_types.ArrayField | BlockField | payload_types.CheckboxField | payload_types.CodeField | payload_types.DateField | payload_types.EmailField | payload_types.GroupField | payload_types.JSONField | payload_types.NumberField | payload_types.PointField | payload_types.RadioField | payload_types.RelationshipField | payload_types.RichTextField<any, any, {}> | payload_types.SelectField | payload_types.TextField | payload_types.TextareaField | payload_types.UploadField;
709
707
  declare function translateFields(fields: Field$1[]): Field$1[];
710
708
  declare function translateCollection(config: CollectionConfig): CollectionConfig;
711
709
  declare function translateGlobal(config: GlobalConfig): GlobalConfig;
@@ -741,6 +739,23 @@ declare function eachDataField(fields: Field$1[], callback: (field: DataField, p
741
739
  declare function textToSlug(value: string): string;
742
740
  declare const formatSlug: (fallback: string) => FieldHook;
743
741
 
742
+ type PublicURL = {
743
+ marketId: string;
744
+ localeId: string;
745
+ templateId: string;
746
+ documentId: string;
747
+ _status?: string;
748
+ _live?: boolean;
749
+ _token?: string;
750
+ };
751
+ declare function getPublicURL({ marketId, localeId, ...qs }: PublicURL): string;
752
+ declare function getPreviewURL(doc: Record<string, any>, locale: string, _token?: string): string;
753
+ declare function getLivePreviewURL(args: {
754
+ data: Record<string, any>;
755
+ documentInfo: ContextType;
756
+ locale: Locale$1;
757
+ }): string;
758
+
744
759
  type CollectionHooks = Omit<CollectionConfig['hooks'], 'afterError'>;
745
760
  type CollectionHookName = keyof CollectionHooks;
746
761
  type CollectionHook<N extends CollectionHookName> = CollectionHooks[N][number];
@@ -765,7 +780,7 @@ type WithNewsletterSubscription = WithNewsletterSubscriptionProps & {
765
780
  type: 'withNewsletterSubscription';
766
781
  };
767
782
 
768
- type WithColorProps = (Omit<TextField, 'type' | 'name'> & {
783
+ type WithColorProps = (Omit<TextField, 'type' | 'name' | 'hasMany'> & {
769
784
  name?: string;
770
785
  });
771
786
  type WithColor = WithColorProps & {
@@ -859,15 +874,15 @@ type BowlRowField = Omit<RowField, 'fields'> & {
859
874
  type BowlTabsField = Omit<TabsField, 'tabs'> & {
860
875
  tabs: BowlTab[];
861
876
  };
862
- type BowlField = Exclude<Field$1, ArrayField | BlockField | CollapsibleField | GroupField | RowField | TabsField> | BowlArrayField | BowlBlockField | BowlCollapsibleField | BowlGroupField | BowlRowField | BowlTabsField | WithAbstract | WithCategory | WithCheckbox | WithColor | WithComponents | WithDate | WithDescription | WithId | WithIsActive | WithIsDefault | WithLink | WithMarkets | WithMedia | WithMedias | WithName | WithNewsletterSubscription | WithOrder | WithRelated | WithRichText | WithSelect | WithSlug | WithTemplate | WithText | WithTitle | WithUserRoles;
877
+ type BowlField = Exclude<Field$1, ArrayField | BlockField | CollapsibleField | GroupField | RowField | TabsField> | BowlArrayField | BowlBlockField | BowlCollapsibleField | BowlGroupField | BowlRowField | BowlTabsField | WithAbstract | WithCategory | WithCheckbox | WithColor | WithComponents | WithDate | WithDescription | WithId | WithIsActive | WithIsDefault | WithLink | WithMarkets | WithMedia | WithMedias | WithName | WithNewsletterSubscription | WithOrder | WithRelated | WithRichText | WithSelect | WithSlug | WithTemplate | WithText | WithTitle | WithRoles;
863
878
  type BowlBlock = Block | WithBlock;
864
879
  type BowlCollection = WithCollection | WithPage | WithStatic | WithMenu | WithAction | CollectionConfig & {
865
880
  type?: string;
866
- routes?: AdminRoute[];
881
+ views?: Record<string, AdminView>;
867
882
  };
868
883
  type BowlGlobal = WithGlobal | GlobalConfig & {
869
884
  type?: string;
870
- routes?: AdminRoute[];
885
+ views?: Record<string, AdminView>;
871
886
  };
872
887
  type CollectionHelper = (options: BowlOptions) => BowlCollection;
873
888
  type GlobalHelper = (options: BowlOptions) => BowlGlobal;
@@ -922,7 +937,7 @@ type BowlOptions = {
922
937
  defaultLocale: string;
923
938
  defaultMarket: string;
924
939
  group: BowlGroup;
925
- locales: string[];
940
+ locales: string[] | Locale$1[];
926
941
  menu: {
927
942
  blocks: BowlBlock[];
928
943
  };
@@ -953,14 +968,21 @@ declare const MenuItem: (pages: string[], customBlocks?: BowlBlock[], depth?: nu
953
968
 
954
969
  declare const bowl: (sourceOptions?: BowlInitOptions) => (sourceConfig: BowlConfig) => Config;
955
970
 
956
- type CategoryListProps = Props$4;
957
- declare const CategoryList: React__default.FC<CategoryListProps>;
971
+ type CategoryMenuProps = {
972
+ collection: SanitizedCollectionConfig;
973
+ };
974
+ declare const CategoryMenu: React__default.FC<CategoryMenuProps>;
958
975
 
959
976
  type CategoryTreeProps = {
960
977
  collection: SanitizedCollectionConfig;
961
978
  };
962
979
  declare const CategoryTree: React__default.FC<CategoryTreeProps>;
963
980
 
981
+ type CustomEditModalProps = DocumentDrawerProps & {
982
+ filter?: (fields: Field$1[]) => Field$1[];
983
+ };
984
+ declare const CustomEditModal: React__default.FC<CustomEditModalProps>;
985
+
964
986
  type TreeItems<T = any> = Record<TreeItemIndex, TreeItem<T>>;
965
987
  type DataTreeItemProps<T = any, C extends string = never> = {
966
988
  item: TreeItem<T>;
@@ -1008,11 +1030,6 @@ type DecoratedListProps = {
1008
1030
  };
1009
1031
  declare const DecoratedList: React__default.FC<DecoratedListProps>;
1010
1032
 
1011
- type EditModalProps = IndexProps & {
1012
- filter?: (fields: Field[]) => Field[];
1013
- };
1014
- declare const EditModal: React__default.FC<EditModalProps>;
1015
-
1016
1033
  type IImportItem = Record<string, string | number | boolean | Date>;
1017
1034
 
1018
1035
  type ImportExportListProps<T = any> = Props$4 & {
@@ -1035,11 +1052,14 @@ declare const LeaveModal: (props: {
1035
1052
  }) => react_jsx_runtime.JSX.Element;
1036
1053
 
1037
1054
  type LocalizedDescriptionProps = {
1038
- value: unknown;
1055
+ value?: unknown;
1039
1056
  callback: (value?: unknown) => string;
1040
1057
  };
1041
1058
  declare const LocalizedDescription: React__default.FC<LocalizedDescriptionProps>;
1042
- declare function withLocalizedDescription(callback: (value?: unknown) => string): React__default.FC<LocalizedDescriptionProps>;
1059
+ declare function withLocalizedDescription(callback: (value?: unknown) => string): React__default.FunctionComponent<{
1060
+ path: string;
1061
+ value?: unknown;
1062
+ }>;
1043
1063
 
1044
1064
  type Props$1 = {};
1045
1065
  declare const Publish: React__default.FC<Props$1>;
@@ -1055,10 +1075,18 @@ declare function toField(item: BowlField): Field$1;
1055
1075
  declare function toBlock(item: BowlBlock): Block;
1056
1076
  declare function toTab(item: BowlTab): Tab;
1057
1077
 
1078
+ declare const defaultSlug: BowlSlug;
1079
+ declare const defaultGroup: BowlGroup;
1080
+ declare const defaultLocales: string[];
1081
+ declare const defaultLocale: string;
1082
+ declare const defaultMarket: string;
1083
+ declare const options: BowlOptions;
1084
+ declare const internalSlugs: string[];
1085
+
1058
1086
  declare const Icon: React__default.FC;
1059
1087
 
1060
1088
  declare const Logo: React__default.FC;
1061
1089
 
1062
1090
  declare function webpack(sourceConfig: BowlConfig): (config: any) => any;
1063
1091
 
1064
- export { ActionDefault, BlockDefaults, BowlArrayField, BowlBlock, BowlBlockField, BowlCollapsibleField, BowlCollection, BowlConfig, BowlField, BowlGlobal, BowlGroup, BowlGroupField, BowlInitOptions, BowlOptions, BowlPlugin, BowlRole, BowlRowField, BowlSlug, BowlTab, BowlTabsField, CategoryDefaults, CategoryList, CategoryListProps, CategoryTree, CategoryTreeProps, CheckboxDefaults, CollectionDefault, CollectionHelper, CollectionHook, CollectionHookName, CollectionHooks, ColorCell, ColorConfig, ColorField, ComponentsDefaults, DataField, DataTree, DataTreeDragItem, DataTreeItem, DataTreeItemLi, DataTreeItemProps, DataTreeProps, DataTreeProvider, DataTreeRenameItem, DateDefaults, DebugField, DecoratedList, DecoratedListProps, EditModal, EditModalProps, GlobalDefault, GlobalHelper, GlobalHook, GlobalHookName, GlobalHooks, GroupKey, IBulkAction, IBulkRecord, ICache, IImportItem, IPage, IPageFull, IPagination, IRelation, IUndecoratedMenu, IUndecoratedMenuBase, IUndecoratedMenuCategory, IUndecoratedMenuCustom, IUndecoratedMenuGroup, IUndecoratedMenuItem, IUndecoratedMenuLink, IUndecoratedMenuPage, Icon, ImportExportList, ImportExportListProps, ImportExportRedirectList, ImportLogInvalidTypes, ImportLogType, ImportMode, InMemoryCache, InMemoryCacheOptions, LeaveModal, LeaveWithoutSavingModal, LeaveWithoutSavingModalProps, LocalizedDescription, LocalizedDescriptionProps, Logo, MAX_INT, MarketDefaults, MediaDefaults, MediasDefaults, MenuItem, MixerContext, Option, OrderDefaults, PRESENTATION_FIELDS, PageDefault, PresentationField, Publish, RelatedDefaults, RichTextDefaults, Save, SaveDraft, SelectDefaults, StaticCollectionConfig, StaticCollectionDefault, TemplateDefaults, TextDefaults, TreeItems, UIStaticCell, UIStaticField, UserRolesDefaults, WithAbstract, WithAbstractProps, WithAction, WithActionProps, WithBlock, WithBlockProps, WithCategory, WithCategoryProps, WithCheckbox, WithCheckboxProps, WithCollection, WithCollectionProps, WithColor, WithColorProps, WithComponents, WithComponentsProps, WithDate, WithDateProps, WithDescription, WithDescriptionProps, WithGlobal, WithGlobalProps, WithId, WithIdProps, WithIsActive, WithIsActiveProps, WithIsDefault, WithIsDefaultProps, WithLink, WithLinkOptions, WithLinkProps, WithMarkets, WithMarketsProps, WithMedia, WithMediaProps, WithMedias, WithMediasProps, WithMenu, WithMenuProps, WithName, WithNameProps, WithOrder, WithOrderProps, WithPage, WithPageProps, WithRelated, WithRelatedProps, WithRichText, WithRichTextProps, WithSelect, WithSelectProps, WithSlug, WithSlugProps, WithStatic, WithStaticProps, WithTemplate, WithTemplateProps, WithText, WithTextProps, WithTitle, WithTitleProps, WithUserRoles, WithUserRolesProps, afterCategoryChangeHook, afterCategoryDeleteHook, afterPageChangeHook, afterPageDeleteHook, afterPageReadHook, appearanceOptions, beforeValidate, bowl, collectionBulkPatch, collectionExportGet, collectionImportPost, collectionIndexGet, collectionUpdatePatch, debugField, decorateHref_, decorateHrefs_, decorateMenu, decorateMenuCategory, decorateMenuGroup, decorateMenuItem, decorateMenuLink, decorateMenuPage, decorateMenuRoute, decorateMenus, decorateNav_, decorateNavs_, decorateSchema_, decorateSchemas_, deepMerge, bowl as default, defaultGroup, defaultLocale, defaultLocales, defaultMarket, defaultSlug, eachDataField, eachField, encryptData, fetchCollection, fetchCollectionItems, fetchEachMarketLocale, fetchEndpoint, fetchGlobal, fetchGlobalItems, fetchPages, formatSlug, getApiUrl, getCollectionItem, getCollectionItems, getGlobalItems, getLocale, getLocales, getMarkets, getNumericParam, getObjectParam, getPagination, getRoute, getRouteByCategoryAndLocale, getRouteByItemAndLocale, getRoutes, getSearchUrl, getStaticLoader, getStore, getStringParam, getTranslation, getTranslations, getTreeItemClassName, hasMarket, hasRole, importExportListWithParser, internalSlugs, isAdmin, isDataField, isObject, isPresentationField, isRelation, isRole, isUndecoratedMenuItem, keyWithRequest, localeGet, localizeCollection, log, logMissingTranslations, menuDetailGet, menuIndexGet, modalSlug, optinPost, options, pageDetailGet, pageIndexGet, parseDepth, populateStaticFields, redirectParser, richTextAfterReadHook, richTextSerialize, roles, routeGet, routePost, routePostHandler, slugToLabel, slugToLabels, sortByGroup, sortCollection, storeGet, textToSlug, toBlock, toCollection, toField, toGlobal, toTab, translateBlock, translateBlocks, translateCollection, translateField, translateFields, translateGlobal, translateTab, translateTabs, webpack, whereCollection, withAbstract, withAbstractRequired, withAction, withBlock, withCategory, withCategoryRequired, withCheckbox, withCheckboxRequired, withCollection, withCollectionHook, withColor, withColorRequired, withComponents, withDate, withDateRequired, withDescription, withDescriptionRequired, withFieldHook, withGlobal, withGlobalHook, withId, withIdRequired, withIsActive, withIsActiveRequired, withIsDefault, withIsDefaultRequired, withLink, withLocalizedDescription, withMarkets, withMarketsRequired, withMedia, withMediaRequired, withMedias, withMediasRequired, withMenu, withName, withNameRequired, withOrder, withOrderRequired, withPage, withRelated, withRichText, withRichTextRequired, withSelect, withSelectRequired, withSlug, withSlugRequired, withStaticCollection, withTemplate, withTemplateRequired, withText, withTextRequired, withTitle, withTitleRequired, withUIStatic, withUserRoles };
1092
+ export { ActionDefault, BlockDefaults, BowlArrayField, BowlBlock, BowlBlockField, BowlCollapsibleField, BowlCollection, BowlConfig, BowlField, BowlGlobal, BowlGroup, BowlGroupField, BowlInitOptions, BowlOptions, BowlPlugin, BowlRole, BowlRowField, BowlSlug, BowlTab, BowlTabsField, CategoryDefaults, CategoryMenu, CategoryMenuProps, CategoryTree, CategoryTreeProps, CheckboxDefaults, CollectionDefault, CollectionHelper, CollectionHook, CollectionHookName, CollectionHooks, ColorCell, ColorConfig, ColorField, ComponentsDefaults, CustomEditModal, CustomEditModalProps, DataField, DataTree, DataTreeDragItem, DataTreeItem, DataTreeItemLi, DataTreeItemProps, DataTreeProps, DataTreeProvider, DataTreeRenameItem, DateDefaults, DebugField, DecoratedList, DecoratedListProps, GlobalDefault, GlobalHelper, GlobalHook, GlobalHookName, GlobalHooks, GroupKey, IBulkAction, IBulkRecord, ICache, IImportItem, IPage, IPageFull, IPagination, IRelation, IUndecoratedMenu, IUndecoratedMenuBase, IUndecoratedMenuCategory, IUndecoratedMenuCustom, IUndecoratedMenuGroup, IUndecoratedMenuItem, IUndecoratedMenuLink, IUndecoratedMenuPage, Icon, ImportExportList, ImportExportListProps, ImportExportRedirectList, ImportLogInvalidTypes, ImportLogType, ImportMode, InMemoryCache, InMemoryCacheOptions, LeaveModal, LeaveWithoutSavingModal, LeaveWithoutSavingModalProps, LocalizedDescription, LocalizedDescriptionProps, Logo, MAX_INT, MarketDefaults, MediaDefaults, MediasDefaults, MenuItem, MixerContext, Option, OrderDefaults, PRESENTATION_FIELDS, PageDefault, PresentationField, PublicURL, Publish, RelatedDefaults, RichTextDefaults, Save, SaveDraft, SelectDefaults, StaticCollectionConfig, StaticCollectionDefault, TemplateDefaults, TextDefaults, TreeItems, UIStaticCell, UIStaticField, UserRolesDefaults, WithAbstract, WithAbstractProps, WithAction, WithActionProps, WithBlock, WithBlockProps, WithCategory, WithCategoryProps, WithCheckbox, WithCheckboxProps, WithCollection, WithCollectionProps, WithColor, WithColorProps, WithComponents, WithComponentsProps, WithDate, WithDateProps, WithDescription, WithDescriptionProps, WithGlobal, WithGlobalProps, WithId, WithIdProps, WithIsActive, WithIsActiveProps, WithIsDefault, WithIsDefaultProps, WithLink, WithLinkOptions, WithLinkProps, WithMarkets, WithMarketsProps, WithMedia, WithMediaProps, WithMedias, WithMediasProps, WithMenu, WithMenuProps, WithName, WithNameProps, WithOrder, WithOrderProps, WithPage, WithPageProps, WithRelated, WithRelatedProps, WithRichText, WithRichTextProps, WithRoles, WithRolesProps, WithSelect, WithSelectProps, WithSlug, WithSlugProps, WithStatic, WithStaticProps, WithTemplate, WithTemplateProps, WithText, WithTextProps, WithTitle, WithTitleProps, afterCategoryChangeHook, afterCategoryDeleteHook, afterPageChangeHook, afterPageDeleteHook, afterPageReadHook, appearanceOptions, beforeValidate, bowl, collectionBulkPatch, collectionExportGet, collectionImportPost, collectionIndexGet, collectionUpdatePatch, debugField, decorateHref_, decorateHrefs_, decorateMenu, decorateMenuCategory, decorateMenuGroup, decorateMenuItem, decorateMenuLink, decorateMenuPage, decorateMenuRoute, decorateMenus, decorateNav_, decorateNavs_, decorateSchema_, decorateSchemas_, deepMerge, bowl as default, defaultGroup, defaultLocale, defaultLocales, defaultMarket, defaultSlug, eachDataField, eachField, encryptData, fetchCollection, fetchCollectionItems, fetchEachMarketLocale, fetchEndpoint, fetchGlobal, fetchGlobalItems, fetchPages, formatSlug, getApiUrl, getCollectionItem, getCollectionItems, getGlobalItems, getLivePreviewURL, getLocale, getLocales, getMarkets, getNumericParam, getObjectParam, getPagination, getPreviewURL, getPublicURL, getRoute, getRouteByCategoryAndLocale, getRouteByItemAndLocale, getRoutes, getSearchUrl, getStaticLoader, getStore, getStringParam, getTranslation, getTranslations, getTreeItemClassName, hasMarket, hasRole, importExportListWithParser, internalSlugs, isAdmin, isDataField, isObject, isPresentationField, isRelation, isRole, isUndecoratedMenuItem, keyWithRequest, localeGet, localizeCollection, log, logMissingTranslations, menuDetailGet, menuIndexGet, modalSlug, optinPost, options, pageDetailGet, pageIndexGet, parseDepth, populateStaticFields, redirectParser, richTextAfterReadHook, richTextSerialize, roles, routeGet, routePost, routePostHandler, slugToLabel, slugToLabels, sortByGroup, sortCollection, storeGet, textToSlug, toBlock, toCollection, toField, toGlobal, toTab, translateBlock, translateBlocks, translateCollection, translateField, translateFields, translateGlobal, translateTab, translateTabs, webpack, whereCollection, withAbstract, withAbstractRequired, withAction, withBlock, withCategory, withCategoryRequired, withCheckbox, withCheckboxRequired, withCollection, withCollectionHook, withColor, withColorRequired, withComponents, withDate, withDateRequired, withDescription, withDescriptionRequired, withFieldHook, withGlobal, withGlobalHook, withId, withIdRequired, withIsActive, withIsActiveRequired, withIsDefault, withIsDefaultRequired, withLink, withLocalizedDescription, withMarkets, withMarketsRequired, withMedia, withMediaRequired, withMedias, withMediasRequired, withMenu, withName, withNameRequired, withOrder, withOrderRequired, withPage, withRelated, withRichText, withRichTextRequired, withRoles, withSelect, withSelectRequired, withSlug, withSlugRequired, withStaticCollection, withTemplate, withTemplateRequired, withText, withTextRequired, withTitle, withTitleRequired, withUIStatic };