@ynput/ayon-frontend-shared 0.2.28 → 0.2.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/DetailsPanel.cjs.js +1 -1
- package/dist/DetailsPanel.es.js +6 -6
- package/dist/Views.cjs.js.map +1 -1
- package/dist/Views.es.js.map +1 -1
- package/dist/api.cjs.js +1 -1
- package/dist/api.es.js +151 -153
- package/dist/components.cjs.js +1 -1
- package/dist/components.es.js +79 -86
- package/dist/components.es.js.map +1 -1
- package/dist/hooks.cjs.js +1 -1
- package/dist/hooks.es.js +8 -6
- package/dist/hooks.es.js.map +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.es.js +6 -6
- package/dist/node_modules/@ungap/structured-clone/esm/deserialize.cjs.js +2 -0
- package/dist/node_modules/@ungap/structured-clone/esm/deserialize.cjs.js.map +1 -0
- package/dist/node_modules/@ungap/structured-clone/esm/deserialize.es.js +63 -0
- package/dist/node_modules/@ungap/structured-clone/esm/deserialize.es.js.map +1 -0
- package/dist/node_modules/@ungap/structured-clone/esm/index.cjs.js +2 -0
- package/dist/node_modules/@ungap/structured-clone/esm/index.cjs.js.map +1 -0
- package/dist/node_modules/@ungap/structured-clone/esm/index.es.js +12 -0
- package/dist/node_modules/@ungap/structured-clone/esm/index.es.js.map +1 -0
- package/dist/node_modules/@ungap/structured-clone/esm/serialize.cjs.js +2 -0
- package/dist/node_modules/@ungap/structured-clone/esm/serialize.cjs.js.map +1 -0
- package/dist/node_modules/@ungap/structured-clone/esm/serialize.es.js +107 -0
- package/dist/node_modules/@ungap/structured-clone/esm/serialize.es.js.map +1 -0
- package/dist/node_modules/@ungap/structured-clone/esm/types.cjs.js +2 -0
- package/dist/node_modules/@ungap/structured-clone/esm/types.cjs.js.map +1 -0
- package/dist/node_modules/@ungap/structured-clone/esm/types.es.js +14 -0
- package/dist/node_modules/@ungap/structured-clone/esm/types.es.js.map +1 -0
- package/dist/node_modules/devlop/lib/default.cjs.js +2 -0
- package/dist/node_modules/devlop/lib/default.cjs.js.map +1 -0
- package/dist/node_modules/devlop/lib/default.es.js +6 -0
- package/dist/node_modules/devlop/lib/default.es.js.map +1 -0
- package/dist/node_modules/entities/dist/esm/decode-codepoint.cjs.js +2 -0
- package/dist/node_modules/entities/dist/esm/decode-codepoint.cjs.js.map +1 -0
- package/dist/node_modules/entities/dist/esm/decode-codepoint.es.js +39 -0
- package/dist/node_modules/entities/dist/esm/decode-codepoint.es.js.map +1 -0
- package/dist/node_modules/entities/dist/esm/decode.cjs.js +2 -0
- package/dist/node_modules/entities/dist/esm/decode.cjs.js.map +1 -0
- package/dist/node_modules/entities/dist/esm/decode.es.js +246 -0
- package/dist/node_modules/entities/dist/esm/decode.es.js.map +1 -0
- package/dist/node_modules/entities/dist/esm/generated/decode-data-html.cjs.js +2 -0
- package/dist/node_modules/entities/dist/esm/generated/decode-data-html.cjs.js.map +1 -0
- package/dist/node_modules/entities/dist/esm/generated/decode-data-html.es.js +8 -0
- package/dist/node_modules/entities/dist/esm/generated/decode-data-html.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/lib/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/lib/index.es.js +218 -0
- package/dist/node_modules/hast-util-raw/lib/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-from-parse5/lib/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-from-parse5/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-from-parse5/lib/index.es.js +146 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-from-parse5/lib/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-parse-selector/lib/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-parse-selector/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-parse-selector/lib/index.es.js +21 -0
- package/dist/node_modules/hast-util-raw/node_modules/hast-util-parse-selector/lib/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/create-h.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/create-h.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/create-h.es.js +113 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/create-h.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/index.es.js +9 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/svg-case-sensitive-tag-names.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/svg-case-sensitive-tag-names.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/svg-case-sensitive-tag-names.es.js +45 -0
- package/dist/node_modules/hast-util-raw/node_modules/hastscript/lib/svg-case-sensitive-tag-names.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/html-void-elements/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/html-void-elements/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/html-void-elements/index.es.js +26 -0
- package/dist/node_modules/hast-util-raw/node_modules/html-void-elements/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/doctype.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/doctype.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/doctype.es.js +99 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/doctype.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/error-codes.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/error-codes.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/error-codes.es.js +8 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/error-codes.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/foreign-content.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/foreign-content.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/foreign-content.es.js +211 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/foreign-content.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/html.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/html.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/html.es.js +251 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/html.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/token.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/token.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/token.es.js +15 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/token.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/unicode.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/unicode.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/unicode.es.js +74 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/unicode.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/formatting-element-list.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/formatting-element-list.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/formatting-element-list.es.js +85 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/formatting-element-list.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/index.es.js +2272 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/open-element-stack.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/open-element-stack.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/open-element-stack.es.js +241 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/open-element-stack.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/serializer/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/serializer/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/serializer/index.es.js +3 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/serializer/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.es.js +1941 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/preprocessor.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/preprocessor.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/preprocessor.es.js +89 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/preprocessor.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tree-adapters/default.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tree-adapters/default.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tree-adapters/default.es.js +163 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tree-adapters/default.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/index.es.js +13 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/aria.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/aria.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/aria.es.js +62 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/aria.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/find.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/find.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/find.es.js +34 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/find.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/html.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/html.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/html.es.js +369 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/html.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/normalize.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/normalize.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/normalize.es.js +7 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/normalize.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/svg.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/svg.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/svg.es.js +567 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/svg.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-insensitive-transform.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-insensitive-transform.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-insensitive-transform.es.js +8 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-insensitive-transform.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-sensitive-transform.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-sensitive-transform.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-sensitive-transform.es.js +7 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/case-sensitive-transform.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/create.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/create.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/create.es.js +20 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/create.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/defined-info.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/defined-info.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/defined-info.es.js +37 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/defined-info.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/info.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/info.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/info.es.js +29 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/info.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/merge.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/merge.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/merge.es.js +11 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/merge.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/schema.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/schema.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/schema.es.js +22 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/schema.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/types.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/types.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/types.es.js +15 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/util/types.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xlink.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xlink.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xlink.es.js +20 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xlink.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xml.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xml.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xml.es.js +12 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xml.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xmlns.cjs.js +2 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xmlns.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xmlns.es.js +12 -0
- package/dist/node_modules/hast-util-raw/node_modules/property-information/lib/xmlns.es.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/vfile-location/lib/index.cjs.js +3 -0
- package/dist/node_modules/hast-util-raw/node_modules/vfile-location/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-raw/node_modules/vfile-location/lib/index.es.js +43 -0
- package/dist/node_modules/hast-util-raw/node_modules/vfile-location/lib/index.es.js.map +1 -0
- package/dist/node_modules/hast-util-to-parse5/lib/index.cjs.js +2 -0
- package/dist/node_modules/hast-util-to-parse5/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/hast-util-to-parse5/lib/index.es.js +119 -0
- package/dist/node_modules/hast-util-to-parse5/lib/index.es.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/unified/lib/index.cjs.js +1 -1
- package/dist/node_modules/rehype/node_modules/unified/lib/index.cjs.js.map +1 -1
- package/dist/node_modules/rehype/node_modules/unified/lib/index.es.js +1 -1
- package/dist/node_modules/rehype/node_modules/unist-util-stringify-position/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/{vfile/node_modules/unist-util-stringify-position/lib/index.cjs.js.map → rehype/node_modules/unist-util-stringify-position/lib/index.es.js.map} +1 -1
- package/dist/node_modules/rehype/node_modules/vfile/lib/index.cjs.js +2 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/index.es.js +2 -2
- package/dist/node_modules/rehype/node_modules/vfile/lib/index.es.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minpath.browser.cjs.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minpath.browser.es.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minproc.browser.cjs.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minproc.browser.es.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minurl.browser.cjs.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minurl.browser.es.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minurl.shared.cjs.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile/lib/minurl.shared.es.js.map +1 -0
- package/dist/node_modules/rehype/node_modules/vfile-message/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/{vfile/node_modules/vfile-message/lib/index.cjs.js.map → rehype/node_modules/vfile-message/lib/index.es.js.map} +1 -1
- package/dist/node_modules/rehype-raw/lib/index.cjs.js +2 -0
- package/dist/node_modules/rehype-raw/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/rehype-raw/lib/index.es.js +13 -0
- package/dist/node_modules/rehype-raw/lib/index.es.js.map +1 -0
- package/dist/node_modules/unist-util-is/lib/index.cjs.js +2 -0
- package/dist/node_modules/unist-util-is/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/unist-util-is/lib/index.es.js +85 -0
- package/dist/node_modules/unist-util-is/lib/index.es.js.map +1 -0
- package/dist/node_modules/unist-util-position/lib/index.cjs.js +2 -0
- package/dist/node_modules/unist-util-position/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/unist-util-position/lib/index.es.js +18 -0
- package/dist/node_modules/unist-util-position/lib/index.es.js.map +1 -0
- package/dist/node_modules/unist-util-visit/lib/index.cjs.js +2 -0
- package/dist/node_modules/unist-util-visit/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/unist-util-visit/lib/index.es.js +17 -0
- package/dist/node_modules/unist-util-visit/lib/index.es.js.map +1 -0
- package/dist/node_modules/unist-util-visit-parents/lib/color.cjs.js +2 -0
- package/dist/node_modules/unist-util-visit-parents/lib/color.cjs.js.map +1 -0
- package/dist/node_modules/unist-util-visit-parents/lib/color.es.js +7 -0
- package/dist/node_modules/unist-util-visit-parents/lib/color.es.js.map +1 -0
- package/dist/node_modules/unist-util-visit-parents/lib/index.cjs.js +2 -0
- package/dist/node_modules/unist-util-visit-parents/lib/index.cjs.js.map +1 -0
- package/dist/node_modules/unist-util-visit-parents/lib/index.es.js +57 -0
- package/dist/node_modules/unist-util-visit-parents/lib/index.es.js.map +1 -0
- package/dist/node_modules/web-namespaces/index.cjs.js +1 -1
- package/dist/node_modules/web-namespaces/index.cjs.js.map +1 -1
- package/dist/node_modules/web-namespaces/index.es.js +8 -3
- package/dist/node_modules/web-namespaces/index.es.js.map +1 -1
- package/dist/shared/src/api/generated/entityLists.cjs.js.map +1 -1
- package/dist/shared/src/api/generated/entityLists.es.js.map +1 -1
- package/dist/shared/src/api/generated/folders.cjs.js.map +1 -1
- package/dist/shared/src/api/generated/folders.es.js.map +1 -1
- package/dist/shared/src/api/generated/graphql.cjs.js +5 -3
- package/dist/shared/src/api/generated/graphql.cjs.js.map +1 -1
- package/dist/shared/src/api/generated/graphql.es.js +14 -12
- package/dist/shared/src/api/generated/graphql.es.js.map +1 -1
- package/dist/shared/src/api/generated/views.cjs.js.map +1 -1
- package/dist/shared/src/api/generated/views.es.js.map +1 -1
- package/dist/shared/src/api/queries/entityLists/getLists.cjs.js +1 -1
- package/dist/shared/src/api/queries/entityLists/getLists.cjs.js.map +1 -1
- package/dist/shared/src/api/queries/entityLists/getLists.es.js +117 -142
- package/dist/shared/src/api/queries/entityLists/getLists.es.js.map +1 -1
- package/dist/shared/src/api/queries/entityLists/updateLists.cjs.js +1 -1
- package/dist/shared/src/api/queries/entityLists/updateLists.cjs.js.map +1 -1
- package/dist/shared/src/api/queries/entityLists/updateLists.es.js +95 -110
- package/dist/shared/src/api/queries/entityLists/updateLists.es.js.map +1 -1
- package/dist/shared/src/api/queries/links/getEntityLinks.cjs.js +1 -1
- package/dist/shared/src/api/queries/links/getEntityLinks.cjs.js.map +1 -1
- package/dist/shared/src/api/queries/links/getEntityLinks.es.js +41 -40
- package/dist/shared/src/api/queries/links/getEntityLinks.es.js.map +1 -1
- package/dist/shared/src/api/queries/links/updateLinks.cjs.js +1 -1
- package/dist/shared/src/api/queries/links/updateLinks.cjs.js.map +1 -1
- package/dist/shared/src/api/queries/links/updateLinks.es.js +164 -143
- package/dist/shared/src/api/queries/links/updateLinks.es.js.map +1 -1
- package/dist/shared/src/api/queries/users/getUsers.cjs.js +1 -1
- package/dist/shared/src/api/queries/users/getUsers.cjs.js.map +1 -1
- package/dist/shared/src/api/queries/users/getUsers.es.js +17 -21
- package/dist/shared/src/api/queries/users/getUsers.es.js.map +1 -1
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributesEditor.cjs.js +26 -37
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributesEditor.cjs.js.map +1 -1
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributesEditor.es.js +100 -97
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributesEditor.es.js.map +1 -1
- package/dist/shared/src/components/DetailsPanelAttributes/components/RenderFieldWidget.cjs.js +6 -5
- package/dist/shared/src/components/DetailsPanelAttributes/components/RenderFieldWidget.cjs.js.map +1 -1
- package/dist/shared/src/components/DetailsPanelAttributes/components/RenderFieldWidget.es.js +169 -62
- package/dist/shared/src/components/DetailsPanelAttributes/components/RenderFieldWidget.es.js.map +1 -1
- package/dist/shared/src/components/DetailsPanelDetails/BorderedSection.cjs.js +48 -0
- package/dist/shared/src/components/DetailsPanelDetails/BorderedSection.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/BorderedSection.es.js +87 -0
- package/dist/shared/src/components/DetailsPanelDetails/BorderedSection.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/DescriptionSection.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/DescriptionSection.cjs.js.map +1 -0
- package/dist/shared/src/components/{ListAttributeForm/ListAttributeForm.es.js → DetailsPanelDetails/DescriptionSection.es.js} +117 -105
- package/dist/shared/src/components/DetailsPanelDetails/DescriptionSection.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/DescriptionSection.styles.cjs.js +385 -0
- package/dist/shared/src/components/DetailsPanelDetails/DescriptionSection.styles.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/DescriptionSection.styles.es.js +401 -0
- package/dist/shared/src/components/DetailsPanelDetails/DescriptionSection.styles.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/DetailsPanelDetails.cjs.js +12 -0
- package/dist/shared/src/components/DetailsPanelDetails/DetailsPanelDetails.cjs.js.map +1 -0
- package/dist/shared/src/components/{LinksManager/LinksManagerDialog.es.js → DetailsPanelDetails/DetailsPanelDetails.es.js} +92 -91
- package/dist/shared/src/components/DetailsPanelDetails/DetailsPanelDetails.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/DetailsSection.cjs.js +51 -0
- package/dist/shared/src/components/DetailsPanelDetails/DetailsSection.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/DetailsSection.es.js +113 -0
- package/dist/shared/src/components/DetailsPanelDetails/DetailsSection.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/FieldLabel.cjs.js +8 -0
- package/dist/shared/src/components/DetailsPanelDetails/FieldLabel.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/FieldLabel.es.js +25 -0
- package/dist/shared/src/components/DetailsPanelDetails/FieldLabel.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useDescriptionEditor.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useDescriptionEditor.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useDescriptionEditor.es.js +61 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useDescriptionEditor.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityData.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityData.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityData.es.js +95 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityData.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityEditing.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityEditing.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityEditing.es.js +109 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityEditing.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFields.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFields.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFields.es.js +131 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFields.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFormData.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFormData.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFormData.es.js +64 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useEntityFormData.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useMentionSystem.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useMentionSystem.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useMentionSystem.es.js +28 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useMentionSystem.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useQuillFormats.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useQuillFormats.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useQuillFormats.es.js +6 -0
- package/dist/shared/src/components/DetailsPanelDetails/hooks/useQuillFormats.es.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/types.cjs.js +2 -0
- package/dist/shared/src/components/DetailsPanelDetails/types.cjs.js.map +1 -0
- package/dist/shared/src/components/DetailsPanelDetails/types.es.js +37 -0
- package/dist/shared/src/components/DetailsPanelDetails/types.es.js.map +1 -0
- package/dist/shared/src/components/EntityPanelUploader/EntityPanelUploader.cjs.js +1 -1
- package/dist/shared/src/components/EntityPanelUploader/EntityPanelUploader.cjs.js.map +1 -1
- package/dist/shared/src/components/EntityPanelUploader/EntityPanelUploader.es.js +9 -9
- package/dist/shared/src/components/LinksManager/AddNewLinks.cjs.js +1 -1
- package/dist/shared/src/components/LinksManager/AddNewLinks.cjs.js.map +1 -1
- package/dist/shared/src/components/LinksManager/AddNewLinks.es.js +5 -5
- package/dist/shared/src/components/LinksManager/CellEditingDialog.cjs.js +8 -0
- package/dist/shared/src/components/LinksManager/CellEditingDialog.cjs.js.map +1 -0
- package/dist/shared/src/components/LinksManager/CellEditingDialog.es.js +86 -0
- package/dist/shared/src/components/LinksManager/CellEditingDialog.es.js.map +1 -0
- package/dist/shared/src/components/LinksManager/LinkManagerItem.cjs.js +1 -1
- package/dist/shared/src/components/LinksManager/LinkManagerItem.cjs.js.map +1 -1
- package/dist/shared/src/components/LinksManager/LinkManagerItem.es.js +29 -20
- package/dist/shared/src/components/LinksManager/LinkManagerItem.es.js.map +1 -1
- package/dist/shared/src/components/LinksManager/LinksManager.cjs.js +1 -1
- package/dist/shared/src/components/LinksManager/LinksManager.cjs.js.map +1 -1
- package/dist/shared/src/components/LinksManager/LinksManager.es.js +55 -43
- package/dist/shared/src/components/LinksManager/LinksManager.es.js.map +1 -1
- package/dist/shared/src/components/LinksManager/LinksManager.styled.cjs.js +42 -9
- package/dist/shared/src/components/LinksManager/LinksManager.styled.cjs.js.map +1 -1
- package/dist/shared/src/components/LinksManager/LinksManager.styled.es.js +49 -16
- package/dist/shared/src/components/LinksManager/LinksManager.styled.es.js.map +1 -1
- package/dist/shared/src/components/LinksManager/hooks/useUpdateLinks.cjs.js +1 -1
- package/dist/shared/src/components/LinksManager/hooks/useUpdateLinks.cjs.js.map +1 -1
- package/dist/shared/src/components/LinksManager/hooks/useUpdateLinks.es.js +9 -9
- package/dist/shared/src/components/Powerpack/PowerpackButton.cjs.js +3 -3
- package/dist/shared/src/components/Powerpack/PowerpackButton.cjs.js.map +1 -1
- package/dist/shared/src/components/Powerpack/PowerpackButton.es.js +5 -5
- package/dist/shared/src/components/Powerpack/PowerpackButton.es.js.map +1 -1
- package/dist/shared/src/components/Powerpack/PowerpackDialog.cjs.js +1 -1
- package/dist/shared/src/components/Powerpack/PowerpackDialog.cjs.js.map +1 -1
- package/dist/shared/src/components/Powerpack/PowerpackDialog.es.js +6 -6
- package/dist/shared/src/components/ProjectTableSettings/ProjectTableSettings.cjs.js +2 -2
- package/dist/shared/src/components/ProjectTableSettings/ProjectTableSettings.cjs.js.map +1 -1
- package/dist/shared/src/components/ProjectTableSettings/ProjectTableSettings.es.js +26 -18
- package/dist/shared/src/components/ProjectTableSettings/ProjectTableSettings.es.js.map +1 -1
- package/dist/shared/src/components/ProjectTableSettings/TableSettingsFallback.cjs.js +1 -1
- package/dist/shared/src/components/ProjectTableSettings/TableSettingsFallback.cjs.js.map +1 -1
- package/dist/shared/src/components/ProjectTableSettings/TableSettingsFallback.es.js +27 -21
- package/dist/shared/src/components/ProjectTableSettings/TableSettingsFallback.es.js.map +1 -1
- package/dist/shared/src/components/QuillListStyles/QuillListStyles.cjs.js +59 -0
- package/dist/shared/src/components/QuillListStyles/QuillListStyles.cjs.js.map +1 -0
- package/dist/shared/src/components/QuillListStyles/QuillListStyles.es.js +63 -0
- package/dist/shared/src/components/QuillListStyles/QuillListStyles.es.js.map +1 -0
- package/dist/shared/src/components/RenameForm/RenameForm.cjs.js +31 -0
- package/dist/shared/src/components/RenameForm/RenameForm.cjs.js.map +1 -0
- package/dist/shared/src/components/RenameForm/RenameForm.es.js +396 -0
- package/dist/shared/src/components/RenameForm/RenameForm.es.js.map +1 -0
- package/dist/shared/src/components/ReviewablesList/ReviewablesList.cjs.js +1 -1
- package/dist/shared/src/components/ReviewablesList/ReviewablesList.cjs.js.map +1 -1
- package/dist/shared/src/components/ReviewablesList/ReviewablesList.es.js +6 -6
- package/dist/shared/src/components/ReviewablesList/ReviewablesUpload.cjs.js +1 -1
- package/dist/shared/src/components/ReviewablesList/ReviewablesUpload.cjs.js.map +1 -1
- package/dist/shared/src/components/ReviewablesList/ReviewablesUpload.es.js +6 -6
- package/dist/shared/src/components/ReviewablesList/SortableReviewableCard.cjs.js +1 -1
- package/dist/shared/src/components/ReviewablesList/SortableReviewableCard.cjs.js.map +1 -1
- package/dist/shared/src/components/ReviewablesList/SortableReviewableCard.es.js +6 -6
- package/dist/shared/src/components/SimpleFormDialog/SimpleFormDialog.cjs.js +1 -1
- package/dist/shared/src/components/SimpleFormDialog/SimpleFormDialog.cjs.js.map +1 -1
- package/dist/shared/src/components/SimpleFormDialog/SimpleFormDialog.es.js +6 -6
- package/dist/shared/src/components/StyledLink/StyledLink.cjs.js +14 -0
- package/dist/shared/src/components/StyledLink/StyledLink.cjs.js.map +1 -0
- package/dist/shared/src/components/StyledLink/StyledLink.es.js +19 -0
- package/dist/shared/src/components/StyledLink/StyledLink.es.js.map +1 -0
- package/dist/shared/src/components/VersionUploader/components/UploadVersionForm.cjs.js +1 -1
- package/dist/shared/src/components/VersionUploader/components/UploadVersionForm.cjs.js.map +1 -1
- package/dist/shared/src/components/VersionUploader/components/UploadVersionForm.es.js +6 -6
- package/dist/shared/src/containers/Actions/ActionConfigDialog.cjs.js +1 -1
- package/dist/shared/src/containers/Actions/ActionConfigDialog.cjs.js.map +1 -1
- package/dist/shared/src/containers/Actions/ActionConfigDialog.es.js +6 -6
- package/dist/shared/src/containers/Actions/InteractiveActionDialog.cjs.js +1 -1
- package/dist/shared/src/containers/Actions/InteractiveActionDialog.cjs.js.map +1 -1
- package/dist/shared/src/containers/Actions/InteractiveActionDialog.es.js +6 -6
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.cjs.js +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.cjs.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.es.js +193 -162
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.es.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.styled.cjs.js +1 -7
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.styled.cjs.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.styled.es.js +6 -13
- package/dist/shared/src/containers/DetailsPanel/DetailsPanel.styled.es.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelFiles/DetailsPanelFiles.cjs.js +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelFiles/DetailsPanelFiles.cjs.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelFiles/DetailsPanelFiles.es.js +6 -6
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelFloating/DetailsPanelFloating.cjs.js +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelFloating/DetailsPanelFloating.cjs.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelFloating/DetailsPanelFloating.es.js +6 -6
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.cjs.js +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.cjs.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.es.js +124 -114
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.es.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.styled.cjs.js +4 -3
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.styled.cjs.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.styled.es.js +1 -0
- package/dist/shared/src/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.styled.es.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/FeedContextWrapper.cjs.js +2 -0
- package/dist/shared/src/containers/DetailsPanel/FeedContextWrapper.cjs.js.map +1 -0
- package/dist/shared/src/containers/DetailsPanel/FeedContextWrapper.es.js +85 -0
- package/dist/shared/src/containers/DetailsPanel/FeedContextWrapper.es.js.map +1 -0
- package/dist/shared/src/containers/DetailsPanel/FeedFilters/FeedFilters.cjs.js +1 -1
- package/dist/shared/src/containers/DetailsPanel/FeedFilters/FeedFilters.cjs.js.map +1 -1
- package/dist/shared/src/containers/DetailsPanel/FeedFilters/FeedFilters.es.js +18 -18
- package/dist/shared/src/containers/DetailsPanel/FeedFilters/FeedFilters.es.js.map +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/EntityPickerDialog.cjs.js +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/EntityPickerDialog.cjs.js.map +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/EntityPickerDialog.es.js +6 -6
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTable.cjs.js +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTable.cjs.js.map +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTable.es.js +6 -6
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTableHeader.cjs.js +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTableHeader.cjs.js.map +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTableHeader.es.js +6 -6
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTableSearch.cjs.js +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTableSearch.cjs.js.map +1 -1
- package/dist/shared/src/containers/EntityPickerDialog/components/EntityTypeTableSearch.es.js +6 -6
- package/dist/shared/src/containers/Feed/components/ActivityDate.cjs.js +8 -3
- package/dist/shared/src/containers/Feed/components/ActivityDate.cjs.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/ActivityDate.es.js +21 -16
- package/dist/shared/src/containers/Feed/components/ActivityDate.es.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.cjs.js +1 -1
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.cjs.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.es.js +21 -21
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.es.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.styled.cjs.js +37 -8
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.styled.cjs.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.styled.es.js +44 -14
- package/dist/shared/src/containers/Feed/components/ActivityVersions/ActivityVersions.styled.es.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.cjs.js +2 -2
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.cjs.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.es.js +58 -57
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.es.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.styled.cjs.js +7 -58
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.styled.cjs.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.styled.es.js +14 -65
- package/dist/shared/src/containers/Feed/components/CommentInput/CommentInput.styled.es.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/modules/index.cjs.js +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/modules/index.cjs.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/modules/index.es.js +17 -15
- package/dist/shared/src/containers/Feed/components/CommentInput/modules/index.es.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/quillToMarkdown.cjs.js +7 -6
- package/dist/shared/src/containers/Feed/components/CommentInput/quillToMarkdown.cjs.js.map +1 -1
- package/dist/shared/src/containers/Feed/components/CommentInput/quillToMarkdown.es.js +27 -18
- package/dist/shared/src/containers/Feed/components/CommentInput/quillToMarkdown.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/ProjectTreeTable.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/ProjectTreeTable.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/ProjectTreeTable.es.js +53 -51
- package/dist/shared/src/containers/ProjectTreeTable/ProjectTreeTable.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/buildTreeTableColumns.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/buildTreeTableColumns.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/buildTreeTableColumns.es.js +280 -207
- package/dist/shared/src/containers/ProjectTreeTable/buildTreeTableColumns.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/components/GroupSettingsFallback.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/components/GroupSettingsFallback.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/components/GroupSettingsFallback.es.js +6 -6
- package/dist/shared/src/containers/ProjectTreeTable/context/CellEditingProvider.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/CellEditingProvider.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/CellEditingProvider.es.js +5 -5
- package/dist/shared/src/containers/ProjectTreeTable/context/ClipboardContext.cjs.js +3 -3
- package/dist/shared/src/containers/ProjectTreeTable/context/ClipboardContext.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/ClipboardContext.es.js +212 -206
- package/dist/shared/src/containers/ProjectTreeTable/context/ClipboardContext.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/ProjectDataContext.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/ProjectDataContext.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/ProjectDataContext.es.js +41 -34
- package/dist/shared/src/containers/ProjectTreeTable/context/ProjectDataContext.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/SelectionCellsProvider.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/SelectionCellsProvider.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/SelectionCellsProvider.es.js +5 -5
- package/dist/shared/src/containers/ProjectTreeTable/context/clipboard/clipboardValidation.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/clipboard/clipboardValidation.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/context/clipboard/clipboardValidation.es.js +130 -33
- package/dist/shared/src/containers/ProjectTreeTable/context/clipboard/clipboardValidation.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useAttributesList.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useAttributesList.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useAttributesList.es.js +10 -13
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useAttributesList.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useBuildGroupByTableData.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useBuildGroupByTableData.es.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useBuildProjectDataTable.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useBuildProjectDataTable.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useBuildProjectDataTable.es.js +48 -45
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useBuildProjectDataTable.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useCellContextMenu.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useCellContextMenu.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useCellContextMenu.es.js +104 -93
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useCellContextMenu.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useCheckSelectedCellsVisible.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useCheckSelectedCellsVisible.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useCheckSelectedCellsVisible.es.js +5 -5
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useGetGroupedFields.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useGetGroupedFields.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useGetGroupedFields.es.js +5 -5
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useKeyboardNavigation.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useKeyboardNavigation.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useKeyboardNavigation.es.js +111 -87
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useKeyboardNavigation.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useMoveEntities.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useMoveEntities.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useMoveEntities.es.js +9 -9
- package/dist/shared/src/containers/ProjectTreeTable/hooks/usePasteLinks.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/usePasteLinks.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/usePasteLinks.es.js +9 -9
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useQueryFilters.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useQueryFilters.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/hooks/useQueryFilters.es.js +5 -5
- package/dist/shared/src/containers/ProjectTreeTable/utils/cellUtils.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/utils/cellUtils.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/utils/cellUtils.es.js +5 -5
- package/dist/shared/src/containers/ProjectTreeTable/widgets/BooleanWidget.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/BooleanWidget.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/BooleanWidget.es.js +7 -7
- package/dist/shared/src/containers/ProjectTreeTable/widgets/BooleanWidget.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/CellWidget.cjs.js +2 -2
- package/dist/shared/src/containers/ProjectTreeTable/widgets/CellWidget.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/CellWidget.es.js +88 -74
- package/dist/shared/src/containers/ProjectTreeTable/widgets/CellWidget.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/EnumWidget.cjs.js +2 -2
- package/dist/shared/src/containers/ProjectTreeTable/widgets/EnumWidget.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/EnumWidget.es.js +66 -66
- package/dist/shared/src/containers/ProjectTreeTable/widgets/EnumWidget.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/LinksWidget.cjs.js +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/LinksWidget.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/LinksWidget.es.js +58 -61
- package/dist/shared/src/containers/ProjectTreeTable/widgets/LinksWidget.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/NameWidget.cjs.js +2 -0
- package/dist/shared/src/containers/ProjectTreeTable/widgets/NameWidget.cjs.js.map +1 -0
- package/dist/shared/src/containers/ProjectTreeTable/widgets/NameWidget.es.js +241 -0
- package/dist/shared/src/containers/ProjectTreeTable/widgets/NameWidget.es.js.map +1 -0
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidget.cjs.js +8 -3
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidget.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidget.es.js +82 -32
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidget.es.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidgetInput.cjs.js +2 -2
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidgetInput.cjs.js.map +1 -1
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidgetInput.es.js +79 -24
- package/dist/shared/src/containers/ProjectTreeTable/widgets/TextWidgetInput.es.js.map +1 -1
- package/dist/shared/src/containers/RepresentationsList/RepresentationsList.cjs.js +1 -1
- package/dist/shared/src/containers/RepresentationsList/RepresentationsList.cjs.js.map +1 -1
- package/dist/shared/src/containers/RepresentationsList/RepresentationsList.es.js +6 -6
- package/dist/shared/src/containers/SimpleTable/SimpleTable.cjs.js +1 -1
- package/dist/shared/src/containers/SimpleTable/SimpleTable.cjs.js.map +1 -1
- package/dist/shared/src/containers/SimpleTable/SimpleTable.es.js +109 -121
- package/dist/shared/src/containers/SimpleTable/SimpleTable.es.js.map +1 -1
- package/dist/shared/src/containers/SimpleTable/SimpleTable.styled.cjs.js +4 -16
- package/dist/shared/src/containers/SimpleTable/SimpleTable.styled.cjs.js.map +1 -1
- package/dist/shared/src/containers/SimpleTable/SimpleTable.styled.es.js +1 -13
- package/dist/shared/src/containers/SimpleTable/SimpleTable.styled.es.js.map +1 -1
- package/dist/shared/src/containers/SimpleTable/SimpleTableRowTemplate.cjs.js +1 -1
- package/dist/shared/src/containers/SimpleTable/SimpleTableRowTemplate.cjs.js.map +1 -1
- package/dist/shared/src/containers/SimpleTable/SimpleTableRowTemplate.es.js +50 -62
- package/dist/shared/src/containers/SimpleTable/SimpleTableRowTemplate.es.js.map +1 -1
- package/dist/shared/src/context/DetailsPanelContext.cjs.js.map +1 -1
- package/dist/shared/src/context/DetailsPanelContext.es.js.map +1 -1
- package/dist/shared/src/context/PowerpackContext.cjs.js +1 -1
- package/dist/shared/src/context/PowerpackContext.cjs.js.map +1 -1
- package/dist/shared/src/context/PowerpackContext.es.js +15 -20
- package/dist/shared/src/context/PowerpackContext.es.js.map +1 -1
- package/dist/shared/src/hooks/useActionTriggers.cjs.js +1 -1
- package/dist/shared/src/hooks/useActionTriggers.cjs.js.map +1 -1
- package/dist/shared/src/hooks/useActionTriggers.es.js +27 -32
- package/dist/shared/src/hooks/useActionTriggers.es.js.map +1 -1
- package/dist/shared/src/hooks/useTagStyling.cjs.js +2 -0
- package/dist/shared/src/hooks/useTagStyling.cjs.js.map +1 -0
- package/dist/shared/src/hooks/useTagStyling.es.js +33 -0
- package/dist/shared/src/hooks/useTagStyling.es.js.map +1 -0
- package/dist/shared/src/util/checkName.cjs.js +2 -0
- package/dist/shared/src/util/checkName.cjs.js.map +1 -0
- package/dist/shared/src/util/checkName.es.js +9 -0
- package/dist/shared/src/util/checkName.es.js.map +1 -0
- package/dist/shared/src/util/clipboardUtils.cjs.js +2 -0
- package/dist/shared/src/util/clipboardUtils.cjs.js.map +1 -0
- package/dist/shared/src/util/clipboardUtils.es.js +13 -0
- package/dist/shared/src/util/clipboardUtils.es.js.map +1 -0
- package/dist/shared/src/util/copyToClipboard.cjs.js +1 -1
- package/dist/shared/src/util/copyToClipboard.cjs.js.map +1 -1
- package/dist/shared/src/util/copyToClipboard.es.js +21 -21
- package/dist/shared/src/util/copyToClipboard.es.js.map +1 -1
- package/dist/shared/src/util/humanizeFieldName.cjs.js +2 -0
- package/dist/shared/src/util/humanizeFieldName.cjs.js.map +1 -0
- package/dist/shared/src/util/humanizeFieldName.es.js +15 -0
- package/dist/shared/src/util/humanizeFieldName.es.js.map +1 -0
- package/dist/shared/src/util/parseHtmlToPlainTextWithLinks.cjs.js +7 -0
- package/dist/shared/src/util/parseHtmlToPlainTextWithLinks.cjs.js.map +1 -0
- package/dist/shared/src/util/parseHtmlToPlainTextWithLinks.es.js +64 -0
- package/dist/shared/src/util/parseHtmlToPlainTextWithLinks.es.js.map +1 -0
- package/dist/types/api/generated/entityLists.d.ts +8 -8
- package/dist/types/api/generated/folders.d.ts +2 -0
- package/dist/types/api/generated/graphql.d.ts +20 -5
- package/dist/types/api/generated/index.d.ts +1 -0
- package/dist/types/api/generated/views.d.ts +9 -47
- package/dist/types/api/queries/entityLists/getLists.d.ts +0 -133
- package/dist/types/api/queries/entityLists/types.d.ts +1 -2
- package/dist/types/api/queries/permissions/getPermissions.d.ts +22 -22
- package/dist/types/api/queries/share/share.d.ts +1 -1
- package/dist/types/api/queries/users/getUsers.d.ts +0 -132
- package/dist/types/api/queries/users/updateUsers.d.ts +3 -3
- package/dist/types/components/DetailsPanelAttributes/DetailsPanelAttributesEditor.d.ts +2 -4
- package/dist/types/components/DetailsPanelAttributes/components/RenderFieldWidget.d.ts +3 -0
- package/dist/types/components/DetailsPanelAttributes/index.d.ts +0 -1
- package/dist/types/components/DetailsPanelDetails/BorderedSection.d.ts +14 -0
- package/dist/types/components/DetailsPanelDetails/DescriptionSection.d.ts +10 -0
- package/dist/types/components/DetailsPanelDetails/DescriptionSection.styles.d.ts +10 -0
- package/dist/types/components/DetailsPanelDetails/DetailsPanelDetails.d.ts +6 -0
- package/dist/types/components/DetailsPanelDetails/DetailsSection.d.ts +1 -1
- package/dist/types/components/DetailsPanelDetails/FieldLabel.d.ts +11 -0
- package/dist/types/components/DetailsPanelDetails/hooks/index.d.ts +7 -0
- package/dist/types/components/DetailsPanelDetails/hooks/useDescriptionEditor.d.ts +17 -0
- package/dist/types/components/DetailsPanelDetails/hooks/useEntityData.d.ts +12 -0
- package/dist/types/components/DetailsPanelDetails/hooks/useEntityEditing.d.ts +10 -0
- package/dist/types/components/DetailsPanelDetails/hooks/useEntityFields.d.ts +16 -0
- package/dist/types/components/DetailsPanelDetails/hooks/useEntityFormData.d.ts +8 -0
- package/dist/types/components/DetailsPanelDetails/hooks/useQuillFormats.d.ts +1 -0
- package/dist/types/components/DetailsPanelDetails/index.d.ts +2 -0
- package/dist/types/components/DetailsPanelDetails/types.d.ts +20 -0
- package/dist/types/components/EnumEditor/EnumEditor.styled.d.ts +1 -1
- package/dist/types/components/LinksManager/CellEditingDialog.d.ts +8 -0
- package/dist/types/components/Powerpack/index.d.ts +0 -1
- package/dist/types/components/QuillListStyles/QuillListStyles.d.ts +5 -0
- package/dist/types/components/QuillListStyles/index.d.ts +1 -0
- package/dist/types/components/RenameForm/RenameForm.d.ts +21 -0
- package/dist/types/components/RenameForm/index.d.ts +1 -0
- package/dist/types/components/StyledLink/StyledLink.d.ts +2 -0
- package/dist/types/components/StyledLink/index.d.ts +1 -0
- package/dist/types/components/index.d.ts +2 -4
- package/dist/types/containers/Actions/ActionsDropdown/ActionsDropdown.styled.d.ts +1 -1
- package/dist/types/containers/DetailsPanel/DetailsPanel.styled.d.ts +0 -7
- package/dist/types/containers/DetailsPanel/DetailsPanelHeader/DetailsPanelHeader.styled.d.ts +4 -4
- package/dist/types/containers/DetailsPanel/FeedContextWrapper.d.ts +19 -0
- package/dist/types/containers/Feed/components/ActivityVersions/ActivityVersions.styled.d.ts +1 -0
- package/dist/types/containers/Feed/components/CommentInput/modules/index.d.ts +2 -1
- package/dist/types/containers/ProjectTreeTable/buildTreeTableColumns.d.ts +1 -1
- package/dist/types/containers/ProjectTreeTable/context/ProjectDataContext.d.ts +2 -0
- package/dist/types/containers/ProjectTreeTable/context/clipboard/clipboardValidation.d.ts +10 -0
- package/dist/types/containers/ProjectTreeTable/hooks/useAttributesList.d.ts +5 -4
- package/dist/types/containers/ProjectTreeTable/hooks/useCellContextMenu.d.ts +1 -1
- package/dist/types/containers/ProjectTreeTable/types/table.d.ts +6 -0
- package/dist/types/containers/ProjectTreeTable/widgets/BooleanWidget.d.ts +0 -1
- package/dist/types/containers/ProjectTreeTable/widgets/CellWidget.d.ts +2 -1
- package/dist/types/containers/ProjectTreeTable/widgets/LinksWidget.d.ts +1 -0
- package/dist/types/containers/ProjectTreeTable/widgets/NameWidget.d.ts +10 -0
- package/dist/types/containers/ProjectTreeTable/widgets/TextWidget.d.ts +2 -0
- package/dist/types/containers/ProjectTreeTable/widgets/TextWidgetInput.d.ts +2 -0
- package/dist/types/containers/SimpleTable/SimpleTable.d.ts +0 -3
- package/dist/types/containers/SimpleTable/SimpleTableRowTemplate.d.ts +1 -5
- package/dist/types/containers/Views/index.d.ts +1 -4
- package/dist/types/context/DetailsPanelContext.d.ts +1 -1
- package/dist/types/context/PowerpackContext.d.ts +1 -1
- package/dist/types/hooks/index.d.ts +1 -0
- package/dist/types/hooks/useActionTriggers.d.ts +1 -1
- package/dist/types/hooks/useTagStyling.d.ts +17 -0
- package/dist/types/util/checkName.d.ts +1 -0
- package/dist/types/util/clipboardUtils.d.ts +18 -0
- package/dist/types/util/copyToClipboard.d.ts +1 -1
- package/dist/types/util/humanizeFieldName.d.ts +1 -0
- package/dist/types/util/index.d.ts +3 -0
- package/dist/types/util/parseHtmlToPlainTextWithLinks.d.ts +6 -0
- package/dist/util.cjs.js +1 -1
- package/dist/util.es.js +38 -32
- package/dist/util.es.js.map +1 -1
- package/package.json +1 -1
- package/dist/node_modules/vfile/lib/index.cjs.js +0 -2
- package/dist/node_modules/vfile/lib/index.cjs.js.map +0 -1
- package/dist/node_modules/vfile/lib/index.es.js.map +0 -1
- package/dist/node_modules/vfile/lib/minpath.browser.cjs.js.map +0 -1
- package/dist/node_modules/vfile/lib/minpath.browser.es.js.map +0 -1
- package/dist/node_modules/vfile/lib/minproc.browser.cjs.js.map +0 -1
- package/dist/node_modules/vfile/lib/minproc.browser.es.js.map +0 -1
- package/dist/node_modules/vfile/lib/minurl.browser.cjs.js.map +0 -1
- package/dist/node_modules/vfile/lib/minurl.browser.es.js.map +0 -1
- package/dist/node_modules/vfile/lib/minurl.shared.cjs.js.map +0 -1
- package/dist/node_modules/vfile/lib/minurl.shared.es.js.map +0 -1
- package/dist/node_modules/vfile/node_modules/unist-util-stringify-position/lib/index.es.js.map +0 -1
- package/dist/node_modules/vfile/node_modules/vfile-message/lib/index.es.js.map +0 -1
- package/dist/shared/src/components/AccessUser/AccessUser.cjs.js +0 -2
- package/dist/shared/src/components/AccessUser/AccessUser.cjs.js.map +0 -1
- package/dist/shared/src/components/AccessUser/AccessUser.es.js +0 -33
- package/dist/shared/src/components/AccessUser/AccessUser.es.js.map +0 -1
- package/dist/shared/src/components/AccessUser/AccessUser.styled.cjs.js +0 -42
- package/dist/shared/src/components/AccessUser/AccessUser.styled.cjs.js.map +0 -1
- package/dist/shared/src/components/AccessUser/AccessUser.styled.es.js +0 -46
- package/dist/shared/src/components/AccessUser/AccessUser.styled.es.js.map +0 -1
- package/dist/shared/src/components/DetailsMetaData/DetailsMetaData.cjs.js +0 -34
- package/dist/shared/src/components/DetailsMetaData/DetailsMetaData.cjs.js.map +0 -1
- package/dist/shared/src/components/DetailsMetaData/DetailsMetaData.es.js +0 -46
- package/dist/shared/src/components/DetailsMetaData/DetailsMetaData.es.js.map +0 -1
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributes.cjs.js +0 -2
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributes.cjs.js.map +0 -1
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributes.es.js +0 -287
- package/dist/shared/src/components/DetailsPanelAttributes/DetailsPanelAttributes.es.js.map +0 -1
- package/dist/shared/src/components/LinksManager/LinksManagerDialog.cjs.js +0 -8
- package/dist/shared/src/components/LinksManager/LinksManagerDialog.cjs.js.map +0 -1
- package/dist/shared/src/components/LinksManager/LinksManagerDialog.es.js.map +0 -1
- package/dist/shared/src/components/ListAttributeForm/ListAttributeForm.cjs.js +0 -2
- package/dist/shared/src/components/ListAttributeForm/ListAttributeForm.cjs.js.map +0 -1
- package/dist/shared/src/components/ListAttributeForm/ListAttributeForm.es.js.map +0 -1
- package/dist/shared/src/components/ListMetaData/ListMetaData.cjs.js +0 -2
- package/dist/shared/src/components/ListMetaData/ListMetaData.cjs.js.map +0 -1
- package/dist/shared/src/components/ListMetaData/ListMetaData.es.js +0 -25
- package/dist/shared/src/components/ListMetaData/ListMetaData.es.js.map +0 -1
- package/dist/shared/src/components/Powerpack/RequiredPowerpackVersion.cjs.js +0 -9
- package/dist/shared/src/components/Powerpack/RequiredPowerpackVersion.cjs.js.map +0 -1
- package/dist/shared/src/components/Powerpack/RequiredPowerpackVersion.es.js +0 -25
- package/dist/shared/src/components/Powerpack/RequiredPowerpackVersion.es.js.map +0 -1
- package/dist/shared/src/components/ShareOptionIcon/ShareOptionIcon.cjs.js +0 -2
- package/dist/shared/src/components/ShareOptionIcon/ShareOptionIcon.cjs.js.map +0 -1
- package/dist/shared/src/components/ShareOptionIcon/ShareOptionIcon.es.js +0 -17
- package/dist/shared/src/components/ShareOptionIcon/ShareOptionIcon.es.js.map +0 -1
- package/dist/shared/src/hooks/useCustomProtocolCheck.cjs.js +0 -2
- package/dist/shared/src/hooks/useCustomProtocolCheck.cjs.js.map +0 -1
- package/dist/shared/src/hooks/useCustomProtocolCheck.es.js +0 -43
- package/dist/shared/src/hooks/useCustomProtocolCheck.es.js.map +0 -1
- package/dist/types/components/AccessUser/AccessUser.d.ts +0 -22
- package/dist/types/components/AccessUser/AccessUser.styled.d.ts +0 -1
- package/dist/types/components/AccessUser/index.d.ts +0 -1
- package/dist/types/components/DetailsMetaData/DetailsMetaData.d.ts +0 -8
- package/dist/types/components/DetailsMetaData/index.d.ts +0 -1
- package/dist/types/components/DetailsPanelAttributes/DetailsPanelAttributes.d.ts +0 -6
- package/dist/types/components/LinksManager/LinksManagerDialog.d.ts +0 -9
- package/dist/types/components/ListAttributeForm/ListAttributeForm.d.ts +0 -13
- package/dist/types/components/ListAttributeForm/index.d.ts +0 -1
- package/dist/types/components/ListMetaData/ListMetaData.d.ts +0 -8
- package/dist/types/components/ListMetaData/index.d.ts +0 -1
- package/dist/types/components/Powerpack/RequiredPowerpackVersion.d.ts +0 -5
- package/dist/types/components/ShareOptionIcon/ShareOptionIcon.d.ts +0 -10
- package/dist/types/components/ShareOptionIcon/index.d.ts +0 -2
- package/dist/types/hooks/useCustomProtocolCheck.d.ts +0 -10
- /package/dist/node_modules/{vfile → rehype}/node_modules/unist-util-stringify-position/lib/index.cjs.js +0 -0
- /package/dist/node_modules/{vfile → rehype}/node_modules/unist-util-stringify-position/lib/index.es.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minpath.browser.cjs.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minpath.browser.es.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minproc.browser.cjs.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minproc.browser.es.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minurl.browser.cjs.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minurl.browser.es.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minurl.shared.cjs.js +0 -0
- /package/dist/node_modules/{vfile → rehype/node_modules/vfile}/lib/minurl.shared.es.js +0 -0
- /package/dist/node_modules/{vfile → rehype}/node_modules/vfile-message/lib/index.cjs.js +0 -0
- /package/dist/node_modules/{vfile → rehype}/node_modules/vfile-message/lib/index.es.js +0 -0
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const i=require("../../../../../../_virtual/jsx-runtime.cjs.js"),l=require("react"),W=require("clsx"),
|
|
2
|
-
`||r===" ",x=le[V];if(n&&a&&x){t.ops[0]&&t.ops[0].retain,ce(x);return}F(e);const k=t.ops.length===2&&!!t.ops[1].delete;if(!r&&k&&(r=s.getText(t.ops[0].retain-1,1)),B.includes(r)){const h=t.ops.findIndex(g=>"insert"in g||"delete"in g),c=r;let f=h===0?0:t.ops[h-1].retain;k&&(f=f-1);let p=null;for(const g of B){let
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const i=require("../../../../../../_virtual/jsx-runtime.cjs.js"),l=require("react"),W=require("clsx"),Ne=require("react-toastify"),je=require("react-quill-ayon"),v=require("@ynput/ayon-react-components"),_e=require("../CommentMentionSelect/CommentMentionSelect.cjs.js"),Ke=require("./InputMarkdownConvert.cjs.js"),Ve=require("../FilesGrid/FilesGrid.cjs.js"),y=require("./CommentInput.styled.cjs.js"),ze=require("../../../../components/QuillListStyles/QuillListStyles.cjs.js"),Qe=require("../../mentionHelpers/getMentionOptions.cjs.js"),Ge=require("../../mentionHelpers/getMentionUsers.cjs.js"),We=require("../../mentionHelpers/getMentionTasks.cjs.js"),$e=require("../../mentionHelpers/getMentionVersions.cjs.js"),Oe=require("./quillToMarkdown.cjs.js"),$=require("./helpers.cjs.js"),fe=require("./modules/index.cjs.js"),Je=require("./hooks/useInitialValue.cjs.js"),Xe=require("./hooks/useSetCursorEnd.cjs.js"),Ye=require("./hooks/useMentionLink.cjs.js"),Ze=require("./hooks/useAnnotationsSync.cjs.js"),et=require("./hooks/useAnnotationsUpload.cjs.js"),tt=require("../../context/FeedContext.cjs.js");var ye=je.Quill.import("delta");const B=["@","@@","@@@"],L={"@@@":{id:"task"},"@@":{id:"version"},"@":{id:"user",isCircle:!0}},nt=({initValue:O,initFiles:Ce=[],onSubmit:J,isEditing:j,disabled:T,isLoading:X,isOpen:u,onOpen:Y,onClose:Z})=>{var ge;const{projectName:q,entities:H,projectInfo:ke,scope:ot,currentTab:qe,mentionSuggestionsData:Ee}=tt.useFeedContext(),{users:ee,versions:te,tasks:ne}=Ee||{},[oe,Me]=l.useState(88),[N,F]=l.useState(""),[E,D]=l.useState(Ce),[_,b]=l.useState([]),[se,A]=l.useState(!1),[Re,re]=l.useState(!1),{annotations:P,removeAnnotation:K,goToAnnotation:we}=Ze.default({entityId:(ge=H[0])==null?void 0:ge.id,filesUploading:_}),[n,C]=l.useState(null),[V,M]=l.useState(0),d=l.useRef(null),ie=l.useRef(null);Je({markdownRef:ie,initValue:O,setEditorValue:F,setInitHeight:Me,isOpen:u,filter:qe}),Xe({initHeight:oe,editorRef:d,isEditing:j}),Ye({projectName:q}),l.useEffect(()=>{var e,t,o;if(u){if((t=(e=d.current)==null?void 0:e.getEditor())==null||t.enable(),P.length>0&&E.length===0)return;(o=d.current)==null||o.focus()}},[u,d]),B.sort((e,t)=>t.length-e.length);const le=l.useMemo(()=>Qe(n==null?void 0:n.type,{"@":()=>Ge(ee),"@@":()=>$e(te),"@@@":()=>We(ne,ke.taskTypes)},n==null?void 0:n.search),[ne,te,ee,n==null?void 0:n.type,n==null?void 0:n.search]),I=le.slice(0,5),[z,ae]=l.useState();l.useEffect(()=>{z&&(ae(null),d.current.getEditor().setSelection(z))},[z]);const ce=e=>{const t=d.current.getEditor(),o=n.type,s=o+(n.search||""),r=o+e.label,a=L[o],x=`${a==null?void 0:a.id}:${e.id}`,k=t.getSelection(!0),R=((k==null?void 0:k.index)||0)-s.length;t.deleteText(R,s.length),t.insertText(R,r,"mention",x);const w=R+r.length;t.updateContents(new ye().retain(w).insert(" ")),t.updateContents(new ye().retain(w+1).delete(1)),ae(w+1),C(null),M(0)},Se=e=>{ce(e)},ve=(e,t,o,s)=>{var R,w;let r=t.ops[0]&&t.ops[0].insert||t.ops[1]&&t.ops[1].insert;const a=r===`
|
|
2
|
+
`||r===" ",x=le[V];if(n&&a&&x){t.ops[0]&&t.ops[0].retain,ce(x);return}F(e);const k=t.ops.length===2&&!!t.ops[1].delete;if(!r&&k&&(r=s.getText(t.ops[0].retain-1,1)),B.includes(r)){const h=t.ops.findIndex(g=>"insert"in g||"delete"in g),c=r;let f=h===0?0:t.ops[h-1].retain;k&&(f=f-1);let p=null;for(const g of B){let S=!0;if(g.endsWith(c))for(let m=g.length-1;m>=0;m--){if(m===0)continue;const U=g[m-1],He=f-(g.length-m);if(s.getText(He,1)!==U){S=!1;break}}else S=!1;if(S){p=g;break}}p?C({type:p,retain:f}):(C(null),M(0))}else if(n){const h=t.ops[0].retain;if(r===" "||!h){C(null),M(0);return}let c=h-n.retain;k||c++;const f=s.getText(n.retain,c),p=f.replace(n.type.slice(-1),"");f.includes(" ")?(C(null),M(0)):C({...n,search:p==null?void 0:p.toLowerCase()})}else{const h=d.current.getEditor(),c=h.getSelection(!1);if(h.getFormat(c==null?void 0:c.index,c==null?void 0:c.length).mention){const[p]=h.getLine(c.index-1)||[],S=(((w=(R=p==null?void 0:p.cache)==null?void 0:R.delta)==null?void 0:w.ops)||[]).reverse().find(m=>{var U;return(U=m.attributes)==null?void 0:U.mention});if(S){const m=S.insert.length;h.deleteText(c.index-m,m)}}}},Te=e=>{var a;const t=d.current.getEditor();let o=((a=t.getSelection(!0))==null?void 0:a.index)||0;const s=t.getText(o-1,1);s!==" "&&s&&(t.insertText(o," "),o++),$.typeWithDelay(t,o,e)},Q=e=>{if(n){const{type:t,retain:o,search:s=""}=n,r=d.current.getEditor(),a=t.length+s.length,x=o-t.length+1;r.deleteText(x,a)}Te(e)},Ie=()=>{u||T||Y&&Y()},ue=()=>{(d.current.getEditor().getText().length<2||j)&&F(""),Z&&Z()},G=({file:e,data:t})=>{const o={id:t.id,name:e.name,mime:e.type,size:e.size,order:E.length};return D(s=>[...s,o]),b(s=>s.filter(r=>r.name!==e.name)),o},Fe=(e,t,o)=>{o?K==null||K(e):(D(s=>s.filter(r=>r.id!==e)),b(s=>s.filter(r=>r.name!==t)))},de=(e,t)=>{const o=Math.round(e.loaded*100/e.total);if(o!==100){const s={name:t.name,progress:o,type:t.type,order:E.length+_.length};b(r=>[...r.filter(x=>x.name!==t.name),s])}},De=e=>{A(!1),$.handleFileDrop(e,q,de,G)},be=e=>{e.preventDefault(),e.stopPropagation(),A(!0)},Ae=et({projectName:q,onSuccess:G}),pe=async()=>{try{re(!0);let e=[],t=[];if(P.length){const{files:a,metadata:x}=await Ae(P);e=a,t=x}const[o]=Oe.convertToMarkdown(N),s=$.parseImages(o),r=[...E,...e];if((s||r.length)&&J)try{await J(s,r,{annotations:t}),F(""),D([])}catch{return}}catch(e){console.error(e),Ne.toast.error("Something went wrong")}finally{re(!1)}},Pe=e=>{if(n){if(e.key==="Escape"){C(null),M(0);return}n&&e.key;const t=e.key==="ArrowUp"?-1:e.key==="ArrowDown"?1:0;if(t){e.preventDefault();let o=V+t;o<0&&(o=I.length-1),o>=I.length&&(o=0),M(o)}e.key}e.key==="Enter"&&(e.ctrlKey||e.metaKey)&&pe(),e.key==="Escape"&&ue()};let xe=u?oe+41:44;j&&(xe=void 0);const Ue=l.useMemo(()=>fe.getModules({imageUploader:{projectName:q,onUpload:G,onUploadProgress:de}}),[q,D,b]),he=[...P,...E||[],..._].sort((e,t)=>e.order-t.order),Be=he.length>6;let me=null;return H.length&&H[0].entityType==="folder"&&(n==null?void 0:n.type)==="@@"&&(me="Version mentions are disabled for folders"),i.jsxRuntimeExports.jsx(i.jsxRuntimeExports.Fragment,{children:i.jsxRuntimeExports.jsxs(y.AutoHeight,{className:W("comment-container",{isOpen:u,isEditing:j}),onDragOver:be,onDragLeave:()=>A(!1),onDrop:De,onClick:()=>A(!1),onKeyDown:e=>e.stopPropagation(),children:[i.jsxRuntimeExports.jsxs(y.Comment,{className:W("block-shortcuts",{isOpen:u,isClosed:!u||T,isEditing:j,isDropping:se,disabled:T,isLoading:X,isSubmitting:Re}),onKeyDown:Pe,onClick:Ie,children:[i.jsxRuntimeExports.jsx(y.Markdown,{ref:ie,children:i.jsxRuntimeExports.jsx(Ke,{typeOptions:L,initValue:O})}),u&&i.jsxRuntimeExports.jsx(Ve,{files:he,isCompact:Be,onRemove:Fe,style:{borderBottom:"1px solid var(--md-sys-color-outline-variant)"},projectName:q,onAnnotationClick:we}),u&&!T?i.jsxRuntimeExports.jsx(ze.QuillListStyles,{children:i.jsxRuntimeExports.jsx(je,{theme:"snow",style:{minHeight:xe,maxHeight:300},ref:d,value:N,onChange:ve,readOnly:!u,placeholder:"Comment or mention with @user, @@version, @@@task...",modules:Ue,formats:fe.quillFormats})}):i.jsxRuntimeExports.jsx(y.Placeholder,{children:T?"Commenting is disabled across multiple projects.":"Add a comment..."}),i.jsxRuntimeExports.jsxs(y.Footer,{children:[i.jsxRuntimeExports.jsxs(y.Buttons,{children:[i.jsxRuntimeExports.jsx(v.Button,{icon:"person",variant:"text",onClick:()=>Q("@"),"data-tooltip":"Mention user","data-shortcut":"@"}),i.jsxRuntimeExports.jsx(v.Button,{icon:"layers",variant:"text",onClick:()=>Q("@@"),"data-tooltip":"Mention version","data-shortcut":"@@"}),i.jsxRuntimeExports.jsx(v.Button,{icon:"check_circle",variant:"text",onClick:()=>Q("@@@"),"data-tooltip":"Mention task","data-shortcut":"@@@"})]}),i.jsxRuntimeExports.jsxs(y.Buttons,{children:[j&&i.jsxRuntimeExports.jsx(v.Button,{variant:"text",onClick:ue,children:"Cancel"}),i.jsxRuntimeExports.jsx(v.SaveButton,{label:j?"Save":"Comment",className:"comment",active:!!N||!!E.length,onClick:pe,disabled:X})]})]}),i.jsxRuntimeExports.jsx(y.Dropzone,{className:W({show:se&&u}),children:i.jsxRuntimeExports.jsx(v.Icon,{icon:"cloud_upload"})})]}),i.jsxRuntimeExports.jsx(_e,{mention:n,options:I,onChange:Se,types:B,z:!0,config:L[n==null?void 0:n.type],noneFound:!I.length&&(n==null?void 0:n.search),noneFoundAtAll:!I.length&&!(n!=null&&n.search),selectedIndex:V,error:me})]})})};exports.default=nt;exports.mentionTypeOptions=L;
|
|
3
3
|
//# sourceMappingURL=CommentInput.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CommentInput.cjs.js","sources":["../../../../../../../src/containers/Feed/components/CommentInput/CommentInput.tsx"],"sourcesContent":["// React and related hooks\nimport React, { FC, useEffect, useMemo, useRef, useState } from 'react'\n\n// Third-party libraries\nimport clsx from 'clsx'\nimport { toast } from 'react-toastify'\nimport ReactQuill, { Quill } from 'react-quill-ayon'\n\n// Components\nimport { Button, Icon, SaveButton } from '@ynput/ayon-react-components'\nimport CommentMentionSelect from '../CommentMentionSelect/CommentMentionSelect'\nimport InputMarkdownConvert from './InputMarkdownConvert'\nimport FilesGrid from '../FilesGrid'\n\n// Styled components\nimport * as Styled from './CommentInput.styled'\n\n// Helpers and utilities\nimport getMentionOptions from '../../mentionHelpers/getMentionOptions'\nimport getMentionUsers from '../../mentionHelpers/getMentionUsers'\nimport getMentionTasks from '../../mentionHelpers/getMentionTasks'\nimport getMentionVersions from '../../mentionHelpers/getMentionVersions'\nimport { convertToMarkdown } from './quillToMarkdown'\nimport { handleFileDrop, parseImages, typeWithDelay } from './helpers'\nimport { getModules, quillFormats } from './modules'\n\n// Hooks\nimport useInitialValue from './hooks/useInitialValue'\nimport useSetCursorEnd from './hooks/useSetCursorEnd'\nimport useMentionLink from './hooks/useMentionLink'\nimport useAnnotationsSync from './hooks/useAnnotationsSync'\n\n// State management\nimport useAnnotationsUpload from './hooks/useAnnotationsUpload'\nimport { useFeedContext } from '../../context/FeedContext'\nimport { SavedAnnotationMetadata } from '../../index'\n\nvar Delta = Quill.import('delta')\n\nconst mentionTypes = ['@', '@@', '@@@']\nexport const mentionTypeOptions = {\n '@@@': {\n id: 'task',\n },\n '@@': {\n id: 'version',\n },\n '@': {\n id: 'user',\n isCircle: true,\n },\n}\n\ninterface CommentInputProps {\n initValue: string | null\n initFiles?: any[]\n onSubmit: (markdown: string, files: any[], data?: any) => Promise<void>\n isEditing?: boolean\n disabled?: boolean\n isLoading?: boolean\n isOpen: boolean\n onOpen?: () => void\n onClose?: () => void\n}\n\nconst CommentInput: FC<CommentInputProps> = ({\n initValue,\n initFiles = [],\n onSubmit,\n isEditing,\n disabled,\n isLoading,\n isOpen,\n onOpen,\n onClose,\n}) => {\n const { projectName, entities, projectInfo, scope, currentTab, mentionSuggestionsData } =\n useFeedContext()\n\n const {\n users: mentionUsers,\n versions: mentionVersions,\n tasks: mentionTasks,\n } = mentionSuggestionsData || {}\n\n const [initHeight, setInitHeight] = useState(88)\n const [editorValue, setEditorValue] = useState('')\n // file uploads\n const [files, setFiles] = useState(initFiles)\n const [filesUploading, setFilesUploading] = useState([])\n const [isDropping, setIsDropping] = useState(false)\n const [isSubmitting, setIsSubmitting] = useState(false)\n\n const { annotations, removeAnnotation, goToAnnotation } = useAnnotationsSync({\n entityId: entities[0]?.id,\n filesUploading,\n })\n\n // MENTION STATES\n const [mention, setMention] = useState<null | any>(null)\n const [mentionSelectedIndex, setMentionSelectedIndex] = useState(0)\n // REFS\n const editorRef = useRef<any>(null)\n const markdownRef = useRef<HTMLDivElement>(null)\n\n // if there is an initial value, set it so the editor is prefilled\n useInitialValue({\n markdownRef,\n initValue,\n setEditorValue,\n setInitHeight,\n isOpen: isOpen,\n filter: currentTab,\n })\n\n // When editing, set selection to the end of the editor\n useSetCursorEnd({ initHeight, editorRef, isEditing })\n // create a new quill format for mentions and registers it\n useMentionLink({ projectName })\n\n // focus on editor when opened\n useEffect(() => {\n if (isOpen) {\n editorRef.current?.getEditor()?.enable()\n // block autofocus if opened from an annotation\n if (annotations.length > 0 && files.length === 0) {\n return\n }\n\n editorRef.current?.focus()\n }\n // We don't set annotations or files as useEffect dependencies, because we don't want to focus\n // the input if it's already open but annotations change (e.g. are removed).\n }, [isOpen, editorRef])\n\n mentionTypes.sort((a, b) => b.length - a.length)\n\n const mentionOptions = useMemo(\n () =>\n getMentionOptions(\n mention?.type,\n {\n '@': () => getMentionUsers(mentionUsers),\n '@@': () => getMentionVersions(mentionVersions),\n '@@@': () => getMentionTasks(mentionTasks, projectInfo.taskTypes),\n },\n mention?.search,\n ),\n [mentionTasks, mentionVersions, mentionUsers, mention?.type, mention?.search],\n )\n\n // show first 5 and filter itself out\n const shownMentionOptions = mentionOptions.slice(0, 5)\n\n // triggered when a mention is selected\n const [newSelection, setNewSelection] = useState<null | number>()\n\n useEffect(() => {\n if (newSelection) {\n setNewSelection(null)\n // now we set selection to the end of the mention\n const quill = editorRef.current.getEditor()\n quill.setSelection(newSelection)\n }\n }, [newSelection])\n\n const handleSelectMention = (selectedOption: any) => {\n // get option text\n const quill = editorRef.current.getEditor()\n\n const typePrefix = mention.type // the type of mention: @, @@, @@@\n const search = typePrefix + (mention.search || '') // the full search string: @Tim\n const mentionLabel = typePrefix + selectedOption.label // the label of the mention: @Tim Bailey\n // @ts-expect-error\n const type = mentionTypeOptions[typePrefix] // the type of mention: user, version, task\n const href = `${type?.id}:${selectedOption.id}` // the href of the mention: user:user.123\n\n // get selection delta\n const selection = quill.getSelection(true)\n const selectionIndex = selection?.index || 0\n const startIndex = selectionIndex - search.length // the start index of the search\n\n // first delete the search string\n quill.deleteText(startIndex, search.length)\n\n // insert embed link\n quill.insertText(startIndex, mentionLabel, 'mention', href)\n\n const endIndex = startIndex + mentionLabel.length\n\n // insert a space after the mention\n quill.updateContents(new Delta().retain(endIndex).insert(' '))\n\n // remove single \\n after mention\n quill.updateContents(new Delta().retain(endIndex + 1).delete(1))\n\n // set selection to the end of the mention + 1\n setNewSelection(endIndex + 1)\n\n // reset mention state\n setMention(null)\n setMentionSelectedIndex(0)\n }\n\n const handleSelectChange = (option: any) => {\n handleSelectMention(option)\n }\n\n const handleChange = (content: string, delta: any, _: any, editor: any) => {\n let currentCharacter =\n (delta.ops[0] && delta.ops[0].insert) || (delta.ops[1] && delta.ops[1].insert)\n\n const tabOrEnter = currentCharacter === '\\n' || currentCharacter === '\\t'\n // find the first option\n const selectedOption = mentionOptions[mentionSelectedIndex]\n\n if (mention && tabOrEnter && selectedOption) {\n // get option text\n const retain = (delta.ops[0] && delta.ops[0].retain) || 0\n // prevent default\n\n // @ts-ignore\n handleSelectMention(selectedOption, retain)\n\n return\n }\n\n setEditorValue(content)\n\n const isDelete = delta.ops.length === 2 && !!delta.ops[1].delete\n\n if (!currentCharacter && isDelete) {\n currentCharacter = editor.getText(delta.ops[0].retain - 1, 1)\n }\n\n const isMention = mentionTypes.includes(currentCharacter)\n\n if (isMention) {\n const mentionIndex = delta.ops.findIndex((op: any) => 'insert' in op || 'delete' in op)\n const mention = currentCharacter\n let retain = mentionIndex === 0 ? 0 : delta.ops[mentionIndex - 1].retain\n if (isDelete) retain = retain - 1\n\n // for each mention denotation char, check if it is a mention\n // sort by length of mention denotation char\n let mentionMatch = null\n\n // loop through each mention denotation char, with longest first. First one to match is the one we want\n for (const chars of mentionTypes) {\n let isMatch = true\n // start with the last character\n if (chars.endsWith(mention)) {\n // loop through the chars backwards\n for (let i = chars.length - 1; i >= 0; i--) {\n // skip first character as that's already been checked\n if (i === 0) continue\n const char = chars[i - 1]\n const indexInDelta = retain - (chars.length - i)\n const valueCharAtIndex = editor.getText(indexInDelta, 1)\n if (valueCharAtIndex !== char) {\n isMatch = false\n break\n }\n }\n } else {\n isMatch = false\n }\n\n if (isMatch) {\n // console.log('match!!!', chars)\n mentionMatch = chars\n break\n }\n }\n\n if (mentionMatch) {\n setMention({\n type: mentionMatch,\n retain: retain,\n })\n } else {\n setMention(null)\n setMentionSelectedIndex(0)\n }\n } else {\n // get full string between mention and new delta\n // This is where SEARCH is handled\n if (mention) {\n const retain = delta.ops[0].retain\n // if space is pressed, remove mention\n if (currentCharacter === ' ' || !retain) {\n setMention(null)\n setMentionSelectedIndex(0)\n return\n }\n\n let distanceMentionToRetain = retain - mention.retain\n if (!isDelete) distanceMentionToRetain++\n const mentionFull = editor.getText(mention.retain, distanceMentionToRetain)\n const mentionSearch = mentionFull.replace(mention.type.slice(-1), '')\n // check for space in mentionFull\n if (mentionFull.includes(' ')) {\n setMention(null)\n setMentionSelectedIndex(0)\n } else {\n setMention({\n ...mention,\n search: mentionSearch?.toLowerCase(),\n })\n }\n } else {\n // just deleting any text\n const quill = editorRef.current.getEditor()\n const currentSelection = quill.getSelection(false)\n const currentFormat = quill.getFormat(currentSelection?.index, currentSelection?.length)\n if (currentFormat.mention) {\n // if format is mention, delete the whole mention\n const [lineBlock] = quill.getLine(currentSelection.index - 1) || []\n const ops = lineBlock?.cache?.delta?.ops || []\n // get last op with attributes mention: true\n const lastMentionOp = ops.reverse().find((op: any) => op.attributes?.mention)\n if (lastMentionOp) {\n const mentionLength = lastMentionOp.insert.length\n quill.deleteText(currentSelection.index - mentionLength, mentionLength)\n }\n }\n }\n }\n }\n\n const addTextToEditor = (type: string) => {\n // get editor retain\n const quill = editorRef.current.getEditor()\n\n let retain = quill.getSelection(true)?.index || 0\n\n // get character at retain\n const currentCharacter = quill.getText(retain - 1, 1)\n\n // if the current character is a character, increment retain\n const addSpace = currentCharacter !== ' ' && currentCharacter\n if (addSpace) {\n quill.insertText(retain, ' ')\n retain++\n }\n\n // This is hack AF, but it works\n typeWithDelay(quill, retain, type)\n }\n\n const handleMentionButton = (type: string) => {\n // first check if mention is already open\n if (mention) {\n const { type, retain, search = '' } = mention\n\n const quill = editorRef.current.getEditor()\n const length = type.length + search.length\n const start = retain - type.length + 1\n // delete the mention\n quill.deleteText(start, length)\n }\n\n addTextToEditor(type)\n }\n\n const handleOpenClick = () => {\n if (isOpen || disabled) return\n\n onOpen && onOpen()\n }\n\n const handleClose = () => {\n // get editor value\n const editor = editorRef.current.getEditor()\n const text = editor.getText()\n if (text.length < 2 || isEditing) {\n setEditorValue('')\n }\n\n // always close editor\n onClose && onClose()\n }\n\n const handleFileUploaded = ({ file, data }: any) => {\n const newFile = {\n id: data.id,\n name: file.name,\n mime: file.type,\n size: file.size,\n order: files.length,\n }\n\n setFiles((prev) => [...prev, newFile])\n // remove from uploading\n setFilesUploading((prev) => prev.filter((uploading: any) => uploading.name !== file.name))\n\n return newFile\n }\n\n const handleFileRemove = (id: string, name: string, isUnsavedAnnotation: boolean) => {\n if (isUnsavedAnnotation) {\n // remove from annotations (if it's an unsaved annotation)\n removeAnnotation?.(id)\n } else {\n // remove file from files\n setFiles((prev) => prev.filter((file) => file.id !== id))\n // remove from uploading\n setFilesUploading((prev) => {\n return prev.filter((file: any) => file.name !== name)\n })\n }\n }\n\n const handleFileProgress = (e: any, file: any) => {\n const progress = Math.round((e.loaded * 100) / e.total)\n if (progress !== 100) {\n const uploadProgress = {\n name: file.name,\n progress,\n type: file.type,\n order: files.length + filesUploading.length,\n }\n\n // @ts-ignore\n setFilesUploading((prev) => {\n // replace or add new progress\n const newProgress = prev.filter((name: any) => name.name !== file.name)\n return [...newProgress, uploadProgress]\n })\n }\n }\n\n // when a file is not dropped onto the comment input\n const handleDrop = (e: React.DragEvent<HTMLDivElement>) => {\n setIsDropping(false)\n // upload file\n handleFileDrop(e, projectName, handleFileProgress, handleFileUploaded)\n }\n\n const handleDragOver = (e: React.DragEvent<HTMLDivElement>) => {\n e.preventDefault()\n e.stopPropagation()\n setIsDropping(true)\n }\n\n const uploadAnnotations = useAnnotationsUpload({\n projectName,\n onSuccess: handleFileUploaded,\n })\n\n const handleSubmit = async () => {\n try {\n setIsSubmitting(true)\n // upload any annotations first\n let annotationFiles = []\n let annotationMetadata: SavedAnnotationMetadata[] = []\n\n if (annotations.length) {\n const { files, metadata } = await uploadAnnotations(annotations)\n annotationFiles = files\n annotationMetadata = metadata\n }\n\n // convert to markdown\n const [markdown] = convertToMarkdown(editorValue)\n\n // remove img query params\n const markdownParsed = parseImages(markdown)\n\n const uploadedFiles = [...files, ...annotationFiles]\n\n if ((markdownParsed || uploadedFiles.length) && onSubmit) {\n try {\n await onSubmit(markdownParsed, uploadedFiles, { annotations: annotationMetadata })\n // only clear if onSubmit is successful\n setEditorValue('')\n setFiles([])\n } catch (error) {\n // error is handled in rtk query mutation\n return\n }\n }\n } catch (error) {\n console.error(error)\n toast.error('Something went wrong')\n } finally {\n setIsSubmitting(false)\n }\n }\n\n const handleKeyDown = (e: React.KeyboardEvent<HTMLElement>) => {\n if (mention) {\n // close mention on escape\n if (e.key === 'Escape') {\n setMention(null)\n setMentionSelectedIndex(0)\n return\n }\n\n // add top search of mention\n if (mention && e.key === 'Tab') {\n // we handle this in the onChange\n }\n\n const arrowDirection = e.key === 'ArrowUp' ? -1 : e.key === 'ArrowDown' ? 1 : 0\n\n if (arrowDirection) {\n // navigate through mentions\n e.preventDefault()\n let newIndex = mentionSelectedIndex + arrowDirection\n if (newIndex < 0) newIndex = shownMentionOptions.length - 1\n if (newIndex >= shownMentionOptions.length) newIndex = 0\n setMentionSelectedIndex(newIndex)\n }\n\n if (e.key === 'Enter') {\n // we handle this in the onChange\n }\n }\n\n if (e.key === 'Enter' && (e.ctrlKey || e.metaKey)) {\n handleSubmit()\n }\n\n if (e.key === 'Escape') {\n handleClose()\n }\n }\n\n let quillMinHeight: number | undefined = isOpen ? initHeight + 41 : 44\n if (isEditing) quillMinHeight = undefined\n\n // QUILL CONFIG\n const modules = useMemo(\n () =>\n getModules({\n imageUploader: {\n projectName,\n onUpload: handleFileUploaded,\n onUploadProgress: handleFileProgress,\n },\n }),\n [projectName, setFiles, setFilesUploading],\n )\n\n const allFiles = [...annotations, ...(files || []), ...filesUploading].sort(\n (a, b) => a.order - b.order,\n )\n const compactGrid = allFiles.length > 6\n\n // disable version mentions for folders\n let mentionsError = null\n if (entities.length && entities[0].entityType === 'folder') {\n if (mention?.type === '@@') {\n mentionsError = 'Version mentions are disabled for folders'\n }\n }\n\n return (\n <>\n <Styled.AutoHeight\n className={clsx('comment-container', { isOpen, isEditing })}\n onDragOver={handleDragOver}\n onDragLeave={() => setIsDropping(false)}\n onDrop={handleDrop}\n onClick={() => setIsDropping(false)}\n onKeyDown={(e) => e.stopPropagation()}\n >\n <Styled.Comment\n className={clsx('block-shortcuts', {\n isOpen,\n isClosed: !isOpen || disabled,\n isEditing,\n isDropping,\n disabled,\n isLoading,\n isSubmitting,\n })}\n onKeyDown={handleKeyDown}\n onClick={handleOpenClick}\n >\n <Styled.Markdown ref={markdownRef}>\n {/* this is purely used to translate the markdown into html for Editor */}\n <InputMarkdownConvert typeOptions={mentionTypeOptions} initValue={initValue} />\n </Styled.Markdown>\n\n {/* file uploads */}\n {isOpen && (\n <FilesGrid\n files={allFiles}\n isCompact={compactGrid}\n onRemove={handleFileRemove}\n style={{ borderBottom: '1px solid var(--md-sys-color-outline-variant)' }}\n projectName={projectName}\n onAnnotationClick={goToAnnotation}\n />\n )}\n {isOpen && !disabled ? (\n <ReactQuill\n theme=\"snow\"\n style={{ minHeight: quillMinHeight, maxHeight: 300 }}\n ref={editorRef}\n value={editorValue}\n onChange={handleChange}\n readOnly={!isOpen}\n placeholder={'Comment or mention with @user, @@version, @@@task...'}\n modules={modules}\n formats={quillFormats}\n />\n ) : (\n <Styled.Placeholder>\n {disabled ? 'Commenting is disabled across multiple projects.' : 'Add a comment...'}\n </Styled.Placeholder>\n )}\n\n <Styled.Footer>\n <Styled.Buttons>\n {/* mention a user */}\n <Button\n icon=\"person\"\n variant=\"text\"\n onClick={() => handleMentionButton('@')}\n data-tooltip={'Mention user'}\n data-shortcut={'@'}\n />\n {/* mention a version */}\n <Button\n icon=\"layers\"\n variant=\"text\"\n onClick={() => handleMentionButton('@@')}\n data-tooltip={'Mention version'}\n data-shortcut={'@@'}\n />\n {/* mention a task */}\n <Button\n icon=\"check_circle\"\n variant=\"text\"\n onClick={() => handleMentionButton('@@@')}\n data-tooltip={'Mention task'}\n data-shortcut={'@@@'}\n />\n </Styled.Buttons>\n <Styled.Buttons>\n {isEditing && (\n <Button variant=\"text\" onClick={handleClose}>\n Cancel\n </Button>\n )}\n <SaveButton\n label={isEditing ? 'Save' : 'Comment'}\n className=\"comment\"\n active={!!editorValue || !!files.length}\n onClick={handleSubmit}\n disabled={isLoading}\n />\n </Styled.Buttons>\n </Styled.Footer>\n\n <Styled.Dropzone className={clsx({ show: isDropping && isOpen })}>\n <Icon icon=\"cloud_upload\" />\n </Styled.Dropzone>\n </Styled.Comment>\n <CommentMentionSelect\n mention={mention}\n options={shownMentionOptions}\n onChange={handleSelectChange}\n types={mentionTypes}\n z\n // @ts-ignore\n config={mentionTypeOptions[mention?.type]}\n noneFound={!shownMentionOptions.length && mention?.search}\n noneFoundAtAll={!shownMentionOptions.length && !mention?.search}\n selectedIndex={mentionSelectedIndex}\n // @ts-ignore\n error={mentionsError}\n />\n </Styled.AutoHeight>\n </>\n )\n}\n\nexport default CommentInput\n"],"names":["Delta","Quill","mentionTypes","mentionTypeOptions","CommentInput","initValue","initFiles","onSubmit","isEditing","disabled","isLoading","isOpen","onOpen","onClose","projectName","entities","projectInfo","scope","currentTab","mentionSuggestionsData","useFeedContext","mentionUsers","mentionVersions","mentionTasks","initHeight","setInitHeight","useState","editorValue","setEditorValue","files","setFiles","filesUploading","setFilesUploading","isDropping","setIsDropping","isSubmitting","setIsSubmitting","annotations","removeAnnotation","goToAnnotation","useAnnotationsSync","_a","mention","setMention","mentionSelectedIndex","setMentionSelectedIndex","editorRef","useRef","markdownRef","useInitialValue","useSetCursorEnd","useMentionLink","useEffect","_b","_c","a","b","mentionOptions","useMemo","getMentionOptions","getMentionUsers","getMentionVersions","getMentionTasks","shownMentionOptions","newSelection","setNewSelection","handleSelectMention","selectedOption","quill","typePrefix","search","mentionLabel","type","href","selection","startIndex","endIndex","handleSelectChange","option","handleChange","content","delta","_","editor","currentCharacter","tabOrEnter","isDelete","mentionIndex","op","retain","mentionMatch","chars","isMatch","i","char","indexInDelta","distanceMentionToRetain","mentionFull","mentionSearch","currentSelection","lineBlock","lastMentionOp","mentionLength","addTextToEditor","typeWithDelay","handleMentionButton","length","start","handleOpenClick","handleClose","handleFileUploaded","file","data","newFile","prev","uploading","handleFileRemove","id","name","isUnsavedAnnotation","handleFileProgress","progress","uploadProgress","handleDrop","handleFileDrop","handleDragOver","uploadAnnotations","useAnnotationsUpload","handleSubmit","annotationFiles","annotationMetadata","metadata","markdown","convertToMarkdown","markdownParsed","parseImages","uploadedFiles","error","toast","handleKeyDown","arrowDirection","newIndex","quillMinHeight","modules","getModules","allFiles","compactGrid","mentionsError","jsx","Fragment","jsxs","Styled.AutoHeight","clsx","Styled.Comment","Styled.Markdown","InputMarkdownConvert","FilesGrid","ReactQuill","quillFormats","Styled.Placeholder","Styled.Footer","Styled.Buttons","Button","SaveButton","Styled.Dropzone","Icon","CommentMentionSelect"],"mappings":"0mCAqCA,IAAIA,GAAQC,GAAAA,MAAM,OAAO,OAAO,EAEhC,MAAMC,EAAe,CAAC,IAAK,KAAM,KAAK,EACzBC,EAAqB,CAChC,MAAO,CACL,GAAI,MACN,EACA,KAAM,CACJ,GAAI,SACN,EACA,IAAK,CACH,GAAI,OACJ,SAAU,EAAA,CAEd,EAcMC,GAAsC,CAAC,CAC3C,UAAAC,EACA,UAAAC,GAAY,CAAC,EACb,SAAAC,EACA,UAAAC,EACA,SAAAC,EACA,UAAAC,EACA,OAAAC,EACA,OAAAC,EACA,QAAAC,CACF,IAAM,QACE,KAAA,CAAE,YAAAC,EAAa,SAAAC,EAAU,YAAAC,GAAa,MAAAC,GAAO,WAAAC,GAAY,uBAAAC,IAC7DC,kBAAe,EAEX,CACJ,MAAOC,GACP,SAAUC,GACV,MAAOC,EACT,EAAIJ,IAA0B,CAAC,EAEzB,CAACK,GAAYC,EAAa,EAAIC,EAAAA,SAAS,EAAE,EACz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2C,EAAA,kBAAA,IAACc,EAAA,OAAA,CACC,KAAK,eACL,QAAQ,OACR,QAAS,IAAMzD,EAAoB,KAAK,EACxC,eAAc,eACd,gBAAe,KAAA,CAAA,CACjB,EACF,EACA6C,yBAACW,EAAAA,QAAA,CACE,SAAA,CAAAzJ,2BACE0J,EAAO,OAAA,CAAA,QAAQ,OAAO,QAASrD,GAAa,SAE7C,SAAA,EAEFuC,EAAA,kBAAA,IAACe,EAAA,WAAA,CACC,MAAO3J,EAAY,OAAS,UAC5B,UAAU,UACV,OAAQ,CAAC,CAACmB,GAAe,CAAC,CAACE,EAAM,OACjC,QAASmG,GACT,SAAUtH,CAAA,CAAA,CACZ,CACF,CAAA,CAAA,EACF,0BAEC0J,EAAO,SAAP,CAAgB,UAAWZ,EAAK,CAAE,KAAMvH,IAActB,CAAQ,CAAA,EAC7D,SAAAyI,EAAAA,kBAAAA,IAACiB,EAAAA,KAAK,CAAA,KAAK,eAAe,CAC5B,CAAA,CAAA,CAAA,CACF,EACAjB,EAAA,kBAAA,IAACkB,GAAA,CACC,QAAA5H,EACA,QAASqB,EACT,SAAUc,GACV,MAAO3E,EACP,EAAC,GAED,OAAQC,EAAmBuC,GAAA,YAAAA,EAAS,IAAI,EACxC,UAAW,CAACqB,EAAoB,SAAUrB,GAAA,YAAAA,EAAS,QACnD,eAAgB,CAACqB,EAAoB,QAAU,EAACrB,GAAA,MAAAA,EAAS,QACzD,cAAeE,EAEf,MAAOuG,EAAA,CAAA,CACT,CAAA,CAAA,EAEJ,CAEJ"}
|
|
1
|
+
{"version":3,"file":"CommentInput.cjs.js","sources":["../../../../../../../src/containers/Feed/components/CommentInput/CommentInput.tsx"],"sourcesContent":["// React and related hooks\nimport React, { FC, useEffect, useMemo, useRef, useState } from 'react'\n\n// Third-party libraries\nimport clsx from 'clsx'\nimport { toast } from 'react-toastify'\nimport ReactQuill, { Quill } from 'react-quill-ayon'\n\n// Components\nimport { Button, Icon, SaveButton } from '@ynput/ayon-react-components'\nimport CommentMentionSelect from '../CommentMentionSelect/CommentMentionSelect'\nimport InputMarkdownConvert from './InputMarkdownConvert'\nimport FilesGrid from '../FilesGrid'\n\n// Styled components\nimport * as Styled from './CommentInput.styled'\nimport { QuillListStyles } from '../../../../components/QuillListStyles'\n\n// Helpers and utilities\nimport getMentionOptions from '../../mentionHelpers/getMentionOptions'\nimport getMentionUsers from '../../mentionHelpers/getMentionUsers'\nimport getMentionTasks from '../../mentionHelpers/getMentionTasks'\nimport getMentionVersions from '../../mentionHelpers/getMentionVersions'\nimport { convertToMarkdown } from './quillToMarkdown'\nimport { handleFileDrop, parseImages, typeWithDelay } from './helpers'\nimport { getModules, quillFormats } from './modules'\n\n// Hooks\nimport useInitialValue from './hooks/useInitialValue'\nimport useSetCursorEnd from './hooks/useSetCursorEnd'\nimport useMentionLink from './hooks/useMentionLink'\nimport useAnnotationsSync from './hooks/useAnnotationsSync'\n\n// State management\nimport useAnnotationsUpload from './hooks/useAnnotationsUpload'\nimport { useFeedContext } from '../../context/FeedContext'\nimport { SavedAnnotationMetadata } from '../../index'\n\nvar Delta = Quill.import('delta')\n\nconst mentionTypes = ['@', '@@', '@@@']\nexport const mentionTypeOptions = {\n '@@@': {\n id: 'task',\n },\n '@@': {\n id: 'version',\n },\n '@': {\n id: 'user',\n isCircle: true,\n },\n}\n\ninterface CommentInputProps {\n initValue: string | null\n initFiles?: any[]\n onSubmit: (markdown: string, files: any[], data?: any) => Promise<void>\n isEditing?: boolean\n disabled?: boolean\n isLoading?: boolean\n isOpen: boolean\n onOpen?: () => void\n onClose?: () => void\n}\n\nconst CommentInput: FC<CommentInputProps> = ({\n initValue,\n initFiles = [],\n onSubmit,\n isEditing,\n disabled,\n isLoading,\n isOpen,\n onOpen,\n onClose,\n}) => {\n const { projectName, entities, projectInfo, scope, currentTab, mentionSuggestionsData } =\n useFeedContext()\n\n const {\n users: mentionUsers,\n versions: mentionVersions,\n tasks: mentionTasks,\n } = mentionSuggestionsData || {}\n\n const [initHeight, setInitHeight] = useState(88)\n const [editorValue, setEditorValue] = useState('')\n // file uploads\n const [files, setFiles] = useState(initFiles)\n const [filesUploading, setFilesUploading] = useState([])\n const [isDropping, setIsDropping] = useState(false)\n const [isSubmitting, setIsSubmitting] = useState(false)\n\n const { annotations, removeAnnotation, goToAnnotation } = useAnnotationsSync({\n entityId: entities[0]?.id,\n filesUploading,\n })\n\n // MENTION STATES\n const [mention, setMention] = useState<null | any>(null)\n const [mentionSelectedIndex, setMentionSelectedIndex] = useState(0)\n // REFS\n const editorRef = useRef<any>(null)\n const markdownRef = useRef<HTMLDivElement>(null)\n\n // if there is an initial value, set it so the editor is prefilled\n useInitialValue({\n markdownRef,\n initValue,\n setEditorValue,\n setInitHeight,\n isOpen: isOpen,\n filter: currentTab,\n })\n\n // When editing, set selection to the end of the editor\n useSetCursorEnd({ initHeight, editorRef, isEditing })\n // create a new quill format for mentions and registers it\n useMentionLink({ projectName })\n\n // focus on editor when opened\n useEffect(() => {\n if (isOpen) {\n editorRef.current?.getEditor()?.enable()\n // block autofocus if opened from an annotation\n if (annotations.length > 0 && files.length === 0) {\n return\n }\n\n editorRef.current?.focus()\n }\n // We don't set annotations or files as useEffect dependencies, because we don't want to focus\n // the input if it's already open but annotations change (e.g. are removed).\n }, [isOpen, editorRef])\n\n mentionTypes.sort((a, b) => b.length - a.length)\n\n const mentionOptions = useMemo(\n () =>\n getMentionOptions(\n mention?.type,\n {\n '@': () => getMentionUsers(mentionUsers),\n '@@': () => getMentionVersions(mentionVersions),\n '@@@': () => getMentionTasks(mentionTasks, projectInfo.taskTypes),\n },\n mention?.search,\n ),\n [mentionTasks, mentionVersions, mentionUsers, mention?.type, mention?.search],\n )\n\n // show first 5 and filter itself out\n const shownMentionOptions = mentionOptions.slice(0, 5)\n\n // triggered when a mention is selected\n const [newSelection, setNewSelection] = useState<null | number>()\n\n useEffect(() => {\n if (newSelection) {\n setNewSelection(null)\n // now we set selection to the end of the mention\n const quill = editorRef.current.getEditor()\n quill.setSelection(newSelection)\n }\n }, [newSelection])\n\n const handleSelectMention = (selectedOption: any) => {\n // get option text\n const quill = editorRef.current.getEditor()\n\n const typePrefix = mention.type // the type of mention: @, @@, @@@\n const search = typePrefix + (mention.search || '') // the full search string: @Tim\n const mentionLabel = typePrefix + selectedOption.label // the label of the mention: @Tim Bailey\n // @ts-expect-error\n const type = mentionTypeOptions[typePrefix] // the type of mention: user, version, task\n const href = `${type?.id}:${selectedOption.id}` // the href of the mention: user:user.123\n\n // get selection delta\n const selection = quill.getSelection(true)\n const selectionIndex = selection?.index || 0\n const startIndex = selectionIndex - search.length // the start index of the search\n\n // first delete the search string\n quill.deleteText(startIndex, search.length)\n\n // insert embed link\n quill.insertText(startIndex, mentionLabel, 'mention', href)\n\n const endIndex = startIndex + mentionLabel.length\n\n // insert a space after the mention\n quill.updateContents(new Delta().retain(endIndex).insert(' '))\n\n // remove single \\n after mention\n quill.updateContents(new Delta().retain(endIndex + 1).delete(1))\n\n // set selection to the end of the mention + 1\n setNewSelection(endIndex + 1)\n\n // reset mention state\n setMention(null)\n setMentionSelectedIndex(0)\n }\n\n const handleSelectChange = (option: any) => {\n handleSelectMention(option)\n }\n\n const handleChange = (content: string, delta: any, _: any, editor: any) => {\n let currentCharacter =\n (delta.ops[0] && delta.ops[0].insert) || (delta.ops[1] && delta.ops[1].insert)\n\n const tabOrEnter = currentCharacter === '\\n' || currentCharacter === '\\t'\n // find the first option\n const selectedOption = mentionOptions[mentionSelectedIndex]\n\n if (mention && tabOrEnter && selectedOption) {\n // get option text\n const retain = (delta.ops[0] && delta.ops[0].retain) || 0\n // prevent default\n\n // @ts-ignore\n handleSelectMention(selectedOption, retain)\n\n return\n }\n\n setEditorValue(content)\n\n const isDelete = delta.ops.length === 2 && !!delta.ops[1].delete\n\n if (!currentCharacter && isDelete) {\n currentCharacter = editor.getText(delta.ops[0].retain - 1, 1)\n }\n\n const isMention = mentionTypes.includes(currentCharacter)\n\n if (isMention) {\n const mentionIndex = delta.ops.findIndex((op: any) => 'insert' in op || 'delete' in op)\n const mention = currentCharacter\n let retain = mentionIndex === 0 ? 0 : delta.ops[mentionIndex - 1].retain\n if (isDelete) retain = retain - 1\n\n // for each mention denotation char, check if it is a mention\n // sort by length of mention denotation char\n let mentionMatch = null\n\n // loop through each mention denotation char, with longest first. First one to match is the one we want\n for (const chars of mentionTypes) {\n let isMatch = true\n // start with the last character\n if (chars.endsWith(mention)) {\n // loop through the chars backwards\n for (let i = chars.length - 1; i >= 0; i--) {\n // skip first character as that's already been checked\n if (i === 0) continue\n const char = chars[i - 1]\n const indexInDelta = retain - (chars.length - i)\n const valueCharAtIndex = editor.getText(indexInDelta, 1)\n if (valueCharAtIndex !== char) {\n isMatch = false\n break\n }\n }\n } else {\n isMatch = false\n }\n\n if (isMatch) {\n // console.log('match!!!', chars)\n mentionMatch = chars\n break\n }\n }\n\n if (mentionMatch) {\n setMention({\n type: mentionMatch,\n retain: retain,\n })\n } else {\n setMention(null)\n setMentionSelectedIndex(0)\n }\n } else {\n // get full string between mention and new delta\n // This is where SEARCH is handled\n if (mention) {\n const retain = delta.ops[0].retain\n // if space is pressed, remove mention\n if (currentCharacter === ' ' || !retain) {\n setMention(null)\n setMentionSelectedIndex(0)\n return\n }\n\n let distanceMentionToRetain = retain - mention.retain\n if (!isDelete) distanceMentionToRetain++\n const mentionFull = editor.getText(mention.retain, distanceMentionToRetain)\n const mentionSearch = mentionFull.replace(mention.type.slice(-1), '')\n // check for space in mentionFull\n if (mentionFull.includes(' ')) {\n setMention(null)\n setMentionSelectedIndex(0)\n } else {\n setMention({\n ...mention,\n search: mentionSearch?.toLowerCase(),\n })\n }\n } else {\n // just deleting any text\n const quill = editorRef.current.getEditor()\n const currentSelection = quill.getSelection(false)\n const currentFormat = quill.getFormat(currentSelection?.index, currentSelection?.length)\n if (currentFormat.mention) {\n // if format is mention, delete the whole mention\n const [lineBlock] = quill.getLine(currentSelection.index - 1) || []\n const ops = lineBlock?.cache?.delta?.ops || []\n // get last op with attributes mention: true\n const lastMentionOp = ops.reverse().find((op: any) => op.attributes?.mention)\n if (lastMentionOp) {\n const mentionLength = lastMentionOp.insert.length\n quill.deleteText(currentSelection.index - mentionLength, mentionLength)\n }\n }\n }\n }\n }\n\n const addTextToEditor = (type: string) => {\n // get editor retain\n const quill = editorRef.current.getEditor()\n\n let retain = quill.getSelection(true)?.index || 0\n\n // get character at retain\n const currentCharacter = quill.getText(retain - 1, 1)\n\n // if the current character is a character, increment retain\n const addSpace = currentCharacter !== ' ' && currentCharacter\n if (addSpace) {\n quill.insertText(retain, ' ')\n retain++\n }\n\n // This is hack AF, but it works\n typeWithDelay(quill, retain, type)\n }\n\n const handleMentionButton = (type: string) => {\n // first check if mention is already open\n if (mention) {\n const { type, retain, search = '' } = mention\n\n const quill = editorRef.current.getEditor()\n const length = type.length + search.length\n const start = retain - type.length + 1\n // delete the mention\n quill.deleteText(start, length)\n }\n\n addTextToEditor(type)\n }\n\n const handleOpenClick = () => {\n if (isOpen || disabled) return\n\n onOpen && onOpen()\n }\n\n const handleClose = () => {\n // get editor value\n const editor = editorRef.current.getEditor()\n const text = editor.getText()\n if (text.length < 2 || isEditing) {\n setEditorValue('')\n }\n\n // always close editor\n onClose && onClose()\n }\n\n const handleFileUploaded = ({ file, data }: any) => {\n const newFile = {\n id: data.id,\n name: file.name,\n mime: file.type,\n size: file.size,\n order: files.length,\n }\n\n setFiles((prev) => [...prev, newFile])\n // remove from uploading\n setFilesUploading((prev) => prev.filter((uploading: any) => uploading.name !== file.name))\n\n return newFile\n }\n\n const handleFileRemove = (id: string, name: string, isUnsavedAnnotation: boolean) => {\n if (isUnsavedAnnotation) {\n // remove from annotations (if it's an unsaved annotation)\n removeAnnotation?.(id)\n } else {\n // remove file from files\n setFiles((prev) => prev.filter((file) => file.id !== id))\n // remove from uploading\n setFilesUploading((prev) => {\n return prev.filter((file: any) => file.name !== name)\n })\n }\n }\n\n const handleFileProgress = (e: any, file: any) => {\n const progress = Math.round((e.loaded * 100) / e.total)\n if (progress !== 100) {\n const uploadProgress = {\n name: file.name,\n progress,\n type: file.type,\n order: files.length + filesUploading.length,\n }\n\n // @ts-ignore\n setFilesUploading((prev) => {\n // replace or add new progress\n const newProgress = prev.filter((name: any) => name.name !== file.name)\n return [...newProgress, uploadProgress]\n })\n }\n }\n\n // when a file is not dropped onto the comment input\n const handleDrop = (e: React.DragEvent<HTMLDivElement>) => {\n setIsDropping(false)\n // upload file\n handleFileDrop(e, projectName, handleFileProgress, handleFileUploaded)\n }\n\n const handleDragOver = (e: React.DragEvent<HTMLDivElement>) => {\n e.preventDefault()\n e.stopPropagation()\n setIsDropping(true)\n }\n\n const uploadAnnotations = useAnnotationsUpload({\n projectName,\n onSuccess: handleFileUploaded,\n })\n\n const handleSubmit = async () => {\n try {\n setIsSubmitting(true)\n // upload any annotations first\n let annotationFiles = []\n let annotationMetadata: SavedAnnotationMetadata[] = []\n\n if (annotations.length) {\n const { files, metadata } = await uploadAnnotations(annotations)\n annotationFiles = files\n annotationMetadata = metadata\n }\n\n // convert to markdown\n const [markdown] = convertToMarkdown(editorValue)\n\n // remove img query params\n const markdownParsed = parseImages(markdown)\n\n const uploadedFiles = [...files, ...annotationFiles]\n\n if ((markdownParsed || uploadedFiles.length) && onSubmit) {\n try {\n await onSubmit(markdownParsed, uploadedFiles, { annotations: annotationMetadata })\n // only clear if onSubmit is successful\n setEditorValue('')\n setFiles([])\n } catch (error) {\n // error is handled in rtk query mutation\n return\n }\n }\n } catch (error) {\n console.error(error)\n toast.error('Something went wrong')\n } finally {\n setIsSubmitting(false)\n }\n }\n\n const handleKeyDown = (e: React.KeyboardEvent<HTMLElement>) => {\n if (mention) {\n // close mention on escape\n if (e.key === 'Escape') {\n setMention(null)\n setMentionSelectedIndex(0)\n return\n }\n\n // add top search of mention\n if (mention && e.key === 'Tab') {\n // we handle this in the onChange\n }\n\n const arrowDirection = e.key === 'ArrowUp' ? -1 : e.key === 'ArrowDown' ? 1 : 0\n\n if (arrowDirection) {\n // navigate through mentions\n e.preventDefault()\n let newIndex = mentionSelectedIndex + arrowDirection\n if (newIndex < 0) newIndex = shownMentionOptions.length - 1\n if (newIndex >= shownMentionOptions.length) newIndex = 0\n setMentionSelectedIndex(newIndex)\n }\n\n if (e.key === 'Enter') {\n // we handle this in the onChange\n }\n }\n\n if (e.key === 'Enter' && (e.ctrlKey || e.metaKey)) {\n handleSubmit()\n }\n\n if (e.key === 'Escape') {\n handleClose()\n }\n }\n\n let quillMinHeight: number | undefined = isOpen ? initHeight + 41 : 44\n if (isEditing) quillMinHeight = undefined\n\n // QUILL CONFIG\n const modules = useMemo(\n () =>\n getModules({\n imageUploader: {\n projectName,\n onUpload: handleFileUploaded,\n onUploadProgress: handleFileProgress,\n },\n }),\n [projectName, setFiles, setFilesUploading],\n )\n\n const allFiles = [...annotations, ...(files || []), ...filesUploading].sort(\n (a, b) => a.order - b.order,\n )\n const compactGrid = allFiles.length > 6\n\n // disable version mentions for folders\n let mentionsError = null\n if (entities.length && entities[0].entityType === 'folder') {\n if (mention?.type === '@@') {\n mentionsError = 'Version mentions are disabled for folders'\n }\n }\n\n return (\n <>\n <Styled.AutoHeight\n className={clsx('comment-container', { isOpen, isEditing })}\n onDragOver={handleDragOver}\n onDragLeave={() => setIsDropping(false)}\n onDrop={handleDrop}\n onClick={() => setIsDropping(false)}\n onKeyDown={(e) => e.stopPropagation()}\n >\n <Styled.Comment\n className={clsx('block-shortcuts', {\n isOpen,\n isClosed: !isOpen || disabled,\n isEditing,\n isDropping,\n disabled,\n isLoading,\n isSubmitting,\n })}\n onKeyDown={handleKeyDown}\n onClick={handleOpenClick}\n >\n <Styled.Markdown ref={markdownRef}>\n {/* this is purely used to translate the markdown into html for Editor */}\n <InputMarkdownConvert typeOptions={mentionTypeOptions} initValue={initValue} />\n </Styled.Markdown>\n\n {/* file uploads */}\n {isOpen && (\n <FilesGrid\n files={allFiles}\n isCompact={compactGrid}\n onRemove={handleFileRemove}\n style={{ borderBottom: '1px solid var(--md-sys-color-outline-variant)' }}\n projectName={projectName}\n onAnnotationClick={goToAnnotation}\n />\n )}\n {isOpen && !disabled ? (\n <QuillListStyles>\n <ReactQuill\n theme=\"snow\"\n style={{ minHeight: quillMinHeight, maxHeight: 300 }}\n ref={editorRef}\n value={editorValue}\n onChange={handleChange}\n readOnly={!isOpen}\n placeholder={'Comment or mention with @user, @@version, @@@task...'}\n modules={modules}\n formats={quillFormats}\n />\n </QuillListStyles>\n ) : (\n <Styled.Placeholder>\n {disabled ? 'Commenting is disabled across multiple projects.' : 'Add a comment...'}\n </Styled.Placeholder>\n )}\n\n <Styled.Footer>\n <Styled.Buttons>\n {/* mention a user */}\n <Button\n icon=\"person\"\n variant=\"text\"\n onClick={() => handleMentionButton('@')}\n data-tooltip={'Mention user'}\n data-shortcut={'@'}\n />\n {/* mention a version */}\n <Button\n icon=\"layers\"\n variant=\"text\"\n onClick={() => handleMentionButton('@@')}\n data-tooltip={'Mention version'}\n data-shortcut={'@@'}\n />\n {/* mention a task */}\n <Button\n icon=\"check_circle\"\n variant=\"text\"\n onClick={() => handleMentionButton('@@@')}\n data-tooltip={'Mention task'}\n data-shortcut={'@@@'}\n />\n </Styled.Buttons>\n <Styled.Buttons>\n {isEditing && (\n <Button variant=\"text\" onClick={handleClose}>\n Cancel\n </Button>\n )}\n <SaveButton\n label={isEditing ? 'Save' : 'Comment'}\n className=\"comment\"\n active={!!editorValue || !!files.length}\n onClick={handleSubmit}\n disabled={isLoading}\n />\n </Styled.Buttons>\n </Styled.Footer>\n\n <Styled.Dropzone className={clsx({ show: isDropping && isOpen })}>\n <Icon icon=\"cloud_upload\" />\n </Styled.Dropzone>\n </Styled.Comment>\n <CommentMentionSelect\n mention={mention}\n options={shownMentionOptions}\n onChange={handleSelectChange}\n types={mentionTypes}\n z\n // @ts-ignore\n config={mentionTypeOptions[mention?.type]}\n noneFound={!shownMentionOptions.length && mention?.search}\n noneFoundAtAll={!shownMentionOptions.length && !mention?.search}\n selectedIndex={mentionSelectedIndex}\n // @ts-ignore\n error={mentionsError}\n />\n </Styled.AutoHeight>\n </>\n )\n}\n\nexport default CommentInput\n"],"names":["Delta","Quill","mentionTypes","mentionTypeOptions","CommentInput","initValue","initFiles","onSubmit","isEditing","disabled","isLoading","isOpen","onOpen","onClose","projectName","entities","projectInfo","scope","currentTab","mentionSuggestionsData","useFeedContext","mentionUsers","mentionVersions","mentionTasks","initHeight","setInitHeight","useState","editorValue","setEditorValue","files","setFiles","filesUploading","setFilesUploading","isDropping","setIsDropping","isSubmitting","setIsSubmitting","annotations","removeAnnotation","goToAnnotation","useAnnotationsSync","_a","mention","setMention","mentionSelectedIndex","setMentionSelectedIndex","editorRef","useRef","markdownRef","useInitialValue","useSetCursorEnd","useMentionLink","useEffect","_b","_c","a","b","mentionOptions","useMemo","getMentionOptions","getMentionUsers","getMentionVersions","getMentionTasks","shownMentionOptions","newSelection","setNewSelection","handleSelectMention","selectedOption","quill","typePrefix","search","mentionLabel","type","href","selection","startIndex","endIndex","handleSelectChange","option","handleChange","content","delta","_","editor","currentCharacter","tabOrEnter","isDelete","mentionIndex","op","retain","mentionMatch","chars","isMatch","i","char","indexInDelta","distanceMentionToRetain","mentionFull","mentionSearch","currentSelection","lineBlock","lastMentionOp","mentionLength","addTextToEditor","typeWithDelay","handleMentionButton","length","start","handleOpenClick","handleClose","handleFileUploaded","file","data","newFile","prev","uploading","handleFileRemove","id","name","isUnsavedAnnotation","handleFileProgress","progress","uploadProgress","handleDrop","handleFileDrop","handleDragOver","uploadAnnotations","useAnnotationsUpload","handleSubmit","annotationFiles","annotationMetadata","metadata","markdown","convertToMarkdown","markdownParsed","parseImages","uploadedFiles","error","toast","handleKeyDown","arrowDirection","newIndex","quillMinHeight","modules","getModules","allFiles","compactGrid","mentionsError","jsx","Fragment","jsxs","Styled.AutoHeight","clsx","Styled.Comment","Styled.Markdown","InputMarkdownConvert","FilesGrid","QuillListStyles","ReactQuill","quillFormats","Styled.Placeholder","Styled.Footer","Styled.Buttons","Button","SaveButton","Styled.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EAAAA,KAAK,CAAA,KAAK,eAAe,CAC5B,CAAA,CAAA,CAAA,CACF,EACAlB,EAAA,kBAAA,IAACmB,GAAA,CACC,QAAA7H,EACA,QAASqB,EACT,SAAUc,GACV,MAAO3E,EACP,EAAC,GAED,OAAQC,EAAmBuC,GAAA,YAAAA,EAAS,IAAI,EACxC,UAAW,CAACqB,EAAoB,SAAUrB,GAAA,YAAAA,EAAS,QACnD,eAAgB,CAACqB,EAAoB,QAAU,EAACrB,GAAA,MAAAA,EAAS,QACzD,cAAeE,EAEf,MAAOuG,EAAA,CAAA,CACT,CAAA,CAAA,EAEJ,CAEJ"}
|
|
@@ -1,28 +1,29 @@
|
|
|
1
1
|
import { j as i } from "../../../../../../_virtual/jsx-runtime.es.js";
|
|
2
2
|
import { useState as g, useRef as he, useEffect as ge, useMemo as xe } from "react";
|
|
3
|
-
import
|
|
4
|
-
import { toast as
|
|
3
|
+
import _ from "clsx";
|
|
4
|
+
import { toast as Ke } from "react-toastify";
|
|
5
5
|
import Ve, { Quill as ze } from "react-quill-ayon";
|
|
6
|
-
import { Button as q, SaveButton as Be, Icon as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
6
|
+
import { Button as q, SaveButton as Be, Icon as Qe } from "@ynput/ayon-react-components";
|
|
7
|
+
import _e from "../CommentMentionSelect/CommentMentionSelect.es.js";
|
|
8
|
+
import Ge from "./InputMarkdownConvert.es.js";
|
|
9
9
|
import We from "../FilesGrid/FilesGrid.es.js";
|
|
10
10
|
import { AutoHeight as $e, Comment as Je, Markdown as Xe, Placeholder as Ye, Footer as Ze, Buttons as ye, Dropzone as Oe } from "./CommentInput.styled.es.js";
|
|
11
|
-
import et from "
|
|
12
|
-
import tt from "../../mentionHelpers/
|
|
13
|
-
import nt from "../../mentionHelpers/
|
|
14
|
-
import ot from "../../mentionHelpers/
|
|
15
|
-
import
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import dt from "./
|
|
19
|
-
import mt from "./hooks/
|
|
20
|
-
import ut from "./hooks/
|
|
21
|
-
import pt from "./hooks/
|
|
22
|
-
import ft from "./hooks/
|
|
23
|
-
import
|
|
11
|
+
import { QuillListStyles as et } from "../../../../components/QuillListStyles/QuillListStyles.es.js";
|
|
12
|
+
import tt from "../../mentionHelpers/getMentionOptions.es.js";
|
|
13
|
+
import nt from "../../mentionHelpers/getMentionUsers.es.js";
|
|
14
|
+
import ot from "../../mentionHelpers/getMentionTasks.es.js";
|
|
15
|
+
import st from "../../mentionHelpers/getMentionVersions.es.js";
|
|
16
|
+
import { convertToMarkdown as rt } from "./quillToMarkdown.es.js";
|
|
17
|
+
import { handleFileDrop as it, parseImages as lt, typeWithDelay as at } from "./helpers.es.js";
|
|
18
|
+
import { getModules as ct, quillFormats as dt } from "./modules/index.es.js";
|
|
19
|
+
import mt from "./hooks/useInitialValue.es.js";
|
|
20
|
+
import ut from "./hooks/useSetCursorEnd.es.js";
|
|
21
|
+
import pt from "./hooks/useMentionLink.es.js";
|
|
22
|
+
import ft from "./hooks/useAnnotationsSync.es.js";
|
|
23
|
+
import ht from "./hooks/useAnnotationsUpload.es.js";
|
|
24
|
+
import { useFeedContext as gt } from "../../context/FeedContext.es.js";
|
|
24
25
|
var ke = ze.import("delta");
|
|
25
|
-
const R = ["@", "@@", "@@@"],
|
|
26
|
+
const R = ["@", "@@", "@@@"], G = {
|
|
26
27
|
"@@@": {
|
|
27
28
|
id: "task"
|
|
28
29
|
},
|
|
@@ -33,7 +34,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
33
34
|
id: "user",
|
|
34
35
|
isCircle: !0
|
|
35
36
|
}
|
|
36
|
-
},
|
|
37
|
+
}, Bt = ({
|
|
37
38
|
initValue: W,
|
|
38
39
|
initFiles: Ce = [],
|
|
39
40
|
onSubmit: $,
|
|
@@ -45,22 +46,22 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
45
46
|
onClose: Y
|
|
46
47
|
}) => {
|
|
47
48
|
var fe;
|
|
48
|
-
const { projectName: w, entities: H, projectInfo: we, scope:
|
|
49
|
+
const { projectName: w, entities: H, projectInfo: we, scope: xt, currentTab: Me, mentionSuggestionsData: ve } = gt(), {
|
|
49
50
|
users: Z,
|
|
50
51
|
versions: O,
|
|
51
52
|
tasks: ee
|
|
52
|
-
} = ve || {}, [te, je] = g(88), [
|
|
53
|
+
} = ve || {}, [te, je] = g(88), [L, S] = g(""), [M, b] = g(Ce), [N, A] = g([]), [ne, E] = g(!1), [Ie, oe] = g(!1), { annotations: P, removeAnnotation: K, goToAnnotation: Te } = ft({
|
|
53
54
|
entityId: (fe = H[0]) == null ? void 0 : fe.id,
|
|
54
|
-
filesUploading:
|
|
55
|
+
filesUploading: N
|
|
55
56
|
}), [n, k] = g(null), [V, v] = g(0), d = he(null), se = he(null);
|
|
56
|
-
|
|
57
|
+
mt({
|
|
57
58
|
markdownRef: se,
|
|
58
59
|
initValue: W,
|
|
59
60
|
setEditorValue: S,
|
|
60
61
|
setInitHeight: je,
|
|
61
62
|
isOpen: c,
|
|
62
63
|
filter: Me
|
|
63
|
-
}),
|
|
64
|
+
}), ut({ initHeight: te, editorRef: d, isEditing: y }), pt({ projectName: w }), ge(() => {
|
|
64
65
|
var e, t, o;
|
|
65
66
|
if (c) {
|
|
66
67
|
if ((t = (e = d.current) == null ? void 0 : e.getEditor()) == null || t.enable(), P.length > 0 && M.length === 0)
|
|
@@ -69,12 +70,12 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
69
70
|
}
|
|
70
71
|
}, [c, d]), R.sort((e, t) => t.length - e.length);
|
|
71
72
|
const re = xe(
|
|
72
|
-
() =>
|
|
73
|
+
() => tt(
|
|
73
74
|
n == null ? void 0 : n.type,
|
|
74
75
|
{
|
|
75
|
-
"@": () =>
|
|
76
|
-
"@@": () =>
|
|
77
|
-
"@@@": () =>
|
|
76
|
+
"@": () => nt(Z),
|
|
77
|
+
"@@": () => st(O),
|
|
78
|
+
"@@@": () => ot(ee, we.taskTypes)
|
|
78
79
|
},
|
|
79
80
|
n == null ? void 0 : n.search
|
|
80
81
|
),
|
|
@@ -84,7 +85,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
84
85
|
z && (ie(null), d.current.getEditor().setSelection(z));
|
|
85
86
|
}, [z]);
|
|
86
87
|
const le = (e) => {
|
|
87
|
-
const t = d.current.getEditor(), o = n.type, s = o + (n.search || ""), r = o + e.label, l =
|
|
88
|
+
const t = d.current.getEditor(), o = n.type, s = o + (n.search || ""), r = o + e.label, l = G[o], u = `${l == null ? void 0 : l.id}:${e.id}`, C = t.getSelection(!0), j = ((C == null ? void 0 : C.index) || 0) - s.length;
|
|
88
89
|
t.deleteText(j, s.length), t.insertText(j, r, "mention", u);
|
|
89
90
|
const I = j + r.length;
|
|
90
91
|
t.updateContents(new ke().retain(I).insert(" ")), t.updateContents(new ke().retain(I + 1).delete(1)), ie(I + 1), k(null), v(0);
|
|
@@ -111,8 +112,8 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
111
112
|
if (h.endsWith(a))
|
|
112
113
|
for (let f = h.length - 1; f >= 0; f--) {
|
|
113
114
|
if (f === 0) continue;
|
|
114
|
-
const U = h[f - 1],
|
|
115
|
-
if (s.getText(
|
|
115
|
+
const U = h[f - 1], Ne = x - (h.length - f);
|
|
116
|
+
if (s.getText(Ne, 1) !== U) {
|
|
116
117
|
T = !1;
|
|
117
118
|
break;
|
|
118
119
|
}
|
|
@@ -159,7 +160,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
159
160
|
const t = d.current.getEditor();
|
|
160
161
|
let o = ((l = t.getSelection(!0)) == null ? void 0 : l.index) || 0;
|
|
161
162
|
const s = t.getText(o - 1, 1);
|
|
162
|
-
s !== " " && s && (t.insertText(o, " "), o++),
|
|
163
|
+
s !== " " && s && (t.insertText(o, " "), o++), at(t, o, e);
|
|
163
164
|
}, B = (e) => {
|
|
164
165
|
if (n) {
|
|
165
166
|
const { type: t, retain: o, search: s = "" } = n, r = d.current.getEditor(), l = t.length + s.length, u = o - t.length + 1;
|
|
@@ -170,7 +171,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
170
171
|
c || D || X && X();
|
|
171
172
|
}, ae = () => {
|
|
172
173
|
(d.current.getEditor().getText().length < 2 || y) && S(""), Y && Y();
|
|
173
|
-
},
|
|
174
|
+
}, Q = ({ file: e, data: t }) => {
|
|
174
175
|
const o = {
|
|
175
176
|
id: t.id,
|
|
176
177
|
name: e.name,
|
|
@@ -180,7 +181,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
180
181
|
};
|
|
181
182
|
return b((s) => [...s, o]), A((s) => s.filter((r) => r.name !== e.name)), o;
|
|
182
183
|
}, Ae = (e, t, o) => {
|
|
183
|
-
o ?
|
|
184
|
+
o ? K == null || K(e) : (b((s) => s.filter((r) => r.id !== e)), A((s) => s.filter((r) => r.name !== t)));
|
|
184
185
|
}, ce = (e, t) => {
|
|
185
186
|
const o = Math.round(e.loaded * 100 / e.total);
|
|
186
187
|
if (o !== 100) {
|
|
@@ -188,17 +189,17 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
188
189
|
name: t.name,
|
|
189
190
|
progress: o,
|
|
190
191
|
type: t.type,
|
|
191
|
-
order: M.length +
|
|
192
|
+
order: M.length + N.length
|
|
192
193
|
};
|
|
193
194
|
A((r) => [...r.filter((u) => u.name !== t.name), s]);
|
|
194
195
|
}
|
|
195
196
|
}, Ee = (e) => {
|
|
196
|
-
E(!1),
|
|
197
|
+
E(!1), it(e, w, ce, Q);
|
|
197
198
|
}, Pe = (e) => {
|
|
198
199
|
e.preventDefault(), e.stopPropagation(), E(!0);
|
|
199
|
-
}, Ue =
|
|
200
|
+
}, Ue = ht({
|
|
200
201
|
projectName: w,
|
|
201
|
-
onSuccess:
|
|
202
|
+
onSuccess: Q
|
|
202
203
|
}), de = async () => {
|
|
203
204
|
try {
|
|
204
205
|
oe(!0);
|
|
@@ -207,7 +208,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
207
208
|
const { files: l, metadata: u } = await Ue(P);
|
|
208
209
|
e = l, t = u;
|
|
209
210
|
}
|
|
210
|
-
const [o] =
|
|
211
|
+
const [o] = rt(L), s = lt(o), r = [...M, ...e];
|
|
211
212
|
if ((s || r.length) && $)
|
|
212
213
|
try {
|
|
213
214
|
await $(s, r, { annotations: t }), S(""), b([]);
|
|
@@ -215,7 +216,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
215
216
|
return;
|
|
216
217
|
}
|
|
217
218
|
} catch (e) {
|
|
218
|
-
console.error(e),
|
|
219
|
+
console.error(e), Ke.error("Something went wrong");
|
|
219
220
|
} finally {
|
|
220
221
|
oe(!1);
|
|
221
222
|
}
|
|
@@ -239,22 +240,22 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
239
240
|
let me = c ? te + 41 : 44;
|
|
240
241
|
y && (me = void 0);
|
|
241
242
|
const Re = xe(
|
|
242
|
-
() =>
|
|
243
|
+
() => ct({
|
|
243
244
|
imageUploader: {
|
|
244
245
|
projectName: w,
|
|
245
|
-
onUpload:
|
|
246
|
+
onUpload: Q,
|
|
246
247
|
onUploadProgress: ce
|
|
247
248
|
}
|
|
248
249
|
}),
|
|
249
250
|
[w, b, A]
|
|
250
|
-
), ue = [...P, ...M || [], ...
|
|
251
|
+
), ue = [...P, ...M || [], ...N].sort(
|
|
251
252
|
(e, t) => e.order - t.order
|
|
252
253
|
), He = ue.length > 6;
|
|
253
254
|
let pe = null;
|
|
254
255
|
return H.length && H[0].entityType === "folder" && (n == null ? void 0 : n.type) === "@@" && (pe = "Version mentions are disabled for folders"), /* @__PURE__ */ i.jsx(i.Fragment, { children: /* @__PURE__ */ i.jsxs(
|
|
255
256
|
$e,
|
|
256
257
|
{
|
|
257
|
-
className:
|
|
258
|
+
className: _("comment-container", { isOpen: c, isEditing: y }),
|
|
258
259
|
onDragOver: Pe,
|
|
259
260
|
onDragLeave: () => E(!1),
|
|
260
261
|
onDrop: Ee,
|
|
@@ -264,7 +265,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
264
265
|
/* @__PURE__ */ i.jsxs(
|
|
265
266
|
Je,
|
|
266
267
|
{
|
|
267
|
-
className:
|
|
268
|
+
className: _("block-shortcuts", {
|
|
268
269
|
isOpen: c,
|
|
269
270
|
isClosed: !c || D,
|
|
270
271
|
isEditing: y,
|
|
@@ -276,7 +277,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
276
277
|
onKeyDown: qe,
|
|
277
278
|
onClick: be,
|
|
278
279
|
children: [
|
|
279
|
-
/* @__PURE__ */ i.jsx(Xe, { ref: se, children: /* @__PURE__ */ i.jsx(
|
|
280
|
+
/* @__PURE__ */ i.jsx(Xe, { ref: se, children: /* @__PURE__ */ i.jsx(Ge, { typeOptions: G, initValue: W }) }),
|
|
280
281
|
c && /* @__PURE__ */ i.jsx(
|
|
281
282
|
We,
|
|
282
283
|
{
|
|
@@ -288,20 +289,20 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
288
289
|
onAnnotationClick: Te
|
|
289
290
|
}
|
|
290
291
|
),
|
|
291
|
-
c && !D ? /* @__PURE__ */ i.jsx(
|
|
292
|
+
c && !D ? /* @__PURE__ */ i.jsx(et, { children: /* @__PURE__ */ i.jsx(
|
|
292
293
|
Ve,
|
|
293
294
|
{
|
|
294
295
|
theme: "snow",
|
|
295
296
|
style: { minHeight: me, maxHeight: 300 },
|
|
296
297
|
ref: d,
|
|
297
|
-
value:
|
|
298
|
+
value: L,
|
|
298
299
|
onChange: Fe,
|
|
299
300
|
readOnly: !c,
|
|
300
301
|
placeholder: "Comment or mention with @user, @@version, @@@task...",
|
|
301
302
|
modules: Re,
|
|
302
|
-
formats:
|
|
303
|
+
formats: dt
|
|
303
304
|
}
|
|
304
|
-
) : /* @__PURE__ */ i.jsx(Ye, { children: D ? "Commenting is disabled across multiple projects." : "Add a comment..." }),
|
|
305
|
+
) }) : /* @__PURE__ */ i.jsx(Ye, { children: D ? "Commenting is disabled across multiple projects." : "Add a comment..." }),
|
|
305
306
|
/* @__PURE__ */ i.jsxs(Ze, { children: [
|
|
306
307
|
/* @__PURE__ */ i.jsxs(ye, { children: [
|
|
307
308
|
/* @__PURE__ */ i.jsx(
|
|
@@ -342,26 +343,26 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
342
343
|
{
|
|
343
344
|
label: y ? "Save" : "Comment",
|
|
344
345
|
className: "comment",
|
|
345
|
-
active: !!
|
|
346
|
+
active: !!L || !!M.length,
|
|
346
347
|
onClick: de,
|
|
347
348
|
disabled: J
|
|
348
349
|
}
|
|
349
350
|
)
|
|
350
351
|
] })
|
|
351
352
|
] }),
|
|
352
|
-
/* @__PURE__ */ i.jsx(Oe, { className:
|
|
353
|
+
/* @__PURE__ */ i.jsx(Oe, { className: _({ show: ne && c }), children: /* @__PURE__ */ i.jsx(Qe, { icon: "cloud_upload" }) })
|
|
353
354
|
]
|
|
354
355
|
}
|
|
355
356
|
),
|
|
356
357
|
/* @__PURE__ */ i.jsx(
|
|
357
|
-
|
|
358
|
+
_e,
|
|
358
359
|
{
|
|
359
360
|
mention: n,
|
|
360
361
|
options: F,
|
|
361
362
|
onChange: De,
|
|
362
363
|
types: R,
|
|
363
364
|
z: !0,
|
|
364
|
-
config:
|
|
365
|
+
config: G[n == null ? void 0 : n.type],
|
|
365
366
|
noneFound: !F.length && (n == null ? void 0 : n.search),
|
|
366
367
|
noneFoundAtAll: !F.length && !(n != null && n.search),
|
|
367
368
|
selectedIndex: V,
|
|
@@ -373,7 +374,7 @@ const R = ["@", "@@", "@@@"], Q = {
|
|
|
373
374
|
) });
|
|
374
375
|
};
|
|
375
376
|
export {
|
|
376
|
-
|
|
377
|
-
|
|
377
|
+
Bt as default,
|
|
378
|
+
G as mentionTypeOptions
|
|
378
379
|
};
|
|
379
380
|
//# sourceMappingURL=CommentInput.es.js.map
|