@igstack/app-catalog-frontend-core 0.8.0 → 0.8.1

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.
@@ -1,6 +1,6 @@
1
1
  import { AppVersionInfo } from '@igstack/app-catalog-backend-core';
2
2
  /**
3
- * Merge the (natera-agnostic) frontend build id into the backend-provided
3
+ * Merge the (company-agnostic) frontend build id into the backend-provided
4
4
  * version info's `frontend` slot.
5
5
  *
6
6
  * The build id is baked into the deployed JS bundle at build time (e.g. a CI
@@ -1 +1 @@
1
- {"version":3,"file":"mergeFrontendBuildId.js","sources":["../../../../../src/modules/appCatalog/context/mergeFrontendBuildId.ts"],"sourcesContent":["import type { AppVersionInfo } from '@igstack/app-catalog-backend-core'\n\n/**\n * Merge the (natera-agnostic) frontend build id into the backend-provided\n * version info's `frontend` slot.\n *\n * The build id is baked into the deployed JS bundle at build time (e.g. a CI\n * pipeline id via a Vite env var). We PREPEND it to the resolved frontend-core\n * npm version instead of replacing it, so the footer surfaces both:\n * `#<buildId> · <frontend-core version> (<sha>)`.\n *\n * - No build id → return versions unchanged.\n * - build id === 'local' → show `local` (local dev, no meaningful SHA/version).\n * - otherwise → prepend `#<buildId> · ` and preserve the version + sha + shaUrl.\n */\nexport function mergeFrontendBuildId(\n versions: AppVersionInfo,\n frontendBuildId: string | undefined,\n): AppVersionInfo {\n if (!frontendBuildId) return versions\n if (frontendBuildId === 'local') {\n return { ...versions, frontend: { displayName: 'local' } }\n }\n const be = versions.frontend\n return {\n ...versions,\n frontend: be\n ? { ...be, displayName: `#${frontendBuildId} · ${be.displayName}` }\n : { displayName: `#${frontendBuildId}` },\n }\n}\n"],"names":[],"mappings":"AAeO,SAAS,qBACd,UACA,iBACgB;AAChB,MAAI,CAAC,gBAAiB,QAAO;AAC7B,MAAI,oBAAoB,SAAS;AAC/B,WAAO,EAAE,GAAG,UAAU,UAAU,EAAE,aAAa,UAAQ;AAAA,EACzD;AACA,QAAM,KAAK,SAAS;AACpB,SAAO;AAAA,IACL,GAAG;AAAA,IACH,UAAU,KACN,EAAE,GAAG,IAAI,aAAa,IAAI,eAAe,MAAM,GAAG,WAAW,OAC7D,EAAE,aAAa,IAAI,eAAe,GAAA;AAAA,EAAG;AAE7C;"}
1
+ {"version":3,"file":"mergeFrontendBuildId.js","sources":["../../../../../src/modules/appCatalog/context/mergeFrontendBuildId.ts"],"sourcesContent":["import type { AppVersionInfo } from '@igstack/app-catalog-backend-core'\n\n/**\n * Merge the (company-agnostic) frontend build id into the backend-provided\n * version info's `frontend` slot.\n *\n * The build id is baked into the deployed JS bundle at build time (e.g. a CI\n * pipeline id via a Vite env var). We PREPEND it to the resolved frontend-core\n * npm version instead of replacing it, so the footer surfaces both:\n * `#<buildId> · <frontend-core version> (<sha>)`.\n *\n * - No build id → return versions unchanged.\n * - build id === 'local' → show `local` (local dev, no meaningful SHA/version).\n * - otherwise → prepend `#<buildId> · ` and preserve the version + sha + shaUrl.\n */\nexport function mergeFrontendBuildId(\n versions: AppVersionInfo,\n frontendBuildId: string | undefined,\n): AppVersionInfo {\n if (!frontendBuildId) return versions\n if (frontendBuildId === 'local') {\n return { ...versions, frontend: { displayName: 'local' } }\n }\n const be = versions.frontend\n return {\n ...versions,\n frontend: be\n ? { ...be, displayName: `#${frontendBuildId} · ${be.displayName}` }\n : { displayName: `#${frontendBuildId}` },\n }\n}\n"],"names":[],"mappings":"AAeO,SAAS,qBACd,UACA,iBACgB;AAChB,MAAI,CAAC,gBAAiB,QAAO;AAC7B,MAAI,oBAAoB,SAAS;AAC/B,WAAO,EAAE,GAAG,UAAU,UAAU,EAAE,aAAa,UAAQ;AAAA,EACzD;AACA,QAAM,KAAK,SAAS;AACpB,SAAO;AAAA,IACL,GAAG;AAAA,IACH,UAAU,KACN,EAAE,GAAG,IAAI,aAAa,IAAI,eAAe,MAAM,GAAG,WAAW,OAC7D,EAAE,aAAa,IAAI,eAAe,GAAA;AAAA,EAAG;AAE7C;"}
@@ -19,8 +19,10 @@ function ServiceDesksPage() {
19
19
  /* @__PURE__ */ jsx(InputGroup, { className: "max-w-sm", children: /* @__PURE__ */ jsx(
20
20
  InputGroupInput,
21
21
  {
22
+ autoFocus: true,
22
23
  value: search,
23
24
  onChange: (e) => setSearch(e.target.value),
25
+ onFocus: (e) => e.target.select(),
24
26
  placeholder: "Search service desks by name…",
25
27
  "aria-label": "Search service desks"
26
28
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ServiceDesksPage.js","sources":["../../../../../../src/modules/appCatalog/ui/pages/ServiceDesksPage.tsx"],"sourcesContent":["import { ExternalLink } from 'lucide-react'\nimport { useMemo, useState } from 'react'\nimport { InputGroup, InputGroupInput } from '~/ui/input-group'\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '~/ui/table'\nimport { useAppCatalogContext } from '../../context/AppCatalogContext'\n\n/**\n * Service Desks view (#9): a searchable table of all service-desk approval\n * methods (type === 'service'), each with a link that opens its portal in a new\n * tab. Data rides in on the existing app-catalog query (context.approvalMethods).\n */\nexport function ServiceDesksPage() {\n const { approvalMethods } = useAppCatalogContext()\n const [search, setSearch] = useState('')\n\n const desks = useMemo(() => {\n const services = approvalMethods.filter((m) => m.type === 'service')\n const q = search.trim().toLowerCase()\n const filtered = q\n ? services.filter((m) => m.displayName.toLowerCase().includes(q))\n : services\n return [...filtered].sort((a, b) =>\n a.displayName.localeCompare(b.displayName),\n )\n }, [approvalMethods, search])\n\n return (\n <div className=\"flex flex-col flex-1 min-h-0 gap-4\">\n <InputGroup className=\"max-w-sm\">\n <InputGroupInput\n value={search}\n onChange={(e) => setSearch(e.target.value)}\n placeholder=\"Search service desks by name…\"\n aria-label=\"Search service desks\"\n />\n </InputGroup>\n\n <div className=\"flex-1 min-h-0 overflow-y-auto\">\n {desks.length === 0 ? (\n <p className=\"text-sm text-muted-foreground\">\n No service desks found{search && ` for \"${search}\"`}.\n </p>\n ) : (\n <Table>\n <TableHeader>\n <TableRow>\n <TableHead>Service Desk</TableHead>\n <TableHead>Link</TableHead>\n </TableRow>\n </TableHeader>\n <TableBody>\n {desks.map((desk) => {\n const url = desk.config.url\n const description = desk.config.description\n return (\n <TableRow key={desk.slug}>\n <TableCell className=\"font-medium align-top\">\n <span data-testid=\"service-desk-name\">\n {desk.displayName}\n </span>\n {description && (\n <span className=\"block text-xs font-normal text-muted-foreground\">\n {description}\n </span>\n )}\n </TableCell>\n <TableCell>\n {url ? (\n <a\n href={url}\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n className=\"inline-flex items-center gap-1 text-primary hover:underline break-all\"\n title={url}\n >\n {url.replace(/^https?:\\/\\//, '')}\n <ExternalLink className=\"size-3 shrink-0\" />\n </a>\n ) : (\n <span className=\"text-muted-foreground\">—</span>\n )}\n </TableCell>\n </TableRow>\n )\n })}\n </TableBody>\n </Table>\n )}\n </div>\n </div>\n )\n}\n"],"names":[],"mappings":";;;;;;AAkBO,SAAS,mBAAmB;AACjC,QAAM,EAAE,gBAAA,IAAoB,qBAAA;AAC5B,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,EAAE;AAEvC,QAAM,QAAQ,QAAQ,MAAM;AAC1B,UAAM,WAAW,gBAAgB,OAAO,CAAC,MAAM,EAAE,SAAS,SAAS;AACnE,UAAM,IAAI,OAAO,KAAA,EAAO,YAAA;AACxB,UAAM,WAAW,IACb,SAAS,OAAO,CAAC,MAAM,EAAE,YAAY,YAAA,EAAc,SAAS,CAAC,CAAC,IAC9D;AACJ,WAAO,CAAC,GAAG,QAAQ,EAAE;AAAA,MAAK,CAAC,GAAG,MAC5B,EAAE,YAAY,cAAc,EAAE,WAAW;AAAA,IAAA;AAAA,EAE7C,GAAG,CAAC,iBAAiB,MAAM,CAAC;AAE5B,SACE,qBAAC,OAAA,EAAI,WAAU,sCACb,UAAA;AAAA,IAAA,oBAAC,YAAA,EAAW,WAAU,YACpB,UAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,OAAO;AAAA,QACP,UA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,MAEJ,CAAC,EAAA,CACH;AAAA,IAAA,EAAA,CACF,EAAA,CAEJ;AAAA,EAAA,GACF;AAEJ;"}
1
+ {"version":3,"file":"ServiceDesksPage.js","sources":["../../../../../../src/modules/appCatalog/ui/pages/ServiceDesksPage.tsx"],"sourcesContent":["import { ExternalLink } from 'lucide-react'\nimport { useMemo, useState } from 'react'\nimport { InputGroup, InputGroupInput } from '~/ui/input-group'\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '~/ui/table'\nimport { useAppCatalogContext } from '../../context/AppCatalogContext'\n\n/**\n * Service Desks view (#9): a searchable table of all service-desk approval\n * methods (type === 'service'), each with a link that opens its portal in a new\n * tab. Data rides in on the existing app-catalog query (context.approvalMethods).\n */\nexport function ServiceDesksPage() {\n const { approvalMethods } = useAppCatalogContext()\n const [search, setSearch] = useState('')\n\n const desks = useMemo(() => {\n const services = approvalMethods.filter((m) => m.type === 'service')\n const q = search.trim().toLowerCase()\n const filtered = q\n ? services.filter((m) => m.displayName.toLowerCase().includes(q))\n : services\n return [...filtered].sort((a, b) =>\n a.displayName.localeCompare(b.displayName),\n )\n }, [approvalMethods, search])\n\n return (\n <div className=\"flex flex-col flex-1 min-h-0 gap-4\">\n <InputGroup className=\"max-w-sm\">\n <InputGroupInput\n autoFocus\n value={search}\n onChange={(e) => setSearch(e.target.value)}\n onFocus={(e) => e.target.select()}\n placeholder=\"Search service desks by name…\"\n aria-label=\"Search service desks\"\n />\n </InputGroup>\n\n <div className=\"flex-1 min-h-0 overflow-y-auto\">\n {desks.length === 0 ? (\n <p className=\"text-sm text-muted-foreground\">\n No service desks found{search && ` for \"${search}\"`}.\n </p>\n ) : (\n <Table>\n <TableHeader>\n <TableRow>\n <TableHead>Service Desk</TableHead>\n <TableHead>Link</TableHead>\n </TableRow>\n </TableHeader>\n <TableBody>\n {desks.map((desk) => {\n const url = desk.config.url\n const description = desk.config.description\n return (\n <TableRow key={desk.slug}>\n <TableCell className=\"font-medium align-top\">\n <span data-testid=\"service-desk-name\">\n {desk.displayName}\n </span>\n {description && (\n <span className=\"block text-xs font-normal text-muted-foreground\">\n {description}\n </span>\n )}\n </TableCell>\n <TableCell>\n {url ? (\n <a\n href={url}\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n className=\"inline-flex items-center gap-1 text-primary hover:underline break-all\"\n title={url}\n >\n {url.replace(/^https?:\\/\\//, '')}\n <ExternalLink className=\"size-3 shrink-0\" />\n </a>\n ) : (\n <span className=\"text-muted-foreground\">—</span>\n )}\n </TableCell>\n </TableRow>\n )\n })}\n </TableBody>\n </Table>\n )}\n </div>\n </div>\n )\n}\n"],"names":[],"mappings":";;;;;;AAkBO,SAAS,mBAAmB;AACjC,QAAM,EAAE,gBAAA,IAAoB,qBAAA;AAC5B,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,EAAE;AAEvC,QAAM,QAAQ,QAAQ,MAAM;AAC1B,UAAM,WAAW,gBAAgB,OAAO,CAAC,MAAM,EAAE,SAAS,SAAS;AACnE,UAAM,IAAI,OAAO,KAAA,EAAO,YAAA;AACxB,UAAM,WAAW,IACb,SAAS,OAAO,CAAC,MAAM,EAAE,YAAY,YAAA,EAAc,SAAS,CAAC,CAAC,IAC9D;AACJ,WAAO,CAAC,GAAG,QAAQ,EAAE;AAAA,MAAK,CAAC,GAAG,MAC5B,EAAE,YAAY,cAAc,EAAE,WAAW;AAAA,IAAA;AAAA,EAE7C,GAAG,CAAC,iBAAiB,MAAM,CAAC;AAE5B,SACE,qBAAC,OAAA,EAAI,WAAU,sCACb,UAAA;AAAA,IAAA,oBAAC,YAAA,EAAW,WAAU,YACpB,UAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAS;AAAA,QACT,OAAO;AAAA,QACP,UAAU,CAAC,MAAM,UAAU,EAAE,OAAO,KAAK;AAAA,QACzC,SAAS,CAAC,MAAM,EAAE,OAAO,OAAA;AAAA,QACzB,aAAY;AAAA,QACZ,cAAW;AAAA,M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;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@igstack/app-catalog-frontend-core",
3
- "version": "0.8.0",
3
+ "version": "0.8.1",
4
4
  "description": "Frontend core library for App Catalog",
5
5
  "homepage": "https://github.com/lislon/app-catalog",
6
6
  "repository": {
@@ -134,8 +134,8 @@
134
134
  "vite-plugin-static-copy": "^3.1.4",
135
135
  "vite-plugin-svgr": "^4.2.0",
136
136
  "vitest": "^4.1.2",
137
- "@igstack/app-catalog-backend-core": "0.8.0",
138
- "@igstack/app-catalog-shared-core": "0.8.0"
137
+ "@igstack/app-catalog-backend-core": "0.8.1",
138
+ "@igstack/app-catalog-shared-core": "0.8.1"
139
139
  },
140
140
  "peerDependencies": {
141
141
  "react": "19.1.2",
@@ -144,7 +144,7 @@
144
144
  "vite": "^6.3.5",
145
145
  "vite-plugin-svgr": "^4.2.0"
146
146
  },
147
- "gitHead": "4b4f0b1953cb84985adc73c75943f1f0819b22ba",
147
+ "gitHead": "16c12c4d457cd8ca88e30ffba17e8b6c23e4d527",
148
148
  "scripts": {
149
149
  "build": "vite build",
150
150
  "build:lenient": "vite build --mode lenient",
@@ -42,10 +42,10 @@ function fullMagazine(
42
42
  },
43
43
  })
44
44
  backendCfg.withApprovalMethod({
45
- slug: 'ux-app-helpdesk',
45
+ slug: 'ops-helpdesk',
46
46
  type: 'service',
47
- displayName: 'UX App Helpdesk',
48
- config: { url: 'https://uxdesk.example.com' },
47
+ displayName: 'Ops Helpdesk',
48
+ config: { url: 'https://opsdesk.example.com' },
49
49
  })
50
50
  const managerApproval = backendCfg.withApprovalMethod({
51
51
  slug: 'manager-approval',
@@ -8,7 +8,7 @@ import { magazine } from './mock-backend/magazines'
8
8
 
9
9
  // #9: a header toggle (Apps | Service Desks) + a /service-desks route showing a
10
10
  // searchable table of all type:'service' approval methods with open links.
11
- // magazine.full() seeds two service desks (IT Help Desk, UX App Helpdesk) and
11
+ // magazine.full() seeds two service desks (IT Help Desk, Ops Helpdesk) and
12
12
  // two custom methods (Manager Approval, Self-Service) which must NOT appear.
13
13
 
14
14
  function serviceDeskTable(): HTMLElement {
@@ -38,7 +38,7 @@ describe('Service Desks view (#9)', () => {
38
38
 
39
39
  const names = deskNames()
40
40
  expect(names).toContain('IT Help Desk')
41
- expect(names).toContain('UX App Helpdesk')
41
+ expect(names).toContain('Ops Helpdesk')
42
42
  // custom-type methods are not service desks
43
43
  expect(names).not.toContain('Manager Approval')
44
44
  expect(names).not.toContain('Self-Service')
@@ -72,12 +72,12 @@ describe('Service Desks view (#9)', () => {
72
72
  const nameCell = within(itRow).getAllByRole('cell')[0]
73
73
  expect(nameCell).toHaveTextContent('IT Infrastructure support desk')
74
74
 
75
- // UX App Helpdesk has no description — its name cell shows only the name.
75
+ // Ops Helpdesk has no description — its name cell shows only the name.
76
76
  const uxRow = within(serviceDeskTable())
77
77
  .getAllByRole('row')
78
- .find((r) => r.textContent.includes('UX App Helpdesk'))!
78
+ .find((r) => r.textContent.includes('Ops Helpdesk'))!
79
79
  const uxNameCell = within(uxRow).getAllByRole('cell')[0]!
80
- expect(uxNameCell.textContent.trim()).toBe('UX App Helpdesk')
80
+ expect(uxNameCell.textContent.trim()).toBe('Ops Helpdesk')
81
81
  })
82
82
 
83
83
  it('filters the desks by search', async () => {
@@ -86,13 +86,13 @@ describe('Service Desks view (#9)', () => {
86
86
  initialRoute: '/service-desks',
87
87
  })
88
88
 
89
- await waitFor(() => expect(deskNames()).toContain('UX App Helpdesk'))
89
+ await waitFor(() => expect(deskNames()).toContain('Ops Helpdesk'))
90
90
 
91
- await user.type(screen.getByLabelText('Search service desks'), 'UX')
91
+ await user.type(screen.getByLabelText('Search service desks'), 'Ops')
92
92
 
93
93
  await waitFor(() => {
94
94
  const names = deskNames()
95
- expect(names).toContain('UX App Helpdesk')
95
+ expect(names).toContain('Ops Helpdesk')
96
96
  expect(names).not.toContain('IT Help Desk')
97
97
  })
98
98
  })
@@ -113,4 +113,13 @@ describe('Service Desks view (#9)', () => {
113
113
  })
114
114
  expect(screen.getByLabelText('Search service desks')).toBeInTheDocument()
115
115
  })
116
+
117
+ it('autofocuses the search input when the view loads (parity with Apps)', async () => {
118
+ await given(magazine.full(), {
119
+ initialRoute: '/service-desks',
120
+ })
121
+
122
+ const search = await screen.findByLabelText('Search service desks')
123
+ await waitFor(() => expect(search).toHaveFocus())
124
+ })
116
125
  })
@@ -50,14 +50,14 @@ describe('searchResources', () => {
50
50
  describe('child resource search', () => {
51
51
  const childResources: Resource[] = [
52
52
  makeChildResource({
53
- slug: 'aws-natera-pipelines-dev',
54
- displayName: 'natera-pipelines-biomarkers-ici-dev',
53
+ slug: 'aws-acme-pipelines-dev',
54
+ displayName: 'acme-pipelines-biomarkers-ici-dev',
55
55
  parentSlug: 'aws-console',
56
- aliases: ['043902793406'],
56
+ aliases: ['000000000001'],
57
57
  }),
58
58
  makeChildResource({
59
- slug: 'aws-natera-infosec-dev',
60
- displayName: 'natera-infosec-dev',
59
+ slug: 'aws-acme-infosec-dev',
60
+ displayName: 'acme-infosec-dev',
61
61
  parentSlug: 'aws-console',
62
62
  aliases: [],
63
63
  }),
@@ -72,13 +72,13 @@ describe('searchResources', () => {
72
72
  })
73
73
 
74
74
  it('finds app by child resource alias (account ID)', () => {
75
- const results = searchResources(allResources, '043902793406')
75
+ const results = searchResources(allResources, '000000000001')
76
76
  expect(results).toHaveLength(1)
77
77
  expect(results[0]!.slug).toBe('aws-console')
78
78
  })
79
79
 
80
80
  it('does not match child resources when none provided', () => {
81
- const results = searchResources(apps, '043902793406')
81
+ const results = searchResources(apps, '000000000001')
82
82
  expect(results).toHaveLength(0)
83
83
  })
84
84
 
@@ -27,7 +27,7 @@ describe('VersionDisplay footer', () => {
27
27
  'href',
28
28
  'https://github.com/lislon/app-catalog/commit/abc1234',
29
29
  )
30
- // Backend line carries the natera SHA suffix
30
+ // Backend line carries the deployment SHA suffix
31
31
  expect(screen.getByText(/#12345 \(deadbee\)/)).toBeInTheDocument()
32
32
  })
33
33
 
@@ -1,7 +1,7 @@
1
1
  import type { AppVersionInfo } from '@igstack/app-catalog-backend-core'
2
2
 
3
3
  /**
4
- * Merge the (natera-agnostic) frontend build id into the backend-provided
4
+ * Merge the (company-agnostic) frontend build id into the backend-provided
5
5
  * version info's `frontend` slot.
6
6
  *
7
7
  * The build id is baked into the deployed JS bundle at build time (e.g. a CI
@@ -35,8 +35,10 @@ export function ServiceDesksPage() {
35
35
  <div className="flex flex-col flex-1 min-h-0 gap-4">
36
36
  <InputGroup className="max-w-sm">
37
37
  <InputGroupInput
38
+ autoFocus
38
39
  value={search}
39
40
  onChange={(e) => setSearch(e.target.value)}
41
+ onFocus={(e) => e.target.select()}
40
42
  placeholder="Search service desks by name…"
41
43
  aria-label="Search service desks"
42
44
  />