@revenexx/studio-shared 0.1.2 → 0.2.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 +22 -12
- package/dist/module.d.mts +9 -0
- package/dist/module.json +9 -0
- package/dist/module.mjs +27 -0
- package/dist/runtime/components/DataTable/ColumnsMenu.d.vue.ts +12 -0
- package/{components → dist/runtime/components}/DataTable/ColumnsMenu.vue +10 -17
- package/dist/runtime/components/DataTable/ColumnsMenu.vue.d.ts +12 -0
- package/dist/runtime/components/DataTable/DataTable.d.vue.ts +59 -0
- package/dist/runtime/components/DataTable/DataTable.vue +453 -0
- package/dist/runtime/components/DataTable/DataTable.vue.d.ts +59 -0
- package/dist/runtime/components/DataTable/FilterMenu.d.vue.ts +12 -0
- package/{components → dist/runtime/components}/DataTable/FilterMenu.vue +4 -8
- package/dist/runtime/components/DataTable/FilterMenu.vue.d.ts +12 -0
- package/dist/runtime/components/DataTable/types.d.ts +70 -0
- package/dist/runtime/components/DataTable/types.js +0 -0
- package/dist/runtime/components/Shared/BuildLogsFlyout.d.vue.ts +30 -0
- package/{components → dist/runtime/components}/Shared/BuildLogsFlyout.vue +27 -45
- package/dist/runtime/components/Shared/BuildLogsFlyout.vue.d.ts +30 -0
- package/dist/runtime/components/Shared/GitDeploymentSettings.d.vue.ts +17 -0
- package/{components → dist/runtime/components}/Shared/GitDeploymentSettings.vue +22 -35
- package/dist/runtime/components/Shared/GitDeploymentSettings.vue.d.ts +17 -0
- package/dist/runtime/components/Shared/KpiTile.d.vue.ts +13 -0
- package/{components → dist/runtime/components}/Shared/KpiTile.vue +11 -19
- package/dist/runtime/components/Shared/KpiTile.vue.d.ts +13 -0
- package/dist/runtime/components/Shared/PageHeader.d.vue.ts +23 -0
- package/{components → dist/runtime/components}/Shared/PageHeader.vue +6 -8
- package/dist/runtime/components/Shared/PageHeader.vue.d.ts +23 -0
- package/dist/runtime/components/Shared/SidebarNav.d.vue.ts +36 -0
- package/{components → dist/runtime/components}/Shared/SidebarNav.vue +15 -47
- package/dist/runtime/components/Shared/SidebarNav.vue.d.ts +36 -0
- package/dist/runtime/components/Shared/SortHeader.d.vue.ts +23 -0
- package/dist/runtime/components/Shared/SortHeader.vue +35 -0
- package/dist/runtime/components/Shared/SortHeader.vue.d.ts +23 -0
- package/dist/runtime/components/Shared/StateCard.d.vue.ts +32 -0
- package/{components → dist/runtime/components}/Shared/StateCard.vue +21 -36
- package/dist/runtime/components/Shared/StateCard.vue.d.ts +32 -0
- package/dist/runtime/components/Shared/StudioCard.d.vue.ts +15 -0
- package/dist/runtime/components/Shared/StudioCard.vue +19 -0
- package/dist/runtime/components/Shared/StudioCard.vue.d.ts +15 -0
- package/dist/runtime/components/Shared/TabBar.d.vue.ts +23 -0
- package/{components → dist/runtime/components}/Shared/TabBar.vue +7 -16
- package/dist/runtime/components/Shared/TabBar.vue.d.ts +23 -0
- package/dist/runtime/components/Shared/ViewTab.d.vue.ts +7 -0
- package/{components → dist/runtime/components}/Shared/ViewTab.vue +7 -9
- package/dist/runtime/components/Shared/ViewTab.vue.d.ts +7 -0
- package/dist/runtime/components/Shared/Wizard.d.vue.ts +47 -0
- package/{components → dist/runtime/components}/Shared/Wizard.vue +24 -41
- package/dist/runtime/components/Shared/Wizard.vue.d.ts +47 -0
- package/{composables/usePlatformAuth.ts → dist/runtime/composables/usePlatformAuth.d.ts} +3 -21
- package/dist/runtime/composables/usePlatformAuth.js +17 -0
- package/dist/runtime/composables/usePlatformTenant.d.ts +14 -0
- package/dist/runtime/composables/usePlatformTenant.js +18 -0
- package/dist/runtime/types/nav.d.ts +23 -0
- package/dist/runtime/types/nav.js +0 -0
- package/dist/types.d.mts +15 -0
- package/package.json +25 -13
- package/components/DataTable/DataTable.vue +0 -518
- package/components/DataTable/types.ts +0 -82
- package/components/Shared/SortHeader.vue +0 -50
- package/components/Shared/StudioCard.vue +0 -24
- package/composables/usePlatformTenant.ts +0 -35
- package/index.ts +0 -16
- package/nuxt.config.ts +0 -23
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { computed, ref } from 'vue'
|
|
2
|
-
import type { Ref } from 'vue'
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Platform tenant provider — companion to `usePlatformAuth`.
|
|
6
|
-
*
|
|
7
|
-
* Standalone default: the active tenant slug comes from runtime config
|
|
8
|
-
* (`NUXT_PUBLIC_DEV_TENANT`) or `localStorage['cockpit.devTenant']`. The full
|
|
9
|
-
* cockpit overrides this at `app/composables/usePlatformTenant.ts` to return
|
|
10
|
-
* the real active-tenant slug from `useConsoleTenants`.
|
|
11
|
-
*/
|
|
12
|
-
export interface PlatformTenant {
|
|
13
|
-
slug: Ref<string | null>
|
|
14
|
-
load: () => Promise<void>
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export function usePlatformTenant(): PlatformTenant {
|
|
18
|
-
const config = useRuntimeConfig()
|
|
19
|
-
const stored = ref<string | null>(null)
|
|
20
|
-
if (import.meta.client) {
|
|
21
|
-
try {
|
|
22
|
-
stored.value = localStorage.getItem('cockpit.devTenant')
|
|
23
|
-
}
|
|
24
|
-
catch {
|
|
25
|
-
stored.value = null
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
const slug = computed<string | null>(() => (config.public.devTenant as string | undefined) || stored.value)
|
|
29
|
-
return {
|
|
30
|
-
slug: slug as unknown as Ref<string | null>,
|
|
31
|
-
async load() {
|
|
32
|
-
// no-op in standalone; the slug is static from config/localStorage.
|
|
33
|
-
},
|
|
34
|
-
}
|
|
35
|
-
}
|
package/index.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Type-level barrel for `@revenexx/studio-shared`.
|
|
3
|
-
*
|
|
4
|
-
* The shell primitive *components* auto-import by bare name via the Nuxt
|
|
5
|
-
* layer (see `nuxt.config.ts`). This barrel exposes the *types* consumers
|
|
6
|
-
* need to import explicitly — DataTable column/filter/sort types and the
|
|
7
|
-
* SidebarNav section/item shapes.
|
|
8
|
-
*/
|
|
9
|
-
export type * from './components/DataTable/types'
|
|
10
|
-
export type { SidebarNavItem, SidebarNavSection } from './components/Shared/SidebarNav.vue'
|
|
11
|
-
export type { PlatformAuth } from './composables/usePlatformAuth'
|
|
12
|
-
export type { PlatformTenant } from './composables/usePlatformTenant'
|
|
13
|
-
// NOTE: components are NOT value-exported here — this barrel is loaded in node
|
|
14
|
-
// contexts (types/config) where a `.vue` import fails. The studio modules that
|
|
15
|
-
// need a component explicitly import it via the `./components/*` subpath export
|
|
16
|
-
// (Vite-only), e.g. `@revenexx/studio-shared/components/Shared/SidebarNav.vue`.
|
package/nuxt.config.ts
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { fileURLToPath } from 'node:url'
|
|
2
|
-
import { dirname, join } from 'node:path'
|
|
3
|
-
|
|
4
|
-
const currentDir = dirname(fileURLToPath(import.meta.url))
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Shared cockpit shell primitives, provided as a Nuxt layer.
|
|
8
|
-
*
|
|
9
|
-
* Components are auto-imported by their **bare** name (`pathPrefix: false`),
|
|
10
|
-
* so `<PageHeader>`, `<DataTable>`, `<SidebarNav>`, `<StateCard>`, `<TabBar>`,
|
|
11
|
-
* … resolve without an explicit import — matching how the cockpit already
|
|
12
|
-
* uses them. Type-level exports (DataTable column/filter types,
|
|
13
|
-
* SidebarNavSection) come from the package barrel `@revenexx/studio-shared`.
|
|
14
|
-
*/
|
|
15
|
-
export default defineNuxtConfig({
|
|
16
|
-
$meta: {
|
|
17
|
-
name: 'studio-shared',
|
|
18
|
-
description: 'Shared cockpit shell primitives + design-system wiring.',
|
|
19
|
-
},
|
|
20
|
-
components: [
|
|
21
|
-
{ path: join(currentDir, 'components'), pathPrefix: false },
|
|
22
|
-
],
|
|
23
|
-
})
|