@backstage/plugin-notifications-common 0.0.10 → 0.1.1-next.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/CHANGELOG.md +13 -0
- package/dist/constants.cjs.js.map +1 -1
- package/dist/constants.esm.js.map +1 -1
- package/dist/filters.cjs.js.map +1 -1
- package/dist/filters.esm.js.map +1 -1
- package/dist/index.d.ts +7 -0
- package/dist/utils.cjs.js.map +1 -1
- package/dist/utils.esm.js.map +1 -1
- package/package.json +4 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# @backstage/plugin-notifications-common
|
|
2
2
|
|
|
3
|
+
## 0.1.1-next.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
- @backstage/config@1.3.4-next.0
|
|
9
|
+
|
|
10
|
+
## 0.1.0
|
|
11
|
+
|
|
12
|
+
### Minor Changes
|
|
13
|
+
|
|
14
|
+
- 9152ba8: Add an optional generic object `metadata` field to `NotificationPayload`. Metadata can be used to store additional unstructured data for the notification and are available to use by processors.
|
|
15
|
+
|
|
3
16
|
## 0.0.10
|
|
4
17
|
|
|
5
18
|
### Patch Changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.cjs.js","sources":["../src/constants.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSeverity } from './types';\n\n/** Ordered list of severities used by the Notifications.\n *\n * @public */\nexport const notificationSeverities: NotificationSeverity[] = [\n 'critical',\n 'high',\n 'normal',\n 'low',\n];\n"],"names":[],"mappings":";;AAoBO,MAAM,
|
|
1
|
+
{"version":3,"file":"constants.cjs.js","sources":["../src/constants.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSeverity } from './types';\n\n/** Ordered list of severities used by the Notifications.\n *\n * @public */\nexport const notificationSeverities: NotificationSeverity[] = [\n 'critical',\n 'high',\n 'normal',\n 'low',\n];\n"],"names":[],"mappings":";;AAoBO,MAAM,sBAAA,GAAiD;AAAA,EAC5D,UAAA;AAAA,EACA,MAAA;AAAA,EACA,QAAA;AAAA,EACA;AACF;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.esm.js","sources":["../src/constants.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSeverity } from './types';\n\n/** Ordered list of severities used by the Notifications.\n *\n * @public */\nexport const notificationSeverities: NotificationSeverity[] = [\n 'critical',\n 'high',\n 'normal',\n 'low',\n];\n"],"names":[],"mappings":"AAoBO,MAAM,
|
|
1
|
+
{"version":3,"file":"constants.esm.js","sources":["../src/constants.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSeverity } from './types';\n\n/** Ordered list of severities used by the Notifications.\n *\n * @public */\nexport const notificationSeverities: NotificationSeverity[] = [\n 'critical',\n 'high',\n 'normal',\n 'low',\n];\n"],"names":[],"mappings":"AAoBO,MAAM,sBAAA,GAAiD;AAAA,EAC5D,UAAA;AAAA,EACA,MAAA;AAAA,EACA,QAAA;AAAA,EACA;AACF;;;;"}
|
package/dist/filters.cjs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filters.cjs.js","sources":["../src/filters.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { Config } from '@backstage/config';\nimport { NotificationProcessorFilters, NotificationSeverity } from './types';\nimport { notificationSeverities } from './constants';\n\n/** @public */\nexport const getProcessorFiltersFromConfig = (config: Config) => {\n const filter: NotificationProcessorFilters = {};\n const minSeverity = config.getOptionalString(\n 'filter.minSeverity',\n ) as NotificationSeverity;\n if (minSeverity) {\n if (notificationSeverities.includes(minSeverity)) {\n filter.minSeverity = minSeverity;\n } else {\n throw new Error(`Invalid minSeverity: ${minSeverity}`);\n }\n }\n const maxSeverity = config.getOptionalString(\n 'filter.maxSeverity',\n ) as NotificationSeverity;\n if (maxSeverity) {\n if (notificationSeverities.includes(maxSeverity)) {\n filter.maxSeverity = maxSeverity;\n } else {\n throw new Error(`Invalid maxSeverity: ${maxSeverity}`);\n }\n }\n filter.excludedTopics = config.getOptionalStringArray(\n 'filter.excludedTopics',\n );\n return filter;\n};\n"],"names":["notificationSeverities"],"mappings":";;;;
|
|
1
|
+
{"version":3,"file":"filters.cjs.js","sources":["../src/filters.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { Config } from '@backstage/config';\nimport { NotificationProcessorFilters, NotificationSeverity } from './types';\nimport { notificationSeverities } from './constants';\n\n/** @public */\nexport const getProcessorFiltersFromConfig = (config: Config) => {\n const filter: NotificationProcessorFilters = {};\n const minSeverity = config.getOptionalString(\n 'filter.minSeverity',\n ) as NotificationSeverity;\n if (minSeverity) {\n if (notificationSeverities.includes(minSeverity)) {\n filter.minSeverity = minSeverity;\n } else {\n throw new Error(`Invalid minSeverity: ${minSeverity}`);\n }\n }\n const maxSeverity = config.getOptionalString(\n 'filter.maxSeverity',\n ) as NotificationSeverity;\n if (maxSeverity) {\n if (notificationSeverities.includes(maxSeverity)) {\n filter.maxSeverity = maxSeverity;\n } else {\n throw new Error(`Invalid maxSeverity: ${maxSeverity}`);\n }\n }\n filter.excludedTopics = config.getOptionalStringArray(\n 'filter.excludedTopics',\n );\n return filter;\n};\n"],"names":["notificationSeverities"],"mappings":";;;;AAoBO,MAAM,6BAAA,GAAgC,CAAC,MAAA,KAAmB;AAC/D,EAAA,MAAM,SAAuC,EAAC;AAC9C,EAAA,MAAM,cAAc,MAAA,CAAO,iBAAA;AAAA,IACzB;AAAA,GACF;AACA,EAAA,IAAI,WAAA,EAAa;AACf,IAAA,IAAIA,gCAAA,CAAuB,QAAA,CAAS,WAAW,CAAA,EAAG;AAChD,MAAA,MAAA,CAAO,WAAA,GAAc,WAAA;AAAA,IACvB,CAAA,MAAO;AACL,MAAA,MAAM,IAAI,KAAA,CAAM,CAAA,qBAAA,EAAwB,WAAW,CAAA,CAAE,CAAA;AAAA,IACvD;AAAA,EACF;AACA,EAAA,MAAM,cAAc,MAAA,CAAO,iBAAA;AAAA,IACzB;AAAA,GACF;AACA,EAAA,IAAI,WAAA,EAAa;AACf,IAAA,IAAIA,gCAAA,CAAuB,QAAA,CAAS,WAAW,CAAA,EAAG;AAChD,MAAA,MAAA,CAAO,WAAA,GAAc,WAAA;AAAA,IACvB,CAAA,MAAO;AACL,MAAA,MAAM,IAAI,KAAA,CAAM,CAAA,qBAAA,EAAwB,WAAW,CAAA,CAAE,CAAA;AAAA,IACvD;AAAA,EACF;AACA,EAAA,MAAA,CAAO,iBAAiB,MAAA,CAAO,sBAAA;AAAA,IAC7B;AAAA,GACF;AACA,EAAA,OAAO,MAAA;AACT;;;;"}
|
package/dist/filters.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filters.esm.js","sources":["../src/filters.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { Config } from '@backstage/config';\nimport { NotificationProcessorFilters, NotificationSeverity } from './types';\nimport { notificationSeverities } from './constants';\n\n/** @public */\nexport const getProcessorFiltersFromConfig = (config: Config) => {\n const filter: NotificationProcessorFilters = {};\n const minSeverity = config.getOptionalString(\n 'filter.minSeverity',\n ) as NotificationSeverity;\n if (minSeverity) {\n if (notificationSeverities.includes(minSeverity)) {\n filter.minSeverity = minSeverity;\n } else {\n throw new Error(`Invalid minSeverity: ${minSeverity}`);\n }\n }\n const maxSeverity = config.getOptionalString(\n 'filter.maxSeverity',\n ) as NotificationSeverity;\n if (maxSeverity) {\n if (notificationSeverities.includes(maxSeverity)) {\n filter.maxSeverity = maxSeverity;\n } else {\n throw new Error(`Invalid maxSeverity: ${maxSeverity}`);\n }\n }\n filter.excludedTopics = config.getOptionalStringArray(\n 'filter.excludedTopics',\n );\n return filter;\n};\n"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"filters.esm.js","sources":["../src/filters.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { Config } from '@backstage/config';\nimport { NotificationProcessorFilters, NotificationSeverity } from './types';\nimport { notificationSeverities } from './constants';\n\n/** @public */\nexport const getProcessorFiltersFromConfig = (config: Config) => {\n const filter: NotificationProcessorFilters = {};\n const minSeverity = config.getOptionalString(\n 'filter.minSeverity',\n ) as NotificationSeverity;\n if (minSeverity) {\n if (notificationSeverities.includes(minSeverity)) {\n filter.minSeverity = minSeverity;\n } else {\n throw new Error(`Invalid minSeverity: ${minSeverity}`);\n }\n }\n const maxSeverity = config.getOptionalString(\n 'filter.maxSeverity',\n ) as NotificationSeverity;\n if (maxSeverity) {\n if (notificationSeverities.includes(maxSeverity)) {\n filter.maxSeverity = maxSeverity;\n } else {\n throw new Error(`Invalid maxSeverity: ${maxSeverity}`);\n }\n }\n filter.excludedTopics = config.getOptionalStringArray(\n 'filter.excludedTopics',\n );\n return filter;\n};\n"],"names":[],"mappings":";;AAoBO,MAAM,6BAAA,GAAgC,CAAC,MAAA,KAAmB;AAC/D,EAAA,MAAM,SAAuC,EAAC;AAC9C,EAAA,MAAM,cAAc,MAAA,CAAO,iBAAA;AAAA,IACzB;AAAA,GACF;AACA,EAAA,IAAI,WAAA,EAAa;AACf,IAAA,IAAI,sBAAA,CAAuB,QAAA,CAAS,WAAW,CAAA,EAAG;AAChD,MAAA,MAAA,CAAO,WAAA,GAAc,WAAA;AAAA,IACvB,CAAA,MAAO;AACL,MAAA,MAAM,IAAI,KAAA,CAAM,CAAA,qBAAA,EAAwB,WAAW,CAAA,CAAE,CAAA;AAAA,IACvD;AAAA,EACF;AACA,EAAA,MAAM,cAAc,MAAA,CAAO,iBAAA;AAAA,IACzB;AAAA,GACF;AACA,EAAA,IAAI,WAAA,EAAa;AACf,IAAA,IAAI,sBAAA,CAAuB,QAAA,CAAS,WAAW,CAAA,EAAG;AAChD,MAAA,MAAA,CAAO,WAAA,GAAc,WAAA;AAAA,IACvB,CAAA,MAAO;AACL,MAAA,MAAM,IAAI,KAAA,CAAM,CAAA,qBAAA,EAAwB,WAAW,CAAA,CAAE,CAAA;AAAA,IACvD;AAAA,EACF;AACA,EAAA,MAAA,CAAO,iBAAiB,MAAA,CAAO,sBAAA;AAAA,IAC7B;AAAA,GACF;AACA,EAAA,OAAO,MAAA;AACT;;;;"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { JsonValue } from '@backstage/types';
|
|
1
2
|
import { Config } from '@backstage/config';
|
|
2
3
|
|
|
3
4
|
/** @public */
|
|
@@ -33,6 +34,12 @@ type NotificationPayload = {
|
|
|
33
34
|
* Optional notification icon
|
|
34
35
|
*/
|
|
35
36
|
icon?: string;
|
|
37
|
+
/**
|
|
38
|
+
* Optional additional customizable metadata.
|
|
39
|
+
*/
|
|
40
|
+
metadata?: {
|
|
41
|
+
[KMetadataKey in string]?: JsonValue;
|
|
42
|
+
};
|
|
36
43
|
};
|
|
37
44
|
/** @public */
|
|
38
45
|
type Notification = {
|
package/dist/utils.cjs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.cjs.js","sources":["../src/utils.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSettings } from './types';\n\n/** @public */\nexport const isNotificationsEnabledFor = (\n settings: NotificationSettings,\n channelId: string,\n originId: string,\n topicId: string | null,\n) => {\n const channel = settings.channels.find(c => c.id === channelId);\n if (!channel) {\n return true;\n }\n\n const origin = channel.origins.find(o => o.id === originId);\n if (!origin) {\n return true;\n }\n if (topicId === null) {\n return origin.enabled;\n }\n const topic = origin.topics?.find(t => t.id === topicId);\n if (!topic) {\n return origin.enabled;\n }\n return topic.enabled;\n};\n"],"names":[],"mappings":";;AAkBO,MAAM,
|
|
1
|
+
{"version":3,"file":"utils.cjs.js","sources":["../src/utils.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSettings } from './types';\n\n/** @public */\nexport const isNotificationsEnabledFor = (\n settings: NotificationSettings,\n channelId: string,\n originId: string,\n topicId: string | null,\n) => {\n const channel = settings.channels.find(c => c.id === channelId);\n if (!channel) {\n return true;\n }\n\n const origin = channel.origins.find(o => o.id === originId);\n if (!origin) {\n return true;\n }\n if (topicId === null) {\n return origin.enabled;\n }\n const topic = origin.topics?.find(t => t.id === topicId);\n if (!topic) {\n return origin.enabled;\n }\n return topic.enabled;\n};\n"],"names":[],"mappings":";;AAkBO,MAAM,yBAAA,GAA4B,CACvC,QAAA,EACA,SAAA,EACA,UACA,OAAA,KACG;AACH,EAAA,MAAM,UAAU,QAAA,CAAS,QAAA,CAAS,KAAK,CAAA,CAAA,KAAK,CAAA,CAAE,OAAO,SAAS,CAAA;AAC9D,EAAA,IAAI,CAAC,OAAA,EAAS;AACZ,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,SAAS,OAAA,CAAQ,OAAA,CAAQ,KAAK,CAAA,CAAA,KAAK,CAAA,CAAE,OAAO,QAAQ,CAAA;AAC1D,EAAA,IAAI,CAAC,MAAA,EAAQ;AACX,IAAA,OAAO,IAAA;AAAA,EACT;AACA,EAAA,IAAI,YAAY,IAAA,EAAM;AACpB,IAAA,OAAO,MAAA,CAAO,OAAA;AAAA,EAChB;AACA,EAAA,MAAM,QAAQ,MAAA,CAAO,MAAA,EAAQ,KAAK,CAAA,CAAA,KAAK,CAAA,CAAE,OAAO,OAAO,CAAA;AACvD,EAAA,IAAI,CAAC,KAAA,EAAO;AACV,IAAA,OAAO,MAAA,CAAO,OAAA;AAAA,EAChB;AACA,EAAA,OAAO,KAAA,CAAM,OAAA;AACf;;;;"}
|
package/dist/utils.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.esm.js","sources":["../src/utils.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSettings } from './types';\n\n/** @public */\nexport const isNotificationsEnabledFor = (\n settings: NotificationSettings,\n channelId: string,\n originId: string,\n topicId: string | null,\n) => {\n const channel = settings.channels.find(c => c.id === channelId);\n if (!channel) {\n return true;\n }\n\n const origin = channel.origins.find(o => o.id === originId);\n if (!origin) {\n return true;\n }\n if (topicId === null) {\n return origin.enabled;\n }\n const topic = origin.topics?.find(t => t.id === topicId);\n if (!topic) {\n return origin.enabled;\n }\n return topic.enabled;\n};\n"],"names":[],"mappings":"AAkBO,MAAM,
|
|
1
|
+
{"version":3,"file":"utils.esm.js","sources":["../src/utils.ts"],"sourcesContent":["/*\n * Copyright 2024 The Backstage Authors\n *\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 { NotificationSettings } from './types';\n\n/** @public */\nexport const isNotificationsEnabledFor = (\n settings: NotificationSettings,\n channelId: string,\n originId: string,\n topicId: string | null,\n) => {\n const channel = settings.channels.find(c => c.id === channelId);\n if (!channel) {\n return true;\n }\n\n const origin = channel.origins.find(o => o.id === originId);\n if (!origin) {\n return true;\n }\n if (topicId === null) {\n return origin.enabled;\n }\n const topic = origin.topics?.find(t => t.id === topicId);\n if (!topic) {\n return origin.enabled;\n }\n return topic.enabled;\n};\n"],"names":[],"mappings":"AAkBO,MAAM,yBAAA,GAA4B,CACvC,QAAA,EACA,SAAA,EACA,UACA,OAAA,KACG;AACH,EAAA,MAAM,UAAU,QAAA,CAAS,QAAA,CAAS,KAAK,CAAA,CAAA,KAAK,CAAA,CAAE,OAAO,SAAS,CAAA;AAC9D,EAAA,IAAI,CAAC,OAAA,EAAS;AACZ,IAAA,OAAO,IAAA;AAAA,EACT;AAEA,EAAA,MAAM,SAAS,OAAA,CAAQ,OAAA,CAAQ,KAAK,CAAA,CAAA,KAAK,CAAA,CAAE,OAAO,QAAQ,CAAA;AAC1D,EAAA,IAAI,CAAC,MAAA,EAAQ;AACX,IAAA,OAAO,IAAA;AAAA,EACT;AACA,EAAA,IAAI,YAAY,IAAA,EAAM;AACpB,IAAA,OAAO,MAAA,CAAO,OAAA;AAAA,EAChB;AACA,EAAA,MAAM,QAAQ,MAAA,CAAO,MAAA,EAAQ,KAAK,CAAA,CAAA,KAAK,CAAA,CAAE,OAAO,OAAO,CAAA;AACvD,EAAA,IAAI,CAAC,KAAA,EAAO;AACV,IAAA,OAAO,MAAA,CAAO,OAAA;AAAA,EAChB;AACA,EAAA,OAAO,KAAA,CAAM,OAAA;AACf;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/plugin-notifications-common",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.1-next.0",
|
|
4
4
|
"description": "Common functionalities for the notifications plugin",
|
|
5
5
|
"backstage": {
|
|
6
6
|
"role": "common-library",
|
|
@@ -39,11 +39,12 @@
|
|
|
39
39
|
"test": "backstage-cli package test"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@backstage/config": "
|
|
42
|
+
"@backstage/config": "1.3.4-next.0",
|
|
43
|
+
"@backstage/types": "1.2.2",
|
|
43
44
|
"@material-ui/icons": "^4.9.1"
|
|
44
45
|
},
|
|
45
46
|
"devDependencies": {
|
|
46
|
-
"@backstage/cli": "
|
|
47
|
+
"@backstage/cli": "0.34.4-next.1"
|
|
47
48
|
},
|
|
48
49
|
"typesVersions": {
|
|
49
50
|
"*": {
|