@wordpress/core-data 7.52.0 → 7.53.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 +16 -0
- package/README.md +1 -0
- package/build/actions.cjs +18 -9
- package/build/actions.cjs.map +2 -2
- package/build/awareness/awareness-state.cjs.map +2 -2
- package/build/awareness/base-awareness.cjs.map +2 -2
- package/build/awareness/block-lookup.cjs.map +2 -2
- package/build/awareness/post-editor-awareness.cjs +7 -0
- package/build/awareness/post-editor-awareness.cjs.map +2 -2
- package/build/awareness/typed-awareness.cjs.map +2 -2
- package/build/awareness/types.cjs.map +1 -1
- package/build/awareness/utils.cjs.map +2 -2
- package/build/batch/create-batch.cjs.map +2 -2
- package/build/batch/default-processor.cjs.map +2 -2
- package/build/components/entities-saved-states/entity-record-item.cjs.map +2 -2
- package/build/components/entities-saved-states/entity-type-list.cjs.map +2 -2
- package/build/components/entities-saved-states/hooks/use-is-dirty.cjs +4 -0
- package/build/components/entities-saved-states/hooks/use-is-dirty.cjs.map +2 -2
- package/build/components/entities-saved-states/index.cjs.map +2 -2
- package/build/dynamic-entities.cjs.map +2 -2
- package/build/entities.cjs.map +2 -2
- package/build/entity-context.cjs.map +2 -2
- package/build/entity-provider.cjs.map +2 -2
- package/build/entity-types/attachment.cjs.map +1 -1
- package/build/entity-types/base.cjs.map +1 -1
- package/build/entity-types/comment.cjs.map +1 -1
- package/build/entity-types/font-collection.cjs.map +1 -1
- package/build/entity-types/font-family.cjs.map +1 -1
- package/build/entity-types/global-styles-revision.cjs.map +1 -1
- package/build/entity-types/helpers.cjs.map +1 -1
- package/build/entity-types/icon.cjs.map +1 -1
- package/build/entity-types/index.cjs.map +1 -1
- package/build/entity-types/menu-location.cjs.map +1 -1
- package/build/entity-types/nav-menu-item.cjs.map +1 -1
- package/build/entity-types/nav-menu.cjs.map +1 -1
- package/build/entity-types/page.cjs.map +1 -1
- package/build/entity-types/plugin.cjs.map +1 -1
- package/build/entity-types/post-revision.cjs.map +1 -1
- package/build/entity-types/post-status.cjs.map +1 -1
- package/build/entity-types/post.cjs.map +1 -1
- package/build/entity-types/settings.cjs.map +1 -1
- package/build/entity-types/sidebar.cjs.map +1 -1
- package/build/entity-types/taxonomy.cjs.map +1 -1
- package/build/entity-types/term.cjs.map +1 -1
- package/build/entity-types/theme.cjs.map +1 -1
- package/build/entity-types/type.cjs.map +1 -1
- package/build/entity-types/user.cjs.map +1 -1
- package/build/entity-types/widget-type.cjs.map +1 -1
- package/build/entity-types/widget.cjs.map +1 -1
- package/build/entity-types/wp-template-part.cjs.map +1 -1
- package/build/entity-types/wp-template.cjs.map +1 -1
- package/build/fetch/__experimental-fetch-link-suggestions.cjs.map +2 -2
- package/build/fetch/__experimental-fetch-url-data.cjs.map +2 -2
- package/build/fetch/index.cjs.map +2 -2
- package/build/footnotes/get-footnotes-order.cjs.map +2 -2
- package/build/footnotes/get-rich-text-values-cached.cjs.map +2 -2
- package/build/footnotes/index.cjs +12 -1
- package/build/footnotes/index.cjs.map +3 -3
- package/build/hooks/index.cjs.map +2 -2
- package/build/hooks/use-entity-block-editor.cjs.map +2 -2
- package/build/hooks/use-entity-id.cjs.map +2 -2
- package/build/hooks/use-entity-prop.cjs.map +2 -2
- package/build/hooks/use-entity-record.cjs.map +2 -2
- package/build/hooks/use-entity-records.cjs +2 -2
- package/build/hooks/use-entity-records.cjs.map +2 -2
- package/build/hooks/use-post-editor-awareness-state.cjs.map +2 -2
- package/build/hooks/use-query-select.cjs.map +2 -2
- package/build/hooks/use-resource-permissions.cjs.map +2 -2
- package/build/hooks/utils.cjs.map +2 -2
- package/build/index.cjs.map +2 -2
- package/build/lock-unlock.cjs.map +2 -2
- package/build/locks/actions.cjs.map +2 -2
- package/build/locks/engine.cjs.map +2 -2
- package/build/locks/reducer.cjs.map +2 -2
- package/build/locks/selectors.cjs.map +2 -2
- package/build/private-actions.cjs +54 -7
- package/build/private-actions.cjs.map +2 -2
- package/build/private-apis.cjs +3 -0
- package/build/private-apis.cjs.map +2 -2
- package/build/private-selectors.cjs +5 -0
- package/build/private-selectors.cjs.map +2 -2
- package/build/queried-data/get-query-parts.cjs.map +2 -2
- package/build/queried-data/reducer.cjs.map +2 -2
- package/build/queried-data/selectors.cjs.map +2 -2
- package/build/reducer.cjs.map +2 -2
- package/build/resolvers.cjs +21 -26
- package/build/resolvers.cjs.map +2 -2
- package/build/selectors.cjs.map +2 -2
- package/build/sync.cjs +26 -0
- package/build/sync.cjs.map +2 -2
- package/build/types.cjs.map +1 -1
- package/build/utils/block-selection-history.cjs.map +2 -2
- package/build/utils/clear-unchanged-edits.cjs.map +2 -2
- package/build/utils/conservative-map-item.cjs.map +2 -2
- package/build/utils/crdt-blocks.cjs.map +2 -2
- package/build/utils/crdt-selection.cjs.map +2 -2
- package/build/utils/crdt-text.cjs.map +2 -2
- package/build/utils/crdt-user-selections.cjs +43 -16
- package/build/utils/crdt-user-selections.cjs.map +3 -3
- package/build/utils/crdt-utils.cjs.map +2 -2
- package/build/utils/crdt.cjs.map +2 -2
- package/build/utils/get-template-info.cjs.map +2 -2
- package/build/utils/get-template-part-icon.cjs.map +2 -2
- package/build/utils/log-entity-deprecation.cjs.map +2 -2
- package/build/utils/save-crdt-doc.cjs.map +2 -2
- package/build-module/actions.mjs +19 -9
- package/build-module/actions.mjs.map +2 -2
- package/build-module/awareness/awareness-state.mjs.map +2 -2
- package/build-module/awareness/base-awareness.mjs.map +2 -2
- package/build-module/awareness/block-lookup.mjs.map +2 -2
- package/build-module/awareness/post-editor-awareness.mjs +7 -0
- package/build-module/awareness/post-editor-awareness.mjs.map +2 -2
- package/build-module/awareness/typed-awareness.mjs.map +2 -2
- package/build-module/awareness/utils.mjs.map +2 -2
- package/build-module/batch/create-batch.mjs.map +2 -2
- package/build-module/batch/default-processor.mjs.map +2 -2
- package/build-module/components/entities-saved-states/entity-record-item.mjs.map +2 -2
- package/build-module/components/entities-saved-states/entity-type-list.mjs.map +2 -2
- package/build-module/components/entities-saved-states/hooks/use-is-dirty.mjs +4 -0
- package/build-module/components/entities-saved-states/hooks/use-is-dirty.mjs.map +2 -2
- package/build-module/components/entities-saved-states/index.mjs.map +2 -2
- package/build-module/dynamic-entities.mjs.map +2 -2
- package/build-module/entities.mjs.map +2 -2
- package/build-module/entity-context.mjs.map +2 -2
- package/build-module/entity-provider.mjs.map +2 -2
- package/build-module/fetch/__experimental-fetch-link-suggestions.mjs.map +2 -2
- package/build-module/fetch/__experimental-fetch-url-data.mjs.map +2 -2
- package/build-module/fetch/index.mjs.map +2 -2
- package/build-module/footnotes/get-footnotes-order.mjs.map +2 -2
- package/build-module/footnotes/get-rich-text-values-cached.mjs.map +2 -2
- package/build-module/footnotes/index.mjs +12 -1
- package/build-module/footnotes/index.mjs.map +2 -2
- package/build-module/hooks/index.mjs.map +2 -2
- package/build-module/hooks/use-entity-block-editor.mjs.map +2 -2
- package/build-module/hooks/use-entity-id.mjs.map +2 -2
- package/build-module/hooks/use-entity-prop.mjs.map +2 -2
- package/build-module/hooks/use-entity-record.mjs.map +2 -2
- package/build-module/hooks/use-entity-records.mjs +2 -2
- package/build-module/hooks/use-entity-records.mjs.map +2 -2
- package/build-module/hooks/use-post-editor-awareness-state.mjs.map +2 -2
- package/build-module/hooks/use-query-select.mjs.map +2 -2
- package/build-module/hooks/use-resource-permissions.mjs.map +2 -2
- package/build-module/hooks/utils.mjs.map +2 -2
- package/build-module/index.mjs.map +2 -2
- package/build-module/lock-unlock.mjs.map +2 -2
- package/build-module/locks/actions.mjs.map +2 -2
- package/build-module/locks/engine.mjs.map +2 -2
- package/build-module/locks/reducer.mjs.map +2 -2
- package/build-module/locks/selectors.mjs.map +2 -2
- package/build-module/private-actions.mjs +54 -7
- package/build-module/private-actions.mjs.map +2 -2
- package/build-module/private-apis.mjs +9 -1
- package/build-module/private-apis.mjs.map +2 -2
- package/build-module/private-selectors.mjs +4 -0
- package/build-module/private-selectors.mjs.map +2 -2
- package/build-module/queried-data/get-query-parts.mjs.map +2 -2
- package/build-module/queried-data/reducer.mjs.map +2 -2
- package/build-module/queried-data/selectors.mjs.map +2 -2
- package/build-module/reducer.mjs.map +2 -2
- package/build-module/resolvers.mjs +21 -26
- package/build-module/resolvers.mjs.map +2 -2
- package/build-module/selectors.mjs.map +2 -2
- package/build-module/sync.mjs +23 -0
- package/build-module/sync.mjs.map +2 -2
- package/build-module/utils/block-selection-history.mjs.map +2 -2
- package/build-module/utils/clear-unchanged-edits.mjs.map +2 -2
- package/build-module/utils/conservative-map-item.mjs.map +2 -2
- package/build-module/utils/crdt-blocks.mjs.map +2 -2
- package/build-module/utils/crdt-selection.mjs.map +2 -2
- package/build-module/utils/crdt-text.mjs.map +2 -2
- package/build-module/utils/crdt-user-selections.mjs +43 -16
- package/build-module/utils/crdt-user-selections.mjs.map +3 -3
- package/build-module/utils/crdt-utils.mjs.map +2 -2
- package/build-module/utils/crdt.mjs.map +2 -2
- package/build-module/utils/get-template-info.mjs.map +2 -2
- package/build-module/utils/get-template-part-icon.mjs.map +2 -2
- package/build-module/utils/log-entity-deprecation.mjs.map +2 -2
- package/build-module/utils/save-crdt-doc.mjs.map +2 -2
- package/build-types/actions.d.ts +4 -0
- package/build-types/actions.d.ts.map +1 -1
- package/build-types/awareness/awareness-state.d.ts.map +1 -1
- package/build-types/awareness/base-awareness.d.ts +0 -3
- package/build-types/awareness/base-awareness.d.ts.map +1 -1
- package/build-types/awareness/block-lookup.d.ts +0 -3
- package/build-types/awareness/block-lookup.d.ts.map +1 -1
- package/build-types/awareness/post-editor-awareness.d.ts +0 -3
- package/build-types/awareness/post-editor-awareness.d.ts.map +1 -1
- package/build-types/awareness/typed-awareness.d.ts +0 -3
- package/build-types/awareness/typed-awareness.d.ts.map +1 -1
- package/build-types/awareness/types.d.ts +0 -6
- package/build-types/awareness/types.d.ts.map +1 -1
- package/build-types/awareness/utils.d.ts +0 -3
- package/build-types/awareness/utils.d.ts.map +1 -1
- package/build-types/batch/create-batch.d.ts.map +1 -1
- package/build-types/batch/default-processor.d.ts.map +1 -1
- package/build-types/components/entities-saved-states/entity-record-item.d.ts.map +1 -1
- package/build-types/components/entities-saved-states/entity-type-list.d.ts.map +1 -1
- package/build-types/components/entities-saved-states/hooks/use-is-dirty.d.ts.map +1 -1
- package/build-types/components/entities-saved-states/index.d.ts.map +1 -1
- package/build-types/dynamic-entities.d.ts +0 -3
- package/build-types/dynamic-entities.d.ts.map +1 -1
- package/build-types/entities.d.ts.map +1 -1
- package/build-types/entity-context.d.ts.map +1 -1
- package/build-types/entity-provider.d.ts.map +1 -1
- package/build-types/entity-types/attachment.d.ts +0 -3
- package/build-types/entity-types/attachment.d.ts.map +1 -1
- package/build-types/entity-types/base.d.ts +0 -3
- package/build-types/entity-types/base.d.ts.map +1 -1
- package/build-types/entity-types/comment.d.ts +0 -3
- package/build-types/entity-types/comment.d.ts.map +1 -1
- package/build-types/entity-types/font-collection.d.ts +0 -3
- package/build-types/entity-types/font-collection.d.ts.map +1 -1
- package/build-types/entity-types/font-family.d.ts +0 -3
- package/build-types/entity-types/font-family.d.ts.map +1 -1
- package/build-types/entity-types/global-styles-revision.d.ts +0 -3
- package/build-types/entity-types/global-styles-revision.d.ts.map +1 -1
- package/build-types/entity-types/helpers.d.ts +0 -3
- package/build-types/entity-types/helpers.d.ts.map +1 -1
- package/build-types/entity-types/icon.d.ts +0 -3
- package/build-types/entity-types/icon.d.ts.map +1 -1
- package/build-types/entity-types/index.d.ts +0 -3
- package/build-types/entity-types/index.d.ts.map +1 -1
- package/build-types/entity-types/menu-location.d.ts +0 -3
- package/build-types/entity-types/menu-location.d.ts.map +1 -1
- package/build-types/entity-types/nav-menu-item.d.ts +0 -3
- package/build-types/entity-types/nav-menu-item.d.ts.map +1 -1
- package/build-types/entity-types/nav-menu.d.ts +0 -3
- package/build-types/entity-types/nav-menu.d.ts.map +1 -1
- package/build-types/entity-types/page.d.ts +0 -3
- package/build-types/entity-types/page.d.ts.map +1 -1
- package/build-types/entity-types/plugin.d.ts +0 -3
- package/build-types/entity-types/plugin.d.ts.map +1 -1
- package/build-types/entity-types/post-revision.d.ts +0 -3
- package/build-types/entity-types/post-revision.d.ts.map +1 -1
- package/build-types/entity-types/post-status.d.ts +0 -3
- package/build-types/entity-types/post-status.d.ts.map +1 -1
- package/build-types/entity-types/post.d.ts +0 -3
- package/build-types/entity-types/post.d.ts.map +1 -1
- package/build-types/entity-types/settings.d.ts +0 -3
- package/build-types/entity-types/settings.d.ts.map +1 -1
- package/build-types/entity-types/sidebar.d.ts +0 -3
- package/build-types/entity-types/sidebar.d.ts.map +1 -1
- package/build-types/entity-types/taxonomy.d.ts +0 -3
- package/build-types/entity-types/taxonomy.d.ts.map +1 -1
- package/build-types/entity-types/term.d.ts +0 -3
- package/build-types/entity-types/term.d.ts.map +1 -1
- package/build-types/entity-types/test/attachment.test.d.ts +0 -8
- package/build-types/entity-types/test/attachment.test.d.ts.map +1 -1
- package/build-types/entity-types/theme.d.ts +0 -3
- package/build-types/entity-types/theme.d.ts.map +1 -1
- package/build-types/entity-types/type.d.ts +0 -3
- package/build-types/entity-types/type.d.ts.map +1 -1
- package/build-types/entity-types/user.d.ts +0 -3
- package/build-types/entity-types/user.d.ts.map +1 -1
- package/build-types/entity-types/widget-type.d.ts +0 -3
- package/build-types/entity-types/widget-type.d.ts.map +1 -1
- package/build-types/entity-types/widget.d.ts +0 -3
- package/build-types/entity-types/widget.d.ts.map +1 -1
- package/build-types/entity-types/wp-template-part.d.ts +0 -3
- package/build-types/entity-types/wp-template-part.d.ts.map +1 -1
- package/build-types/entity-types/wp-template.d.ts +0 -3
- package/build-types/entity-types/wp-template.d.ts.map +1 -1
- package/build-types/fetch/__experimental-fetch-link-suggestions.d.ts.map +1 -1
- package/build-types/fetch/__experimental-fetch-url-data.d.ts.map +1 -1
- package/build-types/fetch/index.d.ts.map +1 -1
- package/build-types/footnotes/get-footnotes-order.d.ts.map +1 -1
- package/build-types/footnotes/get-rich-text-values-cached.d.ts.map +1 -1
- package/build-types/footnotes/index.d.ts.map +1 -1
- package/build-types/hooks/index.d.ts +0 -3
- package/build-types/hooks/index.d.ts.map +1 -1
- package/build-types/hooks/use-entity-block-editor.d.ts.map +1 -1
- package/build-types/hooks/use-entity-id.d.ts.map +1 -1
- package/build-types/hooks/use-entity-prop.d.ts.map +1 -1
- package/build-types/hooks/use-entity-record.d.ts.map +1 -1
- package/build-types/hooks/use-entity-records.d.ts.map +1 -1
- package/build-types/hooks/use-post-editor-awareness-state.d.ts.map +1 -1
- package/build-types/hooks/use-query-select.d.ts.map +1 -1
- package/build-types/hooks/use-resource-permissions.d.ts.map +1 -1
- package/build-types/hooks/utils.d.ts +0 -6
- package/build-types/hooks/utils.d.ts.map +1 -1
- package/build-types/index.d.ts +1 -0
- package/build-types/index.d.ts.map +1 -1
- package/build-types/lock-unlock.d.ts.map +1 -1
- package/build-types/locks/actions.d.ts.map +1 -1
- package/build-types/locks/engine.d.ts.map +1 -1
- package/build-types/locks/reducer.d.ts.map +1 -1
- package/build-types/locks/selectors.d.ts.map +1 -1
- package/build-types/private-actions.d.ts +1 -1
- package/build-types/private-actions.d.ts.map +1 -1
- package/build-types/private-apis.d.ts +4 -3
- package/build-types/private-apis.d.ts.map +1 -1
- package/build-types/private-selectors.d.ts +12 -3
- package/build-types/private-selectors.d.ts.map +1 -1
- package/build-types/queried-data/get-query-parts.d.ts.map +1 -1
- package/build-types/queried-data/reducer.d.ts.map +1 -1
- package/build-types/queried-data/selectors.d.ts.map +1 -1
- package/build-types/reducer.d.ts.map +1 -1
- package/build-types/resolvers.d.ts +1 -2
- package/build-types/resolvers.d.ts.map +1 -1
- package/build-types/selectors.d.ts.map +1 -1
- package/build-types/sync.d.ts +31 -3
- package/build-types/sync.d.ts.map +1 -1
- package/build-types/types.d.ts +9 -8
- package/build-types/types.d.ts.map +1 -1
- package/build-types/utils/block-selection-history.d.ts +0 -6
- package/build-types/utils/block-selection-history.d.ts.map +1 -1
- package/build-types/utils/clear-unchanged-edits.d.ts.map +1 -1
- package/build-types/utils/conservative-map-item.d.ts.map +1 -1
- package/build-types/utils/crdt-blocks.d.ts +0 -3
- package/build-types/utils/crdt-blocks.d.ts.map +1 -1
- package/build-types/utils/crdt-selection.d.ts +0 -3
- package/build-types/utils/crdt-selection.d.ts.map +1 -1
- package/build-types/utils/crdt-text.d.ts +0 -3
- package/build-types/utils/crdt-text.d.ts.map +1 -1
- package/build-types/utils/crdt-user-selections.d.ts.map +1 -1
- package/build-types/utils/crdt-utils.d.ts +0 -6
- package/build-types/utils/crdt-utils.d.ts.map +1 -1
- package/build-types/utils/crdt.d.ts.map +1 -1
- package/build-types/utils/get-template-info.d.ts.map +1 -1
- package/build-types/utils/get-template-part-icon.d.ts.map +1 -1
- package/build-types/utils/log-entity-deprecation.d.ts.map +1 -1
- package/build-types/utils/save-crdt-doc.d.ts.map +1 -1
- package/package.json +24 -23
- package/src/actions.js +45 -29
- package/src/awareness/awareness-state.ts +0 -3
- package/src/awareness/base-awareness.ts +0 -8
- package/src/awareness/block-lookup.ts +1 -8
- package/src/awareness/post-editor-awareness.ts +13 -10
- package/src/awareness/test/awareness-state.ts +0 -11
- package/src/awareness/test/base-awareness.ts +0 -7
- package/src/awareness/test/block-lookup.ts +0 -8
- package/src/awareness/test/post-editor-awareness.ts +0 -7
- package/src/awareness/test/typed-awareness.ts +0 -11
- package/src/awareness/test/utils.ts +0 -3
- package/src/awareness/typed-awareness.ts +0 -7
- package/src/awareness/types.ts +0 -7
- package/src/awareness/utils.ts +0 -3
- package/src/batch/create-batch.js +0 -3
- package/src/batch/default-processor.js +0 -4
- package/src/batch/test/create-batch.js +0 -3
- package/src/batch/test/default-processor.js +0 -7
- package/src/components/entities-saved-states/entity-record-item.js +0 -7
- package/src/components/entities-saved-states/entity-type-list.js +0 -7
- package/src/components/entities-saved-states/hooks/use-is-dirty.js +4 -7
- package/src/components/entities-saved-states/index.js +0 -11
- package/src/components/entities-saved-states/test/use-is-dirty.js +70 -11
- package/src/dynamic-entities.ts +0 -3
- package/src/entities.js +0 -11
- package/src/entity-context.js +0 -3
- package/src/entity-provider.js +0 -7
- package/src/entity-types/attachment.ts +0 -4
- package/src/entity-types/base.ts +0 -3
- package/src/entity-types/comment.ts +0 -3
- package/src/entity-types/font-collection.ts +0 -3
- package/src/entity-types/font-family.ts +0 -3
- package/src/entity-types/global-styles-revision.ts +0 -4
- package/src/entity-types/helpers.ts +0 -3
- package/src/entity-types/icon.ts +0 -4
- package/src/entity-types/index.ts +0 -3
- package/src/entity-types/menu-location.ts +0 -4
- package/src/entity-types/nav-menu-item.ts +0 -4
- package/src/entity-types/nav-menu.ts +0 -4
- package/src/entity-types/page.ts +0 -4
- package/src/entity-types/plugin.ts +0 -4
- package/src/entity-types/post-revision.ts +0 -4
- package/src/entity-types/post-status.ts +0 -3
- package/src/entity-types/post.ts +0 -4
- package/src/entity-types/settings.ts +0 -4
- package/src/entity-types/sidebar.ts +0 -4
- package/src/entity-types/taxonomy.ts +0 -4
- package/src/entity-types/term.ts +0 -4
- package/src/entity-types/test/attachment.test.ts +0 -4
- package/src/entity-types/theme.ts +0 -4
- package/src/entity-types/type.ts +0 -4
- package/src/entity-types/user.ts +0 -4
- package/src/entity-types/widget-type.ts +0 -4
- package/src/entity-types/widget.ts +0 -4
- package/src/entity-types/wp-template-part.ts +0 -4
- package/src/entity-types/wp-template.ts +0 -4
- package/src/fetch/__experimental-fetch-link-suggestions.ts +0 -3
- package/src/fetch/__experimental-fetch-url-data.js +0 -3
- package/src/fetch/index.js +0 -7
- package/src/fetch/test/__experimental-fetch-link-suggestions.js +0 -3
- package/src/fetch/test/__experimental-fetch-url-data.js +1 -7
- package/src/footnotes/get-footnotes-order.js +0 -3
- package/src/footnotes/get-rich-text-values-cached.js +0 -7
- package/src/footnotes/index.js +21 -8
- package/src/footnotes/test/index.js +57 -0
- package/src/hooks/index.ts +0 -3
- package/src/hooks/test/use-entity-record.js +0 -12
- package/src/hooks/test/use-entity-records.js +0 -12
- package/src/hooks/test/use-post-editor-awareness-state.ts +0 -7
- package/src/hooks/test/use-query-select.js +0 -11
- package/src/hooks/test/use-resource-permissions.js +0 -12
- package/src/hooks/use-entity-block-editor.js +0 -7
- package/src/hooks/use-entity-id.js +0 -7
- package/src/hooks/use-entity-prop.js +0 -7
- package/src/hooks/use-entity-record.ts +0 -7
- package/src/hooks/use-entity-records.ts +2 -9
- package/src/hooks/use-post-editor-awareness-state.ts +0 -7
- package/src/hooks/use-query-select.ts +0 -7
- package/src/hooks/use-resource-permissions.ts +0 -7
- package/src/hooks/utils.ts +0 -7
- package/src/index.js +0 -7
- package/src/lock-unlock.ts +0 -3
- package/src/locks/actions.js +0 -3
- package/src/locks/engine.js +0 -3
- package/src/locks/reducer.js +0 -3
- package/src/locks/selectors.js +0 -3
- package/src/locks/test/engine.js +0 -3
- package/src/locks/test/reducer.js +0 -7
- package/src/locks/test/selectors.js +0 -7
- package/src/locks/test/utils.js +0 -7
- package/src/private-actions.js +63 -15
- package/src/private-apis.ts +9 -4
- package/src/private-selectors.ts +22 -7
- package/src/queried-data/get-query-parts.js +0 -7
- package/src/queried-data/reducer.js +0 -7
- package/src/queried-data/selectors.js +0 -7
- package/src/queried-data/test/actions.js +0 -3
- package/src/queried-data/test/get-query-parts.js +0 -3
- package/src/queried-data/test/reducer.js +0 -7
- package/src/queried-data/test/selectors.js +0 -3
- package/src/reducer.js +0 -11
- package/src/resolvers.js +23 -40
- package/src/selectors.ts +0 -7
- package/src/sync.ts +64 -7
- package/src/test/actions.js +256 -8
- package/src/test/deprecated-entity-logging.js +0 -7
- package/src/test/entities.js +0 -8
- package/src/test/entity-provider.js +0 -11
- package/src/test/private-actions.js +297 -7
- package/src/test/private-selectors.js +0 -3
- package/src/test/reducer.js +0 -7
- package/src/test/resolvers.js +0 -12
- package/src/test/rtc-rich-text-offset-space.test.js +0 -12
- package/src/test/selectors.js +0 -7
- package/src/test/store.js +8 -15
- package/src/types.ts +14 -12
- package/src/utils/block-selection-history.ts +0 -10
- package/src/utils/clear-unchanged-edits.ts +0 -3
- package/src/utils/conservative-map-item.js +0 -3
- package/src/utils/crdt-blocks.ts +0 -11
- package/src/utils/crdt-selection.ts +0 -7
- package/src/utils/crdt-text.ts +0 -3
- package/src/utils/crdt-user-selections.ts +85 -23
- package/src/utils/crdt-utils.ts +0 -7
- package/src/utils/crdt.ts +0 -11
- package/src/utils/get-template-info.js +0 -6
- package/src/utils/get-template-part-icon.js +0 -3
- package/src/utils/log-entity-deprecation.ts +0 -7
- package/src/utils/save-crdt-doc.js +0 -7
- package/src/utils/test/block-selection-history.test.ts +0 -7
- package/src/utils/test/clear-unchanged-edits.js +0 -3
- package/src/utils/test/conservative-map-item.js +0 -3
- package/src/utils/test/crdt-blocks.ts +0 -17
- package/src/utils/test/crdt-user-selections.ts +107 -30
- package/src/utils/test/crdt-utils.ts +0 -7
- package/src/utils/test/crdt.ts +0 -16
- package/src/utils/test/get-nested-value.js +0 -3
- package/src/utils/test/get-normalized-comma-separable.js +0 -3
- package/src/utils/test/get-template-info.js +0 -6
- package/src/utils/test/if-matching-action.js +0 -7
- package/src/utils/test/is-numeric-id.js +0 -3
- package/src/utils/test/log-entity-deprecation.js +0 -7
- package/src/utils/test/replace-action.js +0 -3
- package/src/utils/test/rtc-rich-text-cursor-scope.test.js +0 -14
- package/src/utils/test/rtc-rich-text-offset-space.test.js +0 -14
- package/src/utils/test/save-crdt-doc.js +0 -7
- package/src/utils/test/set-nested-value.js +0 -3
- package/src/utils/test/with-weak-map-cache.js +0 -3
- package/build-types/utils/on-sub-key.d.ts +0 -4
- package/build-types/utils/on-sub-key.d.ts.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/crdt.ts"],
|
|
4
|
-
"sourcesContent": ["/**\n * External dependencies\n */\nimport fastDeepEqual from 'fast-deep-equal/es6/index.js';\n\n/**\n * WordPress dependencies\n */\nimport {\n\t__unstableSerializeAndClean,\n\tparse,\n\ttype Block as WPBlock,\n} from '@wordpress/blocks';\nimport {\n\ttype CRDTDoc,\n\ttype ObjectData,\n\ttype ObjectID,\n\ttype ObjectType,\n\ttype SyncConfig,\n\tY,\n} from '@wordpress/sync';\n\n/**\n * Internal dependencies\n */\nimport { BaseAwareness } from '../awareness/base-awareness';\nimport {\n\ttype Block,\n\tdeserializeBlockAttributes,\n\tmergeCrdtBlocks,\n\ttype MergeCursorPosition,\n\tmergeRichTextUpdate,\n\ttype YBlock,\n\ttype YBlocks,\n} from './crdt-blocks';\nimport { type Post } from '../entity-types/post';\nimport { CRDT_DOC_META_PERSISTENCE_KEY, CRDT_RECORD_MAP_KEY } from '../sync';\nimport type { WPSelection } from '../types';\nimport {\n\tgetSelectionHistory,\n\tgetShiftedSelection,\n\tupdateSelectionHistory,\n} from './crdt-selection';\nimport {\n\tasRichTextOffset,\n\tcreateYMap,\n\tgetRootMap,\n\tisYMap,\n\ttype YMapRecord,\n\ttype YMapWrap,\n} from './crdt-utils';\n\n// A function that derives content from blocks. Two callers produce this:\n// `useEntityBlockEditor` reads blocks from its argument (so the optional arg\n// lets it accept whatever caller is invoked with), and the receiver-side\n// injection in this file captures blocks in a closure and ignores the arg.\ntype ContentFromBlocksFn = ( args?: { blocks: Block[] } ) => string;\n\n// Changes that can be applied to a post entity record.\nexport type PostChanges = Partial< Post > & {\n\tblocks?: Block[];\n\tcontent?: Post[ 'content' ] | string | ContentFromBlocksFn;\n\texcerpt?: Post[ 'excerpt' ] | string;\n\tselection?: WPSelection;\n\ttitle?: Post[ 'title' ] | string;\n};\n\n// A post record as represented in the CRDT document (Y.Map).\nexport interface YPostRecord extends YMapRecord {\n\tauthor: number;\n\t// Blocks are undefined when they need to be re-parsed from content.\n\tblocks: YBlocks | undefined;\n\tcontent: Y.Text;\n\tcategories: number[];\n\tcomment_status: string;\n\tdate: string | null;\n\texcerpt: Y.Text;\n\tfeatured_media: number;\n\tformat: string;\n\tmeta: YMapWrap< YMapRecord >;\n\tping_status: string;\n\tslug: string;\n\tstatus: string;\n\tsticky: boolean;\n\ttags: number[];\n\ttemplate: string;\n\ttitle: Y.Text;\n}\n\nexport const POST_META_KEY_FOR_CRDT_DOC_PERSISTENCE = '_crdt_document';\n\n// Post meta keys that should *not* be synced.\nconst disallowedPostMetaKeys = new Set< string >( [\n\tPOST_META_KEY_FOR_CRDT_DOC_PERSISTENCE,\n] );\n\n/**\n * Given a set of local changes to a generic entity record, apply those changes\n * to the local Y.Doc.\n *\n * @param {CRDTDoc} ydoc\n * @param {Partial< ObjectData >} changes\n * @return {void}\n */\nfunction defaultApplyChangesToCRDTDoc(\n\tydoc: CRDTDoc,\n\tchanges: ObjectData\n): void {\n\tconst ymap = getRootMap( ydoc, CRDT_RECORD_MAP_KEY );\n\n\tObject.entries( changes ).forEach( ( [ key, newValue ] ) => {\n\t\t// Cannot serialize function values, so cannot sync them.\n\t\tif ( 'function' === typeof newValue ) {\n\t\t\treturn;\n\t\t}\n\n\t\tswitch ( key ) {\n\t\t\t// Add support for additional data types here.\n\n\t\t\tdefault: {\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tupdateMapValue( ymap, key, currentValue, newValue );\n\t\t\t}\n\t\t}\n\t} );\n}\n\n/**\n * Given a set of local changes to a post record, apply those changes to the\n * local Y.Doc.\n *\n * @param {CRDTDoc} ydoc\n * @param {PostChanges} changes\n * @param {Set<string>} syncedProperties\n * @return {void}\n */\nexport function applyPostChangesToCRDTDoc(\n\tydoc: CRDTDoc,\n\tchanges: PostChanges,\n\tsyncedProperties: Set< string >\n): void {\n\tconst ymap = getRootMap< YPostRecord >( ydoc, CRDT_RECORD_MAP_KEY );\n\n\tObject.keys( changes ).forEach( ( key ) => {\n\t\tif ( ! syncedProperties.has( key ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst newValue = changes[ key ];\n\n\t\t// Cannot serialize function values, so cannot sync them. `content` is\n\t\t// often passed as a lazy serializer by `useEntityBlockEditor`; the\n\t\t// receiver re-derives it from the synced blocks (see\n\t\t// getPostChangesFromCRDTDoc), so dropping it here is intentional.\n\t\tif ( 'function' === typeof newValue ) {\n\t\t\treturn;\n\t\t}\n\n\t\tswitch ( key ) {\n\t\t\tcase 'blocks': {\n\t\t\t\t// Block changes from typing are bundled with a 'selection' update.\n\t\t\t\t// Use the resulting cursor position for block merging.\n\t\t\t\tconst newCursorPosition = parseCursorSelection(\n\t\t\t\t\tchanges.selection\n\t\t\t\t);\n\n\t\t\t\t// Blocks are undefined when they need to be re-parsed from content.\n\t\t\t\t// When new content is also part of this change (e.g. the Code\n\t\t\t\t// Editor dispatching `{ content, blocks: undefined }` on every\n\t\t\t\t// keystroke), derive blocks from content so the merge keeps\n\t\t\t\t// stable YBlock identities for unchanged blocks.\n\n\t\t\t\tconst rawContent = getRawValue( changes.content );\n\t\t\t\tif ( ! newValue && typeof rawContent === 'string' ) {\n\t\t\t\t\t// We have no blocks but an updated content string.\n\t\t\t\t\tmergeContentWithoutBlocks(\n\t\t\t\t\t\tymap,\n\t\t\t\t\t\trawContent,\n\t\t\t\t\t\tnewCursorPosition\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\t\t\t\t} else if ( ! newValue ) {\n\t\t\t\t\t// We have an update containing empty blocks and content.\n\t\t\t\t\t// Set to undefined instead of deleting the key. This is important\n\t\t\t\t\t// since we iterate over the Y.Map keys in getPostChangesFromCRDTDoc.\n\t\t\t\t\tymap.set( key, undefined );\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tlet currentBlocks = ymap.get( key );\n\n\t\t\t\t// Initialize.\n\t\t\t\tif ( ! ( currentBlocks instanceof Y.Array ) ) {\n\t\t\t\t\tcurrentBlocks = new Y.Array< YBlock >();\n\t\t\t\t\tymap.set( key, currentBlocks );\n\t\t\t\t}\n\n\t\t\t\t// Merge blocks does not need `setValue` because it is operating on a\n\t\t\t\t// Yjs type that is already in the Y.Doc.\n\t\t\t\tmergeCrdtBlocks( currentBlocks, newValue, newCursorPosition );\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tcase 'content':\n\t\t\tcase 'excerpt':\n\t\t\tcase 'title': {\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tlet rawValue = getRawValue( newValue );\n\n\t\t\t\t// Copy logic from prePersistPostType to ensure that the \"Auto\n\t\t\t\t// Draft\" template title is not synced.\n\t\t\t\tif (\n\t\t\t\t\tkey === 'title' &&\n\t\t\t\t\t! currentValue?.toString() &&\n\t\t\t\t\t'Auto Draft' === rawValue\n\t\t\t\t) {\n\t\t\t\t\trawValue = '';\n\t\t\t\t}\n\n\t\t\t\tif ( currentValue instanceof Y.Text ) {\n\t\t\t\t\tmergeRichTextUpdate( currentValue, rawValue ?? '' );\n\t\t\t\t} else {\n\t\t\t\t\tconst newYText = new Y.Text( rawValue ?? '' );\n\t\t\t\t\tymap.set( key, newYText );\n\t\t\t\t}\n\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// \"Meta\" is overloaded term; here, it refers to post meta.\n\t\t\tcase 'meta': {\n\t\t\t\tlet metaMap = ymap.get( 'meta' );\n\n\t\t\t\t// Initialize.\n\t\t\t\tif ( ! isYMap( metaMap ) ) {\n\t\t\t\t\tmetaMap = createYMap< YMapRecord >();\n\t\t\t\t\tymap.set( 'meta', metaMap );\n\t\t\t\t}\n\n\t\t\t\t// Iterate over each meta property in the new value and merge it if it\n\t\t\t\t// should be synced.\n\t\t\t\tObject.entries( newValue ?? {} ).forEach(\n\t\t\t\t\t( [ metaKey, metaValue ] ) => {\n\t\t\t\t\t\tif ( disallowedPostMetaKeys.has( metaKey ) ) {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tupdateMapValue(\n\t\t\t\t\t\t\tmetaMap,\n\t\t\t\t\t\t\tmetaKey,\n\t\t\t\t\t\t\tmetaMap.get( metaKey ), // current value in CRDT\n\t\t\t\t\t\t\tmetaValue // new value from changes\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tcase 'slug': {\n\t\t\t\t// Do not sync an empty slug. This indicates that the post is using\n\t\t\t\t// the default auto-generated slug.\n\t\t\t\tif ( ! newValue ) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tupdateMapValue( ymap, key, currentValue, newValue );\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// Add support for additional properties here.\n\n\t\t\tdefault: {\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tupdateMapValue( ymap, key, currentValue, newValue );\n\t\t\t}\n\t\t}\n\t} );\n\n\t// Process changes that we don't want to persist to the CRDT document.\n\tif ( changes.selection ) {\n\t\tconst selection = changes.selection;\n\t\t// Persist selection changes at the end of the current event loop.\n\t\t// This allows undo meta to be saved with the current selection before\n\t\t// it is overwritten by the new selection from Gutenberg.\n\t\t// Without this, selection history will already contain the latest\n\t\t// selection (after this change) when the undo stack is saved.\n\t\tsetTimeout( () => {\n\t\t\tupdateSelectionHistory( ydoc, selection );\n\t\t}, 0 );\n\t}\n}\n\n/**\n * Derive blocks from a raw content string and merge them into the post's\n * blocks Y.Array. Used when a caller dispatches a change with `blocks:\n * undefined` alongside new content, most notably the Code Editor's\n * per-keystroke dispatch.\n *\n * @param ymap The post's root Y.Map.\n * @param rawContent The raw HTML content to parse.\n * @param cursorPosition Cursor position derived from the change's selection,\n * used by mergeCrdtBlocks for rich-text cursor hints.\n */\nfunction mergeContentWithoutBlocks(\n\tymap: YMapWrap< YPostRecord >,\n\trawContent: string,\n\tcursorPosition: MergeCursorPosition\n): void {\n\tlet currentBlocks = ymap.get( 'blocks' );\n\n\tif ( ! ( currentBlocks instanceof Y.Array ) ) {\n\t\tcurrentBlocks = new Y.Array< YBlock >();\n\t\tymap.set( 'blocks', currentBlocks );\n\t}\n\n\tmergeCrdtBlocks(\n\t\tcurrentBlocks,\n\t\tparse( rawContent ) as Block[],\n\t\tcursorPosition,\n\t\t{ preserveClientIds: true }\n\t);\n}\n\n/**\n * Only returns a selection object if it describes a selection within a block, with\n * a cursor inside a RichText field associated with one of that block’s attributes.\n *\n * @param selection Selection object which might represent a selection within a block,\n * within a RichText field associated with a particular attribute of\n * that block, or none at all.\n */\nfunction parseCursorSelection( selection?: WPSelection ): MergeCursorPosition {\n\tconst selectionStart = selection?.selectionStart;\n\n\treturn selectionStart?.clientId &&\n\t\tselectionStart.attributeKey &&\n\t\t'number' === typeof selectionStart.offset &&\n\t\tNumber.isInteger( selectionStart.offset )\n\t\t? {\n\t\t\t\tattributeKey: selectionStart.attributeKey,\n\t\t\t\tclientId: selectionStart.clientId,\n\t\t\t\toffset: asRichTextOffset( selectionStart.offset ),\n\t\t }\n\t\t: null;\n}\n\nfunction defaultGetChangesFromCRDTDoc(\n\tcrdtDoc: CRDTDoc,\n\teditedRecord: ObjectData\n): ObjectData {\n\tconst docRecord = getRootMap( crdtDoc, CRDT_RECORD_MAP_KEY ).toJSON();\n\n\t/*\n\t * Only report properties that differ from the edited record. Reporting\n\t * unchanged properties as edits marks the record dirty: `Y.Map.toJSON()`\n\t * returns fresh object instances, so without this comparison every synced\n\t * update (e.g. from another tab) re-dispatches the entire record as edits.\n\t * See https://github.com/WordPress/gutenberg/issues/79907.\n\t */\n\treturn Object.fromEntries(\n\t\tObject.entries( docRecord ).filter( ( [ key, newValue ] ) =>\n\t\t\thaveValuesChanged( editedRecord?.[ key ], newValue )\n\t\t)\n\t);\n}\n\n/**\n * Given a local Y.Doc that *may* contain changes from remote peers, compare\n * against the local record and determine if there are changes (edits) we want\n * to dispatch.\n *\n * @param {CRDTDoc} ydoc\n * @param {Post} editedRecord\n * @param {Set<string>} syncedProperties\n * @return {Partial<PostChanges>} The changes that should be applied to the local record.\n */\nexport function getPostChangesFromCRDTDoc(\n\tydoc: CRDTDoc,\n\teditedRecord: Post,\n\tsyncedProperties: Set< string >\n): PostChanges {\n\tconst ymap = getRootMap< YPostRecord >( ydoc, CRDT_RECORD_MAP_KEY );\n\n\tlet allowedMetaChanges: Post[ 'meta' ] = {};\n\n\tconst changes = Object.fromEntries(\n\t\tObject.entries( ymap.toJSON() ).filter( ( [ key, newValue ] ) => {\n\t\t\tif ( ! syncedProperties.has( key ) ) {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tconst currentValue = editedRecord[ key ];\n\n\t\t\tswitch ( key ) {\n\t\t\t\tcase 'blocks': {\n\t\t\t\t\t// When we are passed a persisted CRDT document, make a special\n\t\t\t\t\t// comparison of the content and blocks.\n\t\t\t\t\t//\n\t\t\t\t\t// When other fields (besides `blocks`) are mutated outside the block\n\t\t\t\t\t// editor, the change is caught by an equality check (see other cases\n\t\t\t\t\t// in this `switch` statement). As a transient property, `blocks`\n\t\t\t\t\t// cannot be directly mutated outside the block editor -- only\n\t\t\t\t\t// `content` can.\n\t\t\t\t\t//\n\t\t\t\t\t// Therefore, for this special comparison, we serialize the `blocks`\n\t\t\t\t\t// from the persisted CRDT document and compare that to the content\n\t\t\t\t\t// from the persisted record. If they differ, we know that the content\n\t\t\t\t\t// in the database has changed, and therefore the blocks have changed.\n\t\t\t\t\t//\n\t\t\t\t\t// We cannot directly compare the `blocks` from the CRDT document to\n\t\t\t\t\t// the `blocks` derived from the `content` in the persisted record,\n\t\t\t\t\t// because the latter will have different client IDs.\n\t\t\t\t\tif (\n\t\t\t\t\t\tydoc.meta?.get( CRDT_DOC_META_PERSISTENCE_KEY ) &&\n\t\t\t\t\t\teditedRecord.content\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst blocksJson = ymap.get( 'blocks' )?.toJSON() ?? [];\n\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t__unstableSerializeAndClean( blocksJson ).trim() !==\n\t\t\t\t\t\t\tgetRawValue( editedRecord.content )\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\tcase 'date': {\n\t\t\t\t\t// Do not overwrite a \"floating\" date. Borrowing logic from the\n\t\t\t\t\t// isEditedPostDateFloating selector.\n\t\t\t\t\tconst currentDateIsFloating =\n\t\t\t\t\t\tnull === currentValue ||\n\t\t\t\t\t\teditedRecord.modified === currentValue;\n\n\t\t\t\t\tif ( currentDateIsFloating ) {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn haveValuesChanged( currentValue, newValue );\n\t\t\t\t}\n\n\t\t\t\tcase 'meta': {\n\t\t\t\t\tconst currentMeta =\n\t\t\t\t\t\t( currentValue as PostChanges[ 'meta' ] ) ?? {};\n\n\t\t\t\t\tallowedMetaChanges = Object.fromEntries(\n\t\t\t\t\t\tObject.entries( newValue ?? {} ).filter(\n\t\t\t\t\t\t\t( [ metaKey ] ) => {\n\t\t\t\t\t\t\t\tif ( disallowedPostMetaKeys.has( metaKey ) ) {\n\t\t\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Ignore meta keys that are no longer registered\n\t\t\t\t\t\t\t\t// for this post (absent from the REST response).\n\t\t\t\t\t\t\t\t// Without this, orphaned CRDT meta would mark\n\t\t\t\t\t\t\t\t// the post permanently dirty.\n\t\t\t\t\t\t\t\treturn metaKey in currentMeta;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t)\n\t\t\t\t\t);\n\n\t\t\t\t\t// Merge the allowed meta changes with the current meta values since\n\t\t\t\t\t// not all meta properties are synced.\n\t\t\t\t\tconst mergedValue = {\n\t\t\t\t\t\t...currentMeta,\n\t\t\t\t\t\t...allowedMetaChanges,\n\t\t\t\t\t};\n\n\t\t\t\t\treturn haveValuesChanged( currentValue, mergedValue );\n\t\t\t\t}\n\n\t\t\t\tcase 'status': {\n\t\t\t\t\t// Do not sync an invalid status.\n\t\t\t\t\tif ( 'auto-draft' === newValue ) {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn haveValuesChanged( currentValue, newValue );\n\t\t\t\t}\n\n\t\t\t\tcase 'content':\n\t\t\t\tcase 'excerpt':\n\t\t\t\tcase 'title': {\n\t\t\t\t\treturn haveValuesChanged(\n\t\t\t\t\t\tgetRawValue( currentValue ),\n\t\t\t\t\t\tnewValue\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\t// Add support for additional data types here.\n\n\t\t\t\tdefault: {\n\t\t\t\t\treturn haveValuesChanged( currentValue, newValue );\n\t\t\t\t}\n\t\t\t}\n\t\t} )\n\t);\n\n\t// Blocks extracted from the CRDT document have rich-text attributes as\n\t// plain strings (from Y.Text.toJSON()). Convert them back to RichTextData\n\t// so block edit components receive the same types as locally-created blocks.\n\tif ( changes.blocks ) {\n\t\tchanges.blocks = deserializeBlockAttributes(\n\t\t\tchanges.blocks as Block[]\n\t\t);\n\t}\n\n\t// When blocks changed but content didn't (the sender internally used a lazy\n\t// serializer function), inject a closure that captures the synced blocks\n\t// and serializes them on demand. Mirrors what useEntityBlockEditor does\n\t// locally. A fresh function on every persistent edit marks the entity\n\t// dirty (so the save button reactivates for peers), while serialization\n\t// stays lazy (only runs when getEditedPostContent reads it). The closure\n\t// captures `capturedBlocks` so the right content is returned even if the\n\t// caller later clears `record.blocks` (e.g. the Code Editor re-parsing\n\t// from content).\n\tif ( changes.blocks && ! changes.content ) {\n\t\tconst capturedBlocks = changes.blocks;\n\t\tchanges.content = () =>\n\t\t\t__unstableSerializeAndClean( capturedBlocks as WPBlock[] );\n\t}\n\n\t// Meta changes must be merged with the edited record since not all meta\n\t// properties are synced.\n\tif ( 'object' === typeof changes.meta ) {\n\t\tchanges.meta = {\n\t\t\t...editedRecord.meta,\n\t\t\t...allowedMetaChanges,\n\t\t};\n\t}\n\n\t// When remote content changes are detected, recalculate the local user's\n\t// selection using Y.RelativePosition to account for text shifts. The ydoc\n\t// has already been updated with remote content at this point, so converting\n\t// relative positions to absolute gives corrected offsets. Including the\n\t// selection in PostChanges ensures it dispatches atomically with content.\n\tconst selectionHistory = getSelectionHistory( ydoc );\n\tconst shiftedSelection = getShiftedSelection( ydoc, selectionHistory );\n\tif ( shiftedSelection ) {\n\t\tchanges.selection = {\n\t\t\t...shiftedSelection,\n\t\t\tinitialPosition: 0,\n\t\t};\n\t}\n\n\treturn changes;\n}\n\n/**\n * This default sync config can be used for entities that are flat maps of\n * primitive values and do not require custom logic to merge changes.\n */\nexport const defaultSyncConfig: SyncConfig = {\n\tapplyChangesToCRDTDoc: defaultApplyChangesToCRDTDoc,\n\tcreateAwareness: ( ydoc: CRDTDoc ) => new BaseAwareness( ydoc ),\n\tgetChangesFromCRDTDoc: defaultGetChangesFromCRDTDoc,\n};\n\n/**\n * This default collection sync config can be used to sync entity collections\n * (e.g., block comments) where we are not interested in merging changes at the\n * individual record level, but instead want to replace the entire collection\n * when changes are detected.\n */\nexport const defaultCollectionSyncConfig: SyncConfig = {\n\tapplyChangesToCRDTDoc: () => {},\n\tgetChangesFromCRDTDoc: () => ( {} ),\n\tshouldSync: ( _: ObjectType, objectId: ObjectID | null ) =>\n\t\tnull === objectId,\n};\n\n/**\n * Extract the raw string value from a property that may be a string or an object\n * with a `raw` property (`RenderedText`).\n *\n * @param {unknown} value The value to extract from.\n * @return {string|undefined} The raw string value, or undefined if it could not be determined.\n */\nexport function getRawValue( value?: unknown ): string | undefined {\n\t// Value may be a string property or a nested object with a `raw` property.\n\tif ( 'string' === typeof value ) {\n\t\treturn value;\n\t}\n\n\tif (\n\t\tvalue &&\n\t\t'object' === typeof value &&\n\t\t'raw' in value &&\n\t\t'string' === typeof value.raw\n\t) {\n\t\treturn value.raw;\n\t}\n\n\treturn undefined;\n}\n\nfunction haveValuesChanged< ValueType >(\n\tcurrentValue: ValueType | undefined,\n\tnewValue: ValueType | undefined\n): boolean {\n\treturn ! fastDeepEqual( currentValue, newValue );\n}\n\nfunction updateMapValue< T extends YMapRecord, K extends keyof T >(\n\tmap: YMapWrap< T >,\n\tkey: K,\n\tcurrentValue: T[ K ] | undefined,\n\tnewValue: T[ K ] | undefined\n): void {\n\tif ( undefined === newValue ) {\n\t\tmap.delete( key );\n\t\treturn;\n\t}\n\n\tif ( haveValuesChanged< T[ K ] >( currentValue, newValue ) ) {\n\t\tmap.set( key, newValue );\n\t}\n}\n"],
|
|
5
|
-
"mappings": ";
|
|
4
|
+
"sourcesContent": ["import fastDeepEqual from 'fast-deep-equal/es6/index.js';\nimport {\n\t__unstableSerializeAndClean,\n\tparse,\n\ttype Block as WPBlock,\n} from '@wordpress/blocks';\nimport {\n\ttype CRDTDoc,\n\ttype ObjectData,\n\ttype ObjectID,\n\ttype ObjectType,\n\ttype SyncConfig,\n\tY,\n} from '@wordpress/sync';\nimport { BaseAwareness } from '../awareness/base-awareness';\nimport {\n\ttype Block,\n\tdeserializeBlockAttributes,\n\tmergeCrdtBlocks,\n\ttype MergeCursorPosition,\n\tmergeRichTextUpdate,\n\ttype YBlock,\n\ttype YBlocks,\n} from './crdt-blocks';\nimport { type Post } from '../entity-types/post';\nimport { CRDT_DOC_META_PERSISTENCE_KEY, CRDT_RECORD_MAP_KEY } from '../sync';\nimport type { WPSelection } from '../types';\nimport {\n\tgetSelectionHistory,\n\tgetShiftedSelection,\n\tupdateSelectionHistory,\n} from './crdt-selection';\nimport {\n\tasRichTextOffset,\n\tcreateYMap,\n\tgetRootMap,\n\tisYMap,\n\ttype YMapRecord,\n\ttype YMapWrap,\n} from './crdt-utils';\n\n// A function that derives content from blocks. Two callers produce this:\n// `useEntityBlockEditor` reads blocks from its argument (so the optional arg\n// lets it accept whatever caller is invoked with), and the receiver-side\n// injection in this file captures blocks in a closure and ignores the arg.\ntype ContentFromBlocksFn = ( args?: { blocks: Block[] } ) => string;\n\n// Changes that can be applied to a post entity record.\nexport type PostChanges = Partial< Post > & {\n\tblocks?: Block[];\n\tcontent?: Post[ 'content' ] | string | ContentFromBlocksFn;\n\texcerpt?: Post[ 'excerpt' ] | string;\n\tselection?: WPSelection;\n\ttitle?: Post[ 'title' ] | string;\n};\n\n// A post record as represented in the CRDT document (Y.Map).\nexport interface YPostRecord extends YMapRecord {\n\tauthor: number;\n\t// Blocks are undefined when they need to be re-parsed from content.\n\tblocks: YBlocks | undefined;\n\tcontent: Y.Text;\n\tcategories: number[];\n\tcomment_status: string;\n\tdate: string | null;\n\texcerpt: Y.Text;\n\tfeatured_media: number;\n\tformat: string;\n\tmeta: YMapWrap< YMapRecord >;\n\tping_status: string;\n\tslug: string;\n\tstatus: string;\n\tsticky: boolean;\n\ttags: number[];\n\ttemplate: string;\n\ttitle: Y.Text;\n}\n\nexport const POST_META_KEY_FOR_CRDT_DOC_PERSISTENCE = '_crdt_document';\n\n// Post meta keys that should *not* be synced.\nconst disallowedPostMetaKeys = new Set< string >( [\n\tPOST_META_KEY_FOR_CRDT_DOC_PERSISTENCE,\n] );\n\n/**\n * Given a set of local changes to a generic entity record, apply those changes\n * to the local Y.Doc.\n *\n * @param {CRDTDoc} ydoc\n * @param {Partial< ObjectData >} changes\n * @return {void}\n */\nfunction defaultApplyChangesToCRDTDoc(\n\tydoc: CRDTDoc,\n\tchanges: ObjectData\n): void {\n\tconst ymap = getRootMap( ydoc, CRDT_RECORD_MAP_KEY );\n\n\tObject.entries( changes ).forEach( ( [ key, newValue ] ) => {\n\t\t// Cannot serialize function values, so cannot sync them.\n\t\tif ( 'function' === typeof newValue ) {\n\t\t\treturn;\n\t\t}\n\n\t\tswitch ( key ) {\n\t\t\t// Add support for additional data types here.\n\n\t\t\tdefault: {\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tupdateMapValue( ymap, key, currentValue, newValue );\n\t\t\t}\n\t\t}\n\t} );\n}\n\n/**\n * Given a set of local changes to a post record, apply those changes to the\n * local Y.Doc.\n *\n * @param {CRDTDoc} ydoc\n * @param {PostChanges} changes\n * @param {Set<string>} syncedProperties\n * @return {void}\n */\nexport function applyPostChangesToCRDTDoc(\n\tydoc: CRDTDoc,\n\tchanges: PostChanges,\n\tsyncedProperties: Set< string >\n): void {\n\tconst ymap = getRootMap< YPostRecord >( ydoc, CRDT_RECORD_MAP_KEY );\n\n\tObject.keys( changes ).forEach( ( key ) => {\n\t\tif ( ! syncedProperties.has( key ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst newValue = changes[ key ];\n\n\t\t// Cannot serialize function values, so cannot sync them. `content` is\n\t\t// often passed as a lazy serializer by `useEntityBlockEditor`; the\n\t\t// receiver re-derives it from the synced blocks (see\n\t\t// getPostChangesFromCRDTDoc), so dropping it here is intentional.\n\t\tif ( 'function' === typeof newValue ) {\n\t\t\treturn;\n\t\t}\n\n\t\tswitch ( key ) {\n\t\t\tcase 'blocks': {\n\t\t\t\t// Block changes from typing are bundled with a 'selection' update.\n\t\t\t\t// Use the resulting cursor position for block merging.\n\t\t\t\tconst newCursorPosition = parseCursorSelection(\n\t\t\t\t\tchanges.selection\n\t\t\t\t);\n\n\t\t\t\t// Blocks are undefined when they need to be re-parsed from content.\n\t\t\t\t// When new content is also part of this change (e.g. the Code\n\t\t\t\t// Editor dispatching `{ content, blocks: undefined }` on every\n\t\t\t\t// keystroke), derive blocks from content so the merge keeps\n\t\t\t\t// stable YBlock identities for unchanged blocks.\n\n\t\t\t\tconst rawContent = getRawValue( changes.content );\n\t\t\t\tif ( ! newValue && typeof rawContent === 'string' ) {\n\t\t\t\t\t// We have no blocks but an updated content string.\n\t\t\t\t\tmergeContentWithoutBlocks(\n\t\t\t\t\t\tymap,\n\t\t\t\t\t\trawContent,\n\t\t\t\t\t\tnewCursorPosition\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\t\t\t\t} else if ( ! newValue ) {\n\t\t\t\t\t// We have an update containing empty blocks and content.\n\t\t\t\t\t// Set to undefined instead of deleting the key. This is important\n\t\t\t\t\t// since we iterate over the Y.Map keys in getPostChangesFromCRDTDoc.\n\t\t\t\t\tymap.set( key, undefined );\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tlet currentBlocks = ymap.get( key );\n\n\t\t\t\t// Initialize.\n\t\t\t\tif ( ! ( currentBlocks instanceof Y.Array ) ) {\n\t\t\t\t\tcurrentBlocks = new Y.Array< YBlock >();\n\t\t\t\t\tymap.set( key, currentBlocks );\n\t\t\t\t}\n\n\t\t\t\t// Merge blocks does not need `setValue` because it is operating on a\n\t\t\t\t// Yjs type that is already in the Y.Doc.\n\t\t\t\tmergeCrdtBlocks( currentBlocks, newValue, newCursorPosition );\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tcase 'content':\n\t\t\tcase 'excerpt':\n\t\t\tcase 'title': {\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tlet rawValue = getRawValue( newValue );\n\n\t\t\t\t// Copy logic from prePersistPostType to ensure that the \"Auto\n\t\t\t\t// Draft\" template title is not synced.\n\t\t\t\tif (\n\t\t\t\t\tkey === 'title' &&\n\t\t\t\t\t! currentValue?.toString() &&\n\t\t\t\t\t'Auto Draft' === rawValue\n\t\t\t\t) {\n\t\t\t\t\trawValue = '';\n\t\t\t\t}\n\n\t\t\t\tif ( currentValue instanceof Y.Text ) {\n\t\t\t\t\tmergeRichTextUpdate( currentValue, rawValue ?? '' );\n\t\t\t\t} else {\n\t\t\t\t\tconst newYText = new Y.Text( rawValue ?? '' );\n\t\t\t\t\tymap.set( key, newYText );\n\t\t\t\t}\n\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// \"Meta\" is overloaded term; here, it refers to post meta.\n\t\t\tcase 'meta': {\n\t\t\t\tlet metaMap = ymap.get( 'meta' );\n\n\t\t\t\t// Initialize.\n\t\t\t\tif ( ! isYMap( metaMap ) ) {\n\t\t\t\t\tmetaMap = createYMap< YMapRecord >();\n\t\t\t\t\tymap.set( 'meta', metaMap );\n\t\t\t\t}\n\n\t\t\t\t// Iterate over each meta property in the new value and merge it if it\n\t\t\t\t// should be synced.\n\t\t\t\tObject.entries( newValue ?? {} ).forEach(\n\t\t\t\t\t( [ metaKey, metaValue ] ) => {\n\t\t\t\t\t\tif ( disallowedPostMetaKeys.has( metaKey ) ) {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tupdateMapValue(\n\t\t\t\t\t\t\tmetaMap,\n\t\t\t\t\t\t\tmetaKey,\n\t\t\t\t\t\t\tmetaMap.get( metaKey ), // current value in CRDT\n\t\t\t\t\t\t\tmetaValue // new value from changes\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tcase 'slug': {\n\t\t\t\t// Do not sync an empty slug. This indicates that the post is using\n\t\t\t\t// the default auto-generated slug.\n\t\t\t\tif ( ! newValue ) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tupdateMapValue( ymap, key, currentValue, newValue );\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// Add support for additional properties here.\n\n\t\t\tdefault: {\n\t\t\t\tconst currentValue = ymap.get( key );\n\t\t\t\tupdateMapValue( ymap, key, currentValue, newValue );\n\t\t\t}\n\t\t}\n\t} );\n\n\t// Process changes that we don't want to persist to the CRDT document.\n\tif ( changes.selection ) {\n\t\tconst selection = changes.selection;\n\t\t// Persist selection changes at the end of the current event loop.\n\t\t// This allows undo meta to be saved with the current selection before\n\t\t// it is overwritten by the new selection from Gutenberg.\n\t\t// Without this, selection history will already contain the latest\n\t\t// selection (after this change) when the undo stack is saved.\n\t\tsetTimeout( () => {\n\t\t\tupdateSelectionHistory( ydoc, selection );\n\t\t}, 0 );\n\t}\n}\n\n/**\n * Derive blocks from a raw content string and merge them into the post's\n * blocks Y.Array. Used when a caller dispatches a change with `blocks:\n * undefined` alongside new content, most notably the Code Editor's\n * per-keystroke dispatch.\n *\n * @param ymap The post's root Y.Map.\n * @param rawContent The raw HTML content to parse.\n * @param cursorPosition Cursor position derived from the change's selection,\n * used by mergeCrdtBlocks for rich-text cursor hints.\n */\nfunction mergeContentWithoutBlocks(\n\tymap: YMapWrap< YPostRecord >,\n\trawContent: string,\n\tcursorPosition: MergeCursorPosition\n): void {\n\tlet currentBlocks = ymap.get( 'blocks' );\n\n\tif ( ! ( currentBlocks instanceof Y.Array ) ) {\n\t\tcurrentBlocks = new Y.Array< YBlock >();\n\t\tymap.set( 'blocks', currentBlocks );\n\t}\n\n\tmergeCrdtBlocks(\n\t\tcurrentBlocks,\n\t\tparse( rawContent ) as Block[],\n\t\tcursorPosition,\n\t\t{ preserveClientIds: true }\n\t);\n}\n\n/**\n * Only returns a selection object if it describes a selection within a block, with\n * a cursor inside a RichText field associated with one of that block’s attributes.\n *\n * @param selection Selection object which might represent a selection within a block,\n * within a RichText field associated with a particular attribute of\n * that block, or none at all.\n */\nfunction parseCursorSelection( selection?: WPSelection ): MergeCursorPosition {\n\tconst selectionStart = selection?.selectionStart;\n\n\treturn selectionStart?.clientId &&\n\t\tselectionStart.attributeKey &&\n\t\t'number' === typeof selectionStart.offset &&\n\t\tNumber.isInteger( selectionStart.offset )\n\t\t? {\n\t\t\t\tattributeKey: selectionStart.attributeKey,\n\t\t\t\tclientId: selectionStart.clientId,\n\t\t\t\toffset: asRichTextOffset( selectionStart.offset ),\n\t\t }\n\t\t: null;\n}\n\nfunction defaultGetChangesFromCRDTDoc(\n\tcrdtDoc: CRDTDoc,\n\teditedRecord: ObjectData\n): ObjectData {\n\tconst docRecord = getRootMap( crdtDoc, CRDT_RECORD_MAP_KEY ).toJSON();\n\n\t/*\n\t * Only report properties that differ from the edited record. Reporting\n\t * unchanged properties as edits marks the record dirty: `Y.Map.toJSON()`\n\t * returns fresh object instances, so without this comparison every synced\n\t * update (e.g. from another tab) re-dispatches the entire record as edits.\n\t * See https://github.com/WordPress/gutenberg/issues/79907.\n\t */\n\treturn Object.fromEntries(\n\t\tObject.entries( docRecord ).filter( ( [ key, newValue ] ) =>\n\t\t\thaveValuesChanged( editedRecord?.[ key ], newValue )\n\t\t)\n\t);\n}\n\n/**\n * Given a local Y.Doc that *may* contain changes from remote peers, compare\n * against the local record and determine if there are changes (edits) we want\n * to dispatch.\n *\n * @param {CRDTDoc} ydoc\n * @param {Post} editedRecord\n * @param {Set<string>} syncedProperties\n * @return {Partial<PostChanges>} The changes that should be applied to the local record.\n */\nexport function getPostChangesFromCRDTDoc(\n\tydoc: CRDTDoc,\n\teditedRecord: Post,\n\tsyncedProperties: Set< string >\n): PostChanges {\n\tconst ymap = getRootMap< YPostRecord >( ydoc, CRDT_RECORD_MAP_KEY );\n\n\tlet allowedMetaChanges: Post[ 'meta' ] = {};\n\n\tconst changes = Object.fromEntries(\n\t\tObject.entries( ymap.toJSON() ).filter( ( [ key, newValue ] ) => {\n\t\t\tif ( ! syncedProperties.has( key ) ) {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tconst currentValue = editedRecord[ key ];\n\n\t\t\tswitch ( key ) {\n\t\t\t\tcase 'blocks': {\n\t\t\t\t\t// When we are passed a persisted CRDT document, make a special\n\t\t\t\t\t// comparison of the content and blocks.\n\t\t\t\t\t//\n\t\t\t\t\t// When other fields (besides `blocks`) are mutated outside the block\n\t\t\t\t\t// editor, the change is caught by an equality check (see other cases\n\t\t\t\t\t// in this `switch` statement). As a transient property, `blocks`\n\t\t\t\t\t// cannot be directly mutated outside the block editor -- only\n\t\t\t\t\t// `content` can.\n\t\t\t\t\t//\n\t\t\t\t\t// Therefore, for this special comparison, we serialize the `blocks`\n\t\t\t\t\t// from the persisted CRDT document and compare that to the content\n\t\t\t\t\t// from the persisted record. If they differ, we know that the content\n\t\t\t\t\t// in the database has changed, and therefore the blocks have changed.\n\t\t\t\t\t//\n\t\t\t\t\t// We cannot directly compare the `blocks` from the CRDT document to\n\t\t\t\t\t// the `blocks` derived from the `content` in the persisted record,\n\t\t\t\t\t// because the latter will have different client IDs.\n\t\t\t\t\tif (\n\t\t\t\t\t\tydoc.meta?.get( CRDT_DOC_META_PERSISTENCE_KEY ) &&\n\t\t\t\t\t\teditedRecord.content\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst blocksJson = ymap.get( 'blocks' )?.toJSON() ?? [];\n\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t__unstableSerializeAndClean( blocksJson ).trim() !==\n\t\t\t\t\t\t\tgetRawValue( editedRecord.content )\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\tcase 'date': {\n\t\t\t\t\t// Do not overwrite a \"floating\" date. Borrowing logic from the\n\t\t\t\t\t// isEditedPostDateFloating selector.\n\t\t\t\t\tconst currentDateIsFloating =\n\t\t\t\t\t\tnull === currentValue ||\n\t\t\t\t\t\teditedRecord.modified === currentValue;\n\n\t\t\t\t\tif ( currentDateIsFloating ) {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn haveValuesChanged( currentValue, newValue );\n\t\t\t\t}\n\n\t\t\t\tcase 'meta': {\n\t\t\t\t\tconst currentMeta =\n\t\t\t\t\t\t( currentValue as PostChanges[ 'meta' ] ) ?? {};\n\n\t\t\t\t\tallowedMetaChanges = Object.fromEntries(\n\t\t\t\t\t\tObject.entries( newValue ?? {} ).filter(\n\t\t\t\t\t\t\t( [ metaKey ] ) => {\n\t\t\t\t\t\t\t\tif ( disallowedPostMetaKeys.has( metaKey ) ) {\n\t\t\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Ignore meta keys that are no longer registered\n\t\t\t\t\t\t\t\t// for this post (absent from the REST response).\n\t\t\t\t\t\t\t\t// Without this, orphaned CRDT meta would mark\n\t\t\t\t\t\t\t\t// the post permanently dirty.\n\t\t\t\t\t\t\t\treturn metaKey in currentMeta;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t)\n\t\t\t\t\t);\n\n\t\t\t\t\t// Merge the allowed meta changes with the current meta values since\n\t\t\t\t\t// not all meta properties are synced.\n\t\t\t\t\tconst mergedValue = {\n\t\t\t\t\t\t...currentMeta,\n\t\t\t\t\t\t...allowedMetaChanges,\n\t\t\t\t\t};\n\n\t\t\t\t\treturn haveValuesChanged( currentValue, mergedValue );\n\t\t\t\t}\n\n\t\t\t\tcase 'status': {\n\t\t\t\t\t// Do not sync an invalid status.\n\t\t\t\t\tif ( 'auto-draft' === newValue ) {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn haveValuesChanged( currentValue, newValue );\n\t\t\t\t}\n\n\t\t\t\tcase 'content':\n\t\t\t\tcase 'excerpt':\n\t\t\t\tcase 'title': {\n\t\t\t\t\treturn haveValuesChanged(\n\t\t\t\t\t\tgetRawValue( currentValue ),\n\t\t\t\t\t\tnewValue\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\t// Add support for additional data types here.\n\n\t\t\t\tdefault: {\n\t\t\t\t\treturn haveValuesChanged( currentValue, newValue );\n\t\t\t\t}\n\t\t\t}\n\t\t} )\n\t);\n\n\t// Blocks extracted from the CRDT document have rich-text attributes as\n\t// plain strings (from Y.Text.toJSON()). Convert them back to RichTextData\n\t// so block edit components receive the same types as locally-created blocks.\n\tif ( changes.blocks ) {\n\t\tchanges.blocks = deserializeBlockAttributes(\n\t\t\tchanges.blocks as Block[]\n\t\t);\n\t}\n\n\t// When blocks changed but content didn't (the sender internally used a lazy\n\t// serializer function), inject a closure that captures the synced blocks\n\t// and serializes them on demand. Mirrors what useEntityBlockEditor does\n\t// locally. A fresh function on every persistent edit marks the entity\n\t// dirty (so the save button reactivates for peers), while serialization\n\t// stays lazy (only runs when getEditedPostContent reads it). The closure\n\t// captures `capturedBlocks` so the right content is returned even if the\n\t// caller later clears `record.blocks` (e.g. the Code Editor re-parsing\n\t// from content).\n\tif ( changes.blocks && ! changes.content ) {\n\t\tconst capturedBlocks = changes.blocks;\n\t\tchanges.content = () =>\n\t\t\t__unstableSerializeAndClean( capturedBlocks as WPBlock[] );\n\t}\n\n\t// Meta changes must be merged with the edited record since not all meta\n\t// properties are synced.\n\tif ( 'object' === typeof changes.meta ) {\n\t\tchanges.meta = {\n\t\t\t...editedRecord.meta,\n\t\t\t...allowedMetaChanges,\n\t\t};\n\t}\n\n\t// When remote content changes are detected, recalculate the local user's\n\t// selection using Y.RelativePosition to account for text shifts. The ydoc\n\t// has already been updated with remote content at this point, so converting\n\t// relative positions to absolute gives corrected offsets. Including the\n\t// selection in PostChanges ensures it dispatches atomically with content.\n\tconst selectionHistory = getSelectionHistory( ydoc );\n\tconst shiftedSelection = getShiftedSelection( ydoc, selectionHistory );\n\tif ( shiftedSelection ) {\n\t\tchanges.selection = {\n\t\t\t...shiftedSelection,\n\t\t\tinitialPosition: 0,\n\t\t};\n\t}\n\n\treturn changes;\n}\n\n/**\n * This default sync config can be used for entities that are flat maps of\n * primitive values and do not require custom logic to merge changes.\n */\nexport const defaultSyncConfig: SyncConfig = {\n\tapplyChangesToCRDTDoc: defaultApplyChangesToCRDTDoc,\n\tcreateAwareness: ( ydoc: CRDTDoc ) => new BaseAwareness( ydoc ),\n\tgetChangesFromCRDTDoc: defaultGetChangesFromCRDTDoc,\n};\n\n/**\n * This default collection sync config can be used to sync entity collections\n * (e.g., block comments) where we are not interested in merging changes at the\n * individual record level, but instead want to replace the entire collection\n * when changes are detected.\n */\nexport const defaultCollectionSyncConfig: SyncConfig = {\n\tapplyChangesToCRDTDoc: () => {},\n\tgetChangesFromCRDTDoc: () => ( {} ),\n\tshouldSync: ( _: ObjectType, objectId: ObjectID | null ) =>\n\t\tnull === objectId,\n};\n\n/**\n * Extract the raw string value from a property that may be a string or an object\n * with a `raw` property (`RenderedText`).\n *\n * @param {unknown} value The value to extract from.\n * @return {string|undefined} The raw string value, or undefined if it could not be determined.\n */\nexport function getRawValue( value?: unknown ): string | undefined {\n\t// Value may be a string property or a nested object with a `raw` property.\n\tif ( 'string' === typeof value ) {\n\t\treturn value;\n\t}\n\n\tif (\n\t\tvalue &&\n\t\t'object' === typeof value &&\n\t\t'raw' in value &&\n\t\t'string' === typeof value.raw\n\t) {\n\t\treturn value.raw;\n\t}\n\n\treturn undefined;\n}\n\nfunction haveValuesChanged< ValueType >(\n\tcurrentValue: ValueType | undefined,\n\tnewValue: ValueType | undefined\n): boolean {\n\treturn ! fastDeepEqual( currentValue, newValue );\n}\n\nfunction updateMapValue< T extends YMapRecord, K extends keyof T >(\n\tmap: YMapWrap< T >,\n\tkey: K,\n\tcurrentValue: T[ K ] | undefined,\n\tnewValue: T[ K ] | undefined\n): void {\n\tif ( undefined === newValue ) {\n\t\tmap.delete( key );\n\t\treturn;\n\t}\n\n\tif ( haveValuesChanged< T[ K ] >( currentValue, newValue ) ) {\n\t\tmap.set( key, newValue );\n\t}\n}\n"],
|
|
5
|
+
"mappings": ";AAAA,OAAO,mBAAmB;AAC1B;AAAA,EACC;AAAA,EACA;AAAA,OAEM;AACP;AAAA,EAMC;AAAA,OACM;AACP,SAAS,qBAAqB;AAC9B;AAAA,EAEC;AAAA,EACA;AAAA,EAEA;AAAA,OAGM;AAEP,SAAS,+BAA+B,2BAA2B;AAEnE;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAGM;AAuCA,IAAM,yCAAyC;AAGtD,IAAM,yBAAyB,oBAAI,IAAe;AAAA,EACjD;AACD,CAAE;AAUF,SAAS,6BACR,MACA,SACO;AACP,QAAM,OAAO,WAAY,MAAM,mBAAoB;AAEnD,SAAO,QAAS,OAAQ,EAAE,QAAS,CAAE,CAAE,KAAK,QAAS,MAAO;AAE3D,QAAK,eAAe,OAAO,UAAW;AACrC;AAAA,IACD;AAEA,YAAS,KAAM;AAAA;AAAA,MAGd,SAAS;AACR,cAAM,eAAe,KAAK,IAAK,GAAI;AACnC,uBAAgB,MAAM,KAAK,cAAc,QAAS;AAAA,MACnD;AAAA,IACD;AAAA,EACD,CAAE;AACH;AAWO,SAAS,0BACf,MACA,SACA,kBACO;AACP,QAAM,OAAO,WAA2B,MAAM,mBAAoB;AAElE,SAAO,KAAM,OAAQ,EAAE,QAAS,CA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A,EAC9B,uBAAuB,OAAQ,CAAC;AAAA,EAChC,YAAY,CAAE,GAAe,aAC5B,SAAS;AACX;AASO,SAAS,YAAa,OAAsC;AAElE,MAAK,aAAa,OAAO,OAAQ;AAChC,WAAO;AAAA,EACR;AAEA,MACC,SACA,aAAa,OAAO,SACpB,SAAS,SACT,aAAa,OAAO,MAAM,KACzB;AACD,WAAO,MAAM;AAAA,EACd;AAEA,SAAO;AACR;AAEA,SAAS,kBACR,cACA,UACU;AACV,SAAO,CAAE,cAAe,cAAc,QAAS;AAChD;AAEA,SAAS,eACR,KACA,KACA,cACA,UACO;AACP,MAAK,WAAc,UAAW;AAC7B,QAAI,OAAQ,GAAI;AAChB;AAAA,EACD;AAEA,MAAK,kBAA6B,cAAc,QAAS,GAAI;AAC5D,QAAI,IAAK,KAAK,QAAS;AAAA,EACxB;AACD;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/get-template-info.js"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": ";
|
|
4
|
+
"sourcesContent": ["import { layout } from '@wordpress/icons';\nimport { getTemplatePartIcon } from './get-template-part-icon';\nconst EMPTY_OBJECT = {};\n\n/**\n * Helper function to retrieve the corresponding template info for a given template.\n * @param {Object} params\n * @param {Array} params.templateTypes\n * @param {Array} [params.templateAreas]\n * @param {Object} params.template\n */\nexport const getTemplateInfo = ( params ) => {\n\tif ( ! params ) {\n\t\treturn EMPTY_OBJECT;\n\t}\n\n\tconst { templateTypes, templateAreas, template } = params;\n\n\tconst { description, slug, title, area } = template;\n\n\tconst { title: defaultTitle, description: defaultDescription } =\n\t\tObject.values( templateTypes ).find( ( type ) => type.slug === slug ) ??\n\t\tEMPTY_OBJECT;\n\n\tconst templateTitle = typeof title === 'string' ? title : title?.rendered;\n\tconst templateDescription =\n\t\ttypeof description === 'string' ? description : description?.raw;\n\n\tconst templateAreasWithIcon = templateAreas?.map( ( item ) => ( {\n\t\t...item,\n\t\ticon: getTemplatePartIcon( item.icon ),\n\t} ) );\n\n\tconst templateIcon =\n\t\ttemplateAreasWithIcon?.find( ( item ) => area === item.area )?.icon ||\n\t\tlayout;\n\n\treturn {\n\t\ttitle:\n\t\t\ttemplateTitle && templateTitle !== slug\n\t\t\t\t? templateTitle\n\t\t\t\t: defaultTitle || slug,\n\t\tdescription: templateDescription || defaultDescription,\n\t\ticon: templateIcon,\n\t};\n};\n"],
|
|
5
|
+
"mappings": ";AAAA,SAAS,cAAc;AACvB,SAAS,2BAA2B;AACpC,IAAM,eAAe,CAAC;AASf,IAAM,kBAAkB,CAAE,WAAY;AAC5C,MAAK,CAAE,QAAS;AACf,WAAO;AAAA,EACR;AAEA,QAAM,EAAE,eAAe,eAAe,SAAS,IAAI;AAEnD,QAAM,EAAE,aAAa,MAAM,OAAO,KAAK,IAAI;AAE3C,QAAM,EAAE,OAAO,cAAc,aAAa,mBAAmB,IAC5D,OAAO,OAAQ,aAAc,EAAE,KAAM,CAAE,SAAU,KAAK,SAAS,IAAK,KACpE;AAED,QAAM,gBAAgB,OAAO,UAAU,WAAW,QAAQ,OAAO;AACjE,QAAM,sBACL,OAAO,gBAAgB,WAAW,cAAc,aAAa;AAE9D,QAAM,wBAAwB,eAAe,IAAK,CAAE,UAAY;AAAA,IAC/D,GAAG;AAAA,IACH,MAAM,oBAAqB,KAAK,IAAK;AAAA,EACtC,EAAI;AAEJ,QAAM,eACL,uBAAuB,KAAM,CAAE,SAAU,SAAS,KAAK,IAAK,GAAG,QAC/D;AAED,SAAO;AAAA,IACN,OACC,iBAAiB,kBAAkB,OAChC,gBACA,gBAAgB;AAAA,IACpB,aAAa,uBAAuB;AAAA,IACpC,MAAM;AAAA,EACP;AACD;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/get-template-part-icon.js"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": ";
|
|
4
|
+
"sourcesContent": ["import {\n\theader as headerIcon,\n\tfooter as footerIcon,\n\tsidebar as sidebarIcon,\n\tnavigationOverlay as navigationOverlayIcon,\n\tsymbolFilled as symbolFilledIcon,\n} from '@wordpress/icons';\n\n/**\n * Helper function to retrieve the corresponding icon by area name.\n *\n * @param {string} areaOrIconName The area name (e.g., 'header', 'navigation-overlay').\n *\n * @return {Object} The corresponding icon.\n */\nexport function getTemplatePartIcon( areaOrIconName ) {\n\tif ( 'header' === areaOrIconName ) {\n\t\treturn headerIcon;\n\t} else if ( 'footer' === areaOrIconName ) {\n\t\treturn footerIcon;\n\t} else if ( 'sidebar' === areaOrIconName ) {\n\t\treturn sidebarIcon;\n\t} else if ( 'navigation-overlay' === areaOrIconName ) {\n\t\treturn navigationOverlayIcon;\n\t}\n\treturn symbolFilledIcon;\n}\n"],
|
|
5
|
+
"mappings": ";AAAA;AAAA,EACC,UAAU;AAAA,EACV,UAAU;AAAA,EACV,WAAW;AAAA,EACX,qBAAqB;AAAA,EACrB,gBAAgB;AAAA,OACV;AASA,SAAS,oBAAqB,gBAAiB;AACrD,MAAK,aAAa,gBAAiB;AAClC,WAAO;AAAA,EACR,WAAY,aAAa,gBAAiB;AACzC,WAAO;AAAA,EACR,WAAY,cAAc,gBAAiB;AAC1C,WAAO;AAAA,EACR,WAAY,yBAAyB,gBAAiB;AACrD,WAAO;AAAA,EACR;AACA,SAAO;AACR;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/log-entity-deprecation.ts"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": ";
|
|
4
|
+
"sourcesContent": ["import deprecated from '@wordpress/deprecated';\nimport { deprecatedEntities } from '../entities';\n\nlet loggedAlready = false;\n\n/**\n * Logs a deprecation warning for an entity, if it's deprecated.\n *\n * @param kind The kind of the entity.\n * @param name The name of the entity.\n * @param functionName The name of the function that was called with a deprecated entity.\n * @param options The options for the deprecation warning.\n * @param options.alternativeFunctionName The name of the alternative function that should be used instead.\n * @param options.isShorthandSelector Whether the function is a shorthand selector.\n */\nexport default function logEntityDeprecation(\n\tkind: string,\n\tname: string,\n\tfunctionName: string,\n\t{\n\t\talternativeFunctionName,\n\t\tisShorthandSelector = false,\n\t}: {\n\t\talternativeFunctionName?: string;\n\t\tisShorthandSelector?: boolean;\n\t} = {}\n) {\n\tconst deprecation = deprecatedEntities[ kind ]?.[ name ];\n\tif ( ! deprecation ) {\n\t\treturn;\n\t}\n\n\tif ( ! loggedAlready ) {\n\t\tconst { alternative } = deprecation;\n\n\t\tconst message = isShorthandSelector\n\t\t\t? `'${ functionName }'`\n\t\t\t: `The '${ kind }', '${ name }' entity (used via '${ functionName }')`;\n\n\t\tlet alternativeMessage = `the '${ alternative.kind }', '${ alternative.name }' entity`;\n\t\tif ( alternativeFunctionName ) {\n\t\t\talternativeMessage += ` via the '${ alternativeFunctionName }' function`;\n\t\t}\n\n\t\tdeprecated( message, {\n\t\t\t...deprecation,\n\t\t\talternative: alternativeMessage,\n\t\t} );\n\t}\n\n\t// Only log an entity deprecation once per call stack,\n\t// else there's spurious logging when selections or actions call through to other selectors or actions.\n\t// Note: this won't prevent the deprecation warning being logged if a selector or action makes an async call\n\t// to another selector or action, but this is probably the best we can do.\n\tloggedAlready = true;\n\t// At the end of the call stack, reset the flag.\n\tsetTimeout( () => {\n\t\tloggedAlready = false;\n\t}, 0 );\n}\n"],
|
|
5
|
+
"mappings": ";AAAA,OAAO,gBAAgB;AACvB,SAAS,0BAA0B;AAEnC,IAAI,gBAAgB;AAYL,SAAR,qBACN,MACA,MACA,cACA;AAAA,EACC;AAAA,EACA,sBAAsB;AACvB,IAGI,CAAC,GACJ;AACD,QAAM,cAAc,mBAAoB,IAAK,IAAK,IAAK;AACvD,MAAK,CAAE,aAAc;AACpB;AAAA,EACD;AAEA,MAAK,CAAE,eAAgB;AACtB,UAAM,EAAE,YAAY,IAAI;AAExB,UAAM,UAAU,sBACb,IAAK,YAAa,MAClB,QAAS,IAAK,OAAQ,IAAK,uBAAwB,YAAa;AAEnE,QAAI,qBAAqB,QAAS,YAAY,IAAK,OAAQ,YAAY,IAAK;AAC5E,QAAK,yBAA0B;AAC9B,4BAAsB,aAAc,uBAAwB;AAAA,IAC7D;AAEA,eAAY,SAAS;AAAA,MACpB,GAAG;AAAA,MACH,aAAa;AAAA,IACd,CAAE;AAAA,EACH;AAMA,kBAAgB;AAEhB,aAAY,MAAM;AACjB,oBAAgB;AAAA,EACjB,GAAG,CAAE;AACN;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/save-crdt-doc.js"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": ";
|
|
4
|
+
"sourcesContent": ["import apiFetch from '@wordpress/api-fetch';\nimport { getSyncManager } from '../sync';\n\nconst SYNC_SAVE_API_PATH = '/wp-sync/v1/save';\nconst saveCRDTDocQueues = new Map();\n\nasync function serializeAndSaveCRDTDoc( objectType, objectId, room ) {\n\tconst serializedDoc = await getSyncManager()?.createPersistedCRDTDoc(\n\t\tobjectType,\n\t\tobjectId\n\t);\n\n\tif ( ! serializedDoc ) {\n\t\treturn;\n\t}\n\n\tawait apiFetch( {\n\t\tpath: SYNC_SAVE_API_PATH,\n\t\tmethod: 'POST',\n\t\tdata: {\n\t\t\troom,\n\t\t\tdoc: serializedDoc,\n\t\t},\n\t} );\n}\n\n/**\n * Persist the current CRDT document through the sync /save endpoint.\n *\n * @param {import('@wordpress/sync').ObjectType} objectType Object type.\n * @param {import('@wordpress/sync').ObjectID} objectId Object ID.\n */\nexport async function saveCRDTDoc( objectType, objectId ) {\n\tconst room = `${ objectType }:${ objectId }`;\n\n\t// Saves are chained per-room, which forms a queue.\n\t// Without a queue, two /save calls might fire close together with a risk\n\t// that the older serialized CRDT snapshot completes after the newer one and\n\t// overwrites it with stale data.\n\t// Wait for the prior request chain to complete before firing the next save.\n\tconst previousSave = saveCRDTDocQueues.get( room ) || Promise.resolve();\n\n\tconst currentSave = previousSave\n\t\t// A failed save should reject its caller, but not block later saves.\n\t\t.catch( () => {} )\n\t\t.then( () => serializeAndSaveCRDTDoc( objectType, objectId, room ) );\n\n\tsaveCRDTDocQueues.set( room, currentSave );\n\n\ttry {\n\t\tawait currentSave;\n\t} finally {\n\t\tif ( saveCRDTDocQueues.get( room ) === currentSave ) {\n\t\t\tsaveCRDTDocQueues.delete( room );\n\t\t}\n\t}\n}\n"],
|
|
5
|
+
"mappings": ";AAAA,OAAO,cAAc;AACrB,SAAS,sBAAsB;AAE/B,IAAM,qBAAqB;AAC3B,IAAM,oBAAoB,oBAAI,IAAI;AAElC,eAAe,wBAAyB,YAAY,UAAU,MAAO;AACpE,QAAM,gBAAgB,MAAM,eAAe,GAAG;AAAA,IAC7C;AAAA,IACA;AAAA,EACD;AAEA,MAAK,CAAE,eAAgB;AACtB;AAAA,EACD;AAEA,QAAM,SAAU;AAAA,IACf,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,MAAM;AAAA,MACL;AAAA,MACA,KAAK;AAAA,IACN;AAAA,EACD,CAAE;AACH;AAQA,eAAsB,YAAa,YAAY,UAAW;AACzD,QAAM,OAAO,GAAI,UAAW,IAAK,QAAS;AAO1C,QAAM,eAAe,kBAAkB,IAAK,IAAK,KAAK,QAAQ,QAAQ;AAEtE,QAAM,cAAc,aAElB,MAAO,MAAM;AAAA,EAAC,CAAE,EAChB,KAAM,MAAM,wBAAyB,YAAY,UAAU,IAAK,CAAE;AAEpE,oBAAkB,IAAK,MAAM,WAAY;AAEzC,MAAI;AACH,UAAM;AAAA,EACP,UAAE;AACD,QAAK,kBAAkB,IAAK,IAAK,MAAM,aAAc;AACpD,wBAAkB,OAAQ,IAAK;AAAA,IAChC;AAAA,EACD;AACD;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/build-types/actions.d.ts
CHANGED
|
@@ -155,11 +155,15 @@ export declare const deleteEntityRecord: (kind: string, name: string, recordId:
|
|
|
155
155
|
* @param {Object} edits The edits.
|
|
156
156
|
* @param {Object} options Options for the edit.
|
|
157
157
|
* @param {boolean} [options.undoIgnore] Whether to ignore the edit in undo history or not.
|
|
158
|
+
* @param {boolean} [options.isCached] Whether the edit is transient (e.g. typing). Transient
|
|
159
|
+
* edits are staged and eventually merged into the
|
|
160
|
+
* preceding undo level instead of creating a new one.
|
|
158
161
|
*
|
|
159
162
|
* @return {Object} Action object.
|
|
160
163
|
*/
|
|
161
164
|
export declare const editEntityRecord: (kind: string, name: string, recordId: number | string, edits: any, options?: {
|
|
162
165
|
undoIgnore?: boolean;
|
|
166
|
+
isCached?: boolean;
|
|
163
167
|
}) => any;
|
|
164
168
|
/**
|
|
165
169
|
* Action triggered to clear all edits from
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"actions.d.ts","sourceRoot":"","sources":["../src/actions.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"actions.d.ts","sourceRoot":"","sources":["../src/actions.js"],"names":[],"mappings":"AAkFA;;;;;;;;;;GAUG;AACH,wBAAgB,gBAAgB,CAAE,OAAO,EAL9B,MAK8B,EAAE,KAAK,EAJrC,WAIqC,OAM/C;AAED;;;;;;;;;GASG;AACH,wBAAgB,kBAAkB,CAAE,WAAW,KAAA,OAK9C;AAED;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAE,QAAQ,OAAA,OAKpC;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,oBAAoB,CACnC,IAAI,EAVM,MAUN,EACJ,IAAI,EAVM,MAUN,EACJ,OAAO,EAVG,WAUH,EACP,KAAK,GAVK,UAUO,EACjB,eAAe,GAVJ,OAAO,OAUK,E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AAM,GAAC,MAAM,WACb,WAAY,SACZ,UAAO,mBACN,OAAO,2BACR,UAAO;;;mBAuBhB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"awareness-state.d.ts","sourceRoot":"","sources":["../../src/awareness/awareness-state.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"awareness-state.d.ts","sourceRoot":"","sources":["../../src/awareness/awareness-state.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,KAAK,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAWjE,uBAAe,2BAA2B,CACzC,KAAK,SAAS,MAAM,CACnB,SAAQ,cAAc,CAAE,KAAK,CAAE;IAChC,yBAAyB;IAEzB;;;;;;;OAOG;IACI,kBAAkB,CAAE,SAAS,SAAS,MAAM,GAAG,MAAM,KAAK,EAChE,KAAK,EAAE,SAAS,EAChB,KAAK,EAAE,KAAK,CAAE,SAAS,CAAE,GACvB,IAAI,CAYN;IAED,0BAA0B;IAE1B;;;OAGG;IACH,SAAS,CAAC,QAAQ,CAAC,mBAAmB,EAAE;SACrC,SAAS,IAAI,MAAM,KAAK,GAAI,kBAAkB,CAAE,KAAK,EAAE,SAAS,CAAE;KACpE,CAAC;IAEF,qBAAqB;IAErB;;;;;OAKG;IACH,SAAS,CAAC,YAAY,CAAE,SAAS,SAAS,MAAM,KAAK,EACpD,KAAK,EAAE,SAAS,EAChB,MAAM,CAAC,EAAE,KAAK,CAAE,SAAS,CAAE,EAC3B,MAAM,CAAC,EAAE,KAAK,CAAE,SAAS,CAAE,GACzB,OAAO,CAeT;IAED;;;;;OAKG;IACH,SAAS,CAAC,YAAY,CAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,GAAI,OAAO,CAY9D;CACD;AAED;;;GAGG;AACH,8BAAsB,cAAc,CACnC,KAAK,SAAS,MAAM,GAAG,EAAE,CACxB,SAAQ,2BAA2B,CAAE,KAAK,CAAE;IAC7C,wBAAwB;IAExB;;;OAGG;IACH,OAAO,CAAC,WAAW,CAAS;IAE5B;;;;;;;OAOG;IACH,OAAO,CAAC,yBAAyB,CAA4B;IAC7D,OAAO,CAAC,UAAU,CAAmC;IAErD;;;OAGG;IACH,OAAO,CAAC,gBAAgB,CAA+C;IACvE,OAAO,CAAC,kBAAkB,CAEnB;IAEP;;;;;OAKG;IACH,OAAO,CAAC,gBAAgB,CAAwB;IAChD,OAAO,CAAC,gBAAgB,CAA4C;IAEpE,qBAAqB;IAErB;;;;;;;OAOG;IACH,SAAgB,KAAK,QAAO,IAAI,CA8B9B;IAEF;;;;;OAKG;IACH,SAAS,CAAC,QAAQ,CAAC,OAAO,IAAI,IAAI,CAAC;IAEnC;;;;OAIG;IACI,eAAe,IAAI,aAAa,CAAE,KAAK,CAAE,EAAE,CAEjD;IAED;;OAEG;IACI,aAAa,IAAI,GAAG,CAAE,MAAM,EAAE,KAAK,CAAE,CAE3C;IAED;;;OAGG;IACI,aAAa,CACnB,QAAQ,EAAE,CAAE,QAAQ,EAAE,aAAa,CAAE,KAAK,CAAE,EAAE,KAAM,IAAI,GACtD,MAAM,IAAI,CAQZ;IAED;;;;;;OAMG;IACI,2BAA2B,CACjC,SAAS,SAAS,MAAM,GAAG,MAAM,KAAK,EACpC,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,KAAK,CAAE,SAAS,CAAE,EAAE,IAAI,EAAE,MAAM,GAAI,IAAI,CAiBnE;IAED;;;OAGG;IACI,mBAAmB,CAAE,WAAW,EAAE,OAAO,GAAI,IAAI,CAQvD;IAED;;;OAGG;IACH,SAAS,CAAC,iBAAiB,CAAE,WAAW,UAAQ,GAAI,IAAI,CA8DvD;CACD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-awareness.d.ts","sourceRoot":"","sources":["../../src/awareness/base-awareness.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"base-awareness.d.ts","sourceRoot":"","sources":["../../src/awareness/base-awareness.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAEnD,OAAO,EAA4B,yBAAyB,EAAE,MAAM,SAAS,CAAC;AAC9E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC,8BAAsB,kBAAkB,CACvC,KAAK,SAAS,SAAS,CACtB,SAAQ,cAAc,CAAE,KAAK,CAAE;IAChC,SAAS,CAAC,OAAO,IAAI,IAAI,CAExB;IAED;;OAEG;YACW,0BAA0B;CAKxC;AAED,eAAO,MAAM,uBAAuB;IACnC,gBAAgB;CAChB,CAAC;AAEF,qBAAa,aAAc,SAAQ,kBAAkB,CAAE,SAAS,CAAE;IACjE,SAAS,CAAC,mBAAmB;;MAA2B;CACxD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"block-lookup.d.ts","sourceRoot":"","sources":["../../src/awareness/block-lookup.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"block-lookup.d.ts","sourceRoot":"","sources":["../../src/awareness/block-lookup.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,iBAAiB,CAAC;AAGpC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,UAAU,CAAC;AAGvD;;;;GAIG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC9B,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,gBAAgB,EAAE,CAAC;CAChC,CAAC;AAEF;;;;;;;;;;GAUG;AACH,wBAAgB,sBAAsB,CACrC,KAAK,EAAE,CAAC,CAAC,YAAY,CAAE,GAAG,CAAE,GAC1B,CAAC,CAAC,GAAG,CAAE,OAAO,CAAE,GAAG,IAAI,CAmBzB;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CACjC,KAAK,EAAE,CAAC,CAAC,GAAG,CAAE,OAAO,CAAE,GACrB,sBAAsB,GAAG,IAAI,CAuC/B;AAED;;;;;;;GAOG;AACH,wBAAgB,0BAA0B,CACzC,IAAI,EAAE,sBAAsB,EAC5B,MAAM,EAAE,gBAAgB,EAAE,GACxB,MAAM,GAAG,IAAI,CAgBf;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,oBAAoB,IAAI,gBAAgB,EAAE,CAQzD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"post-editor-awareness.d.ts","sourceRoot":"","sources":["../../src/awareness/post-editor-awareness.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"post-editor-awareness.d.ts","sourceRoot":"","sources":["../../src/awareness/post-editor-awareness.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,iBAAiB,CAAC;AAGpC,OAAO,EAAE,kBAAkB,EAA2B,MAAM,kBAAkB,CAAC;AAqB/E,OAAO,KAAK,EACX,iBAAiB,EACjB,cAAc,EAEd,MAAM,UAAU,CAAC;AAElB,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,KAAK,EAEX,WAAW,EACX,eAAe,EAEf,aAAa,EACb,MAAM,SAAS,CAAC;AAEjB,qBAAa,mBAAoB,SAAQ,kBAAkB,CAAE,eAAe,CAAE;IAQ5E,OAAO,CAAC,IAAI;IACZ,OAAO,CAAC,IAAI;IACZ,OAAO,CAAC,MAAM;IATf,SAAS,CAAC,mBAAmB;;+BA2KnB,WAAW,WACX,WAAW,KAClB,OAAO;MA1KR;IAEF,YACC,GAAG,EAAE,CAAC,CAAC,GAAG,EACF,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,EAGtB;IAED,SAAS,CAAC,OAAO,IAAI,IAAI,CAIxB;IAED;;OAEG;IACH,OAAO,CAAC,uCAAuC;IAsG/C;;;;;;OAMG;YACW,6BAA6B;IA+B3C;;;;;;OAMG;IACH,OAAO,CAAC,oBAAoB;IAe5B;;;;;;;;;;;;;;;;OAgBG;IACI,+BAA+B,CACrC,SAAS,EAAE,cAAc,EACzB,MAAM,EAAE,gBAAgB,EAAE,GACxB,iBAAiB,CAgFnB;IAED;;;;OAIG;IACH,OAAO,CAAC,OAAO;IAIf;;;;OAIG;IACI,YAAY,IAAI,aAAa,CAgEnC;CACD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typed-awareness.d.ts","sourceRoot":"","sources":["../../src/awareness/typed-awareness.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"typed-awareness.d.ts","sourceRoot":"","sources":["../../src/awareness/typed-awareness.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C;;GAEG;AACH,qBAAa,cAAc,CAAE,KAAK,SAAS,MAAM,CAAG,SAAQ,SAAS;IACpE;;OAEG;IACI,SAAS,IAAI,GAAG,CAAE,MAAM,EAAE,KAAK,CAAE,CAEvC;IAED;;;OAGG;IACI,kBAAkB,CAAE,SAAS,SAAS,MAAM,KAAK,EACvD,KAAK,EAAE,SAAS,GACd,KAAK,CAAE,SAAS,CAAE,GAAG,IAAI,CAG3B;IAED;;;;OAIG;IACI,kBAAkB,CAAE,SAAS,SAAS,MAAM,GAAG,MAAM,KAAK,EAChE,KAAK,EAAE,SAAS,EAChB,KAAK,EAAE,KAAK,CAAE,SAAS,CAAE,GACvB,IAAI,CAEN;CACD"}
|
|
@@ -1,10 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* WordPress dependencies
|
|
3
|
-
*/
|
|
4
1
|
import type { Y } from '@wordpress/sync';
|
|
5
|
-
/**
|
|
6
|
-
* Internal dependencies
|
|
7
|
-
*/
|
|
8
2
|
import type { SelectionState } from '../types';
|
|
9
3
|
import type { User } from '../entity-types';
|
|
10
4
|
export type CollaboratorInfo = Pick<User<'view'>, 'id' | 'name' | 'slug' | 'avatar_urls'> & {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/awareness/types.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/awareness/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAE5C,MAAM,MAAM,gBAAgB,GAAG,IAAI,CAClC,IAAI,CAAE,MAAM,CAAE,EACd,IAAI,GAAG,MAAM,GAAG,MAAM,GAAG,aAAa,CACtC,GAAG;IACH,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF;;;;GAIG;AACH,MAAM,WAAW,SAAS;IACzB,gBAAgB,EAAE,gBAAgB,CAAC;CACnC;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC3B,SAAS,CAAC,EAAE,cAAc,CAAC;CAC3B;AAED;;;GAGG;AACH,MAAM,WAAW,eAAgB,SAAQ,SAAS;IACjD,WAAW,CAAC,EAAE,WAAW,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,MAAM,aAAa,CAAE,KAAK,IAAK,KAAK,GAAG;IAC5C,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,OAAO,CAAC;IACrB,IAAI,EAAE,OAAO,CAAC;CACd,CAAC;AAEF;;;GAGG;AACH,MAAM,MAAM,wBAAwB,GAAG,aAAa,CAAE,eAAe,CAAE,CAAC;AAGxE,MAAM,MAAM,qBAAqB,GAAG,IAAI,CAAE,gBAAgB,EAAE,MAAM,CAAE,GAAG;IACtE,QAAQ,EAAE,gBAAgB,CAAE,IAAI,CAAE,CAAC;CACnC,CAAC;AAEF,MAAM,WAAW,aAAa;IAC7B,GAAG,EAAE,MAAM,CAAE,MAAM,EAAE,OAAO,CAAE,CAAC;IAC/B,OAAO,EAAE,MAAM,CAAE,MAAM,EAAE,KAAK,CAAE,iBAAiB,CAAE,CAAE,CAAC;IACtD,eAAe,EAAE,MAAM,CAAE,MAAM,EAAE,qBAAqB,CAAE,CAAC;CACzD;AAGD,MAAM,MAAM,oBAAoB,GAAG,IAAI,CACtC,CAAC,CAAC,IAAI,EACN,IAAI,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,CACtC,CAAC;AAGF,MAAM,MAAM,iBAAiB,GAAG,IAAI,CACnC,CAAC,CAAC,IAAI,EACJ,IAAI,GACJ,QAAQ,GACR,QAAQ,GACR,aAAa,GACb,QAAQ,GACR,WAAW,GACX,QAAQ,GACR,SAAS,GACT,MAAM,CACR,GAAG;IACH,IAAI,EAAE,oBAAoB,GAAG,IAAI,CAAC;IAClC,KAAK,EAAE,oBAAoB,GAAG,IAAI,CAAC;CACnC,CAAC;AAEF,MAAM,MAAM,kBAAkB,CAAE,KAAK,EAAE,SAAS,SAAS,MAAM,KAAK,IAAK,CACxE,MAAM,CAAC,EAAE,KAAK,CAAE,SAAS,CAAE,EAC3B,MAAM,CAAC,EAAE,KAAK,CAAE,SAAS,CAAE,KACvB,OAAO,CAAC;AAEb,MAAM,WAAW,aAAa;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,eAAe,EAAE,MAAM,CAAC;IACxB,UAAU,EAAE,MAAM,GAAG,SAAS,CAAC;CAC/B"}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Internal dependencies
|
|
3
|
-
*/
|
|
4
1
|
import type { User } from '../entity-types';
|
|
5
2
|
import type { CollaboratorInfo } from './types';
|
|
6
3
|
export declare function areMapsEqual<Key, Value>(map1: Map<Key, Value>, map2: Map<Key, Value>, comparatorFn: (value1: Value, value2: Value) => boolean): boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/awareness/utils.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/awareness/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAoChD,wBAAgB,YAAY,CAAE,GAAG,EAAE,KAAK,EACvC,IAAI,EAAE,GAAG,CAAE,GAAG,EAAE,KAAK,CAAE,EACvB,IAAI,EAAE,GAAG,CAAE,GAAG,EAAE,KAAK,CAAE,EACvB,YAAY,EAAE,CAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,KAAM,OAAO,GACvD,OAAO,CAgBT;AAED;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CACxC,iBAAiB,CAAC,EAAE,gBAAgB,EACpC,iBAAiB,CAAC,EAAE,gBAAgB,GAClC,OAAO,CAgBT;AAED;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACvC,mBAAmB,EAAE,IAAI,CAAE,MAAM,CAAE,GACjC,gBAAgB,CAWlB;AAED,wBAAgB,cAAc,CAAE,UAAU,EAAE,GAAG,SAAS,MAAM,UAAU,EACvE,GAAG,EAAE,OAAO,EACZ,GAAG,EAAE,GAAG,GACN,UAAU,CAAE,GAAG,CAAE,GAAG,IAAI,CAM1B;AAED,wBAAgB,YAAY,CAAE,CAAC,SAAS,MAAM,EAAI,GAAG,EAAE,CAAC,GAAI,KAAK,CAAE,MAAM,CAAC,CAAE,CAE3E"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-batch.d.ts","sourceRoot":"","sources":["../../src/batch/create-batch.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"create-batch.d.ts","sourceRoot":"","sources":["../../src/batch/create-batch.js"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AACH,MAAM,CAAC,OAAO,UAAU,WAAW,CAAE,SAAS,AAP3C,CAMF,UACgE;IAO/D;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACH,GAAG,eAPQ,GAAG,WAAS,GAEX,eAAQ,GAAG;IA4BvB;;;;;;OAMG;IACG,GAAG,IAHG,OAAO,CAAC,OAAO,CAAC;EAqD7B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"default-processor.d.ts","sourceRoot":"","sources":["../../src/batch/default-processor.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"default-processor.d.ts","sourceRoot":"","sources":["../../src/batch/default-processor.js"],"names":[],"mappings":"AAoBA;;;;;;;;GAQG;AACH,wBAA8B,gBAAgB,CAAE,QAAQ,OAAA,gBAgDvD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entity-record-item.d.ts","sourceRoot":"","sources":["../../../src/components/entities-saved-states/entity-record-item.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"entity-record-item.d.ts","sourceRoot":"","sources":["../../../src/components/entities-saved-states/entity-record-item.js"],"names":[],"mappings":"AAOA,MAAM,CAAC,OAAO,UAAU,gBAAgB,CAAE,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE;;;;CAAA,+BA6CtE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entity-type-list.d.ts","sourceRoot":"","sources":["../../../src/components/entities-saved-states/entity-type-list.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"entity-type-list.d.ts","sourceRoot":"","sources":["../../../src/components/entities-saved-states/entity-type-list.js"],"names":[],"mappings":"AAoEA,MAAM,CAAC,OAAO,UAAU,cAAc,CAAE,EACvC,IAAI,EACJ,kBAAkB,EAClB,qBAAqB,GACrB;;;;CAAA,+BAkDA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-is-dirty.d.ts","sourceRoot":"","sources":["../../../../src/components/entities-saved-states/hooks/use-is-dirty.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"use-is-dirty.d.ts","sourceRoot":"","sources":["../../../../src/components/entities-saved-states/hooks/use-is-dirty.js"],"names":[],"mappings":"AAIA;;;;;;;;GAQG;AACH,eAAO,MAAM,UAAU,WAoFtB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/entities-saved-states/index.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/entities-saved-states/index.js"],"names":[],"mappings":"AAkBA;;;;;;;;;GASG;AACH,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAE,EAC5C,KAAK,EACL,YAAY,EACZ,OAAO,GACP,EAVE;IAAwB,KAAK,WAC7B;IAAwB,YAAY,AAApC,CACA,EADQ,OAAO,YAAC,CAChB;IAAwB,OAAO,EAAvB,MAAM,CAEd;CAMF,GANW,KAAK,CAAC,SAAS,CAgB1B;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,6BAA6B,CAAE,EAC9C,gBAA4B,EAC5B,KAAK,EACL,MAAkB,EAClB,WAAW,EAAE,eAA2B,EACxC,SAAwB,EACxB,YAAY,EACZ,kBAAkB,EAClB,OAAO,EACP,qBAAqB,EACrB,kBAAkB,EAClB,OAAmB,EACnB,oBAAoB,GACpB,EA5BE;IAAwB,gBAAgB,EAAhC,MAAM,CACd;IAAwB,KAAK,WAC7B;IAAwB,MAAM,WAC9B;IAAwB,WAAW,EAA3B,OAAO,CACf;IAAwB,SAAS,EAAzB,MAAM,CACd;IAAwB,YAAY,EAA5B,OAAO,CACf;IAAwB,kBAAkB,QAC1C;IAAwB,OAAO,EAAvB,OAAO,CACf;IAAwB,qBAAqB,WAC7C;IAAwB,kBAAkB,QAC1C;IAAwB,OAAO,EAAvB,MAAM,CACd;IAAwB,oBAAoB,EAApC,MAAM,CAEd;CAeF,GAfW,KAAK,CAAC,SAAS,CAyK1B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dynamic-entities.d.ts","sourceRoot":"","sources":["../src/dynamic-entities.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"dynamic-entities.d.ts","sourceRoot":"","sources":["../src/dynamic-entities.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC9D,OAAO,KAAK,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAE1C,MAAM,MAAM,aAAa,CAAE,CAAC,SAAS,EAAE,CAAC,OAAO,GAAG,MAAM,IAAK;IAC5D,OAAO,EAAE,EAAE,CAAC,OAAO,CAAE,CAAC,CAAE,CAAC;IACzB,YAAY,EAAE,EAAE,CAAC,oBAAoB,CAAE,CAAC,CAAE,CAAC;IAC3C,KAAK,EAAE,EAAE,CAAC,UAAU,CAAE,CAAC,CAAE,CAAC;IAC1B,IAAI,EAAE,EAAE,CAAC,OAAO,CAAE,CAAC,CAAE,CAAC;IACtB,QAAQ,EAAE,EAAE,CAAC,WAAW,CAAE,CAAC,CAAE,CAAC;IAC9B,YAAY,EAAE,EAAE,CAAC,YAAY,CAAE,CAAC,CAAE,CAAC;IACnC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAE,CAAC,CAAE,CAAC;IACvB,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAE,CAAC,CAAE,CAAC;IACvB,QAAQ,EAAE,EAAE,CAAC,YAAY,CAAE,CAAC,CAAE,CAAC;IAC/B,OAAO,EAAE,EAAE,CAAC,OAAO,CAAE,CAAC,CAAE,CAAC;IACzB,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAE,CAAC,CAAE,CAAC;IACvB,MAAM,EAAE,EAAE,CAAC,gBAAgB,CAAE,CAAC,CAAE,CAAC;IACjC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAE,CAAC,CAAE,CA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GAAG,IAAI,MAAO,eAAe,CAAE,MAAM,aAAa,CAAG,EAAE,GAAI,CAC5D,KAAK,EAAE,KAAK,EACZ,KAAK,CAAC,EAAE,mBAAmB,KACvB,KAAK,CACT,aAAa,CAAE,GAAG,SAAS,MAAO,MAAM,CAAE,EAAE,GACzC,iBAAiB,CAAE,CAAC,CAAE,GACtB,KAAK,CAAE,CACV,GAAG,IAAI;CACR,CAAC;AAEF,KAAK,aAAa,GAAG;IACpB,YAAY,CAAC,EAAE,OAAO,CAAC;CACvB,CAAC;AAEF,KAAK,sBAAsB,GAAG,MAAM,CAAE,MAAM,EAAE,GAAG,CAAE,CAAC;AAEpD,MAAM,MAAM,WAAW,GAAG;KACvB,GAAG,IAAI,OAAQ,MAAM,aAAc,EAAE,GAAI,CAC1C,IAAI,EAAE,OAAO,CACZ,aAAa,CAAE,GAAG,SAAS,OAAQ,MAAM,CAAE,EAAE,GAAG,CAAC,GAAG,KAAK,CAAE,CAC3D,EACD,OAAO,CAAC,EAAE,aAAa,KACnB,OAAO,CAAE,IAAI,CAAE;CACpB,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;KACzB,GAAG,IAAI,SAAU,MAAM,aAAc,EAAE,GAAI,CAC5C,EAAE,EAAE,MAAM,GAAG,MAAM,EACnB,KAAK,CAAC,EAAE,sBAAsB,EAC9B,OAAO,CAAC,EAAE,aAAa,KACnB,OAAO,CAAE,IAAI,CAAE;CACpB,CAAC;AAEF,eAAO,IAAI,cAAc,EAAE,WAAW,GAAG,aAAa,CAAC;AAEvD,eAAO,IAAI,gBAAgB,EAAE,eAAe,GAAG,aAAa,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entities.d.ts","sourceRoot":"","sources":["../src/entities.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"entities.d.ts","sourceRoot":"","sources":["../src/entities.js"],"names":[],"mappings":"AAcA,eAAO,MAAM,kBAAkB,OAAO,CAAC;AAYvC,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAsEX,MAAM;;;;;;;;;;;;;;;;;;;QAUN,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAgJzB,CAAC;AAEF,eAAO,MAAM,kBAAkB;IAC9B,IAAI;QACH,KAAK;YACJ,KAAK;YACL,WAAW;gBACV,IAAI;gBACJ,IAAI;;;;CAIP,CAAC;AAEF,eAAO,MAAM,6BAA6B;;;;;;;;;;IASzC,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,kBAAkB,2CAJpB,MAAM,cACN,OAAO,KACN,OAAO,KAgDlB,CAAC;AAEF;;;;GAIG;AACH,iBAAe,oBAAoB,iBA2IlC;AA6BD;;;;GAIG;AACH,iBAAe,cAAc,iBA2B5B;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,aAAa,SANf,MAAM,QACN,MAAM,WACN,MAAM,KAEL,MAMX,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entity-context.d.ts","sourceRoot":"","sources":["../src/entity-context.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"entity-context.d.ts","sourceRoot":"","sources":["../src/entity-context.js"],"names":[],"mappings":"AAEA,eAAO,MAAM,aAAa,6BAAsB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entity-provider.d.ts","sourceRoot":"","sources":["../src/entity-provider.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"entity-provider.d.ts","sourceRoot":"","sources":["../src/entity-provider.js"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,CAAC,OAAO,UAAU,cAAc,CAAE,EACvC,IAAI,EACJ,IAAI,EAAE,IAAI,EACV,EAAE,EACF,UAAU,EACV,QAAQ,GACR,EAlBE;IAAsB,IAAI,EAAlB,MAAM,CACd;IAAsB,IAAI,EAAlB,MAAM,CACd;IAAsB,EAAE,EAAhB,MAAM,CACd;IAAuB,UAAU,AAAjC,CAIA,EAJQ,MAAM,CAId;IAAsB,QAAQ,EAAtB,GAAC,CAET;CASF,OAoBA"}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Internal dependencies
|
|
3
|
-
*/
|
|
4
1
|
import type { Context, ContextualField, MediaType, PostStatus, RenderedText, OmitNevers, CommentingStatus, PingStatus } from './helpers';
|
|
5
2
|
import type { BaseEntityRecords as _BaseEntityRecords } from './base-entity-records';
|
|
6
3
|
interface MediaDetails {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"attachment.d.ts","sourceRoot":"","sources":["../../src/entity-types/attachment.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"attachment.d.ts","sourceRoot":"","sources":["../../src/entity-types/attachment.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACX,OAAO,EACP,eAAe,EACf,SAAS,EACT,UAAU,EACV,YAAY,EACZ,UAAU,EACV,gBAAgB,EAChB,UAAU,EACV,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAAE,iBAAiB,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAErF,UAAU,YAAY;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB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AAQ,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YACxD;;eAEG;YACH,QAAQ,EAAE,MAAM,CAAC;YACjB;;eAEG;YACH,OAAO,EAAE,eAAe,CAAE,YAAY,CAAE,CAAC,CAAE,EAAE,MAAM,EAAE,CAAC,CAAE,CAAC;YACzD;;eAEG;YACH,WAAW,EAAE,eAAe,CAC3B,YAAY,CAAE,CAAC,CAAE,EACjB,MAAM,GAAG,MAAM,EACf,CAAC,CACD,CAAC;YACF;;eAEG;YACH,UAAU,EAAE,SAAS,CAAC;YACtB;;eAEG;YACH,SAAS,EAAE,MAAM,CAAC;YAClB;;eAEG;YACH,aAAa,EAAE,YAAY,CAAC;YAC5B;;eAEG;YACH,IAAI,EAAE,eAAe,CAAE,MAAM,GAAG,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YAC3D;;eAEG;YACH,UAAU,EAAE,MAAM,CAAC;YACnB;;eAEG;YACH,mBAAmB,EAAE,eAAe,CAAE,MAAM,EAAE,EAAE,MAAM,EAAE,CAAC,CAAE,CAAC;YAC5D;;eAEG;YACH,cAAc,EAAE,MAAM,CAAC;YACvB;;eAEG;YACH,UAAU,EAAE,MAAM,EAAE,CAAC;YACrB;;eAEG;YACH,MAAM,CAAC,EAAE,MAAM,CAAE,MAAM,EAAE,OAAO,CAAE,CAAC;SACnC;KACD;CACD;AAED,MAAM,MAAM,UAAU,CAAE,CAAC,SAAS,OAAO,GAAG,MAAM,IAAK,UAAU,CAChE,kBAAkB,CAAC,UAAU,CAAE,CAAC,CAAE,CAClC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../src/entity-types/base.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../src/entity-types/base.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE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|
|
2
|
-
* Internal dependencies
|
|
3
|
-
*/
|
|
4
1
|
import type { AvatarUrls, Context, ContextualField, OmitNevers, RenderedText } from './helpers';
|
|
5
2
|
import type { BaseEntityRecords as _BaseEntityRecords } from './base-entity-records';
|
|
6
3
|
export type CommentStatus = 'hold' | 'approve' | 'spam' | 'trash' | '1' | '0';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"comment.d.ts","sourceRoot":"","sources":["../../src/entity-types/comment.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"comment.d.ts","sourceRoot":"","sources":["../../src/entity-types/comment.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACX,UAAU,EACV,OAAO,EACP,eAAe,EACf,UAAU,EACV,YAAY,EACZ,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAAE,iBAAiB,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAErF,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,GAAG,GAAG,GAAG,GAAG,CAAC;AAE9E,OAAO,QAAQ,uBAAuB,CAAC;IACtC,UAAiB,iBAAiB,CAAC;QAClC,UAAiB,OAAO,CAAE,CAAC,SAAS,OAAO;YAC1C;;eAEG;YACH,EAAE,EAAE,MAAM,CAAC;YACX;;eAEG;YACH,MAAM,EAAE,MAAM,CAAC;YACf;;eAEG;YACH,YAAY,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAE,CAAC;YACnD;;eAEG;YACH,SAAS,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAE,CAAC;YAChD;;eAEG;YACH,WAAW,EAAE,MAAM,CAAC;YACpB;;eAEG;YACH,UAAU,EAAE,MAAM,CAAC;YACnB;;eAEG;YACH,iBAAiB,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAE,CAAC;YACxD;;eAEG;YACH,OAAO,EAAE,YAAY,CAAE,CAAC,CAAE,CAAC;YAC3B;;eAEG;YACH,IAAI,EAAE,MAAM,CAAC;YACb;;eAEG;YACH,QAAQ,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YACxD;;eAEG;YACH,IAAI,EAAE,MAAM,CAAC;YACb;;eAEG;YACH,MAAM,EAAE,MAAM,CAAC;YACf;;eAEG;YACH,IAAI,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YACpD;;eAEG;YACH,MAAM,EAAE,eAAe,CAAE,aAAa,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YAC7D;;eAEG;YACH,IAAI,EAAE,MAAM,CAAC;YACb;;eAEG;YACH,kBAAkB,EAAE,UAAU,CAAC;YAC/B;;eAEG;YACH,IAAI,EAAE,eAAe,CACpB,MAAM,CAAE,MAAM,EAAE,OAAO,CAAE,EACzB,MAAM,GAAG,MAAM,EACf,CAAC,CACD,CAAC;SACF;KACD;CACD;AAED,MAAM,MAAM,OAAO,CAAE,CAAC,SAAS,OAAO,GAAG,MAAM,IAAK,UAAU,CAC7D,kBAAkB,CAAC,OAAO,CAAE,CAAC,CAAE,CAC/B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"font-collection.d.ts","sourceRoot":"","sources":["../../src/entity-types/font-collection.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"font-collection.d.ts","sourceRoot":"","sources":["../../src/entity-types/font-collection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACzC,OAAO,KAAK,EAAE,iBAAiB,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AACrF,OAAO,KAAK,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE1D,OAAO,QAAQ,uBAAuB,CAAC;IACtC,UAAiB,iBAAiB,CAAC;QAElC,UAAiB,cAAc,CAAE,CAAC,SAAS,OAAO;YACjD;;eAEG;YACH,IAAI,EAAE,MAAM,CAAC;YACb;;eAEG;YACH,IAAI,EAAE,MAAM,CAAC;YACb;;eAEG;YACH,WAAW,CAAC,EAAE,MAAM,CAAC;YACrB;;eAEG;YACH,aAAa,CAAC,EAAE,oBAAoB,EAAE,CAAC;YACvC;;eAEG;YACH,UAAU,CAAC,EAAE,KAAK,CAAE;gBACnB,IAAI,EAAE,MAAM,CAAC;gBACb,IAAI,EAAE,MAAM,CAAC;aACb,CAAE,CAAC;SACJ;KACD;CACD;AAED;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACpC,EAAE,EAAE,MAAM,CAAC;IACX,oBAAoB,EAAE,UAAU,CAAC;IACjC,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,SAAS,CAAC,EAAE;QACX,UAAU,CAAC,EAAE,kBAAkB,EAAE,CAAC;KAClC,CAAC;CACF;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IAClC,EAAE,EAAE,MAAM,CAAC;IACX,kBAAkB,EAAE,QAAQ,CAAC;CAC7B;AAED,MAAM,MAAM,cAAc,CAAE,CAAC,SAAS,OAAO,GAAG,MAAM,IACrD,kBAAkB,CAAC,cAAc,CAAE,CAAC,CAAE,CAAC;AAExC,YAAY,EAAE,kBAAkB,IAAI,iBAAiB,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"font-family.d.ts","sourceRoot":"","sources":["../../src/entity-types/font-family.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"font-family.d.ts","sourceRoot":"","sources":["../../src/entity-types/font-family.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACX,OAAO,EACP,eAAe,EACf,YAAY,EACZ,UAAU,EACV,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAAE,iBAAiB,IAAI,kBAAkB,EAA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ACnB,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC7B,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IACxB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,YAAY,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,MAAM,YAAY,CAAE,CAAC,SAAS,OAAO,GAAG,MAAM,IAAK,UAAU,CAClE,kBAAkB,CAAC,YAAY,CAAE,CAAC,CAAE,CACpC,CAAC;AAEF,YAAY,EAAE,kBAAkB,IAAI,iBAAiB,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"global-styles-revision.d.ts","sourceRoot":"","sources":["../../src/entity-types/global-styles-revision.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"global-styles-revision.d.ts","sourceRoot":"","sources":["../../src/entity-types/global-styles-revision.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AACtE,OAAO,KAAK,EAAE,iBAAiB,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAErF,OAAO,QAAQ,uBAAuB,CAAC;IACtC,UAAiB,iBAAiB,CAAC;QAClC,UAAiB,oBAAoB,CAAE,CAAC,SAAS,OAAO;YACvD;;eAEG;YACH,MAAM,EAAE,MAAM,CAAC;YACf;;eAEG;YACH,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;YACpB;;eAEG;YACH,QAAQ,EAAE,eAAe,CAAE,MAAM,GAAG,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YAC/D;;eAEG;YACH,EAAE,EAAE,MAAM,CAAC;YACX;;eAEG;YACH,QAAQ,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YACxD;;eAEG;YACH,YAAY,EAAE,eAAe,CAAE,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,CAAE,CAAC;YAC5D;;eAEG;YACH,MAAM,EAAE,MAAM,CAAC;YACf,MAAM,EAAE,MAAM,CAAE,MAAM,EAAE,MAAM,CAAE,CAAC;YACjC,QAAQ,EAAE,MAAM,CAAE,MAAM,EAAE,MAAM,CAAE,CAAC;SACnC;KACD;CACD;AAED,MAAM,MAAM,oBAAoB,CAAE,CAAC,SAAS,OAAO,GAAG,MAAM,IAAK,UAAU,CAC1E,kBAAkB,CAAC,oBAAoB,CAAE,CAAC,CAAE,CAC5C,CAAC"}
|