@blaze-cms/plugin-data-ui 0.146.0-core-styles.60 → 0.146.0-core-styles.61

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.
Files changed (100) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/README.md +36 -0
  3. package/lib/components/EntityManager/Entity/EntitiyNavLinks/EntityNavLinks.js +0 -1
  4. package/lib/components/EntityManager/Entity/EntitiyNavLinks/EntityNavLinks.js.map +1 -1
  5. package/lib/components/EntityManager/Entity/Entity.js +48 -47
  6. package/lib/components/EntityManager/Entity/Entity.js.map +1 -1
  7. package/lib/components/EntityManager/Entity/EntityHeader/HeaderPreviewButton/HeaderPreviewButton.js +1 -1
  8. package/lib/components/EntityManager/Entity/EntityHeader/HeaderPreviewButton/HeaderPreviewButton.js.map +1 -1
  9. package/lib/components/EntityManager/Entity/SideBarRelations/helpers/build-dynamic-query.js +0 -1
  10. package/lib/components/EntityManager/Entity/SideBarRelations/helpers/build-dynamic-query.js.map +1 -1
  11. package/lib/components/EntityManager/Entity/SideBarRelations/index.js +6 -5
  12. package/lib/components/EntityManager/Entity/SideBarRelations/index.js.map +1 -1
  13. package/lib/components/EntityManager/Entity/actions-handlers/create/submit.js +1 -1
  14. package/lib/components/EntityManager/Entity/actions-handlers/create/submit.js.map +1 -1
  15. package/lib/components/EntityManager/Entity/actions-handlers/delete/delete.js +1 -1
  16. package/lib/components/EntityManager/Entity/actions-handlers/delete/delete.js.map +1 -1
  17. package/lib/components/EntityManager/Entity/actions-handlers/shared/publish.js +1 -1
  18. package/lib/components/EntityManager/Entity/actions-handlers/shared/publish.js.map +1 -1
  19. package/lib/components/EntityManager/Entity/actions-handlers/update/submit.js +1 -1
  20. package/lib/components/EntityManager/Entity/actions-handlers/update/submit.js.map +1 -1
  21. package/lib/components/EntityManager/EntityManager.js +7 -6
  22. package/lib/components/EntityManager/EntityManager.js.map +1 -1
  23. package/lib/components/EntityManager/utils/entity.js +1 -1
  24. package/lib/components/EntityManager/utils/entity.js.map +1 -1
  25. package/lib/components/EntityManager/utils/entityAvailableActions.js +2 -2
  26. package/lib/components/EntityManager/utils/entityAvailableActions.js.map +1 -1
  27. package/lib/components/InfoBoxes/InfoBoxes.js +0 -1
  28. package/lib/components/InfoBoxes/InfoBoxes.js.map +1 -1
  29. package/lib/components/InfoBoxes/container/InfoBoxContainer.js +2 -1
  30. package/lib/components/InfoBoxes/container/InfoBoxContainer.js.map +1 -1
  31. package/lib/components/InfoBoxes/helpers/build-dynamic-query.js +0 -1
  32. package/lib/components/InfoBoxes/helpers/build-dynamic-query.js.map +1 -1
  33. package/lib/components/ListingTable/ListingTable.js +27 -18
  34. package/lib/components/ListingTable/ListingTable.js.map +1 -1
  35. package/lib/components/ListingTable/ListingTableContent/ListingTableContent.js.map +1 -1
  36. package/lib/components/ListingTable/SearchFilter/SearchContainer.js +313 -0
  37. package/lib/components/ListingTable/SearchFilter/SearchContainer.js.map +1 -0
  38. package/lib/components/ListingTable/SearchFilter/SearchFilter.js +58 -0
  39. package/lib/components/ListingTable/SearchFilter/SearchFilter.js.map +1 -0
  40. package/lib/components/ListingTable/SearchFilter/helpers.js +120 -0
  41. package/lib/components/ListingTable/SearchFilter/helpers.js.map +1 -0
  42. package/lib/components/ListingTable/SearchFilter/querys.js +13 -0
  43. package/lib/components/ListingTable/SearchFilter/querys.js.map +1 -0
  44. package/lib/components/ListingTable/TableActions/TableActions.js.map +1 -1
  45. package/lib/components/ListingTable/service/index.js +1 -2
  46. package/lib/components/ListingTable/service/index.js.map +1 -1
  47. package/lib/components/Tabs/index.js +2 -1
  48. package/lib/components/Tabs/index.js.map +1 -1
  49. package/lib/constants.js +3 -1
  50. package/lib/constants.js.map +1 -1
  51. package/lib/index.js +6 -5
  52. package/lib/index.js.map +1 -1
  53. package/lib/utils/add-content-menu-items.js +1 -1
  54. package/lib/utils/add-content-menu-items.js.map +1 -1
  55. package/lib-es/components/EntityManager/Entity/Entity.js.map +1 -1
  56. package/lib-es/components/EntityManager/Entity/EntityHeader/EntityHeader.js.map +1 -1
  57. package/lib-es/components/EntityManager/Entity/EntityHeader/HeaderPreviewButton/HeaderPreviewButton.js.map +1 -1
  58. package/lib-es/components/EntityManager/Entity/SideBarRelations/helpers/build-dynamic-query.js.map +1 -1
  59. package/lib-es/components/EntityManager/Entity/SideBarRelations/hooks/useCustomSidebarData.js.map +1 -1
  60. package/lib-es/components/EntityManager/Entity/SideBarRelations/presentational/CustomSidebarInfo.js.map +1 -1
  61. package/lib-es/components/EntityManager/Entity/actions-handlers/create/submit.js.map +1 -1
  62. package/lib-es/components/EntityManager/Entity/actions-handlers/shared/publish.js.map +1 -1
  63. package/lib-es/components/EntityManager/EntityManager.js.map +1 -1
  64. package/lib-es/components/EntityManager/utils/entity.js.map +1 -1
  65. package/lib-es/components/EntityManager/utils/query.js.map +1 -1
  66. package/lib-es/components/InfoBoxes/InfoBoxTooltip.js.map +1 -1
  67. package/lib-es/components/InfoBoxes/helpers/build-dynamic-query.js.map +1 -1
  68. package/lib-es/components/InfoBoxes/hooks/useData.js.map +1 -1
  69. package/lib-es/components/InfoBoxes/presentational/InfoBox.js.map +1 -1
  70. package/lib-es/components/InfoBoxes/presentational/InfoBoxLabel.js.map +1 -1
  71. package/lib-es/components/ListingTable/ListingTable.js +9 -1
  72. package/lib-es/components/ListingTable/ListingTable.js.map +1 -1
  73. package/lib-es/components/ListingTable/ListingTableContent/ListingTableContent.js.map +1 -1
  74. package/lib-es/components/ListingTable/SearchFilter/SearchContainer.js +207 -0
  75. package/lib-es/components/ListingTable/SearchFilter/SearchContainer.js.map +1 -0
  76. package/lib-es/components/ListingTable/SearchFilter/SearchFilter.js +39 -0
  77. package/lib-es/components/ListingTable/SearchFilter/SearchFilter.js.map +1 -0
  78. package/lib-es/components/ListingTable/SearchFilter/helpers.js +94 -0
  79. package/lib-es/components/ListingTable/SearchFilter/helpers.js.map +1 -0
  80. package/lib-es/components/ListingTable/SearchFilter/querys.js +8 -0
  81. package/lib-es/components/ListingTable/SearchFilter/querys.js.map +1 -0
  82. package/lib-es/components/ListingTable/mappers/populate-rows.js.map +1 -1
  83. package/lib-es/components/ListingTable/service/index.js.map +1 -1
  84. package/lib-es/constants.js +3 -1
  85. package/lib-es/constants.js.map +1 -1
  86. package/lib-es/index.js +2 -2
  87. package/lib-es/index.js.map +1 -1
  88. package/lib-es/utils/add-content-menu-items.js.map +1 -1
  89. package/lib-es/utils/build-create-entity-mutation.js.map +1 -1
  90. package/lib-es/utils/build-delete-entity-mutation.js.map +1 -1
  91. package/lib-es/utils/build-listing-query.js.map +1 -1
  92. package/lib-es/utils/build-update-data-query.js.map +1 -1
  93. package/lib-es/utils/build-update-publish-unpublish-mutation.js.map +1 -1
  94. package/package.json +5 -5
  95. package/src/components/ListingTable/ListingTable.js +9 -0
  96. package/src/components/ListingTable/SearchFilter/SearchContainer.js +238 -0
  97. package/src/components/ListingTable/SearchFilter/SearchFilter.js +37 -0
  98. package/src/components/ListingTable/SearchFilter/helpers.js +96 -0
  99. package/src/components/ListingTable/SearchFilter/querys.js +9 -0
  100. package/src/constants.js +7 -1
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","names":["PLUGIN_NAME","DATA_LISTING_PREFIX","PAGE_BUILDER","TEXT_CONTENT_TYPE","ENTITY_PUBLISHED","SELECT_DEFAULT_VALUE","LEAVE_PAGE_MESSAGE","KEY_TO_CHECK","MENU_PERMISSIONS","PREVIEW_INTERFACE","PAGE_BUILDER_FIELD_ID","PAGE_BUILDER_TEMPLATE_FIELD_ID","ERROR","SUCCESS","PUBLISHED","UNPUBLISHED","SAVE_BUTTON_TEXTS","save","saved","saving","ACTIONS","UNPUBLISHED_WARNING","PAGE_NOT_FOUND","SAVE_BEFORE_PUBLISH_MESSAGE","PAGE_BUILDER_TAB","PAGE_BUILDER_TAB_INDEX","EDITOR_VIEW_TAB","EDITOR_VIEW_TAB_INDEX","ICON_SIZE","WIDTH","HEIGHT","ICON_COLOR","STROKE","FILL"],"sources":["../src/constants.js"],"sourcesContent":["const PLUGIN_NAME = 'data-ui';\nconst DATA_LISTING_PREFIX = '/data-listing';\nconst PAGE_BUILDER = 'pageBuilder';\nconst TEXT_CONTENT_TYPE = 'Publish';\nconst ENTITY_PUBLISHED = 'published';\nconst SELECT_DEFAULT_VALUE = 'Please Choose...';\nconst LEAVE_PAGE_MESSAGE = 'You are going to leave without saving. Are you sure you want to leave?';\nconst KEY_TO_CHECK = 'values.slug';\nconst MENU_PERMISSIONS = ['update:any', 'update:own', 'create:any', 'create:own'];\nconst PREVIEW_INTERFACE = 'preview/can-preview';\nconst PAGE_BUILDER_FIELD_ID = 'pageBuilder';\nconst PAGE_BUILDER_TEMPLATE_FIELD_ID = 'pageBuilderTemplateId';\nconst ERROR = 'error';\nconst SUCCESS = 'success';\nconst PUBLISHED = 'published';\nconst UNPUBLISHED = 'unpublished';\nconst SAVE_BUTTON_TEXTS = { save: 'save', saved: 'saved', saving: 'saving' };\nconst ACTIONS = 'actions';\nconst UNPUBLISHED_WARNING = 'Page already unpublished';\nconst PAGE_NOT_FOUND = 'Page not found';\nconst SAVE_BEFORE_PUBLISH_MESSAGE =\n 'You have to click save to create the record before you can publish';\n\nconst PAGE_BUILDER_TAB = 'Page builder';\nconst PAGE_BUILDER_TAB_INDEX = 1;\nconst EDITOR_VIEW_TAB = 'Editor view';\nconst EDITOR_VIEW_TAB_INDEX = 0;\n\nconst ICON_SIZE = {\n WIDTH: '25px',\n HEIGHT: '25px'\n};\n\nconst ICON_COLOR = {\n STROKE: '#63779C',\n FILL: '#63779C'\n};\n\nexport {\n DATA_LISTING_PREFIX,\n ENTITY_PUBLISHED,\n KEY_TO_CHECK,\n LEAVE_PAGE_MESSAGE,\n MENU_PERMISSIONS,\n PAGE_BUILDER,\n PLUGIN_NAME,\n PREVIEW_INTERFACE,\n SELECT_DEFAULT_VALUE,\n TEXT_CONTENT_TYPE,\n PAGE_BUILDER_FIELD_ID,\n PAGE_BUILDER_TEMPLATE_FIELD_ID,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AMC,qBAAqB,GAAG,CAAC;AAE/B,MAAMC,SAAS,GAAG;EAChBC,KAAK,EAAE,MAAM;EACbC,MAAM,EAAE;AACV,CAAC;AAED,MAAMC,UAAU,GAAG;EACjBC,MAAM,EAAE,SAAS;EACjBC,IAAI,EAAE;AACR,CAAC;AAED,SACEhC,mBAAmB,EACnBG,gBAAgB,EAChBG,YAAY,EACZD,kBAAkB,EAClBE,gBAAgB,EAChBN,YAAY,EACZF,WAAW,EACXS,iBAAiB,EACjBJ,oBAAoB,EACpBF,iBAAiB,EACjBO,qBAAqB,EACrBC,8BAA8B,EAC9BC,KAAK,EACLC,OAAO,EACPC,SAAS,EACTC,WAAW,EACXC,iBAAiB,EACjBI,OAAO,EACPK,sBAAsB,EACtBE,qBAAqB,EACrBD,eAAe,EACfF,gBAAgB,EAChBH,mBAAmB,EACnBE,2BAA2B,EAC3BK,SAAS,EACTG,UAAU,EACVT,cAAc","ignoreList":[]}
1
+ {"version":3,"file":"constants.js","names":["PLUGIN_NAME","DATA_LISTING_PREFIX","PAGE_BUILDER","TEXT_CONTENT_TYPE","ENTITY_PUBLISHED","SELECT_DEFAULT_VALUE","LEAVE_PAGE_MESSAGE","KEY_TO_CHECK","MENU_PERMISSIONS","PREVIEW_INTERFACE","PAGE_BUILDER_FIELD_ID","PAGE_BUILDER_TEMPLATE_FIELD_ID","ERROR","SUCCESS","PUBLISHED","UNPUBLISHED","SAVE_BUTTON_TEXTS","save","saved","saving","ACTIONS","UNPUBLISHED_WARNING","PAGE_NOT_FOUND","SAVE_BEFORE_PUBLISH_MESSAGE","PAGE_BUILDER_TAB","PAGE_BUILDER_TAB_INDEX","EDITOR_VIEW_TAB","EDITOR_VIEW_TAB_INDEX","ENTER_KEY","ICON_SIZE","WIDTH","HEIGHT","ICON_COLOR","STROKE","FILL","DEFAULT_FILTER_OPTION_LABEL"],"sources":["../src/constants.js"],"sourcesContent":["const PLUGIN_NAME = 'data-ui';\nconst DATA_LISTING_PREFIX = '/data-listing';\nconst PAGE_BUILDER = 'pageBuilder';\nconst TEXT_CONTENT_TYPE = 'Publish';\nconst ENTITY_PUBLISHED = 'published';\nconst SELECT_DEFAULT_VALUE = 'Please Choose...';\nconst LEAVE_PAGE_MESSAGE = 'You are going to leave without saving. Are you sure you want to leave?';\nconst KEY_TO_CHECK = 'values.slug';\nconst MENU_PERMISSIONS = ['update:any', 'update:own', 'create:any', 'create:own'];\nconst PREVIEW_INTERFACE = 'preview/can-preview';\nconst PAGE_BUILDER_FIELD_ID = 'pageBuilder';\nconst PAGE_BUILDER_TEMPLATE_FIELD_ID = 'pageBuilderTemplateId';\nconst ERROR = 'error';\nconst SUCCESS = 'success';\nconst PUBLISHED = 'published';\nconst UNPUBLISHED = 'unpublished';\nconst SAVE_BUTTON_TEXTS = { save: 'save', saved: 'saved', saving: 'saving' };\nconst ACTIONS = 'actions';\nconst UNPUBLISHED_WARNING = 'Page already unpublished';\nconst PAGE_NOT_FOUND = 'Page not found';\nconst SAVE_BEFORE_PUBLISH_MESSAGE =\n 'You have to click save to create the record before you can publish';\n\nconst PAGE_BUILDER_TAB = 'Page builder';\nconst PAGE_BUILDER_TAB_INDEX = 1;\nconst EDITOR_VIEW_TAB = 'Editor view';\nconst EDITOR_VIEW_TAB_INDEX = 0;\n\nconst ENTER_KEY = 'Enter';\n\nconst ICON_SIZE = {\n WIDTH: '25px',\n HEIGHT: '25px'\n};\n\nconst ICON_COLOR = {\n STROKE: '#63779C',\n FILL: '#63779C'\n};\n\nconst DEFAULT_FILTER_OPTION_LABEL = 'Any';\n\nexport {\n DATA_LISTING_PREFIX,\n ENTITY_PUBLISHED,\n KEY_TO_CHECK,\n LEAVE_PAGE_MESSAGE,\n MENU_PERMISSIONS,\n PAGE_BUILDER,\n PLUGIN_NAME,\n PREVIEW_INTERFACE,\n SELECT_DEFAULT_VALUE,\n TEXT_CONTENT_TYPE,\n PAGE_BUILDER_FIELD_ID,\n PAGE_BUILDER_TEMPLATE_FIELD_ID,\n ERROR,\n SUC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,eAAe,GAAG,aAAa;AACrC,MAAMC,qBAAqB,GAAG,CAAC;AAE/B,MAAMC,SAAS,GAAG,OAAO;AAEzB,MAAMC,SAAS,GAAG;EAChBC,KAAK,EAAE,MAAM;EACbC,MAAM,EAAE;AACV,CAAC;AAED,MAAMC,UAAU,GAAG;EACjBC,MAAM,EAAE,SAAS;EACjBC,IAAI,EAAE;AACR,CAAC;AAED,MAAMC,2BAA2B,GAAG,KAAK;AAEzC,SACElC,mBAAmB,EACnBG,gBAAgB,EAChBG,YAAY,EACZD,kBAAkB,EAClBE,gBAAgB,EAChBN,YAAY,EACZF,WAAW,EACXS,iBAAiB,EACjBJ,oBAAoB,EACpBF,iBAAiB,EACjBO,qBAAqB,EACrBC,8BAA8B,EAC9BC,KAAK,EACLC,OAAO,EACPC,SAAS,EACTC,WAAW,EACXC,iBAAiB,EACjBI,OAAO,EACPK,sBAAsB,EACtBE,qBAAqB,EACrBD,eAAe,EACfF,gBAAgB,EAChBH,mBAAmB,EACnBE,2BAA2B,EAC3BM,SAAS,EACTG,UAAU,EACVV,cAAc,EACdM,SAAS,EACTO,2BAA2B","ignoreList":[]}
package/lib-es/index.js CHANGED
@@ -4,8 +4,8 @@ import pkg from '../package.json';
4
4
  import { DATA_LISTING_PREFIX, PLUGIN_NAME } from './constants';
5
5
  import getAddContentMenuItems from './utils/add-content-menu-items';
6
6
  import { UserIcon, TaxonomyIcon, ContentIcon, SettingsIcon } from './icons';
7
- const EntityDataListing = React.lazy(() => import(/* webpackChunkName: 'EntityDataListing' */'./components/EntityDataListing'));
8
- const EntityManager = React.lazy(() => import(/* webpackChunkName: 'EntityManager' */'./components/EntityManager'));
7
+ const EntityDataListing = React.lazy(() => import( /* webpackChunkName: 'EntityDataListing' */'./components/EntityDataListing'));
8
+ const EntityManager = React.lazy(() => import( /* webpackChunkName: 'EntityManager' */'./components/EntityManager'));
9
9
  export default async function load(app) {
10
10
  app.events.once('admin:menu:config:load', getAddContentMenuItems(app));
11
11
  app.events.once('load:custom:field:type', addFieldType => {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["getFormBuilderLookup","formFieldTypes","React","pkg","DATA_LISTING_PREFIX","PLUGIN_NAME","getAddContentMenuItems","UserIcon","TaxonomyIcon","ContentIcon","SettingsIcon","EntityDataListing","lazy","EntityManager","load","app","events","once","addFieldType","Object","keys","forEach","type","component","emitAsync","addConfig","main","items","content","label","loadOpen","icon","order","taxonomy","user","settings","entityDataListingRoute","path","key","exact","editEntityRoute","addEntityRoute","addRoute","name","version","pluginName"],"sources":["../src/index.js"],"sourcesContent":["import { getFormBuilderLookup, formFieldTypes } from '@blaze-cms/react-form-builder';\nimport React from 'react';\nimport pkg from '../package.json';\nimport { DATA_LISTING_PREFIX, PLUGIN_NAME } from './constants';\nimport getAddContentMenuItems from './utils/add-content-menu-items';\nimport { UserIcon, TaxonomyIcon, ContentIcon, SettingsIcon } from './icons';\n\nconst EntityDataListing = React.lazy(() =>\n import(/* webpackChunkName: 'EntityDataListing' */ './components/EntityDataListing')\n);\nconst EntityManager = React.lazy(() =>\n import(/* webpackChunkName: 'EntityManager' */ './components/EntityManager')\n);\n\nexport default async function load(app) {\n app.events.once('admin:menu:config:load', getAddContentMenuItems(app));\n\n app.events.once('load:custom:field:type', addFieldType => {\n Object.keys(formFieldTypes).forEach(type => {\n addFieldType({ type, component: formFieldTypes[type] });\n });\n });\n\n app.events.once('plugin:data-ui:load:loaded', async () => {\n await app.events.emitAsync('load:custom:field:type', getFormBuilderLookup.addFieldType);\n });\n\n app.events.once('admin:menu:config:load', ({ addConfig }) => {\n addConfig({\n main: {\n items: {\n content: {\n label: 'content',\n loadOpen: true,\n items: {},\n icon: ContentIcon,\n order: 10\n },\n taxonomy: {\n label: 'Taxonomy',\n items: {},\n icon: TaxonomyIcon,\n order: 40\n },\n user: {\n label: 'User',\n items: {},\n icon: UserIcon,\n order: 90\n },\n settings: {\n label: 'Settings',\n items: {},\n icon: SettingsIcon,\n order: 100\n }\n }\n }\n });\n });\n\n const entityDataListingRoute = {\n path: `${DATA_LISTING_PREFIX}/:entityIdentifier`,\n key: 'entityDataListing',\n component: EntityDataListing,\n exact: true\n };\n\n const editEntityRoute = {\n path: `${DATA_LISTING_PREFIX}/:entityIdentifier/:action/:id`,\n key: 'editEntity',\n component: EntityManager,\n exact: true\n };\n\n const addEntityRoute = {\n path: `${DATA_LISTING_PREFIX}/:entityIdentifier/:action`,\n key: 'createEntity',\n component: EntityManager,\n exact: true\n };\n\n app.addRoute(entityDataListingRoute);\n app.addRoute(editEntityRoute);\n app.addRoute(addEntityRoute);\n\n return {\n name: PLUGIN_NAME,\n version: pkg.version\n };\n}\n\nload.pluginName = PLUGIN_NAME;\n"],"mappings":"AAAA,SAASA,oBAAoB,EAAEC,cAAc,QAAQ,+BAA+B;AACpF,OAAOC,KAAK,MAAM,OAAO;AACzB,OAAOC,GAAG,MAAM,iBAAiB;AACjC,SAASC,mBAAmB,EAAEC,WAAW,QAAQ,aAAa;AAC9D,OAAOC,sBAAsB,MAAM,gCAAgC;AACnE,SAASC,QAAQ,EAAEC,YAAY,EAAEC,WAAW,EAAEC,YAAY,QAAQ,SAAS;AAE3E,MAAMC,iBAAiB,GAAGT,KAAK,CAACU,IAAI,CAAC,MACnC,MAAM,CAAC,2CAA4C,gCAAgC,CACrF,CAAC;AACD,MAAMC,aAAa,GAAGX,KAAK,CAACU,IAAI,CAAC,MAC/B,MAAM,CAAC,uCAAwC,4BAA4B,CAC7E,CAAC;AAED,eAAe,eAAeE,IAAIA,CAACC,GAAG,EAAE;EACtCA,GAAG,CAACC,MAAM,CAACC,IAAI,CAAC,wBAAwB,EAAEX,sBAAsB,CAACS,GAAG,CAAC,CAAC;EAEtEA,GAAG,CAACC,MAAM,CAACC,IAAI,CAAC,wBAAwB,EAAEC,YAAY,IAAI;IACxDC,MAAM,CAACC,IAAI,CAACnB,cAAc,CAAC,CAACoB,OAAO,CAACC,IAAI,IAAI;MAC1CJ,YAAY,CAAC;QAAEI,IAAI;QAA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gC;IAC5DkC,GAAG,EAAE,YAAY;IACjBf,SAAS,EAAEV,aAAa;IACxB0B,KAAK,EAAE;EACT,CAAC;EAED,MAAME,cAAc,GAAG;IACrBJ,IAAI,EAAE,GAAGjC,mBAAmB,4BAA4B;IACxDkC,GAAG,EAAE,cAAc;IACnBf,SAAS,EAAEV,aAAa;IACxB0B,KAAK,EAAE;EACT,CAAC;EAEDxB,GAAG,CAAC2B,QAAQ,CAACN,sBAAsB,CAAC;EACpCrB,GAAG,CAAC2B,QAAQ,CAACF,eAAe,CAAC;EAC7BzB,GAAG,CAAC2B,QAAQ,CAACD,cAAc,CAAC;EAE5B,OAAO;IACLE,IAAI,EAAEtC,WAAW;IACjBuC,OAAO,EAAEzC,GAAG,CAACyC;EACf,CAAC;AACH;AAEA9B,IAAI,CAAC+B,UAAU,GAAGxC,WAAW","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":["getFormBuilderLookup","formFieldTypes","React","pkg","DATA_LISTING_PREFIX","PLUGIN_NAME","getAddContentMenuItems","UserIcon","TaxonomyIcon","ContentIcon","SettingsIcon","EntityDataListing","lazy","EntityManager","load","app","events","once","addFieldType","Object","keys","forEach","type","component","emitAsync","addConfig","main","items","content","label","loadOpen","icon","order","taxonomy","user","settings","entityDataListingRoute","path","key","exact","editEntityRoute","addEntityRoute","addRoute","name","version","pluginName"],"sources":["../src/index.js"],"sourcesContent":["import { getFormBuilderLookup, formFieldTypes } from '@blaze-cms/react-form-builder';\nimport React from 'react';\nimport pkg from '../package.json';\nimport { DATA_LISTING_PREFIX, PLUGIN_NAME } from './constants';\nimport getAddContentMenuItems from './utils/add-content-menu-items';\nimport { UserIcon, TaxonomyIcon, ContentIcon, SettingsIcon } from './icons';\n\nconst EntityDataListing = React.lazy(() =>\n import(/* webpackChunkName: 'EntityDataListing' */ './components/EntityDataListing')\n);\nconst EntityManager = React.lazy(() =>\n import(/* webpackChunkName: 'EntityManager' */ './components/EntityManager')\n);\n\nexport default async function load(app) {\n app.events.once('admin:menu:config:load', getAddContentMenuItems(app));\n\n app.events.once('load:custom:field:type', addFieldType => {\n Object.keys(formFieldTypes).forEach(type => {\n addFieldType({ type, component: formFieldTypes[type] });\n });\n });\n\n app.events.once('plugin:data-ui:load:loaded', async () => {\n await app.events.emitAsync('load:custom:field:type', getFormBuilderLookup.addFieldType);\n });\n\n app.events.once('admin:menu:config:load', ({ addConfig }) => {\n addConfig({\n main: {\n items: {\n content: {\n label: 'content',\n loadOpen: true,\n items: {},\n icon: ContentIcon,\n order: 10\n },\n taxonomy: {\n label: 'Taxonomy',\n items: {},\n icon: TaxonomyIcon,\n order: 40\n },\n user: {\n label: 'User',\n items: {},\n icon: UserIcon,\n order: 90\n },\n settings: {\n label: 'Settings',\n items: {},\n icon: SettingsIcon,\n order: 100\n }\n }\n }\n });\n });\n\n const entityDataListingRoute = {\n path: `${DATA_LISTING_PREFIX}/:entityIdentifier`,\n key: 'entityDataListing',\n component: EntityDataListing,\n exact: true\n };\n\n const editEntityRoute = {\n path: `${DATA_LISTING_PREFIX}/:entityIdentifier/:action/:id`,\n key: 'editEntity',\n component: EntityManager,\n exact: true\n };\n\n const addEntityRoute = {\n path: `${DATA_LISTING_PREFIX}/:entityIdentifier/:action`,\n key: 'createEntity',\n component: EntityManager,\n exact: true\n };\n\n app.addRoute(entityDataListingRoute);\n app.addRoute(editEntityRoute);\n app.addRoute(addEntityRoute);\n\n return {\n name: PLUGIN_NAME,\n version: pkg.version\n };\n}\n\nload.pluginName = PLUGIN_NAME;\n"],"mappings":"AAAA,SAASA,oBAAoB,EAAEC,cAAc,QAAQ,+BAA+B;AACpF,OAAOC,KAAK,MAAM,OAAO;AACzB,OAAOC,GAAG,MAAM,iBAAiB;AACjC,SAASC,mBAAmB,EAAEC,WAAW,QAAQ,aAAa;AAC9D,OAAOC,sBAAsB,MAAM,gCAAgC;AACnE,SAASC,QAAQ,EAAEC,YAAY,EAAEC,WAAW,EAAEC,YAAY,QAAQ,SAAS;AAE3E,MAAMC,iBA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AAK,EAAE,MAAM;YACbF,KAAK,EAAE,CAAC,CAAC;YACTI,IAAI,EAAExB,QAAQ;YACdyB,KAAK,EAAE;UACT,CAAC;UACDG,QAAQ,EAAE;YACRN,KAAK,EAAE,UAAU;YACjBF,KAAK,EAAE,CAAC,CAAC;YACTI,IAAI,EAAErB,YAAY;YAClBsB,KAAK,EAAE;UACT;QACF;MACF;IACF,CAAC,CAAC;EACJ,CAAC,CAAC;EAEF,MAAMI,sBAAsB,GAAG;IAC7BC,IAAI,EAAG,GAAEjC,mBAAoB,oBAAmB;IAChDkC,GAAG,EAAE,mBAAmB;IACxBf,SAAS,EAAEZ,iBAAiB;IAC5B4B,KAAK,EAAE;EACT,CAAC;EAED,MAAMC,eAAe,GAAG;IACtBH,IAAI,EAAG,GAAEjC,mBAAoB,gCAA+B;IAC5DkC,GAAG,EAAE,YAAY;IACjBf,SAAS,EAAEV,aAAa;IACxB0B,KAAK,EAAE;EACT,CAAC;EAED,MAAME,cAAc,GAAG;IACrBJ,IAAI,EAAG,GAAEjC,mBAAoB,4BAA2B;IACxDkC,GAAG,EAAE,cAAc;IACnBf,SAAS,EAAEV,aAAa;IACxB0B,KAAK,EAAE;EACT,CAAC;EAEDxB,GAAG,CAAC2B,QAAQ,CAACN,sBAAsB,CAAC;EACpCrB,GAAG,CAAC2B,QAAQ,CAACF,eAAe,CAAC;EAC7BzB,GAAG,CAAC2B,QAAQ,CAACD,cAAc,CAAC;EAE5B,OAAO;IACLE,IAAI,EAAEtC,WAAW;IACjBuC,OAAO,EAAEzC,GAAG,CAACyC;EACf,CAAC;AACH;AAEA9B,IAAI,CAAC+B,UAAU,GAAGxC,WAAW","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"add-content-menu-items.js","names":["getQuery","MENU_PERMISSIONS","require","getAddContentMenuItems","app","addConfig","client","getClient","data","getEntitySchemas","query","variables","canDoActions","length","menuItems","sectionMenuItems","settings","forEach","id","displayName","displayProperties","adminMenu","sectionKey","sectionItems","label","uri","menuConfig","main","items","Object","entries","sectionConfig"],"sources":["../../src/utils/add-content-menu-items.js"],"sourcesContent":["import { getQuery } from '@blaze-cms/admin-ui-utils';\n\nconst { MENU_PERMISSIONS } = require('../constants');\n\nfunction getAddContentMenuItems(app) {\n return async ({ addConfig }) => {\n const client = app.getClient();\n const {\n data: { getEntitySchemas }\n } = await client.query({\n query: getQuery('GET_USER_EDITABLE_ENTITIES'),\n variables: {\n // only return entities that the current user can do the following actions on\n canDoActions: MENU_PERMISSIONS\n }\n });\n\n if (!getEntitySchemas || !getEntitySchemas.length) return; // no items so don't add section\n\n const menuItems = {};\n const sectionMenuItems = { settings: {} };\n\n getEntitySchemas.forEach(({ id, displayName, displayProperties }) => {\n if (!displayProperties) return null;\n\n const { adminMenu: { sectionKey = 'settings' } = {} } = displayProperties;\n const sectionItems = sectionMenuItems[sectionKey] || {};\n sectionItems[id] = {\n label: displayName,\n uri: `/data-listing/${id}`\n };\n sectionMenuItems[sectionKey] = sectionItems;\n });\n\n const menuConfig = {\n main: {\n items: {\n settings: {\n items: menuItems\n }\n }\n }\n };\n\n Object.entries(sectionMenuItems).forEach(([sectionKey, sectionItems]) => {\n const sectionConfig = menuConfig.main.items[sectionKey] || {};\n sectionConfig.items = sectionItems;\n menuConfig.main.items[sectionKey] = sectionConfig;\n });\n\n getEntitySchemas.forEach(({ id, displayName }) => {\n menuItems[id] = {\n label: displayName,\n uri: `/data-listing/${id}`\n };\n });\n\n addConfig(menuConfig);\n };\n}\n\nexport default getAddContentMenuItems;\n"],"mappings":"AAAA,SAASA,QAAQ,QAAQ,2BAA2B;AAEpD,MAAM;EAAEC;AAAiB,CAAC,GAAGC,OAAO,CAAC,cAAc,CAAC;AAEpD,SAASC,sBAAsBA,CAACC,GAAG,EAAE;EACnC,OAAO,OAAO;IAAEC;EAAU,CAAC,KAAK;IAC9B,MAAMC,MAAM,GAAGF,GAAG,CAACG,SAAS,CAAC,CAAC;IAC9B,MAAM;MACJC,IAAI,EAAE;QAAE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CAACC,IAAI,CAACC,KAAK,CAACN,UAAU,CAAC,GAAGS,aAAa;IACnD,CAAC,CAAC;IAEFtB,gBAAgB,CAACQ,OAAO,CAAC,CAAC;MAAEC,EAAE;MAAEC;IAAY,CAAC,KAAK;MAChDL,SAAS,CAACI,EAAE,CAAC,GAAG;QACdM,KAAK,EAAEL,WAAW;QAClBM,GAAG,EAAE,iBAAiBP,EAAE;MAC1B,CAAC;IACH,CAAC,CAAC;IAEFb,SAAS,CAACqB,UAAU,CAAC;EACvB,CAAC;AACH;AAEA,eAAevB,sBAAsB","ignoreList":[]}
1
+ {"version":3,"file":"add-content-menu-items.js","names":["getQuery","MENU_PERMISSIONS","require","getAddContentMenuItems","app","addConfig","client","getClient","data","getEntitySchemas","query","variables","canDoActions","length","menuItems","sectionMenuItems","settings","forEach","id","displayName","displayProperties","adminMenu","sectionKey","sectionItems","label","uri","menuConfig","main","items","Object","entries","sectionConfig"],"sources":["../../src/utils/add-content-menu-items.js"],"sourcesContent":["import { getQuery } from '@blaze-cms/admin-ui-utils';\n\nconst { MENU_PERMISSIONS } = require('../constants');\n\nfunction getAddContentMenuItems(app) {\n return async ({ addConfig }) => {\n const client = app.getClient();\n const {\n data: { getEntitySchemas }\n } = await client.query({\n query: getQuery('GET_USER_EDITABLE_ENTITIES'),\n variables: {\n // only return entities that the current user can do the following actions on\n canDoActions: MENU_PERMISSIONS\n }\n });\n\n if (!getEntitySchemas || !getEntitySchemas.length) return; // no items so don't add section\n\n const menuItems = {};\n const sectionMenuItems = { settings: {} };\n\n getEntitySchemas.forEach(({ id, displayName, displayProperties }) => {\n if (!displayProperties) return null;\n\n const { adminMenu: { sectionKey = 'settings' } = {} } = displayProperties;\n const sectionItems = sectionMenuItems[sectionKey] || {};\n sectionItems[id] = {\n label: displayName,\n uri: `/data-listing/${id}`\n };\n sectionMenuItems[sectionKey] = sectionItems;\n });\n\n const menuConfig = {\n main: {\n items: {\n settings: {\n items: menuItems\n }\n }\n }\n };\n\n Object.entries(sectionMenuItems).forEach(([sectionKey, sectionItems]) => {\n const sectionConfig = menuConfig.main.items[sectionKey] || {};\n sectionConfig.items = sectionItems;\n menuConfig.main.items[sectionKey] = sectionConfig;\n });\n\n getEntitySchemas.forEach(({ id, displayName }) => {\n menuItems[id] = {\n label: displayName,\n uri: `/data-listing/${id}`\n };\n });\n\n addConfig(menuConfig);\n };\n}\n\nexport default getAddContentMenuItems;\n"],"mappings":"AAAA,SAASA,QAAQ,QAAQ,2BAA2B;AAEpD,MAAM;EAAEC;AAAiB,CAAC,GAAGC,OAAO,CAAC,cAAc,CAAC;AAEpD,SAASC,sBAAsBA,CAACC,GAAG,EAAE;EACnC,OAAO,OAAO;IAAEC;EAAU,CAAC,KAAK;IAC9B,MAAMC,MAAM,GAAGF,GAAG,CAACG,SAAS,CAAC,CAAC;IAC9B,MAAM;MACJC,IAAI,EAAE;QAAEC;MAAiB;IAC3B,CAAC,GAAG,MAAMH,MAAM,CAACI,KAAK,CAAC;MACrBA,KAAK,EAAEV,QAAQ,CAAC,4BAA4B,CAAC;MAC7CW,SAAS,EAAE;QACT;QACAC,YAAY,EAAEX;MAChB;IACF,CAAC,CAAC;IAEF,IAAI,CAACQ,gBAAgB,IAAI,CAACA,gBAAgB,CAACI,MAAM,EAAE,OAAO,CAAC;;IAE3D,MAAMC,SAAS,GAAG,CAAC,CAAC;IACpB,MAAMC,gBAAgB,GAAG;MAAEC,QAAQ,EAAE,CAAC;IAAE,CAAC;IAEzCP,gBAAgB,CAACQ,OAAO,CAAC,CAAC;MAAEC,EAAE;MAAEC,WAAW;MAAEC;IAAkB,CAAC,KAAK;MACnE,IAAI,CAACA,iBAAiB,EAAE,OAAO,IAAI;MAEnC,MAAM;QAAEC,SAAS,EAAE;UAAEC,UAAU,GAAG;QAAW,CAAC,GAAG,CAAC;MAAE,CAAC,GAAGF,iBAAiB;MACzE,MAAMG,YAAY,GAAGR,gBAAgB,CAACO,UAAU,CAAC,IAAI,CAAC,CAAC;MACvDC,YAAY,CAACL,EAAE,CAAC,GAAG;QACjBM,KAAK,EAAEL,WAAW;QAClBM,GAAG,EAAG,iBAAgBP,EAAG;MAC3B,CAAC;MACDH,gBAAgB,CAACO,UAAU,CAAC,GAAGC,YAAY;IAC7C,CAAC,CAAC;IAEF,MAAMG,UAAU,GAAG;MACjBC,IAAI,EAAE;QACJC,KAAK,EAAE;UACLZ,QAAQ,EAAE;YACRY,KAAK,EAAEd;UACT;QACF;MACF;IACF,CAAC;IAEDe,MAAM,CAACC,OAAO,CAACf,gBAAgB,CAAC,CAACE,OAAO,CAAC,CAAC,CAACK,UAAU,EAAEC,YAAY,CAAC,KAAK;MACvE,MAAMQ,aAAa,GAAGL,UAAU,CAACC,IAAI,CAACC,KAAK,CAACN,UAAU,CAAC,IAAI,CAAC,CAAC;MAC7DS,aAAa,CAACH,KAAK,GAAGL,YAAY;MAClCG,UAAU,CAACC,IAAI,CAACC,KAAK,CAACN,UAAU,CAAC,GAAGS,aAAa;IACnD,CAAC,CAAC;IAEFtB,gBAAgB,CAACQ,OAAO,CAAC,CAAC;MAAEC,EAAE;MAAEC;IAAY,CAAC,KAAK;MAChDL,SAAS,CAACI,EAAE,CAAC,GAAG;QACdM,KAAK,EAAEL,WAAW;QAClBM,GAAG,EAAG,iBAAgBP,EAAG;MAC3B,CAAC;IACH,CAAC,CAAC;IAEFb,SAAS,CAACqB,UAAU,CAAC;EACvB,CAAC;AACH;AAEA,eAAevB,sBAAsB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"build-create-entity-mutation.js","names":["gql","BlazeError","upperfirst","getDataProperties","buildCreateEntityMutation","entitySchema","actions","create","properties","actionInput","dataProperties","join"],"sources":["../../src/utils/build-create-entity-mutation.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport upperfirst from 'lodash.upperfirst';\nimport { getDataProperties } from '@blaze-cms/admin-ui-utils';\n\nfunction buildCreateEntityMutation(entitySchema) {\n if (\n !entitySchema ||\n !entitySchema.actions ||\n !entitySchema.actions.create ||\n !entitySchema.properties\n ) {\n throw new BlazeError(\n 'Create entity query requires create action and properties from entity schema'\n );\n }\n\n const actionInput = upperfirst(`${entitySchema.actions.create}Input`);\n const dataProperties = getDataProperties(entitySchema);\n\n return gql`mutation createEntity($input: ${actionInput}) {\n createdEntity: ${entitySchema.actions.create}(input: $input){\n result {\n id,\n ${dataProperties.join(',\\n')}\n }\n }\n }`;\n}\n\nexport default buildCreateEntityMutation;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,OAAOC,UAAU,MAAM,mBAAmB;AAC1C,SAASC,iBAAiB,QAAQ,2BAA2B;AAE7D,SAASC,yBAAyBA,CAACC,YAAY,EAAE;EAC/C,IACE,CAACA,YAAY,IACb,CAACA,YAAY,CAACC,OAAO,IACrB,CAACD,YAAY,CAACC,OAAO,CAACC,MAAM,IAC5B,CAACF,YAAY,CAACG,UAAU,EACxB;IACA,MAAM,IAAIP,UAAU,CAClB,8EACF,CAAC;EACH;EAEA,MAAMQ,WAAW,GAAGP,UAAU,CAAC,GAAGG,YAAY,CAACC,OAAO,CAACC,MAAM,OAAO,CAAC;EACrE,MAAMG,cAAc,GAAGP,iBAAiB,CAACE,YAAY,CAAC;EAEtD,OAAOL,GAAG,kCAAkCS,WAAW;AACzD,qBAAqBJ,YAAY,CAACC,OAAO,CAACC,MAAM;AAChD;AACA;AACA,YAAYG,cAAc,CAACC,IAAI,CAAC,KAAK,CAAC;AACtC;AACA;AACA,IAAI;AACJ;AAEA,eAAeP,yBAAyB","ignoreList":[]}
1
+ {"version":3,"file":"build-create-entity-mutation.js","names":["gql","BlazeError","upperfirst","getDataProperties","buildCreateEntityMutation","entitySchema","actions","create","properties","actionInput","dataProperties","join"],"sources":["../../src/utils/build-create-entity-mutation.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport upperfirst from 'lodash.upperfirst';\nimport { getDataProperties } from '@blaze-cms/admin-ui-utils';\n\nfunction buildCreateEntityMutation(entitySchema) {\n if (\n !entitySchema ||\n !entitySchema.actions ||\n !entitySchema.actions.create ||\n !entitySchema.properties\n ) {\n throw new BlazeError(\n 'Create entity query requires create action and properties from entity schema'\n );\n }\n\n const actionInput = upperfirst(`${entitySchema.actions.create}Input`);\n const dataProperties = getDataProperties(entitySchema);\n\n return gql`mutation createEntity($input: ${actionInput}) {\n createdEntity: ${entitySchema.actions.create}(input: $input){\n result {\n id,\n ${dataProperties.join(',\\n')}\n }\n }\n }`;\n}\n\nexport default buildCreateEntityMutation;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,OAAOC,UAAU,MAAM,mBAAmB;AAC1C,SAASC,iBAAiB,QAAQ,2BAA2B;AAE7D,SAASC,yBAAyBA,CAACC,YAAY,EAAE;EAC/C,IACE,CAACA,YAAY,IACb,CAACA,YAAY,CAACC,OAAO,IACrB,CAACD,YAAY,CAACC,OAAO,CAACC,MAAM,IAC5B,CAACF,YAAY,CAACG,UAAU,EACxB;IACA,MAAM,IAAIP,UAAU,CAClB,8EACF,CAAC;EACH;EAEA,MAAMQ,WAAW,GAAGP,UAAU,CAAE,GAAEG,YAAY,CAACC,OAAO,CAACC,MAAO,OAAM,CAAC;EACrE,MAAMG,cAAc,GAAGP,iBAAiB,CAACE,YAAY,CAAC;EAEtD,OAAOL,GAAI,kCAAiCS,WAAY;AAC1D,qBAAqBJ,YAAY,CAACC,OAAO,CAACC,MAAO;AACjD;AACA;AACA,YAAYG,cAAc,CAACC,IAAI,CAAC,KAAK,CAAE;AACvC;AACA;AACA,IAAI;AACJ;AAEA,eAAeP,yBAAyB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"build-delete-entity-mutation.js","names":["gql","BlazeError","upperfirst","buildDeleteEntity","entitySchema","actions","delete","actionInput"],"sources":["../../src/utils/build-delete-entity-mutation.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport upperfirst from 'lodash.upperfirst';\n\nfunction buildDeleteEntity(entitySchema) {\n if (!entitySchema || !entitySchema.actions || !entitySchema.actions.delete) {\n throw new BlazeError('Delete query requires delete action from entity schema');\n }\n\n const actionInput = upperfirst(`${entitySchema.actions.delete}Input`);\n\n return gql`\n mutation deleteEntity($input: ${actionInput}) {\n deleteEntity: ${entitySchema.actions.delete}(input: $input){\n result\n }\n }\n `;\n}\n\nexport default buildDeleteEntity;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,OAAOC,UAAU,MAAM,mBAAmB;AAE1C,SAASC,iBAAiBA,CAACC,YAAY,EAAE;EACvC,IAAI,CAACA,YAAY,IAAI,CAACA,YAAY,CAACC,OAAO,IAAI,CAACD,YAAY,CAACC,OAAO,CAACC,MAAM,EAAE;IAC1E,MAAM,IAAIL,UAAU,CAAC,wDAAwD,CAAC;EAChF;EAEA,MAAMM,WAAW,GAAGL,UAAU,CAAC,GAAGE,YAAY,CAACC,OAAO,CAACC,MAAM,OAAO,CAAC;EAErE,OAAON,GAAG;AACZ,mCAAmCO,WAAW;AAC9C,oBAAoBH,YAAY,CAACC,OAAO,CAACC,MAAM;AAC/C;AACA;AACA;AACA,GAAG;AACH;AAEA,eAAeH,iBAAiB","ignoreList":[]}
1
+ {"version":3,"file":"build-delete-entity-mutation.js","names":["gql","BlazeError","upperfirst","buildDeleteEntity","entitySchema","actions","delete","actionInput"],"sources":["../../src/utils/build-delete-entity-mutation.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport upperfirst from 'lodash.upperfirst';\n\nfunction buildDeleteEntity(entitySchema) {\n if (!entitySchema || !entitySchema.actions || !entitySchema.actions.delete) {\n throw new BlazeError('Delete query requires delete action from entity schema');\n }\n\n const actionInput = upperfirst(`${entitySchema.actions.delete}Input`);\n\n return gql`\n mutation deleteEntity($input: ${actionInput}) {\n deleteEntity: ${entitySchema.actions.delete}(input: $input){\n result\n }\n }\n `;\n}\n\nexport default buildDeleteEntity;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,OAAOC,UAAU,MAAM,mBAAmB;AAE1C,SAASC,iBAAiBA,CAACC,YAAY,EAAE;EACvC,IAAI,CAACA,YAAY,IAAI,CAACA,YAAY,CAACC,OAAO,IAAI,CAACD,YAAY,CAACC,OAAO,CAACC,MAAM,EAAE;IAC1E,MAAM,IAAIL,UAAU,CAAC,wDAAwD,CAAC;EAChF;EAEA,MAAMM,WAAW,GAAGL,UAAU,CAAE,GAAEE,YAAY,CAACC,OAAO,CAACC,MAAO,OAAM,CAAC;EAErE,OAAON,GAAI;AACb,mCAAmCO,WAAY;AAC/C,oBAAoBH,YAAY,CAACC,OAAO,CAACC,MAAO;AAChD;AACA;AACA;AACA,GAAG;AACH;AAEA,eAAeH,iBAAiB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"build-listing-query.js","names":["gql","BlazeError","getDynamicQuery","buildAdminSearchQuery","entitySchema","index","listingProperties","parsedProperties","join","buildListingQuery","isSearchQuery","actions","getAll","sortType","toUpperCase","substr","countAll"],"sources":["../../src/utils/build-listing-query.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport { getDynamicQuery } from '@blaze-cms/admin-ui-utils';\n\nconst buildAdminSearchQuery = (entitySchema, index) => {\n const { listingProperties = [] } = entitySchema || {};\n const parsedProperties = `id, ${listingProperties.join(' ') || 'id name'}`;\n\n return getDynamicQuery('ADMIN_SEARCH')([entitySchema], parsedProperties, true, index);\n};\n\nfunction buildListingQuery(entitySchema, index, isSearchQuery) {\n if (!entitySchema.actions || !entitySchema.actions.getAll || !entitySchema.listingProperties) {\n throw new BlazeError(\n 'Listing query requires getAll action and listingProperties from entity schema'\n );\n }\n\n if (isSearchQuery) return buildAdminSearchQuery(entitySchema, index);\n\n const sortType =\n entitySchema.actions.getAll[0].toUpperCase() + entitySchema.actions.getAll.substr(1);\n\n return gql`\n query ${\n entitySchema.actions.getAll\n }($where: JSON, $limit: Int, $offset:Int, $sort: [${sortType}SortItem]) {\n listingData: ${\n entitySchema.actions.getAll\n }(where: $where, limit: $limit, offset:$offset, sort:$sort){\n id,\n ${entitySchema.listingProperties.join(',\\n')}\n }\n totalRecords: ${entitySchema.actions.countAll}(where: $where)\n }\n `;\n}\n\nexport default buildListingQuery;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,SAASC,eAAe,QAAQ,2BAA2B;AAE3D,MAAMC,qBAAqB,GAAGA,CAACC,YAAY,EAAEC,KAAK,KAAK;EACrD,MAAM;IAAEC,iBAAiB,GAAG;EAAG,CAAC,GAAGF,YAAY,IAAI,CAAC,CAAC;EACrD,MAAMG,gBAAgB,GAAG,OAAOD,iBAAiB,CAACE,IAAI,CAAC,GAAG,CAAC,IAAI,SAAS,EAAE;EAE1E,OAAON,eAAe,CAAC,cAAc,CAAC,CAAC,CAACE,YAAY,CAAC,EAAEG,gBAAgB,EAAE,IAAI,EAAEF,KAAK,CAAC;AACvF,CAAC;AAED,SAASI,iBAAiBA,CAACL,YAAY,EAAEC,KAAK,EAAEK,aAAa,EAAE;EAC7D,IAAI,CAACN,YAAY,CAACO,OAAO,IAAI,CAACP,YAAY,CAACO,OAAO,CAACC,MAAM,IAAI,CAACR,YAAY,CAACE,iBAAiB,EAAE;IAC5F,MAAM,IAAIL,UAAU,CAClB,+EACF,CAAC;EACH;EAEA,IAAIS,aAAa,EAAE,OAAOP,qBAAqB,CAACC,YAAY,EAAEC,KAAK,CAAC;EAEpE,MAAMQ,QAAQ,GACZT,YAAY,CAACO,OAAO,CAACC,MAAM,CAAC,CAAC,CAAC,CAACE,WAAW,CAAC,CAAC,GAAGV,YAAY,CAACO,OAAO,CAACC,MAAM,CAACG,MAAM,CAAC,CAAC,CAAC;EAEtF,OAAOf,GAAG;AACZ,YACMI,YAAY,CAACO,OAAO,CAACC,MAAM,oDACuBC,QAAQ;AAChE,qBACQT,YAAY,CAACO,OAAO,CAACC,MAAM;AACnC;AACA,UACUR,YAAY,CAACE,iBAAiB,CAACE,IAAI,CAAC,KAAK,CAAC;AACpD;AACA,sBAAsBJ,YAAY,CAACO,OAAO,CAACK,QAAQ;AACnD;AACA,GAAG;AACH;AAEA,eAAeP,iBAAiB","ignoreList":[]}
1
+ {"version":3,"file":"build-listing-query.js","names":["gql","BlazeError","getDynamicQuery","buildAdminSearchQuery","entitySchema","index","listingProperties","parsedProperties","join","buildListingQuery","isSearchQuery","actions","getAll","sortType","toUpperCase","substr","countAll"],"sources":["../../src/utils/build-listing-query.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport { getDynamicQuery } from '@blaze-cms/admin-ui-utils';\n\nconst buildAdminSearchQuery = (entitySchema, index) => {\n const { listingProperties = [] } = entitySchema || {};\n const parsedProperties = `id, ${listingProperties.join(' ') || 'id name'}`;\n\n return getDynamicQuery('ADMIN_SEARCH')([entitySchema], parsedProperties, true, index);\n};\n\nfunction buildListingQuery(entitySchema, index, isSearchQuery) {\n if (!entitySchema.actions || !entitySchema.actions.getAll || !entitySchema.listingProperties) {\n throw new BlazeError(\n 'Listing query requires getAll action and listingProperties from entity schema'\n );\n }\n\n if (isSearchQuery) return buildAdminSearchQuery(entitySchema, index);\n\n const sortType =\n entitySchema.actions.getAll[0].toUpperCase() + entitySchema.actions.getAll.substr(1);\n\n return gql`\n query ${\n entitySchema.actions.getAll\n }($where: JSON, $limit: Int, $offset:Int, $sort: [${sortType}SortItem]) {\n listingData: ${\n entitySchema.actions.getAll\n }(where: $where, limit: $limit, offset:$offset, sort:$sort){\n id,\n ${entitySchema.listingProperties.join(',\\n')}\n }\n totalRecords: ${entitySchema.actions.countAll}(where: $where)\n }\n `;\n}\n\nexport default buildListingQuery;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,SAASC,eAAe,QAAQ,2BAA2B;AAE3D,MAAMC,qBAAqB,GAAGA,CAACC,YAAY,EAAEC,KAAK,KAAK;EACrD,MAAM;IAAEC,iBAAiB,GAAG;EAAG,CAAC,GAAGF,YAAY,IAAI,CAAC,CAAC;EACrD,MAAMG,gBAAgB,GAAI,OAAMD,iBAAiB,CAACE,IAAI,CAAC,GAAG,CAAC,IAAI,SAAU,EAAC;EAE1E,OAAON,eAAe,CAAC,cAAc,CAAC,CAAC,CAACE,YAAY,CAAC,EAAEG,gBAAgB,EAAE,IAAI,EAAEF,KAAK,CAAC;AACvF,CAAC;AAED,SAASI,iBAAiBA,CAACL,YAAY,EAAEC,KAAK,EAAEK,aAAa,EAAE;EAC7D,IAAI,CAACN,YAAY,CAACO,OAAO,IAAI,CAACP,YAAY,CAACO,OAAO,CAACC,MAAM,IAAI,CAACR,YAAY,CAACE,iBAAiB,EAAE;IAC5F,MAAM,IAAIL,UAAU,CAClB,+EACF,CAAC;EACH;EAEA,IAAIS,aAAa,EAAE,OAAOP,qBAAqB,CAACC,YAAY,EAAEC,KAAK,CAAC;EAEpE,MAAMQ,QAAQ,GACZT,YAAY,CAACO,OAAO,CAACC,MAAM,CAAC,CAAC,CAAC,CAACE,WAAW,CAAC,CAAC,GAAGV,YAAY,CAACO,OAAO,CAACC,MAAM,CAACG,MAAM,CAAC,CAAC,CAAC;EAEtF,OAAOf,GAAI;AACb,YACMI,YAAY,CAACO,OAAO,CAACC,MACtB,oDAAmDC,QAAS;AACjE,qBACQT,YAAY,CAACO,OAAO,CAACC,MACtB;AACP;AACA,UAAUR,YAAY,CAACE,iBAAiB,CAACE,IAAI,CAAC,KAAK,CAAE;AACrD;AACA,sBAAsBJ,YAAY,CAACO,OAAO,CAACK,QAAS;AACpD;AACA,GAAG;AACH;AAEA,eAAeP,iBAAiB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"build-update-data-query.js","names":["gql","BlazeError","upperfirst","getDataProperties","buildUpdateDataQuery","entitySchema","actions","update","properties","actionInput","dataProperties","join"],"sources":["../../src/utils/build-update-data-query.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport upperfirst from 'lodash.upperfirst';\nimport { getDataProperties } from '@blaze-cms/admin-ui-utils';\n\nfunction buildUpdateDataQuery(entitySchema) {\n if (!entitySchema.actions || !entitySchema.actions.update || !entitySchema.properties) {\n throw new BlazeError(\n 'Update DataEntity query requires get action and properties from entity schema'\n );\n }\n\n const actionInput = upperfirst(`${entitySchema.actions.update}Input`);\n const dataProperties = getDataProperties(entitySchema);\n\n return gql`\n mutation updateEntity($input: ${actionInput}) {\n updateEntity: ${entitySchema.actions.update}(input: $input){\n result {\n id,\n ${dataProperties.join(',\\n')},\n updated\n }\n }\n }\n `;\n}\n\nexport default buildUpdateDataQuery;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,OAAOC,UAAU,MAAM,mBAAmB;AAC1C,SAASC,iBAAiB,QAAQ,2BAA2B;AAE7D,SAASC,oBAAoBA,CAACC,YAAY,EAAE;EAC1C,IAAI,CAACA,YAAY,CAACC,OAAO,IAAI,CAACD,YAAY,CAACC,OAAO,CAACC,MAAM,IAAI,CAACF,YAAY,CAACG,UAAU,EAAE;IACrF,MAAM,IAAIP,UAAU,CAClB,+EACF,CAAC;EACH;EAEA,MAAMQ,WAAW,GAAGP,UAAU,CAAC,GAAGG,YAAY,CAACC,OAAO,CAACC,MAAM,OAAO,CAAC;EACrE,MAAMG,cAAc,GAAGP,iBAAiB,CAACE,YAAY,CAAC;EAEtD,OAAOL,GAAG;AACZ,mCAAmCS,WAAW;AAC9C,oBAAoBJ,YAAY,CAACC,OAAO,CAACC,MAAM;AAC/C;AACA;AACA,YAAYG,cAAc,CAACC,IAAI,CAAC,KAAK,CAAC;AACtC;AACA;AACA;AACA;AACA,GAAG;AACH;AAEA,eAAeP,oBAAoB","ignoreList":[]}
1
+ {"version":3,"file":"build-update-data-query.js","names":["gql","BlazeError","upperfirst","getDataProperties","buildUpdateDataQuery","entitySchema","actions","update","properties","actionInput","dataProperties","join"],"sources":["../../src/utils/build-update-data-query.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\nimport upperfirst from 'lodash.upperfirst';\nimport { getDataProperties } from '@blaze-cms/admin-ui-utils';\n\nfunction buildUpdateDataQuery(entitySchema) {\n if (!entitySchema.actions || !entitySchema.actions.update || !entitySchema.properties) {\n throw new BlazeError(\n 'Update DataEntity query requires get action and properties from entity schema'\n );\n }\n\n const actionInput = upperfirst(`${entitySchema.actions.update}Input`);\n const dataProperties = getDataProperties(entitySchema);\n\n return gql`\n mutation updateEntity($input: ${actionInput}) {\n updateEntity: ${entitySchema.actions.update}(input: $input){\n result {\n id,\n ${dataProperties.join(',\\n')},\n updated\n }\n }\n }\n `;\n}\n\nexport default buildUpdateDataQuery;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AACnD,OAAOC,UAAU,MAAM,mBAAmB;AAC1C,SAASC,iBAAiB,QAAQ,2BAA2B;AAE7D,SAASC,oBAAoBA,CAACC,YAAY,EAAE;EAC1C,IAAI,CAACA,YAAY,CAACC,OAAO,IAAI,CAACD,YAAY,CAACC,OAAO,CAACC,MAAM,IAAI,CAACF,YAAY,CAACG,UAAU,EAAE;IACrF,MAAM,IAAIP,UAAU,CAClB,+EACF,CAAC;EACH;EAEA,MAAMQ,WAAW,GAAGP,UAAU,CAAE,GAAEG,YAAY,CAACC,OAAO,CAACC,MAAO,OAAM,CAAC;EACrE,MAAMG,cAAc,GAAGP,iBAAiB,CAACE,YAAY,CAAC;EAEtD,OAAOL,GAAI;AACb,mCAAmCS,WAAY;AAC/C,oBAAoBJ,YAAY,CAACC,OAAO,CAACC,MAAO;AAChD;AACA;AACA,YAAYG,cAAc,CAACC,IAAI,CAAC,KAAK,CAAE;AACvC;AACA;AACA;AACA;AACA,GAAG;AACH;AAEA,eAAeP,oBAAoB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"build-update-publish-unpublish-mutation.js","names":["gql","BlazeError","buildUpdatePublishUnpublishMutation","entitySchema","id","action","cache","actions","publish","withClient"],"sources":["../../src/utils/build-update-publish-unpublish-mutation.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\n\nfunction buildUpdatePublishUnpublishMutation(entitySchema, id, action, cache) {\n if (!entitySchema || !entitySchema.actions || !entitySchema.actions.publish || !id || !action) {\n throw new BlazeError(\n 'Update DataEntity query requires publish action from entity schema and id'\n );\n }\n\n const withClient = `${cache ? '@client' : ''}`;\n\n return gql`\n mutation {\n response: ${entitySchema.actions[action]} ${withClient}(input: {\n id: \"${id}\"\n }){\n result {\n id,\n status\n }\n }\n }\n `;\n}\n\nexport default buildUpdatePublishUnpublishMutation;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AAEnD,SAASC,mCAAmCA,CAACC,YAAY,EAAEC,EAAE,EAAEC,MAAM,EAAEC,KAAK,EAAE;EAC5E,IAAI,CAACH,YAAY,IAAI,CAACA,YAAY,CAACI,OAAO,IAAI,CAACJ,YAAY,CAACI,OAAO,CAACC,OAAO,IAAI,CAACJ,EAAE,IAAI,CAACC,MAAM,EAAE;IAC7F,MAAM,IAAIJ,UAAU,CAClB,2EACF,CAAC;EACH;EAEA,MAAMQ,UAAU,GAAG,GAAGH,KAAK,GAAG,SAAS,GAAG,EAAE,EAAE;EAE9C,OAAON,GAAG;AACZ;AACA,kBAAkBG,YAAY,CAACI,OAAO,CAACF,MAAM,CAAC,IAAII,UAAU;AAC5D,eAAeL,EAAE;AACjB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AAEA,eAAeF,mCAAmC","ignoreList":[]}
1
+ {"version":3,"file":"build-update-publish-unpublish-mutation.js","names":["gql","BlazeError","buildUpdatePublishUnpublishMutation","entitySchema","id","action","cache","actions","publish","withClient"],"sources":["../../src/utils/build-update-publish-unpublish-mutation.js"],"sourcesContent":["import { gql } from '@apollo/client';\nimport { BlazeError } from '@blaze-cms/core-errors';\n\nfunction buildUpdatePublishUnpublishMutation(entitySchema, id, action, cache) {\n if (!entitySchema || !entitySchema.actions || !entitySchema.actions.publish || !id || !action) {\n throw new BlazeError(\n 'Update DataEntity query requires publish action from entity schema and id'\n );\n }\n\n const withClient = `${cache ? '@client' : ''}`;\n\n return gql`\n mutation {\n response: ${entitySchema.actions[action]} ${withClient}(input: {\n id: \"${id}\"\n }){\n result {\n id,\n status\n }\n }\n }\n `;\n}\n\nexport default buildUpdatePublishUnpublishMutation;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,SAASC,UAAU,QAAQ,wBAAwB;AAEnD,SAASC,mCAAmCA,CAACC,YAAY,EAAEC,EAAE,EAAEC,MAAM,EAAEC,KAAK,EAAE;EAC5E,IAAI,CAACH,YAAY,IAAI,CAACA,YAAY,CAACI,OAAO,IAAI,CAACJ,YAAY,CAACI,OAAO,CAACC,OAAO,IAAI,CAACJ,EAAE,IAAI,CAACC,MAAM,EAAE;IAC7F,MAAM,IAAIJ,UAAU,CAClB,2EACF,CAAC;EACH;EAEA,MAAMQ,UAAU,GAAI,GAAEH,KAAK,GAAG,SAAS,GAAG,EAAG,EAAC;EAE9C,OAAON,GAAI;AACb;AACA,kBAAkBG,YAAY,CAACI,OAAO,CAACF,MAAM,CAAE,IAAGI,UAAW;AAC7D,eAAeL,EAAG;AAClB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AAEA,eAAeF,mCAAmC","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blaze-cms/plugin-data-ui",
3
- "version": "0.146.0-core-styles.60",
3
+ "version": "0.146.0-core-styles.61",
4
4
  "description": "Blaze plugin data ui",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib-es/index.js",
@@ -27,11 +27,11 @@
27
27
  },
28
28
  "license": "GPL-3.0",
29
29
  "dependencies": {
30
- "@blaze-cms/admin-ui-utils": "0.146.0-core-styles.60",
30
+ "@blaze-cms/admin-ui-utils": "0.146.0-core-styles.61",
31
31
  "@blaze-cms/core-errors": "0.146.0-core-styles.52",
32
32
  "@blaze-cms/plugin-render-hooks-ui": "0.145.1-core-styles.0",
33
- "@blaze-cms/react-form-builder": "0.146.0-core-styles.60",
34
- "@blaze-cms/react-page-builder": "0.146.0-core-styles.60",
33
+ "@blaze-cms/react-form-builder": "0.146.0-core-styles.61",
34
+ "@blaze-cms/react-page-builder": "0.146.0-core-styles.61",
35
35
  "@blaze-cms/setup-ui": "0.145.1-core-styles.0",
36
36
  "@blaze-cms/versioning-ui": "0.146.0-core-styles.3",
37
37
  "@blaze-react/button": "0.8.0-alpha.82",
@@ -68,5 +68,5 @@
68
68
  "lib/*",
69
69
  "lib-es/*"
70
70
  ],
71
- "gitHead": "46c7acca5c2b59a139a483135c81e0ee40f50e51"
71
+ "gitHead": "8fa30efb2aec60464da5156e9670c0adc44e6384"
72
72
  }
@@ -7,6 +7,7 @@ import { PageHeader, DeleteAction, CardPrompt } from '@blaze-cms/admin';
7
7
  import { useToasts } from '@blaze-react/toaster';
8
8
  import { RenderHook } from '@blaze-cms/plugin-render-hooks-ui';
9
9
  import ListingTableContent from './ListingTableContent';
10
+ import SearchFilter from './SearchFilter/SearchFilter';
10
11
  import availableActions from '../EntityManager/Entity/actions-handlers';
11
12
  import { fetchData } from './service';
12
13
  import { populateRows, formatRows, getParsedRowData } from './mappers/populate-rows';
@@ -207,6 +208,11 @@ const ListingTable = ({ match, entitySchema, history }) => {
207
208
  listFilters={listFilters}
208
209
  setListFilters={updateListingFilters}
209
210
  />
211
+ <SearchFilter
212
+ schema={entitySchema}
213
+ listFilters={listFilters}
214
+ setListFilters={updateListingFilters}
215
+ />
210
216
  <ListingTableContent
211
217
  totalItems={totalItems}
212
218
  currentPage={currentPage}
@@ -214,6 +220,9 @@ const ListingTable = ({ match, entitySchema, history }) => {
214
220
  handleOnPageChange={handleOnPageChange}
215
221
  tableData={tableData}
216
222
  onCloseCardPrompt={onCloseCardPrompt}
223
+ schema={entitySchema}
224
+ listFilters={listFilters}
225
+ setListFilters={updateListingFilters}
217
226
  />
218
227
  </>
219
228
  )}
@@ -0,0 +1,238 @@
1
+ import React, { useState, useMemo, useEffect, useCallback } from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import Select from '@blaze-react/select';
4
+ import { useQuery, useApolloClient } from '@apollo/client';
5
+ import { getDynamicQuery, getQuery } from '@blaze-cms/admin-ui-utils';
6
+ import { BsArrowCounterclockwise, BsSearch } from 'react-icons/bs';
7
+ import { updateListFilters, buildQueryFields } from './helpers';
8
+ import { NOOP_QUERY } from './querys';
9
+ import { ENTER_KEY, DEFAULT_FILTER_OPTION_LABEL } from '../../../constants';
10
+
11
+ const SearchContainer = ({
12
+ setListFilters,
13
+ keywordFiltersToUse = [],
14
+ selectFiltersToDisplay = [],
15
+ schema,
16
+ index
17
+ }) => {
18
+ const apolloClient = useApolloClient();
19
+ const [searchTerm, setSearchTerm] = useState('');
20
+ const [selectedFilters, setSelectedFilters] = useState({});
21
+ const [selectOptions, setSelectOptions] = useState([]);
22
+
23
+ const displaySearchFilter = keywordFiltersToUse.length > 0;
24
+ const displaySelectFilters = selectFiltersToDisplay.length > 0;
25
+
26
+ const { keywordSearchProperties, keywordSearchLabels } = useMemo(
27
+ () => {
28
+ const labels = [];
29
+ const properties = [];
30
+
31
+ keywordFiltersToUse.forEach(([property, { label }]) => {
32
+ if (label) labels.push(label);
33
+ properties.push(property);
34
+ });
35
+
36
+ return { keywordSearchProperties: properties, keywordSearchLabels: labels };
37
+ },
38
+ [keywordFiltersToUse]
39
+ );
40
+
41
+ const { gqlFields, rawQuery } = useMemo(
42
+ () => buildQueryFields(selectFiltersToDisplay, schema.id),
43
+ [selectFiltersToDisplay, schema.id]
44
+ );
45
+ const action = displaySelectFilters
46
+ ? getDynamicQuery('ADMIN_SEARCH')([schema], gqlFields, false, index)
47
+ : NOOP_QUERY;
48
+
49
+ const { data } = useQuery(action, {
50
+ skip: !displaySelectFilters,
51
+ variables: { where: rawQuery, limit: 0 },
52
+ fetchPolicy: 'cache-and-network'
53
+ });
54
+
55
+ const filterData = useMemo(
56
+ () => {
57
+ const { searchResults: { rawResults: { aggregations = {} } = {} } = {} } = data || {};
58
+ const proccessedData = [];
59
+ Object.entries(aggregations).forEach(([key, { buckets }]) => {
60
+ proccessedData.push(
61
+ Array.isArray(buckets) ? [key, buckets.map(b => b.key).filter(Boolean)] : []
62
+ );
63
+ });
64
+
65
+ return proccessedData;
66
+ },
67
+ [data]
68
+ );
69
+
70
+ useEffect(
71
+ () => {
72
+ if (!filterData.length) {
73
+ setSelectOptions([]);
74
+ return;
75
+ }
76
+
77
+ (async () => {
78
+ const results = await Promise.all(
79
+ filterData.map(async ([property, ids]) => {
80
+ try {
81
+ if (!ids || !ids.length) return {};
82
+
83
+ const [, selectionDetails] =
84
+ selectFiltersToDisplay.find(([selectProperty]) => selectProperty === property) ||
85
+ [];
86
+
87
+ if (!selectionDetails) return null;
88
+
89
+ if (!selectionDetails.relation) {
90
+ return {
91
+ id: property,
92
+ label: selectionDetails.label,
93
+ options: ids.map(value => [value, value])
94
+ };
95
+ }
96
+ const query = getQuery('GET_ENTITY_SCHEMA');
97
+ const {
98
+ data: {
99
+ getEntitySchemas: [relationSchema]
100
+ }
101
+ } = await apolloClient.query({
102
+ query,
103
+ variables: { identifier: selectionDetails.relation.entityIdentifier }
104
+ });
105
+
106
+ const {
107
+ data: { result: selected = [] }
108
+ } = await apolloClient
109
+ .query({
110
+ query: getDynamicQuery('GET_ALL_ENTITIES')(relationSchema),
111
+ variables: {
112
+ where: {
113
+ id: {
114
+ _in: ids
115
+ }
116
+ },
117
+ sort: [{ property: 'name', direction: 'asc' }]
118
+ }
119
+ })
120
+ // eslint-disable-next-line no-console
121
+ .catch(e => console.error(e));
122
+
123
+ return {
124
+ id: property,
125
+ label: selectionDetails.label,
126
+ options: selected.map(item => [item.id, item.name])
127
+ };
128
+ } catch {
129
+ return null;
130
+ }
131
+ })
132
+ );
133
+
134
+ setSelectOptions(results.filter(Boolean));
135
+ })();
136
+ },
137
+ [apolloClient, filterData, schema, selectFiltersToDisplay]
138
+ );
139
+
140
+ const updateFilters = useCallback(
141
+ (term, filters) => updateListFilters(term, filters, setListFilters, keywordSearchProperties),
142
+ [setListFilters, keywordSearchProperties]
143
+ );
144
+
145
+ const handleSearch = useCallback(() => updateFilters(searchTerm, selectedFilters), [
146
+ searchTerm,
147
+ selectedFilters,
148
+ updateFilters
149
+ ]);
150
+ const handleSearchChange = useCallback(e => setSearchTerm(e.target.value), []);
151
+ const handleEnterKey = useCallback(
152
+ e => {
153
+ if (e.key === ENTER_KEY) handleSearch();
154
+ },
155
+ [handleSearch]
156
+ );
157
+ const handleReset = useCallback(
158
+ () => {
159
+ setSearchTerm('');
160
+ setSelectedFilters(
161
+ Object.keys(selectedFilters).reduce(
162
+ (acc, key) => ({ ...acc, [key]: DEFAULT_FILTER_OPTION_LABEL }),
163
+ {}
164
+ )
165
+ );
166
+ updateFilters('', {});
167
+ },
168
+ [selectedFilters, updateFilters]
169
+ );
170
+ const handleSelect = useCallback(
171
+ (property, event) => {
172
+ const { value } = event;
173
+ const next = { ...selectedFilters, [property]: value };
174
+ setSelectedFilters(next);
175
+ updateFilters(searchTerm, next);
176
+ },
177
+ [searchTerm, selectedFilters, updateFilters]
178
+ );
179
+
180
+ const placeholderText = `Search ${keywordSearchLabels.join(', ')}`;
181
+
182
+ return (
183
+ <div className="search-container">
184
+ {displaySearchFilter && (
185
+ <div className="search-container__search-input-container">
186
+ <input
187
+ type="search"
188
+ className="search-container__search-input-container__search-input"
189
+ placeholder={placeholderText}
190
+ value={searchTerm}
191
+ onChange={handleSearchChange}
192
+ onKeyDown={handleEnterKey}
193
+ />
194
+ <i role="button" onClick={handleSearch}>
195
+ <BsSearch />
196
+ </i>
197
+ </div>
198
+ )}
199
+
200
+ {displaySelectFilters &&
201
+ selectOptions.map(({ id, options, label }) => (
202
+ <div className="search-container__select-wrapper">
203
+ <Select
204
+ label={label}
205
+ id={id}
206
+ name={id}
207
+ onChange={event => handleSelect(id, event)}
208
+ options={options}
209
+ value={selectedFilters[id]}
210
+ defaultTextValue={DEFAULT_FILTER_OPTION_LABEL}
211
+ />
212
+ </div>
213
+ ))}
214
+
215
+ <div className="search-container__reset-button">
216
+ <span role="button" onClick={handleReset}>
217
+ <BsArrowCounterclockwise />
218
+ </span>
219
+ </div>
220
+ </div>
221
+ );
222
+ };
223
+
224
+ SearchContainer.propTypes = {
225
+ setListFilters: PropTypes.func.isRequired,
226
+ keywordFiltersToUse: PropTypes.array,
227
+ selectFiltersToDisplay: PropTypes.array,
228
+ schema: PropTypes.object.isRequired,
229
+ index: PropTypes.string
230
+ };
231
+
232
+ SearchContainer.defaultProps = {
233
+ keywordFiltersToUse: [],
234
+ selectFiltersToDisplay: [],
235
+ index: 'admin'
236
+ };
237
+
238
+ export default SearchContainer;
@@ -0,0 +1,37 @@
1
+ import React, { useMemo } from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import { getKeywordSearchFilters, findSelectFilters } from './helpers';
4
+ import SearchContainer from './SearchContainer';
5
+
6
+ const SearchFilter = ({ schema, setListFilters }) => {
7
+ const { displayProperties = {} } = schema || {};
8
+ const {
9
+ adminListings: { dataSource: { source, index } = {}, disableListingFilter = false } = {}
10
+ } = displayProperties;
11
+
12
+ const keywordFiltersToUse = useMemo(() => getKeywordSearchFilters(schema), [schema]);
13
+ const selectFiltersToDisplay = useMemo(() => findSelectFilters(schema), [schema]);
14
+
15
+ if (disableListingFilter) return null;
16
+
17
+ const canSearch =
18
+ source === 'search' && (keywordFiltersToUse.length > 0 || selectFiltersToDisplay.length > 0);
19
+ if (!canSearch) return null;
20
+
21
+ return (
22
+ <SearchContainer
23
+ index={index}
24
+ setListFilters={setListFilters}
25
+ keywordFiltersToUse={keywordFiltersToUse}
26
+ selectFiltersToDisplay={selectFiltersToDisplay}
27
+ schema={schema}
28
+ />
29
+ );
30
+ };
31
+
32
+ SearchFilter.propTypes = {
33
+ setListFilters: PropTypes.func.isRequired,
34
+ schema: PropTypes.object.isRequired
35
+ };
36
+
37
+ export default SearchFilter;
@@ -0,0 +1,96 @@
1
+ import { DEFAULT_FILTER_OPTION_LABEL } from '../../../constants';
2
+
3
+ const updateListFilters = (searchTerm, selectedFilters, setListFilters, fields = []) => {
4
+ const filters = [];
5
+ if (searchTerm) {
6
+ filters.push({
7
+ simple_query_string: {
8
+ query: `${searchTerm}*`,
9
+ fields
10
+ }
11
+ });
12
+ }
13
+
14
+ Object.keys(selectedFilters).forEach(filterKey => {
15
+ const filterValue = selectedFilters[filterKey];
16
+ if (!filterValue || filterValue === DEFAULT_FILTER_OPTION_LABEL) return;
17
+ filters.push({
18
+ match: {
19
+ [filterKey]: filterValue
20
+ }
21
+ });
22
+ });
23
+
24
+ setListFilters(filters);
25
+ };
26
+
27
+ const getKeywordSearchFilters = schema => {
28
+ if (!schema || !schema.properties) return [];
29
+
30
+ const { properties = {}, dynamicProperties = {} } = schema;
31
+
32
+ const propertyKeyword = Object.entries(properties).filter(isFilterKeywordItem);
33
+ const dynamicPropertyKeywords = Object.entries(dynamicProperties).filter(isFilterKeywordItem);
34
+
35
+ return [...propertyKeyword, ...dynamicPropertyKeywords];
36
+ };
37
+
38
+ const isFilterKeywordItem = ([, item]) =>
39
+ item.adminListingOptions && item.adminListingOptions.includeInKeywordSeach === true;
40
+
41
+ const findSelectFilters = schema => {
42
+ if (!schema || !schema.properties) return [];
43
+
44
+ const { properties = {}, dynamicProperties = {} } = schema;
45
+
46
+ const propertySelects = Object.entries(properties).filter(isFilterSelectItem);
47
+ const dynamicPropertySelects = Object.entries(dynamicProperties).filter(isFilterSelectItem);
48
+
49
+ return [...propertySelects, ...dynamicPropertySelects];
50
+ };
51
+
52
+ const isFilterSelectItem = ([, item]) =>
53
+ item.adminListingOptions && item.adminListingOptions.filterType === 'select';
54
+
55
+ const buildQueryFields = (selectFilters, entityId) => {
56
+ if (!Array.isArray(selectFilters) || selectFilters.length === 0) {
57
+ return { gqlFields: '', rawQuery: '{}' };
58
+ }
59
+
60
+ const aggs = {};
61
+ selectFilters.forEach(([property, details]) => {
62
+ aggs[property] = {
63
+ terms: {
64
+ field: `${property}.keyword`, // todo: handle different field types
65
+ size: 1000, // todo: customise size
66
+ order: {
67
+ _key: 'asc'
68
+ }
69
+ }
70
+ };
71
+ });
72
+
73
+ const docType = entityId;
74
+ const rawQueryObject = {
75
+ size: 0,
76
+ query: {
77
+ bool: {
78
+ filter: {
79
+ bool: {
80
+ must: [{ match: { docType } }]
81
+ }
82
+ }
83
+ }
84
+ },
85
+ aggs
86
+ };
87
+ const rawQuery = JSON.stringify(rawQueryObject);
88
+
89
+ const gqlFields = `
90
+ rawResults
91
+ `;
92
+
93
+ return { gqlFields, rawQuery };
94
+ };
95
+
96
+ export { buildQueryFields, updateListFilters, getKeywordSearchFilters, findSelectFilters };
@@ -0,0 +1,9 @@
1
+ import { gql } from '@apollo/client';
2
+
3
+ const NOOP_QUERY = gql`
4
+ query NoOp {
5
+ __typename
6
+ }
7
+ `;
8
+
9
+ export { NOOP_QUERY };
package/src/constants.js CHANGED
@@ -26,6 +26,8 @@ const PAGE_BUILDER_TAB_INDEX = 1;
26
26
  const EDITOR_VIEW_TAB = 'Editor view';
27
27
  const EDITOR_VIEW_TAB_INDEX = 0;
28
28
 
29
+ const ENTER_KEY = 'Enter';
30
+
29
31
  const ICON_SIZE = {
30
32
  WIDTH: '25px',
31
33
  HEIGHT: '25px'
@@ -36,6 +38,8 @@ const ICON_COLOR = {
36
38
  FILL: '#63779C'
37
39
  };
38
40
 
41
+ const DEFAULT_FILTER_OPTION_LABEL = 'Any';
42
+
39
43
  export {
40
44
  DATA_LISTING_PREFIX,
41
45
  ENTITY_PUBLISHED,
@@ -63,5 +67,7 @@ export {
63
67
  SAVE_BEFORE_PUBLISH_MESSAGE,
64
68
  ICON_SIZE,
65
69
  ICON_COLOR,
66
- PAGE_NOT_FOUND
70
+ PAGE_NOT_FOUND,
71
+ ENTER_KEY,
72
+ DEFAULT_FILTER_OPTION_LABEL
67
73
  };