@veiag/payload-cmdk 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +594 -0
- package/dist/components/CommandMenuContext.d.ts +15 -0
- package/dist/components/CommandMenuContext.js +430 -0
- package/dist/components/CommandMenuContext.js.map +1 -0
- package/dist/components/SearchButton.d.ts +8 -0
- package/dist/components/SearchButton.js +106 -0
- package/dist/components/SearchButton.js.map +1 -0
- package/dist/components/SearchButton.scss +133 -0
- package/dist/components/cmdk/command.scss +334 -0
- package/dist/components/cmdk/index.d.ts +12 -0
- package/dist/components/cmdk/index.js +77 -0
- package/dist/components/cmdk/index.js.map +1 -0
- package/dist/components/modal.scss +94 -0
- package/dist/endpoints/customEndpointHandler.d.ts +2 -0
- package/dist/endpoints/customEndpointHandler.js +7 -0
- package/dist/endpoints/customEndpointHandler.js.map +1 -0
- package/dist/exports/client.d.ts +2 -0
- package/dist/exports/client.js +4 -0
- package/dist/exports/client.js.map +1 -0
- package/dist/exports/rsc.d.ts +0 -0
- package/dist/exports/rsc.js +2 -0
- package/dist/exports/rsc.js.map +1 -0
- package/dist/hooks/useMutationObserver.d.ts +1 -0
- package/dist/hooks/useMutationObserver.js +21 -0
- package/dist/hooks/useMutationObserver.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +74 -0
- package/dist/index.js.map +1 -0
- package/dist/translations/index.d.ts +32 -0
- package/dist/translations/index.js +38 -0
- package/dist/translations/index.js.map +1 -0
- package/dist/types.d.ts +223 -0
- package/dist/types.js +6 -0
- package/dist/types.js.map +1 -0
- package/dist/utils/index.d.ts +30 -0
- package/dist/utils/index.js +191 -0
- package/dist/utils/index.js.map +1 -0
- package/package.json +126 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/utils/index.ts"],"sourcesContent":["import type { ClientConfig, LabelFunction, TextFieldClient } from 'payload'\nimport type {\n CommandMenuGroup,\n CommandMenuItem,\n CustomMenuGroup,\n CustomMenuItem,\n LocalizedString,\n PluginCommandMenuConfig,\n} from 'src/types'\n\nimport { Files, Globe } from 'lucide-react'\n\nexport const convertSlugToTitle = (slug: string): string => {\n return slug.replace(/-/g, ' ').replace(/\\b\\w/g, (char) => char.toUpperCase())\n}\n\nexport const extractLocalizedValue = (\n value: LocalizedString,\n locale: string,\n slug?: string,\n): string => {\n if (typeof value === 'string') {\n return value\n }\n return value[locale] || convertSlugToTitle(slug || '')\n}\n\nexport const extractLocalizedCollectionName = (\n collection: {\n labels?: { plural?: LocalizedString; singular?: LocalizedString }\n slug: string\n },\n locale: string,\n): string => {\n //Get plural name if exists, otherwise singular, otherwise slug\n if (collection.labels?.plural) {\n return extractLocalizedValue(collection.labels.plural, locale, collection.slug)\n }\n if (collection.labels?.singular) {\n return extractLocalizedValue(collection.labels.singular, locale, collection.slug)\n }\n return '' //Generally should not happen\n}\n\nexport const extractLocalizedGlobalName = (\n global: {\n label?: LabelFunction | LocalizedString\n slug: string\n },\n locale: string,\n): string => {\n if (global.label) {\n return extractLocalizedValue(\n //Ignore label functions, they are not serializable\n typeof global.label === 'function' ? {} : global.label,\n locale,\n global.slug,\n )\n }\n return '' //Generally should not happen\n}\n\nexport const extractLocalizedGroupName = (\n object: {\n admin?: { group?: false | LocalizedString }\n },\n locale: string,\n): null | string => {\n if (object.admin?.group) {\n //Try to extract group name, with fallback to null (no group)\n return extractLocalizedValue(object.admin.group, locale)?.trim() || null\n }\n return null\n}\n\nexport const convertConfigItem = (item: CustomMenuItem, currentLang: string): CommandMenuItem => {\n return {\n slug: item.slug,\n type: 'custom',\n action: item.action,\n icon: item.icon,\n label: extractLocalizedValue(item.label, currentLang, item.slug),\n }\n}\n\nexport const convertConfigGroup = (\n group: CustomMenuGroup,\n currentLang: string,\n): CommandMenuGroup => {\n return {\n items: group.items.map((item) => convertConfigItem(item, currentLang)), // Will be merged with existing items if group exists\n title: extractLocalizedValue(group.title, currentLang),\n }\n}\n/**\n * Set of collection/globals slugs to ignore in the command menu.\n * This is useful to avoid showing certain collections/globals in the command menu.\n */\nconst DEFAULT_SLUGS_TO_IGNORE: string[] = [\n 'payload-migrations',\n 'payload-preferences',\n 'payload-locked-documents',\n]\nexport const createDefaultGroups = (\n config: ClientConfig,\n currentLang: string,\n pluginConfig: PluginCommandMenuConfig,\n): {\n groups: CommandMenuGroup[]\n /**\n * Stray items that don't belong to any group.\n * Only with custom items.\n */\n items: CommandMenuItem[]\n} => {\n const groups: CommandMenuGroup[] = []\n const items: CommandMenuItem[] = []\n const avaibleGroups = new Set<string>() //To avoid duplicates\n let slugsToIgnore = [...DEFAULT_SLUGS_TO_IGNORE]\n\n //Handle slugs to ignore from plugin config\n if (pluginConfig?.slugsToIgnore) {\n if (Array.isArray(pluginConfig.slugsToIgnore)) {\n slugsToIgnore.push(...pluginConfig.slugsToIgnore)\n } else {\n //Object with ignoreList and replaceDefaults\n if (pluginConfig.slugsToIgnore.replaceDefaults) {\n //Replace defaults\n slugsToIgnore = [] //Reset\n }\n slugsToIgnore.push(...pluginConfig.slugsToIgnore.ignoreList)\n }\n }\n\n if (config.collections) {\n config.collections.forEach((collection) => {\n if (slugsToIgnore.includes(collection.slug)) {\n return\n }\n\n const groupName = extractLocalizedGroupName(collection, currentLang) || 'Collections'\n // console.log(collection.slug, 'groupName:', groupName, 'Object', collection.admin)\n if (!avaibleGroups.has(groupName)) {\n avaibleGroups.add(groupName)\n groups.push({\n items: [],\n title: groupName,\n })\n }\n const group = groups.find((g) => g.title === groupName)\n if (group) {\n const useAsTitleField = collection.admin?.useAsTitle || 'id'\n let useAsTitleFieldLabel: TextFieldClient['label'] | undefined = undefined\n let useAsTitleLabel: string | undefined = undefined\n //Only extract useAsTitle label if submenu is enabled\n if (pluginConfig?.submenu?.enabled !== false) {\n useAsTitleFieldLabel = (\n collection?.fields?.find((field) => {\n if ('name' in field === false) {\n return null\n }\n return field.name === useAsTitleField\n }) as null | TextFieldClient\n )?.label\n //Extract label for useAsTitle field\n useAsTitleLabel = extractLocalizedValue(\n typeof useAsTitleFieldLabel === 'function' ? {} : useAsTitleFieldLabel || {},\n currentLang,\n useAsTitleField,\n )\n }\n group.items.push({\n slug: collection.slug,\n type: 'collection',\n action: {\n type: 'link',\n href: `/admin/collections/${collection.slug}`,\n },\n //Either custom icon from plugin config, or default Files icon\n icon: pluginConfig?.icons?.collections?.[collection.slug] || Files,\n label: extractLocalizedCollectionName(collection, currentLang),\n useAsTitle: useAsTitleField,\n useAsTitleLabel: useAsTitleLabel || useAsTitleField,\n })\n }\n })\n }\n //Globals\n if (config.globals) {\n config.globals.forEach((global) => {\n if (slugsToIgnore.includes(global.slug)) {\n return\n }\n //Same logic as collections\n const groupName = extractLocalizedGroupName(global, currentLang) || 'Globals'\n if (!avaibleGroups.has(groupName)) {\n avaibleGroups.add(groupName)\n groups.push({\n items: [],\n title: groupName,\n })\n }\n const group = groups.find((g) => g.title === groupName)\n if (group) {\n group.items.push({\n slug: global.slug,\n type: 'global',\n action: {\n type: 'link',\n href: `/admin/globals/${global.slug}`,\n },\n //Either custom icon from plugin config, or default Globe icon\n icon: pluginConfig?.icons?.globals?.[global.slug] || Globe,\n label: extractLocalizedGlobalName(global, currentLang),\n })\n }\n })\n }\n //Now custom items/groups from plugin config\n if (pluginConfig?.customItems) {\n //We are not using slugsToIgnore for custom items, as they are user-defined\n pluginConfig.customItems.forEach((value) => {\n if (value.type === 'group') {\n const convertedGroup = convertConfigGroup(value, currentLang)\n //Check if group already exists using our set\n if (!avaibleGroups.has(convertedGroup.title)) {\n avaibleGroups.add(convertedGroup.title)\n groups.push({\n items: [], //Don't add items yet, will do below\n title: convertedGroup.title,\n })\n }\n const group = groups.find((g) => g.title === convertedGroup.title)\n if (group) {\n //Append items to existing group, or if it was empty - add items\n group.items.push(...convertedGroup.items)\n }\n }\n if (value.type === 'item') {\n //Stray item, add to items array\n const convertedItem = convertConfigItem(value, currentLang)\n items.push(convertedItem)\n }\n })\n }\n return { groups, items }\n}\n"],"names":["Files","Globe","convertSlugToTitle","slug","replace","char","toUpperCase","extractLocalizedValue","value","locale","extractLocalizedCollectionName","collection","labels","plural","singular","extractLocalizedGlobalName","global","label","extractLocalizedGroupName","object","admin","group","trim","convertConfigItem","item","currentLang","type","action","icon","convertConfigGroup","items","map","title","DEFAULT_SLUGS_TO_IGNORE","createDefaultGroups","config","pluginConfig","groups","avaibleGroups","Set","slugsToIgnore","Array","isArray","push","replaceDefaults","ignoreList","collections","forEach","includes","groupName","has","add","find","g","useAsTitleField","useAsTitle","useAsTitleFieldLabel","undefined","useAsTitleLabel","submenu","enabled","fields","field","name","href","icons","globals","customItems","convertedGroup","convertedItem"],"mappings":"AAUA,SAASA,KAAK,EAAEC,KAAK,QAAQ,eAAc;AAE3C,OAAO,MAAMC,qBAAqB,CAACC;IACjC,OAAOA,KAAKC,OAAO,CAAC,MAAM,KAAKA,OAAO,CAAC,SAAS,CAACC,OAASA,KAAKC,WAAW;AAC5E,EAAC;AAED,OAAO,MAAMC,wBAAwB,CACnCC,OACAC,QACAN;IAEA,IAAI,OAAOK,UAAU,UAAU;QAC7B,OAAOA;IACT;IACA,OAAOA,KAAK,CAACC,OAAO,IAAIP,mBAAmBC,QAAQ;AACrD,EAAC;AAED,OAAO,MAAMO,iCAAiC,CAC5CC,YAIAF;IAEA,+DAA+D;IAC/D,IAAIE,WAAWC,MAAM,EAAEC,QAAQ;QAC7B,OAAON,sBAAsBI,WAAWC,MAAM,CAACC,MAAM,EAAEJ,QAAQE,WAAWR,IAAI;IAChF;IACA,IAAIQ,WAAWC,MAAM,EAAEE,UAAU;QAC/B,OAAOP,sBAAsBI,WAAWC,MAAM,CAACE,QAAQ,EAAEL,QAAQE,WAAWR,IAAI;IAClF;IACA,OAAO,GAAG,6BAA6B;;AACzC,EAAC;AAED,OAAO,MAAMY,6BAA6B,CACxCC,QAIAP;IAEA,IAAIO,OAAOC,KAAK,EAAE;QAChB,OAAOV,sBACL,mDAAmD;QACnD,OAAOS,OAAOC,KAAK,K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OoC,eAAepC,KAAK;oBAC7B;gBACF;gBACA,MAAMX,QAAQgB,OAAOe,IAAI,CAAC,CAACC,IAAMA,EAAErB,KAAK,KAAKoC,eAAepC,KAAK;gBACjE,IAAIX,OAAO;oBACT,gEAAgE;oBAChEA,MAAMS,KAAK,CAACa,IAAI,IAAIyB,eAAetC,KAAK;gBAC1C;YACF;YACA,IAAItB,MAAMkB,IAAI,KAAK,QAAQ;gBACzB,gCAAgC;gBAChC,MAAM2C,gBAAgB9C,kBAAkBf,OAAOiB;gBAC/CK,MAAMa,IAAI,CAAC0B;YACb;QACF;IACF;IACA,OAAO;QAAEhC;QAAQP;IAAM;AACzB,EAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@veiag/payload-cmdk",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "A command menu plugin for Payload CMS to enhance navigation and accessibility within the admin panel.",
|
|
5
|
+
"author": "VeiaG",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"type": "module",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"import": "./src/index.ts",
|
|
11
|
+
"types": "./src/index.ts",
|
|
12
|
+
"default": "./src/index.ts"
|
|
13
|
+
},
|
|
14
|
+
"./client": {
|
|
15
|
+
"import": "./src/exports/client.ts",
|
|
16
|
+
"types": "./src/exports/client.ts",
|
|
17
|
+
"default": "./src/exports/client.ts"
|
|
18
|
+
},
|
|
19
|
+
"./rsc": {
|
|
20
|
+
"import": "./src/exports/rsc.ts",
|
|
21
|
+
"types": "./src/exports/rsc.ts",
|
|
22
|
+
"default": "./src/exports/rsc.ts"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"main": "./src/index.ts",
|
|
26
|
+
"types": "./src/index.ts",
|
|
27
|
+
"files": [
|
|
28
|
+
"dist"
|
|
29
|
+
],
|
|
30
|
+
"scripts": {
|
|
31
|
+
"build": "pnpm copyfiles && pnpm build:types && pnpm build:swc",
|
|
32
|
+
"build:swc": "swc ./src -d ./dist --config-file .swcrc --strip-leading-paths",
|
|
33
|
+
"build:types": "tsc --outDir dist --rootDir ./src",
|
|
34
|
+
"clean": "rimraf {dist,*.tsbuildinfo}",
|
|
35
|
+
"copyfiles": "copyfiles -u 1 \"src/**/*.{html,css,scss,ttf,woff,woff2,eot,svg,jpg,png,json}\" dist/",
|
|
36
|
+
"dev": "next dev dev --turbo",
|
|
37
|
+
"dev:generate-importmap": "pnpm dev:payload generate:importmap",
|
|
38
|
+
"dev:generate-types": "pnpm dev:payload generate:types",
|
|
39
|
+
"dev:payload": "cross-env PAYLOAD_CONFIG_PATH=./dev/payload.config.ts payload",
|
|
40
|
+
"generate:importmap": "pnpm dev:generate-importmap",
|
|
41
|
+
"generate:types": "pnpm dev:generate-types",
|
|
42
|
+
"lint": "eslint",
|
|
43
|
+
"lint:fix": "eslint ./src --fix",
|
|
44
|
+
"prepublishOnly": "pnpm clean && pnpm build",
|
|
45
|
+
"test": "pnpm test:int && pnpm test:e2e",
|
|
46
|
+
"test:e2e": "playwright test",
|
|
47
|
+
"test:int": "vitest"
|
|
48
|
+
},
|
|
49
|
+
"devDependencies": {
|
|
50
|
+
"@eslint/eslintrc": "^3.2.0",
|
|
51
|
+
"@payloadcms/db-mongodb": "3.37.0",
|
|
52
|
+
"@payloadcms/db-postgres": "3.37.0",
|
|
53
|
+
"@payloadcms/db-sqlite": "3.37.0",
|
|
54
|
+
"@payloadcms/eslint-config": "3.9.0",
|
|
55
|
+
"@payloadcms/next": "3.37.0",
|
|
56
|
+
"@payloadcms/richtext-lexical": "3.37.0",
|
|
57
|
+
"@payloadcms/ui": "3.37.0",
|
|
58
|
+
"@playwright/test": "1.56.1",
|
|
59
|
+
"@swc-node/register": "1.10.9",
|
|
60
|
+
"@swc/cli": "0.6.0",
|
|
61
|
+
"@types/node": "^22.5.4",
|
|
62
|
+
"@types/react": "19.2.1",
|
|
63
|
+
"@types/react-dom": "19.2.1",
|
|
64
|
+
"copyfiles": "2.4.1",
|
|
65
|
+
"cross-env": "^7.0.3",
|
|
66
|
+
"eslint": "^9.23.0",
|
|
67
|
+
"eslint-config-next": "15.4.7",
|
|
68
|
+
"graphql": "^16.8.1",
|
|
69
|
+
"mongodb-memory-server": "10.1.4",
|
|
70
|
+
"next": "15.4.8",
|
|
71
|
+
"open": "^10.1.0",
|
|
72
|
+
"payload": "3.37.0",
|
|
73
|
+
"prettier": "^3.4.2",
|
|
74
|
+
"qs-esm": "7.0.2",
|
|
75
|
+
"react": "19.2.1",
|
|
76
|
+
"react-dom": "19.2.1",
|
|
77
|
+
"rimraf": "3.0.2",
|
|
78
|
+
"sharp": "0.34.2",
|
|
79
|
+
"sort-package-json": "^2.10.0",
|
|
80
|
+
"typescript": "5.7.3",
|
|
81
|
+
"vite-tsconfig-paths": "^5.1.4",
|
|
82
|
+
"vitest": "^3.1.2"
|
|
83
|
+
},
|
|
84
|
+
"peerDependencies": {
|
|
85
|
+
"payload": "^3.37.0"
|
|
86
|
+
},
|
|
87
|
+
"engines": {
|
|
88
|
+
"node": "^18.20.2 || >=20.9.0",
|
|
89
|
+
"pnpm": "^9 || ^10"
|
|
90
|
+
},
|
|
91
|
+
"publishConfig": {
|
|
92
|
+
"exports": {
|
|
93
|
+
".": {
|
|
94
|
+
"import": "./dist/index.js",
|
|
95
|
+
"types": "./dist/index.d.ts",
|
|
96
|
+
"default": "./dist/index.js"
|
|
97
|
+
},
|
|
98
|
+
"./client": {
|
|
99
|
+
"import": "./dist/exports/client.js",
|
|
100
|
+
"types": "./dist/exports/client.d.ts",
|
|
101
|
+
"default": "./dist/exports/client.js"
|
|
102
|
+
},
|
|
103
|
+
"./rsc": {
|
|
104
|
+
"import": "./dist/exports/rsc.js",
|
|
105
|
+
"types": "./dist/exports/rsc.d.ts",
|
|
106
|
+
"default": "./dist/exports/rsc.js"
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
"main": "./dist/index.js",
|
|
110
|
+
"types": "./dist/index.d.ts"
|
|
111
|
+
},
|
|
112
|
+
"pnpm": {
|
|
113
|
+
"onlyBuiltDependencies": [
|
|
114
|
+
"sharp",
|
|
115
|
+
"esbuild",
|
|
116
|
+
"unrs-resolver"
|
|
117
|
+
]
|
|
118
|
+
},
|
|
119
|
+
"registry": "https://registry.npmjs.org/",
|
|
120
|
+
"dependencies": {
|
|
121
|
+
"@payloadcms/translations": "^3.37.0",
|
|
122
|
+
"cmdk": "^1.1.1",
|
|
123
|
+
"lucide-react": "^0.556.0",
|
|
124
|
+
"react-hotkeys-hook": "^5.2.1"
|
|
125
|
+
}
|
|
126
|
+
}
|