@perses-dev/core 0.53.1 → 0.54.0-beta.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.
Files changed (104) hide show
  1. package/dist/cjs/constants/dashboard-defaults.js +3 -3
  2. package/dist/cjs/model/calculations.js +6 -6
  3. package/dist/cjs/model/definitions.js +1 -3
  4. package/dist/cjs/model/folder.js +16 -0
  5. package/dist/cjs/model/index.js +1 -0
  6. package/dist/cjs/model/legend.js +11 -11
  7. package/dist/cjs/model/otlp/index.js +4 -4
  8. package/dist/cjs/model/otlp/trace/v1/trace.js +4 -4
  9. package/dist/cjs/model/resource.js +3 -3
  10. package/dist/cjs/model/roles.js +4 -4
  11. package/dist/cjs/model/time.js +21 -309
  12. package/dist/cjs/model/units/bits.js +4 -4
  13. package/dist/cjs/model/units/bytes.js +4 -4
  14. package/dist/cjs/model/units/currency.js +4 -4
  15. package/dist/cjs/model/units/date.js +4 -4
  16. package/dist/cjs/model/units/decimal.js +4 -4
  17. package/dist/cjs/model/units/formatterCache.js +3 -3
  18. package/dist/cjs/model/units/percent.js +4 -4
  19. package/dist/cjs/model/units/temperature.js +4 -4
  20. package/dist/cjs/model/units/throughput.js +4 -4
  21. package/dist/cjs/model/units/time.js +5 -5
  22. package/dist/cjs/model/units/units.js +18 -18
  23. package/dist/cjs/model/units/utils.js +4 -4
  24. package/dist/cjs/model/variables.js +3 -3
  25. package/dist/cjs/schema/datasource.js +13 -29
  26. package/dist/cjs/schema/display.js +2 -6
  27. package/dist/cjs/schema/duration.js +2 -4
  28. package/dist/cjs/schema/metadata.js +4 -4
  29. package/dist/cjs/schema/panel.js +20 -73
  30. package/dist/cjs/schema/plugin.js +2 -6
  31. package/dist/cjs/schema/role.js +6 -6
  32. package/dist/cjs/schema/rolebinding.js +6 -6
  33. package/dist/cjs/schema/secret.js +5 -5
  34. package/dist/cjs/schema/user.js +5 -5
  35. package/dist/cjs/schema/variable.js +24 -137
  36. package/dist/cjs/utils/fetch.js +5 -5
  37. package/dist/cjs/utils/panel-refs.js +4 -4
  38. package/dist/cjs/utils/regexp.js +3 -3
  39. package/dist/cjs/utils/text.js +7 -7
  40. package/dist/cjs/utils/time-series-data.js +4 -4
  41. package/dist/cjs/utils/transform-data.js +6 -6
  42. package/dist/model/dashboard.d.ts +2 -21
  43. package/dist/model/dashboard.d.ts.map +1 -1
  44. package/dist/model/dashboard.js.map +1 -1
  45. package/dist/model/datasource.d.ts +3 -22
  46. package/dist/model/datasource.d.ts.map +1 -1
  47. package/dist/model/datasource.js +1 -3
  48. package/dist/model/datasource.js.map +1 -1
  49. package/dist/model/definitions.d.ts +1 -12
  50. package/dist/model/definitions.d.ts.map +1 -1
  51. package/dist/model/definitions.js +1 -6
  52. package/dist/model/definitions.js.map +1 -1
  53. package/dist/model/display.d.ts +1 -4
  54. package/dist/model/display.d.ts.map +1 -1
  55. package/dist/model/display.js.map +1 -1
  56. package/dist/model/folder.d.ts +19 -0
  57. package/dist/model/folder.d.ts.map +1 -0
  58. package/dist/model/folder.js +15 -0
  59. package/dist/model/folder.js.map +1 -0
  60. package/dist/model/index.d.ts +1 -0
  61. package/dist/model/index.d.ts.map +1 -1
  62. package/dist/model/index.js +1 -0
  63. package/dist/model/index.js.map +1 -1
  64. package/dist/model/project.d.ts +1 -1
  65. package/dist/model/project.d.ts.map +1 -1
  66. package/dist/model/project.js.map +1 -1
  67. package/dist/model/resource.d.ts +1 -1
  68. package/dist/model/resource.d.ts.map +1 -1
  69. package/dist/model/resource.js.map +1 -1
  70. package/dist/model/time.d.ts +3 -54
  71. package/dist/model/time.d.ts.map +1 -1
  72. package/dist/model/time.js +2 -299
  73. package/dist/model/time.js.map +1 -1
  74. package/dist/schema/datasource.d.ts +10 -9
  75. package/dist/schema/datasource.d.ts.map +1 -1
  76. package/dist/schema/datasource.js +2 -14
  77. package/dist/schema/datasource.js.map +1 -1
  78. package/dist/schema/display.d.ts +1 -11
  79. package/dist/schema/display.d.ts.map +1 -1
  80. package/dist/schema/display.js +1 -5
  81. package/dist/schema/display.js.map +1 -1
  82. package/dist/schema/duration.d.ts +1 -2
  83. package/dist/schema/duration.d.ts.map +1 -1
  84. package/dist/schema/duration.js +1 -3
  85. package/dist/schema/duration.js.map +1 -1
  86. package/dist/schema/panel.d.ts +1 -12
  87. package/dist/schema/panel.d.ts.map +1 -1
  88. package/dist/schema/panel.js +1 -54
  89. package/dist/schema/panel.js.map +1 -1
  90. package/dist/schema/plugin.d.ts +2 -13
  91. package/dist/schema/plugin.d.ts.map +1 -1
  92. package/dist/schema/plugin.js +1 -5
  93. package/dist/schema/plugin.js.map +1 -1
  94. package/dist/schema/role.d.ts +4 -4
  95. package/dist/schema/rolebinding.d.ts +4 -4
  96. package/dist/schema/secret.d.ts +70 -70
  97. package/dist/schema/variable.d.ts +1 -91
  98. package/dist/schema/variable.d.ts.map +1 -1
  99. package/dist/schema/variable.js +1 -105
  100. package/dist/schema/variable.js.map +1 -1
  101. package/dist/utils/fetch.js.map +1 -1
  102. package/dist/utils/text.js +4 -4
  103. package/dist/utils/text.js.map +1 -1
  104. package/package.json +3 -2
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/schema/duration.ts"],"sourcesContent":["// Copyright The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { z } from 'zod';\nimport { DURATION_REGEX } from '../model';\n\nexport const durationValidationSchema = z\n .string()\n .min(1, 'Required')\n .regex(DURATION_REGEX, 'Must be a valid duration string');\n"],"names":["z","DURATION_REGEX","durationValidationSchema","string","min","regex"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,CAAC,QAAQ,MAAM;AACxB,SAASC,cAAc,QAAQ,WAAW;AAE1C,OAAO,MAAMC,2BAA2BF,EACrCG,MAAM,GACNC,GAAG,CAAC,GAAG,YACPC,KAAK,CAACJ,gBAAgB,mCAAmC"}
1
+ {"version":3,"sources":["../../src/schema/duration.ts"],"sourcesContent":["// Copyright The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport { durationValidationSchema } from '@perses-dev/spec';\n"],"names":["durationValidationSchema"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,wBAAwB,QAAQ,mBAAmB"}
@@ -1,13 +1,2 @@
1
- import { z } from 'zod';
2
- import { Link, PanelDefinition, PanelDisplay, PanelEditorValues, PanelSpec, QueryDefinition } from '../model';
3
- import { PluginSchema } from './plugin';
4
- export declare const panelDisplaySpec: z.ZodSchema<PanelDisplay>;
5
- export declare const querySpecSchema: z.ZodSchema<QueryDefinition>;
6
- export declare const linkSchema: z.ZodSchema<Link>;
7
- export declare const panelSpecSchema: z.ZodSchema<PanelSpec>;
8
- export declare function buildPanelSpecSchema(pluginSchema: PluginSchema): z.ZodSchema<PanelSpec>;
9
- export declare const panelDefinitionSchema: z.ZodSchema<PanelDefinition>;
10
- export declare function buildPanelDefinitionSchema(pluginSchema: PluginSchema): z.ZodSchema<PanelDefinition>;
11
- export declare const panelEditorSchema: z.ZodSchema<PanelEditorValues>;
12
- export declare function buildPanelEditorSchema(pluginSchema: PluginSchema): z.ZodSchema<PanelEditorValues>;
1
+ export { panelDisplaySpec, querySpecSchema, linkSchema, panelSpecSchema, buildPanelSpecSchema, panelDefinitionSchema, buildPanelDefinitionSchema, panelEditorSchema, buildPanelEditorSchema, } from '@perses-dev/spec';
13
2
  //# sourceMappingURL=panel.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"panel.d.ts","sourceRoot":"","sources":["../../src/schema/panel.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,IAAI,EAAE,eAAe,EAAE,YAAY,EAAE,iBAAiB,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC9G,OAAO,EAAE,YAAY,EAAgB,MAAM,UAAU,CAAC;AAEtD,eAAO,MAAM,gBAAgB,EAAE,CAAC,CAAC,SAAS,CAAC,YAAY,CAGrD,CAAC;AAEH,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,SAAS,CAAC,eAAe,CAMvD,CAAC;AAEH,eAAO,MAAM,UAAU,EAAE,CAAC,CAAC,SAAS,CAAC,IAAI,CAMvC,CAAC;AAEH,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,SAAS,CAAC,SAAS,CAKjD,CAAC;AAEH,wBAAgB,oBAAoB,CAAC,YAAY,EAAE,YAAY,GAAG,CAAC,CAAC,SAAS,CAAC,SAAS,CAAC,CAOvF;AAED,eAAO,MAAM,qBAAqB,EAAE,CAAC,CAAC,SAAS,CAAC,eAAe,CAG7D,CAAC;AAEH,wBAAgB,0BAA0B,CAAC,YAAY,EAAE,YAAY,GAAG,CAAC,CAAC,SAAS,CAAC,eAAe,CAAC,CAKnG;AAED,eAAO,MAAM,iBAAiB,EAAE,CAAC,CAAC,SAAS,CAAC,iBAAiB,CAG3D,CAAC;AAEH,wBAAgB,sBAAsB,CAAC,YAAY,EAAE,YAAY,GAAG,CAAC,CAAC,SAAS,CAAC,iBAAiB,CAAC,CAKjG"}
1
+ {"version":3,"file":"panel.d.ts","sourceRoot":"","sources":["../../src/schema/panel.ts"],"names":[],"mappings":"AAaA,OAAO,EACL,gBAAgB,EAChB,eAAe,EACf,UAAU,EACV,eAAe,EACf,oBAAoB,EACpB,qBAAqB,EACrB,0BAA0B,EAC1B,iBAAiB,EACjB,sBAAsB,GACvB,MAAM,kBAAkB,CAAC"}
@@ -10,59 +10,6 @@
10
10
  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
- import { z } from 'zod';
14
- import { pluginSchema } from './plugin';
15
- export const panelDisplaySpec = z.object({
16
- name: z.string().optional(),
17
- description: z.string().optional()
18
- });
19
- export const querySpecSchema = z.object({
20
- kind: z.string().min(1),
21
- spec: z.object({
22
- name: z.string().optional(),
23
- plugin: pluginSchema
24
- })
25
- });
26
- export const linkSchema = z.object({
27
- name: z.string().optional(),
28
- url: z.string().min(1),
29
- tooltip: z.string().optional(),
30
- renderVariables: z.boolean().optional(),
31
- targetBlank: z.boolean().optional()
32
- });
33
- export const panelSpecSchema = z.object({
34
- display: panelDisplaySpec.optional(),
35
- plugin: pluginSchema,
36
- queries: z.array(querySpecSchema).optional(),
37
- links: z.array(linkSchema).optional()
38
- });
39
- export function buildPanelSpecSchema(pluginSchema) {
40
- return z.object({
41
- display: panelDisplaySpec.optional(),
42
- plugin: pluginSchema,
43
- queries: z.array(querySpecSchema).optional(),
44
- links: z.array(linkSchema).optional()
45
- });
46
- }
47
- export const panelDefinitionSchema = z.object({
48
- kind: z.literal('Panel'),
49
- spec: panelSpecSchema
50
- });
51
- export function buildPanelDefinitionSchema(pluginSchema) {
52
- return z.object({
53
- kind: z.literal('Panel'),
54
- spec: buildPanelSpecSchema(pluginSchema)
55
- });
56
- }
57
- export const panelEditorSchema = z.object({
58
- groupId: z.number(),
59
- panelDefinition: panelDefinitionSchema
60
- });
61
- export function buildPanelEditorSchema(pluginSchema) {
62
- return z.object({
63
- groupId: z.number(),
64
- panelDefinition: buildPanelDefinitionSchema(pluginSchema)
65
- });
66
- }
13
+ export { panelDisplaySpec, querySpecSchema, linkSchema, panelSpecSchema, buildPanelSpecSchema, panelDefinitionSchema, buildPanelDefinitionSchema, panelEditorSchema, buildPanelEditorSchema } from '@perses-dev/spec';
67
14
 
68
15
  //# sourceMappingURL=panel.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/schema/panel.ts"],"sourcesContent":["// Copyright The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { z } from 'zod';\nimport { Link, PanelDefinition, PanelDisplay, PanelEditorValues, PanelSpec, QueryDefinition } from '../model';\nimport { PluginSchema, pluginSchema } from './plugin';\n\nexport const panelDisplaySpec: z.ZodSchema<PanelDisplay> = z.object({\n name: z.string().optional(),\n description: z.string().optional(),\n});\n\nexport const querySpecSchema: z.ZodSchema<QueryDefinition> = z.object({\n kind: z.string().min(1),\n spec: z.object({\n name: z.string().optional(),\n plugin: pluginSchema,\n }),\n});\n\nexport const linkSchema: z.ZodSchema<Link> = z.object({\n name: z.string().optional(),\n url: z.string().min(1),\n tooltip: z.string().optional(),\n renderVariables: z.boolean().optional(),\n targetBlank: z.boolean().optional(),\n});\n\nexport const panelSpecSchema: z.ZodSchema<PanelSpec> = z.object({\n display: panelDisplaySpec.optional(),\n plugin: pluginSchema,\n queries: z.array(querySpecSchema).optional(),\n links: z.array(linkSchema).optional(),\n});\n\nexport function buildPanelSpecSchema(pluginSchema: PluginSchema): z.ZodSchema<PanelSpec> {\n return z.object({\n display: panelDisplaySpec.optional(),\n plugin: pluginSchema,\n queries: z.array(querySpecSchema).optional(),\n links: z.array(linkSchema).optional(),\n });\n}\n\nexport const panelDefinitionSchema: z.ZodSchema<PanelDefinition> = z.object({\n kind: z.literal('Panel'),\n spec: panelSpecSchema,\n});\n\nexport function buildPanelDefinitionSchema(pluginSchema: PluginSchema): z.ZodSchema<PanelDefinition> {\n return z.object({\n kind: z.literal('Panel'),\n spec: buildPanelSpecSchema(pluginSchema),\n });\n}\n\nexport const panelEditorSchema: z.ZodSchema<PanelEditorValues> = z.object({\n groupId: z.number(),\n panelDefinition: panelDefinitionSchema,\n});\n\nexport function buildPanelEditorSchema(pluginSchema: PluginSchema): z.ZodSchema<PanelEditorValues> {\n return z.object({\n groupId: z.number(),\n panelDefinition: buildPanelDefinitionSchema(pluginSchema),\n });\n}\n"],"names":["z","pluginSchema","panelDisplaySpec","object","name","string","optional","description","querySpecSchema","kind","min","spec","plugin","linkSchema","url","tooltip","renderVariables","boolean","targetBlank","panelSpecSchema","display","queries","array","links","buildPanelSpecSchema","panelDefinitionSchema","literal","buildPanelDefinitionSchema","panelEditorSchema","groupId","number","panelDefinition","buildPanelEditorSchema"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,CAAC,QAAQ,MAAM;AAExB,SAAuBC,YAAY,QAAQ,WAAW;AAEtD,OAAO,MAAMC,mBAA8CF,EAAEG,MAAM,CAAC;IAClEC,MAAMJ,EAAEK,MAAM,GAAGC,QAAQ;IACzBC,aAAaP,EAAEK,MAAM,GAAGC,QAAQ;AAClC,GAAG;AAEH,OAAO,MAAME,kBAAgDR,EAAEG,MAAM,CAAC;IACpEM,MAAMT,EAAEK,MAAM,GAAGK,GAAG,CAAC;IACrBC,MAAMX,EAAEG,MAAM,CAAC;QACbC,MAAMJ,EAAEK,MAAM,GAAGC,QAAQ;QACzBM,QAAQX;IACV;AACF,GAAG;AAEH,OAAO,MAAMY,aAAgCb,EAAEG,MAAM,CAAC;IACpDC,MAAMJ,EAAEK,MAAM,GAAGC,QAAQ;IACzBQ,KAAKd,EAAEK,MAAM,GAAGK,GAAG,CAAC;IACpBK,SAASf,EAAEK,MAAM,GAAGC,QAAQ;IAC5BU,iBAAiBhB,EAAEiB,OAAO,GAAGX,QAAQ;IACrCY,aAAalB,EAAEiB,OAAO,GAAGX,QAAQ;AACnC,GAAG;AAEH,OAAO,MAAMa,kBAA0CnB,EAAEG,MAAM,CAAC;IAC9DiB,SAASlB,iBAAiBI,QAAQ;IAClCM,QAAQX;IACRoB,SAASrB,EAAEsB,KAAK,CAACd,iBAAiBF,QAAQ;IAC1CiB,OAAOvB,EAAEsB,KAAK,CAACT,YAAYP,QAAQ;AACrC,GAAG;AAEH,OAAO,SAASkB,qBAAqBvB,YAA0B;IAC7D,OAAOD,EAAEG,MAAM,CAAC;QACdiB,SAASlB,iBAAiBI,QAAQ;QAClCM,QAAQX;QACRoB,SAASrB,EAAEsB,KAAK,CAACd,iBAAiBF,QAAQ;QAC1CiB,OAAOvB,EAAEsB,KAAK,CAACT,YAAYP,QAAQ;IACrC;AACF;AAEA,OAAO,MAAMmB,wBAAsDzB,EAAEG,MAAM,CAAC;IAC1EM,MAAMT,EAAE0B,OAAO,CAAC;IAChBf,MAAMQ;AACR,GAAG;AAEH,OAAO,SAASQ,2BAA2B1B,YAA0B;IACnE,OAAOD,EAAEG,MAAM,CAAC;QACdM,MAAMT,EAAE0B,OAAO,CAAC;QAChBf,MAAMa,qBAAqBvB;IAC7B;AACF;AAEA,OAAO,MAAM2B,oBAAoD5B,EAAEG,MAAM,CAAC;IACxE0B,SAAS7B,EAAE8B,MAAM;IACjBC,iBAAiBN;AACnB,GAAG;AAEH,OAAO,SAASO,uBAAuB/B,YAA0B;IAC/D,OAAOD,EAAEG,MAAM,CAAC;QACd0B,SAAS7B,EAAE8B,MAAM;QACjBC,iBAAiBJ,2BAA2B1B;IAC9C;AACF"}
1
+ {"version":3,"sources":["../../src/schema/panel.ts"],"sourcesContent":["// Copyright The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport {\n panelDisplaySpec,\n querySpecSchema,\n linkSchema,\n panelSpecSchema,\n buildPanelSpecSchema,\n panelDefinitionSchema,\n buildPanelDefinitionSchema,\n panelEditorSchema,\n buildPanelEditorSchema,\n} from '@perses-dev/spec';\n"],"names":["panelDisplaySpec","querySpecSchema","linkSchema","panelSpecSchema","buildPanelSpecSchema","panelDefinitionSchema","buildPanelDefinitionSchema","panelEditorSchema","buildPanelEditorSchema"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SACEA,gBAAgB,EAChBC,eAAe,EACfC,UAAU,EACVC,eAAe,EACfC,oBAAoB,EACpBC,qBAAqB,EACrBC,0BAA0B,EAC1BC,iBAAiB,EACjBC,sBAAsB,QACjB,mBAAmB"}
@@ -1,14 +1,3 @@
1
- import { z } from 'zod';
2
- export declare const pluginSchema: z.ZodObject<{
3
- kind: z.ZodString;
4
- spec: z.ZodRecord<z.ZodString, z.ZodAny>;
5
- }, "strip", z.ZodTypeAny, {
6
- kind: string;
7
- spec: Record<string, any>;
8
- }, {
9
- kind: string;
10
- spec: Record<string, any>;
11
- }>;
12
- export type PluginSchemaType = z.infer<typeof pluginSchema>;
13
- export type PluginSchema = typeof pluginSchema;
1
+ export { pluginSchema } from '@perses-dev/spec';
2
+ export type { PluginSchemaType, PluginSchema } from '@perses-dev/spec';
14
3
  //# sourceMappingURL=plugin.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../src/schema/plugin.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,YAAY;;;;;;;;;EAGvB,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAC5D,MAAM,MAAM,YAAY,GAAG,OAAO,YAAY,CAAC"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../src/schema/plugin.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,YAAY,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC"}
@@ -10,10 +10,6 @@
10
10
  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
- import { z } from 'zod';
14
- export const pluginSchema = z.object({
15
- kind: z.string().min(1, 'Required'),
16
- spec: z.record(z.string(), z.any())
17
- });
13
+ export { pluginSchema } from '@perses-dev/spec';
18
14
 
19
15
  //# sourceMappingURL=plugin.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/schema/plugin.ts"],"sourcesContent":["// Copyright The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { z } from 'zod';\n\nexport const pluginSchema = z.object({\n kind: z.string().min(1, 'Required'),\n spec: z.record(z.string(), z.any()),\n});\n\nexport type PluginSchemaType = z.infer<typeof pluginSchema>;\nexport type PluginSchema = typeof pluginSchema;\n"],"names":["z","pluginSchema","object","kind","string","min","spec","record","any"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,CAAC,QAAQ,MAAM;AAExB,OAAO,MAAMC,eAAeD,EAAEE,MAAM,CAAC;IACnCC,MAAMH,EAAEI,MAAM,GAAGC,GAAG,CAAC,GAAG;IACxBC,MAAMN,EAAEO,MAAM,CAACP,EAAEI,MAAM,IAAIJ,EAAEQ,GAAG;AAClC,GAAG"}
1
+ {"version":3,"sources":["../../src/schema/plugin.ts"],"sourcesContent":["// Copyright The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport { pluginSchema } from '@perses-dev/spec';\nexport type { PluginSchemaType, PluginSchema } from '@perses-dev/spec';\n"],"names":["pluginSchema"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,YAAY,QAAQ,mBAAmB"}
@@ -18,18 +18,18 @@ export declare const roleSchema: z.ZodObject<{
18
18
  spec: z.ZodType<RoleSpec, z.ZodTypeDef, RoleSpec>;
19
19
  }, "strip", z.ZodTypeAny, {
20
20
  kind: "Role";
21
- spec: RoleSpec;
22
21
  metadata: {
23
22
  name: string;
24
23
  project: string;
25
24
  };
25
+ spec: RoleSpec;
26
26
  }, {
27
27
  kind: "Role";
28
- spec: RoleSpec;
29
28
  metadata: {
30
29
  name: string;
31
30
  project: string;
32
31
  };
32
+ spec: RoleSpec;
33
33
  }>;
34
34
  export declare const globalRoleSchema: z.ZodObject<{
35
35
  kind: z.ZodLiteral<"GlobalRole">;
@@ -43,16 +43,16 @@ export declare const globalRoleSchema: z.ZodObject<{
43
43
  spec: z.ZodType<RoleSpec, z.ZodTypeDef, RoleSpec>;
44
44
  }, "strip", z.ZodTypeAny, {
45
45
  kind: "GlobalRole";
46
- spec: RoleSpec;
47
46
  metadata: {
48
47
  name: string;
49
48
  };
49
+ spec: RoleSpec;
50
50
  }, {
51
51
  kind: "GlobalRole";
52
- spec: RoleSpec;
53
52
  metadata: {
54
53
  name: string;
55
54
  };
55
+ spec: RoleSpec;
56
56
  }>;
57
57
  export declare const rolesEditorSchema: z.ZodSchema<Role>;
58
58
  //# sourceMappingURL=role.d.ts.map
@@ -18,18 +18,18 @@ export declare const roleBindingSchema: z.ZodObject<{
18
18
  spec: z.ZodType<RoleBindingSpec, z.ZodTypeDef, RoleBindingSpec>;
19
19
  }, "strip", z.ZodTypeAny, {
20
20
  kind: "RoleBinding";
21
- spec: RoleBindingSpec;
22
21
  metadata: {
23
22
  name: string;
24
23
  project: string;
25
24
  };
25
+ spec: RoleBindingSpec;
26
26
  }, {
27
27
  kind: "RoleBinding";
28
- spec: RoleBindingSpec;
29
28
  metadata: {
30
29
  name: string;
31
30
  project: string;
32
31
  };
32
+ spec: RoleBindingSpec;
33
33
  }>;
34
34
  export declare const globalRoleBindingSchema: z.ZodObject<{
35
35
  kind: z.ZodLiteral<"GlobalRoleBinding">;
@@ -43,16 +43,16 @@ export declare const globalRoleBindingSchema: z.ZodObject<{
43
43
  spec: z.ZodType<RoleBindingSpec, z.ZodTypeDef, RoleBindingSpec>;
44
44
  }, "strip", z.ZodTypeAny, {
45
45
  kind: "GlobalRoleBinding";
46
- spec: RoleBindingSpec;
47
46
  metadata: {
48
47
  name: string;
49
48
  };
49
+ spec: RoleBindingSpec;
50
50
  }, {
51
51
  kind: "GlobalRoleBinding";
52
- spec: RoleBindingSpec;
53
52
  metadata: {
54
53
  name: string;
55
54
  };
55
+ spec: RoleBindingSpec;
56
56
  }>;
57
57
  export declare const roleBindingsEditorSchema: z.ZodSchema<RoleBinding>;
58
58
  //# sourceMappingURL=rolebinding.d.ts.map