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Ja,MAAVG,GAED,IAAYC,WAAW,CAAE5U,KAAK,mCAAoC8D,WAAY,CAAE0Q,cAAeA,EAAeK,KAAKpS,GAAYzC,KAAMR,SAASiD,GAAYU,QAAQpF,QAAQX,GAAItI,OAAM,WAEzK6f,EAAOjT,WAAW,SAAWC,eAAeC,WAAW,EAGtE,KAAA9V,OAAS,IAAM,IAAI,yFArCnB,CAYA,kBAAMuO,GACJxP,KAAKwV,cAAgBxV,KAAKypB,gBAAgBpW,WAAW,CAAEK,UAAW1T,KAAK0T,UAAWqK,SAAU/d,KAAK+d,SAAUkM,kBAAkBjqB,KAAKiqB,mBAAqBjqB,KAAKkqB,cAC9J,CAIA,UAAI5R,GACF,OAAOtY,KAAKwV,OACd,GAhCO,EAAArU,OAAS,IAAG;;;;;;;;IAckC,IAApD,QAAS,CAAEyB,UAAW,aAAc9B,KAAMgB,0CACL,IAArC,QAAS,CAAEc,UAAW,6CACyB,IAA/C,QAAS,CAAEA,UAAW,gEACkC,IAAxD,QAAS,CAAEA,UAAW,iBAAkB9B,KAAM+T,8CAEE,IAAhD,OAAM,uEArBI0U,EAAqB,IADjC,QAAc,4BACFA,4YCJN,IAAMY,EAAN,cAA6B,KAGlC,MAAAlpB,GACE,OAAO,IAAI;iCACkBjB,KAAKoqB;OAEpC,GANY,IAAX,yCADUD,EAAc,IAD1B,QAAc,oBACFA,8VCMN,IAAME,EAAN,cAA0B,KAY/B,MAAAppB,GACE,OAAO,IAAI;6BACcjB,KAAK6O;oCACE7O,KAAKoqB;;OAGvC,GAbO,EAAAjpB,OAAS,CAACmpB,EAAA,EACf,IAAG;;;;KALO,IAAX,uCACW,IAAX,yCACW,IAAX,6CAHUD,EAAW,IADvB,QAAc,iBACFA","sources":["webpack://ClientApp/./src/components/category-edit.ts","webpack://ClientApp/./src/components/category-item.ts","webpack://ClientApp/./src/components/category-list.ts","webpack://ClientApp/./src/components/close-button.ts","webpack://ClientApp/./src/components/confirmation-dialog.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-button-group.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-button.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-editor-examples.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-editor.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-heading-select.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-preview.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-select-option.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-select.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-snippet-button.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-snippets-select-option.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-snippets-select.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-textarea.ts","webpack://ClientApp/./src/components/content-editor/ctx-content-toolbar.ts","webpack://ClientApp/./src/components/content-editor/ctx-editor-content-event.ts","webpack://ClientApp/./src/components/content-editor/ctx-snippets.ts","webpack://ClientApp/./src/components/ctx-card.ts","webpack://ClientApp/./src/components/ctx-checkbox.ts","webpack://ClientApp/./src/components/ctx-hero.ts","webpack://ClientApp/./src/components/dca-select.ts","webpack://ClientApp/./src/components/dca-wizard.ts","webpack://ClientApp/./src/components/dialog-wrapper.ts","webpack://ClientApp/./src/components/display-select.ts","webpack://ClientApp/./src/components/embedded-powerbi-manager.ts","webpack://ClientApp/./src/components/embedded-powerbi-wrapper.ts","webpack://ClientApp/./src/components/feedback/feedback-manager.ts","webpack://ClientApp/./src/components/feedback/page-feedback.ts","webpack://ClientApp/./src/components/fluentComponentRegistration.ts","webpack://ClientApp/./src/components/form-input.ts","webpack://ClientApp/./src/components/group-user-item.ts","webpack://ClientApp/./src/components/info-details.ts","webpack://ClientApp/./src/components/input-select.ts","webpack://ClientApp/./src/components/download-bar.ts","webpack://ClientApp/./src/components/message-list.ts","webpack://ClientApp/./src/components/alert-message.ts","webpack://ClientApp/./src/components/message-manager.ts","webpack://ClientApp/./src/components/permission-changes.ts","webpack://ClientApp/./src/components/radio-button-list.ts","webpack://ClientApp/./src/components/report-news.ts","webpack://ClientApp/./src/components/router/router.ts","webpack://ClientApp/./src/components/router/routes.ts","webpack://ClientApp/./src/components/show-component-wrapper.ts","webpack://ClientApp/./src/components/side-panel.ts","webpack://ClientApp/./src/components/thalamus-card.ts","webpack://ClientApp/./src/components/thalamus-hero.ts","webpack://ClientApp/./src/components/thalamus-powerbi-report.ts","webpack://ClientApp/./src/components/youtube-element.ts","webpack://ClientApp/./src/components/youtube-card.ts"],"sourcesContent":["import { html, css, LitElement } from 'lit';\nimport { customElement, property, query } from 'lit/decorators.js';\n\nimport { Dialog } from \"@material/mwc-dialog\";\nimport { TextField } from \"@material/mwc-textfield\";\nimport { Icon } from \"@material/mwc-icon\";\nimport { Button } from \"@material/mwc-button\";\nDialog; TextField; Icon; Button;\n\nexport interface CategoryEventDetail {\n description: string\n icon: string\n}\n\n@customElement('category-edit')\nexport class CategoryEdit extends LitElement {\n static styles = css`\n\n :root {\n --mdc-dialog-max-width :50vw\n }\n\n .dialog-content{\n display:flex;\n flex-direction:column; \n width: 80vw;\n max-width: 493px;\n row-gap: 2rem; \n }\n\n mwc-icon {\n --mdc-icon-size: 16px;\n }\n `;\n\n @property() heading: string;\n\n @property() description: string;\n\n @property() icon: string;\n\n show = () => this._dialog.show();\n\n @query(\"mwc-dialog\") private _dialog: Dialog;\n\n @query(\"mwc-textfield\") private _textField: TextField;\n\n @query(\"#iconName\") private _iconName: TextField;\n\n #iconChanged = (event: Event) => {\n this.requestUpdate();\n };\n\n #accepted = async (event: Event) => {\n this.dispatchEvent(new CustomEvent(\"accepted\", { detail: { description: this._textField.value, icon: this._iconName.value } }));\n }\n\n #closed = (event: CustomEvent) => {\n let myEvent = new CustomEvent(event.type, {\n detail: event.detail,\n bubbles: true,\n composed: true\n });\n this.dispatchEvent(myEvent);\n }\n\n render() {\n return html`\n \n
\n \n \n \n Help: Material icon listopen_in_new\n
\n Save\n Cancel\n
\n `;\n }\n}\n","import { html, css, LitElement, nothing } from \"lit\";\nimport { customElement, property, query } from \"lit/decorators.js\";\nimport { Dialog } from \"@material/mwc-dialog\";\nimport { TextField } from \"@material/mwc-textfield\";\nimport { Icon } from \"@material/mwc-icon\";\nimport { LinearProgress } from \"@material/mwc-linear-progress\";\nimport { IconButton } from \"@material/mwc-icon-button\";\n\nTextField; Dialog; Icon; LinearProgress; IconButton;\n\nimport { updateCategory, deleteCategory } from \"./../services\";\nimport { CategoryEdit, CategoryEventDetail } from \"./category-edit\";\n\n@customElement(\"category-item\")\nexport class CategoryItem extends LitElement {\n static styles = css`\n :host([hidden]){\n display:none\n }\n\n mwc-linear-progress{\n zoom:0.5\n }\n\n mwc-icon-button\n {\n position: relative;\n top: -11px; \n right: 10px;\n }\n `;\n\n @property({ type: Number }) key: number;\n\n @property() description: string;\n\n @property() icon: string;\n\n @property({ type: Boolean }) deletable: boolean\n\n @property({ type: Boolean }) updating = false;\n\n\n @query(\"mwc-dialog\")\n private _dialog: Dialog;\n\n @query(\"category-edit\")\n private _categoryEdit: CategoryEdit;\n\n editCategory = (event: Event) => {\n this._dialog.show();\n };\n\n clickCategory = (event: CustomEvent) => {\n // todo we should reset changes here\n this._categoryEdit.show();\n };\n\n updateCategoryHandler = async (event: CustomEvent) => {\n this.icon = event.detail.icon;\n this.description = event.detail.description\n this.updating = true;\n await updateCategory(this.key, this.description, this.icon);\n this.updating = false;\n };\n\n requestDeleteHandler = async (event: Event) => {\n event.cancelBubble = true;\n this.updating = true;\n await deleteCategory(this.key)\n this.updating = false;\n this.hidden = true;\n }\n\n render() {\n return html`\n \n ${this.icon}\n ${this.description}\n \n\n \n ${(this.deletable) ? html`` : nothing}\n \n \n \n `;\n }\n}\n","import { html, css, LitElement, nothing } from \"lit\";\nimport { customElement, property, query } from \"lit/decorators.js\";\n\nimport \"./category-edit\";\nimport \"./category-item\";\n\nimport \"@material/mwc-list/mwc-list\";\nimport \"@material/mwc-list/mwc-list-item\";\nimport '@material/mwc-fab';\n\nimport { CategoryEdit, CategoryEventDetail } from \"./category-edit\";\n\nimport { createCategory } from \"./../services\";\n\ninterface CategoryDetail {\n description: string\n icon: string\n busy: boolean\n key?: number\n}\n\n@customElement(\"category-list\")\nexport class CategoryList extends LitElement {\n\n @query(\"category-edit\")\n private _newCategory: CategoryEdit;\n\n @property({ attribute: false })\n private categoryItems: CategoryDetail[] = [];\n\n createCategoryHandler = async (event: CustomEvent) => {\n console.log(event.detail)\n const newItem: CategoryDetail = { ...event.detail, busy: true };\n this.categoryItems = [newItem, ...this.categoryItems];\n const response = await createCategory(event.detail.description, event.detail.icon);\n newItem.busy = false;\n newItem.key = response.key;\n this.requestUpdate();\n }\n\n displayCreateCategory = () => {\n this._newCategory.show();\n }\n\n render() {\n return html`\n \n \n \n ${this.categoryItems.map(cat => html``)}\n \n \n `;\n }\n}\n","import { LitElement, html, css } from 'lit';\nimport { customElement, property } from 'lit/decorators.js'\nimport { CloseViewEvent } from 'src/events/close-view';\nimport { IconButton } from '@material/mwc-icon-button';\n\nIconButton;\n\n@customElement('close-button')\nexport class CloseButton extends LitElement {\n static styles = [\n css`\n :host {\n display: block;\n }\n `\n ];\n\n render() {\n return html`\n this.dispatchEvent(new CloseViewEvent())}>\n `;\n }\n}\n","import { LitElement, html, css } from 'lit';\nimport { customElement, property, query } from 'lit/decorators.js'\nimport { CloseViewEvent } from 'src/events/close-view';\n\nimport { CloseButton } from './close-button';\nCloseButton;\nimport { Divider } from '@fluentui/web-components';\nimport { actionBarStyles } from 'src/styles/action-bar';\nDivider;\n\n@customElement('confirmation-dialog')\nexport class ConfirmationDialog extends LitElement {\n static styles = [actionBarStyles,\n css`\n :host {\n display: contents;\n }\n\n .dialog-inner {\n display:flex;\n flex-direction:column;\n }\n\n .dialog-header {\n text-decoration:underline\n }\n\n .dialog-footer {\n margin-top:1em;\n }\n \n `\n ];\n\n @property({ type: String }) heading: string;\n\n @property({ type: String, attribute:\"confirm-text\" }) confirmText: string;\n\n @query(\"#dialog\") dialog:HTMLDialogElement \n okHandler = (e:Event) =>{\n this.dispatchEvent(new ConfirmedEvent());\n this.dialog.close(); \n }\n\n openDialogHandler = (e:Event) =>{\n e.stopPropagation();\n e.preventDefault();\n this.dialog.showModal();\n }\n\n closeEventHandler = (e:CloseViewEvent) => { \n this.dialog.close(); \n e.stopPropagation(); \n e.preventDefault(); \n }\n\n\n render() {\n return html`\n \n \n
\n
\n
${this.heading ?? \"Confirm\"}
\n \n
\n \n
\n Are You Sure?\n
\n
\n \n
\n \n ${this.confirmText ??\"Ok\"}\n \n \n Cancel\n \n
\n
\n \n
\n `;\n }\n}\nexport class ConfirmedEvent extends Event {\n static readonly eventName = 'confirmed';\n onDisconnect?: () => void;\n\n constructor() {\n super(ConfirmedEvent.eventName, {\n bubbles: true,\n composed: true,\n cancelable: false,\n });\n }\n}\n\ndeclare global {\n interface HTMLElementEventMap {\n [ConfirmedEvent.eventName]: ConfirmedEvent;\n }\n}","import { LitElement, html, css } from 'lit';\nimport { customElement } from 'lit/decorators.js'\n\n@customElement('ctx-content-button-group')\nexport class CtxContentButtonGroup extends LitElement {\n static styles = [\n css`\n .button-group {\n align-items: center;\n cursor: pointer;\n display: flex;\n gap: 0.125rem;\n min-height: 2.25rem;\n }\n `\n ];\n\n render() {\n return html`
\n \n
`;\n }\n}","import { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property } from 'lit/decorators.js'\nimport { SnippetInsertValue, SnippetWrapValue } from './ctx-snippet-types';\nimport { EditorContentEvent } from './ctx-editor-content-event';\nimport { EditorBehaviour } from './ctx-editor-types';\n\n@customElement('ctx-content-button')\nexport class CtxContentButton extends LitElement {\n static styles = [\n css`\n .button {\n align-items: center;\n background-color: #FFFFFF;\n border: 0.5px solid #d1d5db;\n cursor: pointer;\n display: flex;\n justify-content: center;\n min-height: 2.25rem;\n min-width: 2.25rem;\n padding-inline: 0.5rem;\n }\n\n .button:hover {\n color: #0069d9;\n }\n\n .flex {\n align-items: center;\n display: flex;\n gap: 0.25rem;\n }\n `\n ];\n\n @property() behaviour: EditorBehaviour = \"wrap\";\n @property() displayIcon: string;\n @property() displayText: string;\n @property() value: SnippetInsertValue | SnippetWrapValue;\n\n private _clicked = async () => {\n this.dispatchEvent(new EditorContentEvent({\n behaviour: this.behaviour,\n value: this.value\n }));\n }\n\n render() {\n return html`
\n ${ this._renderDisplayContent() }\n
`;\n }\n\n private _renderDisplayContent() {\n return this.displayIcon || this.displayText ? html`
${this._renderDisplayIcon()} ${this.displayText}
` : html``;\n }\n\n private _renderDisplayIcon() {\n return this.displayIcon ? html`${this.displayIcon}` : nothing;\n }\n}","const newlines = `\\n\\n`;\n\nexport const boldSnippet = `**An example of bold text**${newlines}`;\nexport const italicSnippet = `*An example of italic text*${newlines}`;\nexport const linkSnippet = `[An example of a link to Google](https://www.google.com/)${newlines}`;\n\n// Headings\nexport const heading1Snippet = `# Heading 1${newlines}`;\nexport const heading2Snippet = `## Heading 2${newlines}`;\nexport const heading3Snippet = `### Heading 3${newlines}`;\nexport const heading4Snippet = `#### Heading 4${newlines}`;\nexport const heading5Snippet = `##### Heading 5${newlines}`;\nexport const heading6Snippet = `###### Heading 6${newlines}`;\n\n// Lists\nexport const orderedListSnippet = `1. Item 1\n2. Item 2\n a. Item 2A\n b. Item 2B\n3. Item 3${newlines}`;\n\nexport const unOrderedListSnippet = `* Item 1\n* Item 2\n * Item 2A\n * Item 2B\n* Item 3${newlines}`;\n\n// Tables\nexport const tableSnippet = `|Heading 1|Heading 2|Heading 3|\n|---------|---------|---------|\n|Row 1, Column 1|Row 1, Column 2|Row 1, Column 3|\n|Row 2, Column 1|Row 2, Column 2|Row 2, Column 3|${newlines}`;\n\nexport const tableOfContentsSnippet = `## Table of Contents\n\n* [Section 1](#section-1)\n* [Section 2](#section-2)\n * [Section 1A](#section-1-a)\n * [Section 1B](#section-1-b)\n* [Section 3](#section-3)${newlines}`;\n\n\n// Components\nexport const heroSnippet = `\n\n\n\n\n* Add your Description here.\n\n\n\n${newlines}`;\nexport const informationMessageSnippet = `The information goes here${newlines}`;\nexport const warningMessageSnippet = `The warning goes here${newlines}`;\nexport const errorMessageSnippet = `The error goes here${newlines}`;\n\nexport const reportNewsSnippet = ``;\n\nexport const colleagueAuditSnippet = `${newlines}`;\n\n// Documentation\nexport const documentationSnippet = `# An example of a document layout\n\n## Table of contents\n\n* [Creating a table of contents](#creating-a-table-of-contents)\n* [Creating headings](#creating-headings)\n* [Creating lists](#creating-lists)\n * [Creating an ordered list](#creating-an-ordered-list)\n * [Creating an unordered list](#creating-an-unordered-list)\n* [Creating tables](#creating-tables)\n* [Creating alerts](#creating-alerts)\n * [Creating information alerts](#creating-information-alerts)\n * [Creating warning alerts](#creating-warning-alerts)\n * [Creating error alerts](#creating-error-alerts)\n\n## Creating a table of contents\n\nA table of contents begins with a heading, followed by a list of sections. Each section must start with the '*' character, followed by a description enclosed in square brackets and the ID of the corresponding heading. The ID should start with the '#' character, followed by the exact wording of the heading, with spaces replaced by '-' characters.\n\n## Creating headings\n\nHeadings are created by placing the '#' character followed by a space at the beginning of the text. You can create headings from Level 1 to Level 6 by increasing the number of '#' characters; more '#' characters indicate a smaller heading.\n\n${ heading4Snippet }\n${ heading5Snippet }\n${ heading6Snippet }\n\n## Creating lists\n\nA list is a collection of items that can start with either a numerical value or the '*' character, depending on the type of list. Below are examples of how to create both ordered and unordered lists.\n\n### Creating an ordered list\n\n${ orderedListSnippet }\n\n### Creating an unordered list\n\n${ unOrderedListSnippet }\n\n\n## Creating tables\n\nTables are used to organise data into rows and columns. They are constructed by arranging headings, rows, and columns, with each element separated by the '|' character, as illustrated below.\n\n${ tableSnippet }\n\n## Creating alerts\n\nAlerts are components used to convey standard information or to notify users about warnings or errors. To display a specific type of alert, set the level property to either 'information', 'warning', or 'error'.\n\n### Creating information alerts\n\n${ informationMessageSnippet }\n\n### Creating warning alerts\n\n${ warningMessageSnippet }\n\n### Creating error alerts\n\n${ errorMessageSnippet }${newlines}`;","import { LitElement, html, css, nothing } from 'lit';\nimport { provide } from '@lit/context';\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { classMap } from 'lit/directives/class-map.js';\nimport { CtxContentTextArea } from './ctx-content-textarea';\nimport { EditorContentEvent } from './ctx-editor-content-event';\nimport { CtxContentPreview } from './ctx-content-preview';\nimport { editModeContext } from 'src/context/content-context';\nimport { subscriberKeyContext } from 'src/context/subscriber-context';\n\nexport type PreviewPosition = \"right\" | \"below\";\n\n@customElement('ctx-content-editor')\nexport class CtxContentEditor extends LitElement {\n static styles = [\n css`\n :host {\n position: relative;\n height: 100%;\n }\n\n .content-editor {\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n height: 100%;\n padding: 0;\n position: relative;\n }\n\n .preview {\n min-height: 200px;\n overflow-y: auto;\n position: relative;\n padding: 0.5rem;\n width: auto;\n }\n\n .preview-below {\n display: block;\n }\n\n .preview-right {\n display: grid;\n grid-template-columns: calc(50% - 4px) calc(50% - 4px); /* To account for the gap */\n gap: 8px;\n height: 100%;\n }\n\n .slot {\n width: 100%;\n padding: 0;\n }\n\n .textarea-and-preview {\n flex-grow: 1;\n height: 100%;\n }\n\n .top-slot {\n position: sticky;\n top: 0;\n z-index: 999;\n }\n `\n ];\n\n static formAssociated = true;\n\n @property({ type: Boolean }) readonly: boolean = false;\n @property({ type: Boolean }) showPreview: boolean = true;\n @property({ type: String }) previewPosition: string = \"bottom\";\n\n @provide({ context: subscriberKeyContext })\n @property({ type: Number, attribute: 'subscriber-key' }) subscriberKey?: number;\n\n @provide({ context: editModeContext }) editMode = true;\n\n @query(\"#text-area\") textArea: CtxContentTextArea;\n\n @state() private _preview: CtxContentPreview;\n\n @state() private _value: string = '';\n\n get value(): string {\n return this._value;\n }\n\n set value(newValue: string) {\n this._value = newValue;\n\n this._internals.setFormValue(newValue);\n this.requestUpdate();\n }\n\n private _internals: ElementInternals;\n\n private _handlePreviewSlotChange(e: Event) {\n const slot = e.target as HTMLSlotElement;\n const slottedElements = slot.assignedElements();\n \n slottedElements.forEach(element => {\n if (element instanceof HTMLElement && element.tagName.toLowerCase() === 'ctx-content-preview') {\n this._preview = element as CtxContentPreview;\n this._preview.scrollToCursor = this.previewPosition !== \"bottom\";\n this._setPreviewValueAndCursorPosition(this.value);\n }\n });\n }\n\n private _handleContentFromToolbar = async (event: EditorContentEvent) => {\n this.textArea.handleContentChange(event.content);\n }\n\n private _setPreviewValueAndCursorPosition(value: string, cursorPosition: number = 0) {\n if (this._preview) {\n this._preview.cursorPosition = cursorPosition;\n this._preview.value = value;\n }\n }\n\n private _textAreaContentChanged = async (event: CustomEvent<{cursorPosition:number, content:string}>) => {\n var content = event.detail.content;\n this._internals.setFormValue(content);\n this._setPreviewValueAndCursorPosition(content, event.detail.cursorPosition);\n }\n\n constructor() {\n super();\n this._internals = this.attachInternals();\n this.addEventListener('handle-editor-content', this._handleContentFromToolbar);\n }\n\n connectedCallback() {\n super.connectedCallback();\n if (this.hasAttribute('value')) {\n this.value = this.getAttribute('value') || '';\n }\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n document.removeEventListener('handle-editor-content', this._handleContentFromToolbar);\n }\n\n render() {\n return html`
\n
\n \n
\n
\n ${this._renderTextAreaAndPreviewSlot()}\n
\n
`;\n }\n\n private _renderBottomSlot() {\n return html``;\n }\n\n private _renderTextArea() {\n return html``; \n }\n\n private _renderTextAreaAndPreviewSlot() {\n const classes = { 'preview-below': this.previewPosition === 'below', 'preview-right': this.previewPosition === 'right' };\n return html`
\n
\n ${ this._renderTextArea() }\n ${ this._renderBottomSlot() }\n
\n ${ this._renderPreviewSlot() }\n
`;\n }\n\n private _renderPreviewSlot() {\n return this.showPreview ? html`
\n \n
` : nothing;\n }\n}","import { LitElement, html, css } from 'lit';\nimport { customElement } from 'lit/decorators.js'\nimport { heading1Snippet, heading2Snippet, heading3Snippet, heading4Snippet, heading5Snippet, heading6Snippet } from './ctx-content-editor-examples';\n\n@customElement('ctx-content-heading-select')\nexport class CtxContentHeadingSelect extends LitElement {\n static styles = [\n css`\n .heading-1 {\n font-size: 20px;\n }\n\n .heading-2 {\n font-size: 19px;\n }\n\n .heading-3 {\n font-size: 18px;\n }\n\n .heading-4 {\n font-size: 17px;\n }\n\n .heading-5 {\n font-size: 16px;\n }\n\n .heading-6 {\n font-size: 15px;\n }\n `\n ];\n\n render() {\n return html`\n \n
\n Heading 1\n
\n
\n \n
\n Heading 2\n
\n
\n \n
\n Heading 3\n
\n
\n \n
\n Heading 4\n
\n
\n \n
\n Heading 5\n
\n
\n \n
\n Heading 6\n
\n
\n
`;\n }\n}","import { LitElement, html } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js'\nimport { Task } from '@lit/task';\nimport { services } from \"src/services\";\nimport { unsafeHTML } from 'lit/directives/unsafe-html.js';\nimport { raiseFetchResponseError } from 'src/modules/helpers/response-helpers';\n\n@customElement('ctx-content-preview')\nexport class CtxContentPreview extends LitElement {\n createRenderRoot() {\n return this;\n }\n\n @property({ type: Boolean }) grow: boolean = false;\n @property({ type: Boolean }) scrollToCursor: boolean = true;\n @property({ type: Number }) cursorPosition: number;\n\n @state() private _value: string = \"\";\n @state() htmlContent: string = \"\";\n\n get value(): string {\n return this._value;\n }\n\n set value(newValue: string) {\n this._value = newValue;\n this.requestUpdate();\n }\n\n private _markdownPreviewTask: Task = new Task(this, {\n task: async ([value], { signal }) => {\n var response = await services.management.markdown.preview(value).catch(raiseFetchResponseError);\n if(signal.aborted)\n {\n return this._value;\n }\n this.htmlContent = response.markup;\n return response.markup;\n },\n args: () => [this._value],\n });\n\n private _scrollToCursor() {\n if (this.scrollToCursor) {\n const bottomOffset = 100; // We want to check if the cursor is within the last 100 characters.\n const contentLength = this.value.length;\n let bottomPosition = contentLength <= bottomOffset ? contentLength : contentLength - bottomOffset;\n\n // If the cursor position is withing the last 100 characters of the content, add a scroll marker.\n if (this.cursorPosition > bottomPosition) {\n this.scrollIntoView({ behavior: 'smooth', block: 'end' });\n }\n }\n }\n\n // This component is rendered using the light DOM to ensure the markdown being previewed renders as expected.\n // So styles are added to the render method to get it applied.\n render() {\n return html`\n \n ${ this.grow ? this._renderPerview() : html`
${ this._renderPerview() }
` }`;\n }\n\n private _renderPerview() {\n return html`${this._markdownPreviewTask.render({\n initial: () => html``,\n pending: () => unsafeHTML(this.htmlContent),\n complete: () => html`${unsafeHTML(this.htmlContent)}${this._scrollToCursor()}`,\n error: (error) => html`

Oops, something went wrong: ${error}

`,\n })}`;\n }\n}","import { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property } from 'lit/decorators.js'\nimport { SnippetInsertValue, SnippetWrapValue } from './ctx-snippet-types';\nimport { EditorContentEvent } from './ctx-editor-content-event';\n\n@customElement('ctx-content-select-option')\nexport class CtxContentSelectOption extends LitElement {\n static styles = [\n css`\n .flex {\n align-items: center;\n display: flex;\n gap: 0.25rem;\n }\n\n .option {\n cursor: pointer;\n }\n\n .option:hover {\n background-color: #f3f4f6;\n } \n `\n ];\n\n @property() displayIcon: string;\n @property() displayText: string;\n @property() value: string | SnippetInsertValue | SnippetWrapValue;\n\n private _selected = async () => {\n this.dispatchEvent(new EditorContentEvent({\n behaviour: \"insert\",\n value: this.value\n }));\n\n\n this.dispatchEvent(new CustomEvent(\"option-selected\", { detail: {\n value: this.value\n }, bubbles: true, composed: true }));\n }\n\n render() {\n return html`
\n ${this._renderDisplayContent()}\n
`;\n }\n\n private _renderDisplayContent() {\n return this.displayIcon || this.displayText ? html`
${this._renderDisplayIcon()} ${this.displayText}
` : html``;\n }\n\n private _renderDisplayIcon() {\n return this.displayIcon ? html`${this.displayIcon}` : nothing;\n }\n}","import { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js'\n\n@customElement('ctx-content-select')\nexport class CtxContentSelect extends LitElement {\n static styles = [\n css`\n .flex {\n align-items: center;\n display: flex;\n gap: 0.25rem;\n }\n\n .heading {\n flex-grow: 1;\n }\n\n .options {\n background-color: #FFFFFF;\n border: 0.5px solid #d1d5db;\n display: flex;\n flex-direction: column;\n gap: 0.5rem;\n margin-top: 0.25rem;\n min-width: 11rem;\n padding-block: 0.25rem;\n padding-inline: 0.5rem;\n position: absolute;\n user-select: none;\n z-index: 999;\n }\n\n .select {\n align-items: center;\n background-color: #FFFFFF;\n border: 0.5px solid #d1d5db;\n cursor: pointer;\n display: flex;\n min-height: 1.75rem;\n min-width: 11rem;\n padding-block: 0.25rem;\n padding-inline: 0.5rem;\n user-select: none;\n }\n\n .select-container {\n position: relative;\n }\n `\n ];\n\n @property() heading: string;\n @property() headingIcon: string;\n\n @state() showOptions: boolean = false;\n\n private _boundHandleOutsideClick: (event: MouseEvent) => void;\n\n private _handleOutsideClick(event: MouseEvent) {\n if (!this.showOptions) return; // Don't do anything if options are already hidden\n\n const path = event.composedPath();\n if (!path.includes(this)) {\n this.showOptions = false;\n this.requestUpdate();\n }\n }\n\n private _optionSelected = async (event: CustomEvent) => {\n this._toggleShowOptions();\n }\n\n private _toggleShowOptions() {\n this.showOptions = !this.showOptions;\n }\n\n constructor() {\n super();\n this.addEventListener('option-selected', this._optionSelected);\n this._boundHandleOutsideClick = this._handleOutsideClick.bind(this);\n }\n\n connectedCallback() {\n super.connectedCallback();\n document.addEventListener('click', this._boundHandleOutsideClick);\n }\n\n disconnectedCallback() {\n document.removeEventListener('click', this._boundHandleOutsideClick);\n super.disconnectedCallback();\n }\n\n render() {\n return html`
e.stopPropagation()}>\n
\n ${this._renderHeading()}\n ${this._renderIcon()}\n
\n ${this._renderOptions()}\n
`;\n }\n\n private _renderHeading() {\n return html`
\n ${this.headingIcon || this.heading ? html`
${this._renderHeadingIcon()} ${this.heading}
` : html`${this.heading}`}\n
`;\n }\n\n private _renderHeadingIcon() {\n return this.headingIcon ? html`${this.headingIcon}` : nothing;\n }\n\n private _renderIcon() {\n return !this.showOptions ? html`keyboard_arrow_right` : html`keyboard_arrow_down`;\n }\n\n private _renderOptions() {\n return this.showOptions ? html`` : nothing;\n }\n}","import { LitElement, html } from 'lit';\nimport { customElement, property } from 'lit/decorators.js'\nimport { SnippetKeys } from './ctx-snippet-types';\nimport { snippets } from './ctx-snippets';\nimport { EditorBehaviour } from './ctx-editor-types';\n\n@customElement('ctx-content-snippet-button')\nexport class CtxContentSnippetButton extends LitElement {\n @property() snippet: SnippetKeys;\n @property() behaviour: EditorBehaviour = \"wrap\";\n\n render() {\n var currentSnippet = snippets[this.snippet];\n return html``;\n }\n}","import { LitElement, html } from 'lit';\nimport { customElement, property } from 'lit/decorators.js'\nimport { snippets } from './ctx-snippets';\nimport { SnippetKeys } from './ctx-snippet-types';\n\n@customElement('ctx-content-snippets-select-option')\nexport class CtxContentSnippetsSelectOption extends LitElement {\n @property() snippet: SnippetKeys;\n\n render() {\n var currentSnippet = snippets[this.snippet];\n return html``;\n }\n}","import { LitElement, html } from 'lit';\nimport { customElement } from 'lit/decorators.js'\n\n@customElement('ctx-content-snippets-select')\nexport class CtxContentSnippetsSelect extends LitElement {\n render() {\n return html`\n \n `;\n }\n}","import { LitElement, html, css } from 'lit';\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { EditorContent } from './ctx-editor-content-event';\nimport { SnippetInsertValue, SnippetWrapValue } from './ctx-snippet-types';\n\n@customElement('ctx-content-textarea')\nexport class CtxContentTextArea extends LitElement {\n static styles = [\n css`\n textarea {\n border: 0.5px solid #d1d5db;\n box-sizing: border-box;\n height: 100%;\n max-height: 100%;\n min-height: 200px;\n overflow-y: auto;\n padding: 0.5rem;\n width: 100%;\n }\n `\n ];\n\n @query(\"#editor\") editor: HTMLTextAreaElement;\n\n @property({ type: Boolean }) readonly: boolean = false;\n\n @property({attribute:\"value\"}) private initialValue: string = '';\n\n handleContentChange(content: EditorContent) {\n if (content.behaviour === \"insert\") {\n this._insertContent(content.value as SnippetInsertValue);\n }\n\n if (content.behaviour === \"wrap\") {\n this._wrapSelectedContent(content.value as SnippetWrapValue);\n }\n }\n\n private _contentChanged = async (event: InputEvent) => {\n this.#raiseContentChanged();\n }\n\n #raiseContentChanged = () => {\n this.dispatchEvent(new CustomEvent(\"content-changed\", { detail: {\n content: this.editor.value,\n cursorPosition: this.editor.selectionStart\n }, bubbles:true, composed:true }));\n }\n\n private _insertContent(content: string | SnippetInsertValue) {\n var contentToInsert = typeof content === 'string' ? content : content.snippet; \n this.editor.setRangeText(contentToInsert, this.editor.selectionStart, this.editor.selectionEnd, \"preserve\");\n this.editor.setSelectionRange(this.editor.selectionStart, this.editor.selectionStart + contentToInsert.length)\n this.editor.focus();\n this.#raiseContentChanged();\n }\n\n\n private _wrapSelectedContent(value: SnippetWrapValue) {\n const start = this.editor.selectionStart;\n const end = this.editor.selectionEnd;\n\n const selectedContent = this.editor.value.slice(start, end);\n const wrappedContent = `${value.pre}${selectedContent}${value.post}`;\n\n this.editor.setRangeText(wrappedContent, start, end, \"preserve\");\n this.#raiseContentChanged();\n }\n\n render() {\n return html``;\n }\n}","import { LitElement, html, css } from 'lit';\nimport { customElement } from 'lit/decorators.js'\nimport { EditorContentEvent } from './ctx-editor-content-event';\n\n@customElement('ctx-content-toolbar')\nexport class CtxContentToolbar extends LitElement {\n static styles = [\n css`\n .grow {\n align-items: center;\n display: flex;\n flex-grow: 1;\n justify-content: right;\n }\n\n .help-icon {\n color: #111827;\n }\n\n .help-icon:hover {\n cursor: pointer;\n color: #0069d9;\n }\n\n .help-icon-container {\n padding-top: 0.5rem;\n }\n\n select {\n border: 0.5px solid #d1d5db;\n padding: 0.250rem;\n }\n\n .toolbar {\n align-items: center;\n background-color: #f9fafb;\n border: 0.5px solid #d1d5db;\n box-sizing: border-box;\n display: flex;\n gap: 0.5rem;\n margin-bottom: 0.250rem;\n padding: 0.5rem;\n width: 100%;\n }\n `\n ];\n\n private _selectedToolbarContentChanged = async (event: CustomEvent) => {\n this.dispatchEvent(new EditorContentEvent(event.detail.value))\n }\n\n constructor() {\n super();\n this.addEventListener('selected-content-changed', this._selectedToolbarContentChanged);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.removeEventListener('selected-content-changed', this._selectedToolbarContentChanged);\n }\n\n render() {\n return html`
\n \n ${this._renderRightSlot()}\n
`;\n }\n\n private _renderHelpIcon() {\n return html``;\n }\n\n private _renderRightSlot() {\n return html`
\n \n ${ this._renderHelpIcon() }\n
`;\n }\n}","import { EditorBehaviour } from \"./ctx-editor-types\";\nimport { SnippetInsertValue, SnippetWrapValue } from \"./ctx-snippet-types\";\n\nexport type EditorContent = {\n behaviour: EditorBehaviour, \n value: string | SnippetInsertValue | SnippetWrapValue\n}\n\nexport class EditorContentEvent extends Event {\n static readonly eventName = 'handle-editor-content';\n onDisconnect?: () => void;\n \n public readonly content:EditorContent;\n constructor(content:EditorContent) {\n super(EditorContentEvent.eventName, {\n bubbles: true,\n composed: true,\n cancelable: false,\n });\n this.content = content;\n }\n }\n \n declare global {\n interface HTMLElementEventMap {\n [EditorContentEvent.eventName]: EditorContentEvent;\n }\n }","import { boldSnippet, colleagueAuditSnippet, documentationSnippet, errorMessageSnippet, heroSnippet, informationMessageSnippet, italicSnippet, linkSnippet, orderedListSnippet, reportNewsSnippet, tableOfContentsSnippet, unOrderedListSnippet, warningMessageSnippet } from \"./ctx-content-editor-examples\";\nimport { SnippetCollection } from \"./ctx-snippet-types\";\n\nexport const snippets: SnippetCollection = {\n bold: {\n icon: 'format_bold',\n description: 'Bold',\n insert: {\n snippet: boldSnippet\n },\n wrap: {\n pre: '**',\n post: '**'\n }\n },\n documentLayout: {\n icon: 'dashboard',\n description: 'Document Layout',\n insert: {\n snippet: documentationSnippet\n }\n },\n errorAlert: {\n icon: 'cancel',\n description: 'Error Message',\n insert: {\n snippet: errorMessageSnippet\n }\n },\n hero: {\n icon: 'filter',\n description: 'Hero',\n insert: {\n snippet: heroSnippet\n }\n },\n infoAlert: {\n icon: 'info',\n description: 'Info Message',\n insert: {\n snippet: informationMessageSnippet\n }\n },\n italic: {\n icon: 'format_italic',\n description: 'Italic',\n insert: {\n snippet: italicSnippet\n },\n wrap: {\n pre: '*',\n post: '*'\n }\n },\n link: {\n icon: 'link',\n description: 'Link',\n insert: {\n snippet: linkSnippet\n }\n },\n orderedList: {\n icon: 'format_list_numbered',\n description: 'Ordered List',\n insert: {\n snippet: orderedListSnippet\n }\n },\n tableOfContents: {\n icon: 'format_list_bulleted',\n description: 'Table of Contents',\n insert: {\n snippet: tableOfContentsSnippet\n }\n },\n unorderedList: {\n icon: 'format_list_bulleted',\n description: 'Unordered List',\n insert: {\n snippet: unOrderedListSnippet\n }\n },\n warningAlert: {\n icon: 'warning',\n description: 'Warning Message',\n insert: {\n snippet: warningMessageSnippet\n }\n },\n reportNews: {\n icon: 'newspaper', \n description: 'Report News',\n insert: {\n snippet: reportNewsSnippet\n }\n },\n colleagueAudit: {\n icon: 'checklist', \n description: 'Colleague Audit',\n insert: {\n snippet: colleagueAuditSnippet\n }\n }\n}","import {css, html, LitElement, nothing} from \"lit\";\nimport {customElement, property} from \"lit/decorators.js\";\nimport \"@material/mwc-icon\"\n\n@customElement('ctx-card')\nexport class CtxCard extends LitElement {\n static styles = css`\n :host {\n box-sizing: border-box;\n display: block;\n\n border: 0 solid rgba(0, 0, 0, .125);\n border-radius: 0.25rem;\n\n background-color: var(--card-background-color);\n box-shadow: var(--card-box-shadow);\n }\n\n .body {\n padding: 1.25rem;\n }\n\n header {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n\n font-weight: 500;\n line-height: 1.2;\n font-size: 1.25rem;\n align-items: center;\n gap: 1em;\n }\n\n hr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0, 0, 0, .1);\n }\n `;\n\n @property() heading: string;\n @property() icon: string;\n @property({type: Boolean}) underline: boolean;\n\n render() {\n return html`\n \n
\n
\n
\n ${this.heading}\n
\n \n \n ${this.icon}\n \n
\n ${this.underline ? html`\n
` : nothing}\n \n
\n `\n }\n}","import { LitElement, html, css } from 'lit';\nimport { customElement } from 'lit/decorators.js'\nimport { choose } from 'lit/directives/choose.js';\n\ntype CheckboxState = boolean | null;\n@customElement('ctx-checkbox')\nexport class CtxCheckbox extends LitElement {\n static styles = [\n css`\n :host {\n display: inline-block;\n }\n\n .checkbox-container {\n display: flex;\n align-items: center;\n cursor: pointer;\n user-select: none; /* Prevents text selection */\n }\n\n .checkbox {\n width: 20px;\n height: 20px;\n border: 0.5px solid var(--checkbox-border-color, #4b5563);\n border-radius: 2px;\n margin-right: 8px;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.2s;\n }\n\n .icon {\n font-size: 16px;\n color: var(--icon-color, #4b5563);\n }\n `\n ];\n\n static formAssociated = true;\n\n private _internals: ElementInternals;\n private _value: CheckboxState = null;\n\n get value(): CheckboxState {\n return this._value;\n }\n\n set value(newValue: CheckboxState) {\n this._value = newValue;\n this._internals.setFormValue(newValue?.toString());\n this._dispatchChangeEvent(newValue);\n this.requestUpdate();\n }\n\n constructor() {\n super();\n this._internals = this.attachInternals();\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.setAttribute('role', 'checkbox');\n this._setValue();\n }\n\n private _dispatchChangeEvent(value: CheckboxState) {\n this.dispatchEvent(new CustomEvent('change', {\n detail: { value },\n bubbles: true,\n composed: true\n }));\n }\n\n private _setValue() {\n if (this.hasAttribute('value')) {\n const attrValue = this.getAttribute('value').toLowerCase();\n if (attrValue === 'true') {\n this.value = true;\n } else if (attrValue === 'false') {\n this.value = false;\n } else {\n this.value = null;\n }\n }\n }\n \n private _toggleState() {\n if (this.value === null) {\n this.value = true;\n } else if (this.value === true) {\n this.value = false;\n } else {\n this.value = null;\n }\n }\n\n render() {\n return html`
\n
\n ${ this.renderIcon() }\n
\n ${ this.renderStateContentSlot() }\n
`;\n }\n\n renderIcon() {\n return html`\n ${choose(this.value, [\n [true, () => html`check`],\n [false, () => html`close`]\n ],\n () => html``)}\n `;\n }\n\n renderStateContentSlot() {\n const slotName = this.value === null ? 'not-set' : this.value === true ? 'on' : 'off';\n return html``;\n }\n}\n\n","import { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property } from 'lit/decorators.js'\n\n@customElement('ctx-hero')\nexport class CtxHero extends LitElement {\n static styles = [\n css`\n :host {\n display: block;\n \n /* padding: 1em;*/\n\n /*background-color:#dbeeff;*/\n box-shadow:0px 10px 25px -10px rgba(0,0,0,0.52);\n\n \n padding: clamp(1em, 5%, 6em);\n }\n\n :host([short]){\n padding-block: 0;\n }\n\n .grid{\n display:grid;\n grid-template-columns:1fr 1fr;\n gap:1em;\n }\n\n .left {\n display:flex;\n flex-direction: column;\n justify-content: space-evenly;\n gap:0.8em;\n }\n\n .title {\n font-size:2em;\n font-weight:700;\n }\n\n .cta{\n \n }\n .cta fluent-button {\n border-radius:0;\n --control-corner-radius:0;\n /*box-shadow: 5px 10px;*/\n box-shadow:0px 10px 25px -10px rgba(0,0,0,0.52);\n }\n\n img{\n display: block;\n width: 100%; /* or any custom size */\n /*height: 100%; \n object-fit: contain;*/\n }\n\n .image{\n align-self: center;\n justify-self: center;\n }\n\n a {\n //just to make it hidden\n display:contents\n }\n `\n ];\n\n@property({ type: String }) title: string;\n@property({ type: String }) description: string;\n@property({ type: String, attribute:\"call-to-action\" }) callToAction: string;\n@property({ type: String, attribute:\"call-to-action-url\" }) callToActionUrl: string;\n@property({ type: String, attribute:\"src\" }) src: string;\n\n@property({ type: Boolean, attribute:\"short\" }) short:boolean=false;\n\n render() {\n return html`\n \n
\n
\n
${this.title}
\n
\n \n \n ${this.description}\n \n \n
\n \n ${this.callToActionUrl != null ? html`\n \n `:nothing} \n \n
\n \n
\n \n \n \n
\n\n
\n \n \n `;\n }\n}\n\n","import { css, html, LitElement } from \"lit\";\nimport { customElement, property, query, state } from \"lit/decorators.js\";\n\n/*\n\nhttps://css-tricks.com/creating-custom-form-controls-with-elementinternals/\n\ntodo\n provider improved standard styles\n better documentation\ntodo low\n support \n obsolete input-select\n*/\n\n\n@customElement(\"dca-select\")\nexport class DcaSelect extends LitElement {\n\n static styles = css`\n :host{\n display: inline-flex;\n }\n \n :host([hidden]){\n display:none;\n }\n\n input {\n box-sizing:border-box;\n flex-grow:1\n }\n `;\n\n @property({ type: Boolean }) required: boolean = false;\n @property({ type: Boolean }) autofocus: boolean = false;\n @property() placeholder: string;\n\n @query(\"input\")\n private _input: HTMLInputElement;\n\n static formAssociated = true;\n\n //https://github.com/microsoft/TypeScript/issues/33218\n internals?: any;\n\n constructor() {\n super();\n }\n\n connectedCallback() {\n super.connectedCallback()\n }\n\n protected _options(): HTMLOptionElement[] {\n return Array.from(this.querySelectorAll(\"option\"));\n }\n\n firstUpdated(value: any) {\n this.internals = (this as any).attachInternals();;\n\n /** Make sure validations are set up */\n /** This ensures our element always participates in the form */\n this._manageRequired();\n }\n\n _onInput(event: Event) {\n this._manageRequired();\n }\n\n protected _manageRequired() {\n var match = this._findOptionMatch(this._input.value)\n this.internals.setFormValue(match?.value);\n if (match == null && this.required) {\n this.internals.setValidity({\n valueMissing: true\n }, 'This field is required', this._input);\n\n } else {\n this.internals.setValidity({});\n }\n }\n\n protected _findOptionMatch(value: string): HTMLOptionElement {\n // potentially have more ways to match if there are more ways to set data\n // e.g \n return this._options().find(option => option.innerText === value);\n }\n\n render() {\n return html`\n \n \n ${this._options().map(option => html``)}\n \n `;\n }\n}","import { html, css, LitElement } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js';\n\nimport '@material/mwc-button';\nimport '@material/mwc-textfield';\n\n/*\n [] remove step-id,activeStep no need at the moment\n [] add cancel or swap previous to cancel, or only show if cancel function as implementation\n [] next button spin while progressing\n [] consider better event naming (show, checkValidity, displayValidity, complete)\n [] avoid RequestUpdate by integrating component\n\n [] is the a way to avoid/ignore nullable (e.g in final step everything will be set, why should i go x.y?.z?.value)\n \n\n [] support host:hidden {display:none}\n [] show step progress\n [] we might need a concept of Summary step, which shows the result of the Complete Step(or Summary and Conclusion step)\n\n [] how do i split the ui so can have any presentation but the same logic\n [] support adding steps dynamically\n [] reset/start \n [] think about step reuse (e.g select-category-step) would either have to bind to parent or onprogress( wizard.cat = currentStep.cat )\n [] add checkValidity(wizardStep) on dca-wizard \n [] consider auto-progress for steps that only have one option\n\nQuestions\n[] in _getSteps, why does \n this.shadowRoot.querySelector('slot').assignedNodes({flatten: true})[0];\n not work for finding DcaWizardStep[]. the current method may be descendent nodes, and we only want child\n\n\n*/\n\n@customElement(\"dca-wizard\")\nexport class DcaWizard extends LitElement {\n\n @property({ type: String, attribute: \"complete-label\" }) CompleteLabel: string = \"Complete\";\n @state() activeStep: number = 0;\n @state() canNavigatePrevious: boolean = false;\n @state() private _isLastStep: boolean;\n\n constructor() {\n super();\n }\n\n protected _getSteps(): NodeListOf {\n return this.querySelectorAll(\"dca-wizard-step\");\n }\n\n protected get Steps(): DcaWizardStep[] { return Array.from(this._getSteps()) }\n\n protected _getActiveStep(): DcaWizardStep {\n let activeStep: DcaWizardStep;\n this._getSteps().forEach(step => {\n if (step.step === this.activeStep) {\n activeStep = step;\n }\n });\n return activeStep;\n }\n\n protected setSteps() {\n this._getSteps().forEach(step => {\n step.hidden = step.step !== this.activeStep;\n });\n this.canNavigatePrevious = this._getActiveStep().step != 0;\n }\n\n previousStepHandler = async (event: Event) => {\n console.log(\"previous step\")\n const activeStep = this._getActiveStep();\n var index = this.Steps.findIndex(i => i=== activeStep);\n var previousStep = this.Steps[index-1];\n this.activeStep = previousStep.step;\n this._setLastStep();\n }\n\n // todo rename to progress handler\n protected nextStepHandler = async (event: Event) => {\n //get current\n const activeStep = this._getActiveStep();\n const isValid = activeStep.checkValidity();\n if (isValid) {\n if (activeStep.completeStep) {\n await activeStep.completeStep();\n }\n var index = this.Steps.findIndex(i => i=== activeStep);\n var nextStep = this.Steps[index+1];\n this.activeStep = nextStep.step;\n\n this._setLastStep();\n }\n }\n\n\n private _setLastStep() {\n const lastStep = Array.from(this._getSteps()).slice(-1)[0];\n const currentStep = this._getActiveStep();\n this._isLastStep = lastStep == currentStep;\n }\n\n\n render() {\n // todo move setSteps out of here, but would need to make sure changing property activeStep triggers set-step\n this.setSteps();\n const currentStep = this._getActiveStep();\n return html`\n
\n

\n ${currentStep.title}\n

\n
\n \n
\n
\n \n ${this._isLastStep ?\n html`` :\n html``} \n
\n `;\n }\n}\n\n\n@customElement(\"dca-wizard-step\")\nexport class DcaWizardStep extends LitElement {\n @property({ type: Number }) step: number = 0;\n @property() title: string;\n\n // named generically as it may be used for Next|Finish\n @property({ attribute: false }) completeStep: () => Promise;\n\n checkValidity(): boolean {\n const event = new CustomEvent<{ isValid: boolean }>('validate', { detail: { isValid: true }, bubbles: true, composed: true, cancelable: true });\n this.dispatchEvent(event);\n return event.detail.isValid\n }\n\n render() {\n return html`\n \n `;\n }\n}\n\n","import { LitElement, html, css } from 'lit';\nimport { customElement, property, query } from 'lit/decorators.js'\nimport { CloseViewEvent } from 'src/events/close-view';\n\n@customElement('dialog-wrapper')\nexport class DialogWrapper extends LitElement {\n static styles = [\n css`\n :host {\n display: block;\n }\n `\n ];\n\n @query(\"#dialog\") dialog:HTMLDialogElement \n\n openDialogHandler = (e:Event) =>{\n e.stopPropagation();\n e.preventDefault();\n this.dialog.showModal();\n }\n\n closeEventHandler = (e:CloseViewEvent) => { \n this.dialog.close(); \n e.stopPropagation(); \n e.preventDefault(); \n }\n \n render() {\n return html`\n \n \n \n \n `;\n }\n}\n","import { Menu, MenuItem } from \"@fluentui/web-components\";\nimport { LitElement, html, css } from \"lit\";\nimport { customElement, property, query, state } from \"lit/decorators.js\"\nimport { downSvg } from \"src/modules/svg/svgIcons\";\n\n@customElement(\"display-select\")\nexport class DisplaySelect extends LitElement {\n static styles = [\n css`\n :host {\n display: block;\n }\n\n .anchor-button {\n anchor-name: --anchor-el;\n }\n\n .menu {\n position-anchor: --anchor-el;\n top: anchor(bottom);\n margin: 0;\n justify-self: anchor-center;\n position-area: right span-bottom;\n border: 0;\n padding: 10px 50px 50px;\n background-color: transparent;\n }\n `\n ];\n\n @state() iconSlotName?:string = \"default\";\n\n @query(\"#menu\") menu:Menu & { hidePopover:()=> void, togglePopover:()=> void }\n\n buttonClickHandler = (e: Event)=>{\n this.menu.togglePopover();\n }\n\n menuClickHandler = (e:Event) =>{\n const targetMenuItem =(e.target as HTMLElement).closest(\"fluent-menu-item\") as MenuItem;\n var iconSlot = `${targetMenuItem.id}-icon`;\n this.iconSlotName =iconSlot;\n this.close()\n } \n\n close = () => this.menu.hidePopover();\n\n render() {\n return html`\n \n
\n \n ${downSvg(24)}\n
\n
\n \n
\n \n \n \n
\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"display-select\": DisplaySelect;\n }\n}\n","import appInsights from './../application-insights';\n\nimport { css, html, LitElement } from \"lit\";\nimport { repeat } from 'lit/directives/repeat.js';\nimport { customElement, query, state } from \"lit/decorators.js\";\nimport './embedded-powerbi-wrapper'\nimport { EmbeddedPowerBiWrapper } from \"./embedded-powerbi-wrapper\";\nimport * as pbi from 'powerbi-client';\nimport { DashboardReportAccessor, IReportApiEmbedAccessor, IReportRequest } from \"src/modules/DashboardReportAccessor\";\nimport { IEmbedCodeResponse } from \"./../services\";\nimport { PowerBiTokenUpdater } from 'src/modules/PowerBiTokenUpdater';\nimport { createEmbedConfig, isMobileView } from 'src/modules/helpers/powerbi-client-helpers';\nimport { IEmbedSettings } from './../services';\nimport { IEmbedConfigurationBase } from 'embed';\n\nexport type PageChangedAfterLoadDetail = { newPage: pbi.Page };\ntype EmbedItem = { powerBiType?:\"Report\"|\"Dashboard\", clientGroup?: string, name?: string, isMobile: boolean, loadedDatasets:Map };\n@customElement(\"embedded-powerbi-manager\")\nexport class EmbeddedPowerBiManager extends LitElement {\n\n\n static styles = css`\n :host{\n display:flex\n }\n\n embedded-powerbi-wrapper{\n flex-grow:1\n }\n \n`;\n\n private _report: pbi.Report;\n private reportKey: number;\n private _loaded: boolean = false;\n\n private readonly _reportAccessor: IReportApiEmbedAccessor;\n get reportAccessor() {\n return this._reportAccessor;\n }\n\n private _embeddedList: EmbedItem[]\n @state() _activeEmbed: EmbedItem;\n\n @query(\"#default\") protected _firstPowerBiReport: EmbeddedPowerBiWrapper\n\n\n private _tokenUpdater: PowerBiTokenUpdater;\n\n constructor() {\n super();\n const isMobile= false;\n const defaultEmbed: EmbedItem = { name: \"default\", isMobile, loadedDatasets:new Map() };\n\n this._embeddedList = [defaultEmbed];\n this._activeEmbed = defaultEmbed;\n this._reportAccessor = new DashboardReportAccessor();\n }\n\n bootstrap = async () => {\n await this._firstPowerBiReport.updateComplete\n\n var bootstrapConfig: IEmbedConfigurationBase = {\n type: 'report',\n hostname: \"https://app.powerbi.com\",\n embedUrl: \"https://app.powerbi.com/reportEmbed\", //fake because bookmarks don't work https://community.powerbi.com/t5/Issues/Javascript-API-Problem-with-BookmarksManager-when-Bootstrap-API/idi-p/1168698\n };\n\n // uncomment when/if we bring in screen detect\n // no need now as there are no mobile reports\n // if (this._embeddedList[0].isMobile) {\n // bootstrapConfig.settings = {\n // layoutType: pbi.models.LayoutType.MobilePortrait\n // }\n // }\n\n this._embeddedList[0].powerBiType = \"Report\";\n var config = this._firstPowerBiReport.bootstrap(bootstrapConfig);\n console.log(config);\n console.log(\"bootstrapped\");\n }\n\n\n loadReport = async (reportRequest: IReportRequest,clientEmbedSettings?: IEmbedSettings, bookmarkName?:string) => {\n\n\n await this.firstUpdated\n this.initializeDefaultActiveEmbed(reportRequest);\n\n\n const reportKey = reportRequest.reportKey;\n if (!this._tokenUpdater) {\n this._tokenUpdater = new PowerBiTokenUpdater(this);\n }\n\n this._loaded = false;\n if (slowLoadTimeout != null) {\n window.clearTimeout(slowLoadTimeout);\n\n appInsights.stopTrackEvent(\"report-load-event\", { reportKey: this.reportKey?.toString(), action: \"new-report\" })\n slowLoadTimeout = null;\n }\n\n\n this.reportAccessor.SetEmbedRequestData(reportRequest);\n var embedResponse = await this.reportAccessor.GetCachedEmbedCode();\n\n const isMobile = clientEmbedSettings?.layoutType != null ? clientEmbedSettings?.layoutType === pbi.models.LayoutType.MobilePortrait : isMobileView();\n\n const mobileSettings = isMobile ? { layoutType: pbi.models.LayoutType.MobilePortrait }:{}\n await this.setOrCreateActiveEmbed(reportRequest.clientGroup, embedResponse.reportId, isMobile, reportRequest.reportKey, embedResponse.powerBiType, new Map(Object.entries(embedResponse.datasets)))\n\n let config = this.getEmbedConfiguration(embedResponse);\n config.settings = { ...mobileSettings, ...config.settings, ...clientEmbedSettings };\n\n if(bookmarkName)\n {\n config.bookmark= { name :bookmarkName };\n }\n\n appInsights.startTrackEvent(\"LoadFrame\")\n appInsights.startTrackEvent(\"report-load-event\");\n\n var slowLoadTimeout = window.setTimeout(function () {\n console.log(\"report-load-event timer\");\n appInsights.stopTrackEvent(\"report-load-event\", { reportKey: reportKey.toString(), action: \"slowtimer\" })\n window.clearTimeout(slowLoadTimeout);\n slowLoadTimeout = null;\n }, 50000);\n\n const loadedReport = await this.loadFrame(config);\n\n if (slowLoadTimeout !== null) {\n // loaded ok so clear\n window.clearTimeout(slowLoadTimeout);\n slowLoadTimeout = null;\n }\n appInsights.stopTrackEvent(\"report-load-event\", { reportKey: reportKey.toString(), action: \"loaded\" })\n\n\n appInsights.stopTrackEvent(\"LoadFrame\", { reportKey: reportKey.toString() })\n\n this.reportKey = reportKey;\n this._report = loadedReport;\n this._loaded = true;\n this._tokenUpdater.AttachInterval(embedResponse.expiration);\n return this._report;\n };\n\n\n private initializeDefaultActiveEmbed(reportRequest: IReportRequest) {\n // this bootstrapped embed to be loaded assumes the reportData\n if (this._activeEmbed.clientGroup == null) {\n this._activeEmbed.clientGroup = reportRequest.clientGroup;\n }\n }\n\n private setOrCreateActiveEmbed = async (clientGroup: string, reportId: string, isMobile: boolean, reportKey: number, powerBiType: \"Report\"|\"Dashboard\", datasets:Map): Promise => {\n let currentEmbed: EmbedItem;\n\n // find embed to place compatible report\n if (currentEmbed == null) {\n for (const embed of this._embeddedList) {\n if (embed.powerBiType === powerBiType && embed.clientGroup === clientGroup && embed.isMobile === isMobile) // must be same client group\n {\n //should check that all loaded datasets are compatible (i.e the same dataset but with different config has not already been loaded)\n if(this.#checkDataSetsAreCompatible(embed.loadedDatasets, datasets))\n {\n console.log(\"compatible dataset found!\");\n embed.loadedDatasets = new Map([...embed.loadedDatasets, ...datasets])\n currentEmbed = embed;\n break;\n }\n }\n }\n }\n\n // could not find embed, so create a new one\n if (currentEmbed == null) {\n // create new embed and assign it, name to be unique but can hold many reports\n currentEmbed = { name: `${reportId}_${reportKey}`, loadedDatasets: new Map(datasets), clientGroup: clientGroup, isMobile, powerBiType };\n this._embeddedList.push(currentEmbed);\n console.log(this._embeddedList.length ==1? \"first embed required\" : \"new embedded-powerbi-wrapper required\");\n }\n\n // todo might only need to updateComplete when new nodes are created,\n if (this._activeEmbed != currentEmbed) {\n this._activeEmbed = currentEmbed;\n await this.updateComplete;\n }\n }\n\n #checkDataSetsAreCompatible(existingDataset:Map, incomingDatasets:Map) {\n for(var incomingDatasetKey of incomingDatasets.keys())\n {\n if(existingDataset.has(incomingDatasetKey)){\n if(existingDataset.get(incomingDatasetKey) !== incomingDatasets.get(incomingDatasetKey)){\n console.log(\"dataset: already loaded with a different configuration\")\n return false;\n }\n }\n\n }\n return true;\n\n }\n\n fullscreen = () => this.getCurrentReport().fullscreen();\n\n\n getReportBookmarks = async (): Promise => await this.getCurrentReport().bookmarksManager.getBookmarks();\n\n getReportState = async (): Promise<{ reportKey: number, state: string }> => {\n const capturedBookmark = await this.getCurrentReport().bookmarksManager.capture();\n return { reportKey: this.reportKey, state: capturedBookmark.state };\n };\n\n getReport = () => this.getCurrentReport();\n\n getPages = async (): Promise => {\n return this._report.getPages();\n }\n\n\n // page must be active\n getTableColumns = async (visualDescriptor: pbi.VisualDescriptor): Promise => {\n const data = await visualDescriptor.exportData(pbi.models.ExportDataType.Summarized, 1);\n const firstRow = (data as any).data.split(\"\\r\\n\")[0];\n return firstRow.split(\",\");\n }\n\n setReportState = async (state: string) => {\n await this.getCurrentReport().bookmarksManager.applyState(state);\n }\n\n setAccessToken = async (accessToken: string) => await this.getCurrentReport().setAccessToken(accessToken);\n\n applyBookmark = async (bookmarkName: string) => await this.getCurrentReport().bookmarksManager.apply(bookmarkName)\n\n private getCurrentReport = (): pbi.Report => this._report;\n\n\n private getCurrentEmbedElement = (): EmbeddedPowerBiWrapper => {\n\n const activeEmbedElement = this.shadowRoot.querySelector(`embedded-powerbi-wrapper:not([hidden])`) as EmbeddedPowerBiWrapper\n return activeEmbedElement ?? this.shadowRoot.querySelector(\"embedded-powerbi-wrapper\");\n }\n\n getActivePageInfo = async (): Promise<{ displayName: string, name: string }> => {\n const activePage = await this._report.getActivePage()\n return { displayName: activePage.displayName, name: activePage.name };\n };\n\n\n private getEmbedConfiguration = (embedResponse: IEmbedCodeResponse) => {\n console.log(\"embed\", embedResponse);\n return createEmbedConfig(embedResponse.powerBiType, embedResponse.reportId, embedResponse.embedToken, embedResponse.url)\n }\n\n\n private loadFrame = (config: pbi.IEmbedConfiguration): Promise => {\n\n return new Promise((resolve, reject) => {\n // todo could add a reject timeout here or somewhere\n\n var oldReport = this._report;\n if (oldReport) {\n console.log(\"unloading previous report\");\n oldReport.off(\"loaded\"); // todo remove specific event instead of all\n oldReport.off(\"rendered\"); // todo remove specific event instead of all\n oldReport.off(\"pageChanged\");\n oldReport.off(\"selectionChanged\");\n oldReport.off(\"visualClicked\");\n oldReport.off(\"error\");\n }\n\n var report = this.getCurrentEmbedElement().embed(config) as pbi.Report;\n this._report = report;\n\n console.log(\"report\", report.getId());\n\n if(config.type === \"report\")\n {\n report.on(\"pageChanged\", this.pageChangedEventHandler);\n report.on(\"selectionChanged\", this.selectionChangedEventHandler);\n report.on(\"visualClicked\", this.visualClickedEventHandler);\n }\n \n\n report.on(\"error\", (event) => {\n console.log(\"error\", event);\n\n if (event instanceof Error) {\n appInsights.trackException({\n exception: event\n });\n } else {\n appInsights.trackTrace({ message: \"powerbi error\", properties: event })\n appInsights.trackException({\n exception: new Error(\"powerbi error\")\n });\n }\n\n reject(event);\n });\n\n report.on(\"loaded\", (event) => {\n console.log(\"loaded [%o] [%o]\", event, report.getId());\n\n appInsights.stopTrackEvent(\"report-loaded\", { reportId: report.getId() })\n resolve(report);\n });\n\n\n report.on(\"rendered\", this.renderedEventHandler);\n console.log(\"loadFrame end\")\n });\n };\n\n private selectionChangedEventHandler = (event: Event) => {\n console.log(\"selectionChanged\", event);\n\n this.raiseUserActivityEvent(\"selectionChanged\");\n }\n\n private visualClickedEventHandler = (event: Event) => {\n console.log(\"visualClicked\", event);\n this.raiseUserActivityEvent(\"visualClicked\");\n };\n\n private renderedEventHandler = (event: pbi.service.ICustomEvent<{ newPage: { displayname: string } }>) => {\n appInsights.stopTrackEvent(\"report-rendered\", { reportId: this._report.getId() })\n console.log(\"rendered [%o] [%o]\", event, this._report.getId());\n };\n\n\n private pageChangedEventHandler = (event: CustomEvent<{ newPage: pbi.Page }>) => {\n console.log(\"pageChanged\", event)\n if (this._loaded) {\n const pageChangeEvent = new CustomEvent(\"page-changed-after-load\", { detail: event.detail, bubbles: true, composed: true })\n this.getCurrentEmbedElement().dispatchEvent(pageChangeEvent);\n }\n }\n\n private raiseUserActivityEvent = (activityType: string) => {\n const activityEvent = new CustomEvent(\"userActivity\", {\n detail: {\n activityType: activityType\n },\n bubbles: true\n });\n this.getCurrentEmbedElement().dispatchEvent(activityEvent);\n }\n\n render = () => html`\n ${repeat(this._embeddedList, (item) => item.name, (embedItem, index) => {\n const hideReport: boolean = embedItem !== this._activeEmbed;\n return html``\n })\n }\n `;\n\n}","import { IEmbedConfigurationBase } from \"embed\";\nimport { css, html, LitElement } from \"lit\";\nimport { customElement, query } from \"lit/decorators.js\";\nimport { IComponentEmbedConfiguration } from \"service\";\nimport { Embed } from \"embed\";\n\n@customElement(\"embedded-powerbi-wrapper\")\nexport class EmbeddedPowerBiWrapper extends LitElement {\n\n // iframe background-color may not be needed anymore... but leaving for now\n static styles = css`\n :host{\n display:block\n }\n \n :host([hidden]) { display: none }\n \n #reportContainer {\n height:100%;\n display:flex;\n }\n\n iframe {\n border: 0px;\n background-color: var(--background-theme-color);\n }\n\n iframe:fullscreen {\n background-color: var(--background-theme-color);\n }\n `;\n\n @query('#reportContainer') private reportContainer: HTMLElement\n\n \n pageChangedEventHandler = (event:CustomEvent) => {\n console.log(\"EmbeddedPowerBiWrapper page changed\",event )\n const replayEvent = new CustomEvent(event.type, { bubbles:true,composed:true, detail: event.detail})\n this.dispatchEvent(replayEvent);\n }\n\n bootstrap = (config?: IComponentEmbedConfiguration | IEmbedConfigurationBase): Embed => window.powerbi.bootstrap(this.reportContainer, config);\n \n embed = (config?: IComponentEmbedConfiguration | IEmbedConfigurationBase): Embed => window.powerbi.embed(this.reportContainer, config);\n\n render = () => html`
`;\n}\n","import { LitElement, html, css, nothing } from \"lit\";\nimport { customElement, property, state } from \"lit/decorators.js\"\nimport { createRef, ref, Ref } from \"lit/directives/ref.js\";\nimport { WebComponentEvent } from \"src/events/WebComponentEvent\";\nimport { PageFeedback } from \"src/components/feedback/page-feedback\";\n\n@customElement(\"feedback-manager\")\nexport class FeedbackManager extends LitElement {\n static styles = [\n css`\n :host {\n display: contents\n }\n `\n ];\n\n connectedCallback() {\n super.connectedCallback();\n window.addEventListener(DisplayFeedbackEvent.eventName, this.showFeedbackHandler);\n }\n \n @state() pageFeedback: { ref:Ref, reportKey?:number }[] = [];\n\n showFeedbackHandler = async (displayFeedbackEvent: DisplayFeedbackEvent) => {\n const feedbackRef: Ref = createRef();\n this.pageFeedback = [...this.pageFeedback, { ref:feedbackRef, reportKey:displayFeedbackEvent.reportKey }];\n await this.updateComplete;\n feedbackRef.value.showModal();\n }\n\n removeFeedback = (value:Ref) => {\n this.pageFeedback = this.pageFeedback.filter(x=> x.ref !== value);\n }\n\n render() {\n return html`\n ${this.pageFeedback.map(x=> html` this.removeFeedback(x.ref)}>`)} \n `;\n }\n\n disconnectedCallback() {\n window.removeEventListener(DisplayFeedbackEvent.eventName, this.showFeedbackHandler);;\n super.disconnectedCallback();\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"feedback-manager\": FeedbackManager;\n }\n}\nexport class DisplayFeedbackEvent extends WebComponentEvent {\n static readonly eventName = 'display-feedback-event';\n onDisconnect?: () => void;\n constructor(public reportKey?:number) {\n super(DisplayFeedbackEvent.eventName);\n }\n}","import appInsights from 'src/application-insights';\nimport { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property, query } from 'lit/decorators.js'\nimport { actionBarStyles } from 'src/styles/action-bar';\nimport { services } from 'src/services';\nimport { TextArea } from '@microsoft/fast-foundation';\nimport {RadioButtonList, RadioButton} from 'src/components/radio-button-list'\nimport { raisePromiseEvent } from 'src/modules/helpers/message-helper';\nimport '../close-button';\nimport { CloseViewEvent } from 'src/events/close-view';\nTextArea;\nRadioButtonList; RadioButton;\n@customElement('page-feedback')\nexport class PageFeedback extends LitElement {\n static styles = [actionBarStyles,\n css`\n :host {\n box-sizing:border-box;\n }\n\n dialog[open] {\n border:0px;\n box-shadow: rgb(0 0 0 / 22%) 0px 25.6px 57.6px 0px, rgb(0 0 0 / 18%) 0px 4.8px 14.4px 0px;\n\n display:flex;\n flex-direction:column;\n gap:1rem;\n }\n\n dialog::backdrop {\n background: rgba(0, 0, 0, 0.4); \n }\n\n .title-text {\n font-size:20px;\n font-weight:600;\n }\n\n .button-text {\n font-weight:600;\n }\n\n\n fluent-text-area::part(control)\n {\n width: 70vw;\n height:30vh;\n max-width:1000px;\n }\n `\n ];\n\n @query(\"dialog\") private _dialog: HTMLDialogElement;\n @query(\"fluent-text-area\") private _textArea: TextArea;\n @query(\"radio-button-list\") private _RadioButtons: RadioButtonList;\n\n @property({type:Number}) reportKey?:number;\n\n private reset = ()=> {\n this._textArea.value = \"\";\n }\n\n protected submit = async () =>{\n if(this._textArea.reportValidity() === true)\n {\n\n try {\n this.#close();\n var task = async () => {\n if(this.reportKey && this._RadioButtons.selectedValue == \"report\" )\n {\n await services.users.sendFeedback(window.location.href,this._textArea.value,this.reportKey )\n } else {\n await services.users.sendFeedback(window.location.href,this._textArea.value)\n }\n }\n \n raisePromiseEvent(this, { task: task(), messages: { success: \"Feedback sent\", failed: \"Could not send feedback\", progress: \"Sending\" } })\n this.reportKey = null;\n this.reset();\n\n } \n catch(er) {\n appInsights.trackException(er);\n throw er;\n }\n }\n }\n\n showModal = () => {\n const selectedValue = this.reportKey ? \"report\" : \"general\";\n this._RadioButtons.selectValue(selectedValue)\n this._dialog.showModal();\n }\n\n #close =()=>{\n this._dialog.close();\n this.dispatchEvent(new CloseViewEvent())\n }\n render() {\n return html`\n \n
\n contact_support \n
Feedback
\n \n
\n
\n \n This Report\n General Feedback\n \n
\n
\n \n
\n
\n Submit\n this.#close()}>Cancel\n
\n
\n `;\n }\n}\n","import {\n provideFluentDesignSystem,\n fluentAnchor,\n fluentBadge,\n fluentButton,\n fluentProgress,\n fluentProgressRing,\n fluentSwitch,\n fluentTab,\n fluentTabPanel,\n fluentTabs,\n fluentTextField,\n fluentTextArea,\n fluentSelect,\n fluentOption,\n fluentMenu,\n fluentMenuItem,\n fluentDivider,\n fluentCombobox,\n fluentCheckbox,\n fluentRadioGroup,\n fluentRadio,\n fluentListbox,\n fluentAnchoredRegion\n \n\n} from \"@fluentui/web-components\";\n\n\n/*\nimport {css} from \"@microsoft/fast-element\"\n\nimport {\n provideFASTDesignSystem,\n fastDisclosure,\n disclosureStyles,\n \n\n} from \"@microsoft/fast-components\";\n\nprovideFASTDesignSystem()\n .register(\n fastDisclosure({\n styles: (ctx, def) => css`\n ${disclosureStyles(ctx, def)}\n\n :host(.success) {\n --accent-foreground-rest: #0f5132;\n --accent-foreground-hover: #badbcc;\n }\n `})\n );\n*/\n\n\n\n//var accentBaseColor = \"#DA1A5F\";\n//accentPalette.withDefault(PaletteRGB.from(SwatchRGB.from({r:16,g:124,b:16 })));\n\nprovideFluentDesignSystem()\n .register(\n fluentAnchor(),\n fluentBadge(),\n fluentButton(),\n fluentProgress(),\n fluentProgressRing(),\n fluentSwitch(),\n fluentTab(),\n fluentTabPanel(),\n fluentTabs(),\n fluentTextField(),\n fluentTextArea(),\n fluentSelect(),\n fluentOption(),\n fluentMenu(),\n fluentMenuItem(),\n fluentDivider(),\n fluentCombobox(),\n fluentCheckbox(),\n fluentRadioGroup(),\n fluentRadio(),\n fluentListbox(),\n fluentAnchoredRegion()\n );\n\n","import { css, html, LitElement } from \"lit\";\nimport { customElement, property } from \"lit/decorators.js\";\n\n@customElement(\"form-input\")\nexport class FormInput extends LitElement {\n static styles = css`\n :host { \n display: contents; \n }\n `;\n\n @property() name: string;\n @property() query: string;\n @property() property: string;\n // @property() for:string;\n\n @property({type:Boolean}) stringify:boolean = false;\n\n constructor() {\n super();\n this._handleFormDataEvent = this._handleFormDataEvent.bind(this);\n }\n\n connectedCallback() {\n super.connectedCallback()\n this.closest(\"form\").addEventListener(\"formdata\", this._handleFormDataEvent);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n // no idea it's been removed, or is being removed, and it won't be able to find the form if it's already removed\n this.closest(\"form\").removeEventListener(\"formdata\", this._handleFormDataEvent);\n }\n\n protected _slottedChildren() {\n const slot = this.shadowRoot.querySelector('slot');\n const childNodes = slot.assignedNodes({ flatten: true });\n return childNodes.filter((node: Node) => node.nodeType == Node.ELEMENT_NODE) as Element[];\n }\n\n protected _handleFormDataEvent(event: FormDataEvent) {\n const propertyName = this.property ? this.property : \"value\";\n const nodes = this.query ? this.querySelectorAll(this.query) : this._slottedChildren();\n\n\n //remove any existing formdata\n nodes.forEach(n => {\n event.formData.delete((n as any)[\"name\"] ?? this.name);\n })\n\n nodes.forEach(n => {\n let name = (n as any)[\"name\"];\n if (name == null || name === '') {\n name = this.name;\n }\n\n const formValue =this.stringify ? JSON.stringify((n as any)[propertyName]) : (n as any)[propertyName];\n event.formData.append(name ?? this.name, formValue);\n })\n }\n\n render() {\n return html`\n \n `;\n }\n}","\nimport type { Switch } from '@fluentui/web-components';\nimport 'src/components/fluentComponentRegistration';\n\nimport { LinearProgress } from \"@material/mwc-linear-progress\";\nLinearProgress;\nimport { Icon } from \"@material/mwc-icon\";\nIcon\n\nimport { html, css, LitElement, nothing } from \"lit\";\nimport { customElement, property, query } from \"lit/decorators.js\";\nimport { updateGroupUser } from 'src/services';\nimport styleSheet from \"src/styles/group-user-item-css\"\nimport { classMap } from 'lit/directives/class-map.js';\n\n@customElement(\"group-user-item\")\nexport class GroupUserItem extends LitElement {\n static styles = [styleSheet, css`\n :host([hidden]){\n display:none\n }\n\n mwc-linear-progress{\n zoom:0.5;\n }\n\n mwc-icon-button\n {\n position: relative;\n top: -11px; \n right: 10px;\n }\n\n mwc-linear-progress.failure {\n --mdc-theme-primary: red;\n } \n\n `];\n\n @property({ type: Number }) groupUserKey: number\n //todo change to drill-down\n @property({ type: Boolean }) drilldown: boolean\n @property({ type: Boolean }) readonly: boolean\n\n @property() username: string\n\n @property() failedState= false;\n\n @query(\"fluent-switch\") private _switch: Switch;\n @query(\"mwc-linear-progress\") private _progress: LinearProgress;\n\n requestToggleDrillDownHandler = async (event: Event) => {\n console.log(\"DrillDownHandler\", event);\n await this.ProgressPromise(updateGroupUser(this.groupUserKey, this._switch.checked))\n }\n\n private ProgressPromise = async (innerPromise: Promise): Promise => {\n this.failedState = false;\n this._progress.indeterminate = true;\n try {\n const result = await innerPromise;\n return result; \n } catch {\n debugger;\n this.failedState = true;\n } finally{\n this._progress.indeterminate = false;\n this._progress.progress =1;\n\n }\n \n \n \n }\n\n render() {\n return html`\n
\n ${this.username}\n ${this.readonly ? this.drilldown ? html`lock_open`:nothing :html`\n \n lock_open\n \n `}\n \n
\n \n `;\n }\n}\n\n","import { css, html, LitElement, nothing } from \"lit\";\nimport { customElement, property, state } from \"lit/decorators.js\";\n\n/*\n A twist on the traditional details component, \n - allowing the details to exist outside of the element\n\n Usage\n click me for info\n i can be anywhere in the document\n\n - while is not good practice for components to directly talk to each other, I'll make an exception here.\n\ntodo:\n[] needs show/hide animation\n[] support details slot or(summary slot)\n[] consider adding title and rendering a default style (like disclosure)\n\n[] add title summary slot (which is any div that is wrapped in a info-summary)\n[] add title text which creates a summary slot if not exists\n */\n\n\ndeclare global {\n interface WindowEventMap {\n \"info-detail-change\": CustomEvent\n }\n}\nexport interface InfoDetailChangeEvent {\n open: boolean\n}\n\n@customElement(\"info-summary\")\nexport class InfoSummary extends LitElement {\n @property() for: string;\n\n @state() open: boolean;\n\n static styles = css`\n :host{\n display:block;\n cursor:pointer;\n }\n ::slotted(:hover){\n cursor:pointer\n }\n `\n\n connectedCallback() {\n super.connectedCallback()\n window.addEventListener(\"info-detail-change\", this._infoDetailChangeEventHandler);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback()\n window.removeEventListener(\"info-detail-change\", this._infoDetailChangeEventHandler);\n }\n\n private _infoDetailChangeEventHandler = (event: CustomEvent) => {\n const target = this.#findTarget();\n if (target === event.target) {\n this.open = event.detail.open;\n }\n };\n\n clickEventHandler(event: Event) {\n const target = this.#findTarget();\n\n if (target instanceof InfoDetails) {\n target.toggle();\n }\n }\n\n render() {\n return html`\n \n ${this.open ? html`` : html``}\n `\n }\n\n #findTarget = () => {\n var closestDocumentFragment = closestNode(this.parentNode, isDocumentFragment)\n if (closestDocumentFragment) {\n return closestDocumentFragment.getElementById(this.for)\n }\n return null;\n }\n}\n\n@customElement(\"info-details\")\nexport class InfoDetails extends LitElement {\n @property({ type: Boolean, reflect: true }) open: boolean;\n\n static styles = css`\n :host{\n display:block\n }\n `\n toggle() {\n this.open = !this.open;\n const downloadReportEvent = new CustomEvent(\"info-detail-change\", { detail: { open: this.open }, bubbles: true });\n this.dispatchEvent(downloadReportEvent);\n }\n\n render() {\n return html`\n ${this.open ? html`` : nothing}\n `\n }\n}\n\n\n\n\nfunction isDocumentFragment(element: Node): element is DocumentFragment {\n return (element as any)?.getElementById;\n}\n\n\n\n/** Returns the first (starting at node) inclusive ancestor that matches selectors, and null otherwise. */\nconst closestNode = (node: Node, predicate: (node: Node) => node is T): T | null => {\n if (predicate(node)) {\n return node;\n } else {\n if (node.parentNode) {\n return closestNode(node.parentNode, predicate);\n } else {\n return null;\n }\n }\n};\n\n","\n// OBSOLETE PLEASE USE \n\n//requirements:\n// input with datalist and data-value-name\n/*\n m.AddPracticeKey)\" >\n \n @foreach (var practice in Model.Practices)\n {\n \n }\n \n*/\nexport function RegisterInput(inputElement: HTMLInputElement) {\n //todo learn about memory deallocation\n new InputSelect(inputElement);\n}\n\n\nclass InputSelect {\n inputElement: HTMLInputElement\n constructor(inputElement: HTMLInputElement) {\n this.inputElement = inputElement;\n this.applyRequiredDataListItem();\n this.submitFormData();\n }\n\n applyRequiredDataListItem() {\n this.inputElement.addEventListener(\"change\", function (event: Event) {\n\n var datalist = this.list as HTMLDataListElement;\n // Determine whether an option exists with the current value of the input.\n const optionFound = findOption(datalist, this.value) != null;\n // use the setCustomValidity function of the Validation API\n // to provide an user feedback if the value does not exist in the datalist\n if (optionFound) {\n this.setCustomValidity(\"\");\n } else {\n this.setCustomValidity(\"Please select an item in the list.\");\n }\n });\n }\n\n\n submitFormData() {\n const inputName = this.inputElement.dataset[\"valueName\"];\n if (inputName) {\n this.inputElement.form.addEventListener(\"formdata\", (event: FormDataEvent) => {\n const option = findOption(this.inputElement.list as HTMLDataListElement, this.inputElement.value);\n event.formData.append(inputName, option.dataset[\"value\"]);\n });\n }\n }\n}\n\n\nfunction findOption(datalist: HTMLDataListElement, value: string) {\n // todo why not for??\n for (var j = 0; j < datalist.options.length; j++) {\n if (value == datalist.options[j].value) {\n return datalist.options[j];\n }\n }\n}\n\n","/*\ntodo:\nshould be download-item\n2px height https://nolanlawson.com/2021/01/03/options-for-styling-web-components/\n*/\n\nimport { html, css, LitElement } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport '@material/mwc-linear-progress'\n\n@customElement('download-bar')\nexport class DownloadBar extends LitElement {\n static styles = css`\n :host { \n display: block; \n }\n\n .description{\n color: rgb(96, 94, 92);\n font-size: 12px;\n line-height: 18px;\n }\n `;\n\n @property()\n title: string;\n @property()\n description: string;\n\n //0-100\n @property()\n progress: number;\n\n render() {\n const showBuffer = this.progress == 0 ? 0 : 1;\n return html`\n
${this.title}
\n \n
${this.description}
\n `;\n }\n}\n","import { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport { DownloadReportEvent } from './../download-manager';\n\ndeclare global {\n interface WindowEventMap {\n \"download-report\": CustomEvent\n }\n}\n\n/*\ntodo: \nconsider controller for updating\nconsider litstate\nnew download-bar per download\ndismiss animation\n*/\n\nimport { DownloadBar } from './download-bar';\nDownloadBar;\nimport { Button } from '@material/mwc-button'\nButton;\n\n\n@customElement('message-list')\nexport class MessageList extends LitElement {\n static styles = css`\n :host { \n display: block; \n background-color: rgb(250, 249, 248);\n }\n\n \n .danger {\n --mdc-theme-primary: var(--bootstrap-danger);\n color:var(--bootstrap-danger);\n }\n\n :host([hidden]) { \n display: none; \n }\n\n div {\n display:flex;\n flex-direction:row;\n align-items: center;\n padding-left:10px;\n padding-right:10px;\n }\n .content{\n width:100%;\n margin-left:20px;\n margin-right:20px;\n }\n `;\n\n @property()\n title = \"Starting Download\";\n\n private _progress = 0;\n private _visible = false;\n private _failed = false;\n connectedCallback() {\n super.connectedCallback()\n window.addEventListener(\"download-report\", this._downloadReportEvent);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback()\n window.removeEventListener(\"download-report\", this._downloadReportEvent);\n }\n\n\n private _getDescriptionText = () => {\n switch (true) {\n case (this._progress < 15):\n return 'Initializing';\n case (this._progress < 25):\n return 'Queuing Report';\n case (this._progress < 45):\n return 'Analyzing Report';\n case (this._progress < 65):\n return 'Retrieving Data';\n case (this._progress < 75):\n return 'Preparing Download';\n case (this._progress >= 100):\n return 'Completed';\n default:\n return 'Rendering Report';\n }\n }\n\n private _downloadReportEvent = (event: CustomEvent) => {\n console.log(\"DownloadReportEvent status Event triggered\");\n console.log(event);\n this._progress = event.detail.progress;\n this.title = `Downloading: ${event.detail.reportName} `;\n\n if (event.detail.newDownload === true) {\n this._visible = true;\n }\n this._failed = event.detail.failed ? true : false;\n this.requestUpdate();\n }\n\n dismissHandler(event: Event) {\n console.log(event.target);\n // todo might be nicer to have an animation\n this._visible = false;\n this.requestUpdate();\n }\n\n dismissTemplate = html`Dismiss`\n failedTemplate = html`
Error: Unable to download report\n ${this.dismissTemplate}\n
`\n\n render() {\n return this._visible ?\n this._failed ? this.failedTemplate :\n html`\n
\n ${this.dismissTemplate}\n
`\n : nothing\n }\n\n}","import { css, html, LitElement } from \"lit\";\nimport { customElement, property } from \"lit/decorators.js\";\n\n@customElement('alert-message')\nexport class AlertMessage extends LitElement {\n static styles = css`\n\n :host {\n padding:1em;\n box-sizing: border-box;\n display: grid;\n grid-template-columns: auto 1fr auto;\n align-items: center;\n gap: 1em;\n box-shadow: rgba(0, 0, 0, 0.52) 0px 8px 10px -6px;\n border: 0.5px solid #f3f4f6;\n border-radius: 2px;\n }\n \n :host {\n background-color: white;\n color:#084298;\n }\n\n :host([level=warning]){\n color:#664d03;\n }\n \n :host([level=error]){\n color:#842029;\n }\n \n :host([height=flat]){\n box-shadow: rgba(0, 0, 0, 0) 0px 0px 0px 0px;\n }\n\n :host([height=short]){\n box-shadow: rgba(0, 0, 0, 0.52) 0px 2px 4px -2px;\n }\n\n :host([height=average]){\n }\n\n :host([height=tall]){\n box-shadow: rgba(0, 0, 0, 0.52) 0px 25px 50px -12px;\n }\n\n .end-wrapper\n {\n display:flex;gap: 1em;\n }\n`;\n\n @property() level: \"information\" | \"warning\" | \"error\";\n @property() height: \"flat\" | \"short\" | \"average\" | \"tall\" = \"average\";\n \n render() {\n return html`\n \n ${this.#getIcon(this.level)}\n \n \n
\n \n \n
\n `\n }\n\n #getIcon = (level: string) => {\n switch (level) {\n case \"information\":\n return \"info\"\n case \"warning\":\n return \"warning\";\n case \"error\":\n return \"report\";\n default:\n return \"info\"\n }\n }\n}","import appInsights from './../application-insights';\nimport { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js'\nimport { MessagePromiseEvent, MessageDetail, MessagePromise } from 'src/modules/helpers/message-helper';\nimport { later } from 'src/modules/helpers/promise-helper';\nimport { AlertMessage } from './alert-message';\nAlertMessage;\nimport \"@material/mwc-icon\";\n\n//cancelable promise\n//https://stackoverflow.com/questions/22707475/how-to-make-a-promise-from-settimeout \n\ntype MessageType = { message: string, level: \"error\" | \"success\" | \"information\", timer: Promise, showProgress: boolean }\n\n@customElement('message-manager')\nexport class MessageManager extends LitElement {\n static styles = [\n css`\n :host {\n display: flex;\n position: fixed;\n z-index: 1;\n flex-direction: column;\n gap: 1vh;\n inset-block-end: 1em;\n inset-inline-end: 1em;\n\n width:320px;\n }\n\n .alert-message {\n box-shadow: rgba(0, 0, 0, 0.52) 0px 6px 13px -2px;\n }\n\n fluent-progress-ring {\n --density: -3;\n }\n `\n ];\n\n @state() Messages: MessageType[] = []\n\n messageHandler = (e: CustomEvent) => {\n this.#addMessage(e.detail.message, e.detail.level);\n }\n\n #addMessage = (message: string, level: \"error\" | \"success\") => {\n var newMessage: MessageType = {\n message: message,\n level: level,\n showProgress: false,\n get timer() {\n return later(3000, this)\n }\n }\n\n this.Messages = [...this.Messages, newMessage];\n newMessage.timer.then((x) =>\n this.removeMessage(x)\n )\n\n console.log(\"message added\")\n\n }\n actionMessageHandler = async (e:MessagePromiseEvent)=> {\n console.log(\"message-manage-action start\");\n\n var newMessage: MessageType = {\n message: e.messages.progress,\n level: \"information\",\n timer: null,\n showProgress: e.messages.progress == null\n }\n this.Messages = [...this.Messages, newMessage];\n \n try {\n await e.promise;\n this.removeMessage(newMessage);\n // maybe it would be better to update message, or replace message (but at this stage it's unlikely to be there for long)\n this.#addMessage(e.messages.success, \"success\")\n } catch (ex) {\n console.log(\"promise error\")\n this.removeMessage(newMessage);\n this.#addMessage(e.messages.failed, \"error\")\n appInsights.trackException(ex)\n } finally {\n console.log(\"message-manage-action end\");\n }\n \n }\n\n promiseMessageHandler = async (e: CustomEvent>) => {\n var newMessage: MessageType = {\n message: e.detail.messages.progress,\n level: \"information\",\n timer: null,\n showProgress: e.detail.messages.progress == null\n }\n this.Messages = [...this.Messages, newMessage];\n\n try {\n await e.detail.task;\n this.removeMessage(newMessage);\n\n // maybe it would be better to update message, or replace message (but at this stage it's unlikely to be there for long)\n this.#addMessage(e.detail.messages.success, \"success\")\n } catch (ex) {\n console.log(\"promise error\")\n this.removeMessage(newMessage);\n this.#addMessage(e.detail.messages.failed, \"error\")\n appInsights.trackException(ex)\n }\n }\n\n removeMessage = (message: MessageType) => {\n this.Messages = this.Messages.filter(m => m !== message);\n }\n\n\n\n connectedCallback() {\n super.connectedCallback();\n window.addEventListener(\"interface-message\", this.messageHandler);\n window.addEventListener(\"message-promise\", this.promiseMessageHandler);\n window.addEventListener(MessagePromiseEvent.eventName, this.actionMessageHandler);\n }\n\n disconnectedCallback(): void {\n window.removeEventListener(\"interface-message\", this.messageHandler);\n window.removeEventListener(\"message-promise\", this.promiseMessageHandler);\n window.removeEventListener(MessagePromiseEvent.eventName, this.actionMessageHandler);\n }\n render() {\n if (this.Messages.length === 0) {\n return nothing;\n }\n\n return html`\n ${this.Messages.map(m => html`\n ${m.showProgress ? html`` : nothing}\n ${m.message}\n `)}\n `;\n }\n\n\n}\n","import {css, html, LitElement} from 'lit';\nimport {customElement, property, state} from 'lit/decorators.js';\nimport {ChangeType, ReportPermissionChange} from '../services';\n\n@customElement('permission-changes')\nexport class PermissionChanges extends LitElement {\n static styles = css`\n .container {\n box-sizing: border-box;\n padding: 0.25rem;\n max-height: 500px;\n overflow: auto;\n }\n\n .entry {\n border-radius: 0.5rem;\n overflow: hidden;\n transition: box-shadow 0.1s ease-in-out;\n\n &.expanded {\n box-shadow: var(--card-box-shadow);\n }\n }\n\n .expandable {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 0.25rem;\n cursor: pointer;\n\n &:hover {\n background-color: rgba(0, 0, 0, 0.05);\n }\n\n &.expanded {\n background-color: rgba(0, 0, 0, 0.03);\n }\n\n .expand-icon {\n transition: transform 0.3s ease-in-out;\n\n &.expanded {\n transform: rotate(180deg);\n }\n }\n }\n\n .expandable-content {\n max-height: 0;\n overflow: hidden;\n display: flex;\n flex-direction: column;\n margin-left: 0.5rem;\n gap: 0.5rem;\n transition: max-height 0.2s ease-in-out, padding 0.2s ease-in-out;\n\n &.expanded {\n max-height: 200px;\n overflow: auto;\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n animation: hide-scroll 0.2s backwards;\n }\n }\n\n .diff {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n\n &.added {\n color: rgb(15, 62, 15);\n }\n\n &.removed {\n color: rgb(86, 21, 21);\n }\n\n &.updated {\n color: rgb(21, 70, 86);\n }\n }\n\n .count-badge {\n opacity: 0.5;\n font-size: 0.75rem;\n }\n\n @keyframes hide-scroll {\n from, to {\n overflow: hidden;\n }\n }\n `;\n\n @property({type: Object, attribute: \"data\"}) permissionChanges: ReportPermissionChange[];\n\n @state() expandedItem: string | null = null;\n\n toggleExpand(reportKey: number, userKey: number) {\n const itemKey = this.getItemKey(reportKey, userKey);\n this.expandedItem = this.expandedItem === itemKey ? null : itemKey;\n }\n\n getItemKey(reportKey: number, userKey: number): string {\n return `${reportKey}-${userKey}`;\n }\n\n getIconName(changeType: ChangeType) {\n switch (changeType) {\n case ChangeType.Added:\n return 'add_circle';\n case ChangeType.Removed:\n return 'remove_circle';\n case ChangeType.Updated:\n return 'swap_vertical_circle';\n default:\n return 'help_outline';\n }\n }\n\n render() {\n return html`\n
\n ${this.permissionChanges.map(pc => {\n const expanded = this.expandedItem === this.getItemKey(pc.reportKey, pc.userKey) ? 'expanded' : '';\n return html`\n
\n
this.toggleExpand(pc.reportKey, pc.userKey)}\">\n
\n ${this.getIconName(pc.changeType)}\n ${pc.changeType} access to report ${pc.reportName} for user ${pc.userName}\n
\n
\n ${pc.facilityChanges.length}\n arrow_drop_down\n
\n
\n\n
\n ${pc.facilityChanges.map(fac => html`\n
\n subdirectory_arrow_right\n ${this.getIconName(fac.changeType)}\n \n ${fac.changeType} ${fac.decrypt ? 'decrypt' : 'non-decrypt'} access\n ${fac.facilityKey\n ? html` to facility ${fac.facilityName}`\n : html` (report only)`\n }\n \n
\n `)}\n
\n
\n `;\n })}\n
\n `;\n }\n}\n","import { LitElement, html, css } from 'lit';\nimport { customElement, property, queryAssignedElements } from 'lit/decorators.js'\n\nexport type RadioButtonListChangeDetail = { value:any, index:number }\n\n@customElement('radio-button-list')\nexport class RadioButtonList extends LitElement {\n static styles = [\n css`\n :host {\n display: block;\n }\n\n div {\n display: flex;\n flex-direction:row;\n \n }\n \n :host([grow]) ::slotted(*) { flex-grow: 1; }\n `\n ];\n\n @property({ attribute:\"selected-value\", type:Object }) selectedValue: any;\n @property({ attribute:\"selected-index\", type:Number }) selectedIndex: number;\n\n @property() label: string;\n\n @queryAssignedElements({selector: 'radio-button'}) buttons: Array;\n\n\n public selectValue = (value:any) => {\n var valueButton = this.buttons.find(rb => rb.value == value)\n this.selectItem(valueButton);\n }\n\n private selectItem = (item:RadioButton) => {\n this.buttons.forEach((rb, i) => {\n if(item ==rb)\n {\n rb.active = true\n this.selectedValue = rb.value\n this.selectedIndex = i;\n } else{\n rb.active = false;\n }\n });\n }\n\n private clickHandler = (e: MouseEvent) => {\n this.selectItem(e.target as RadioButton)\n this.dispatchEvent(new CustomEvent(\"change\",{ detail:{ value:this.selectedValue, index:this.selectedIndex } }))\n };\n\n render() {\n return html`\n
${this.label}
\n
\n \n
`;\n }\n}\n\n@customElement('radio-button')\nexport class RadioButton extends LitElement {\n static styles = [\n css`\n :host {\n display: flex;\n }\n\n :host([grow]){\n flex-grow:1;\n }\n\n fluent-button {\n --control-corner-radius: 0;\n flex-grow:1;\n }\n `\n ];\n\n @property({ type:Boolean}) active: boolean;\n \n @property({ type: String }) value: string;\n \n private clickHandler = (event:Event) =>{\n }\n render() {\n var appearance = this.active ? \"accent\":\"outline\"\n return html`\n \n \n \n \n \n `;\n }\n}\n","import {css, html, LitElement} from 'lit';\nimport {consume} from '@lit/context';\nimport {customElement, state} from 'lit/decorators.js'\nimport {classMap} from 'lit/directives/class-map.js';\nimport {unsafeHTML} from 'lit/directives/unsafe-html.js';\nimport {IReportNews, services} from 'src/services';\nimport {editModeContext} from 'src/context/content-context';\nimport {subscriberKeyContext} from 'src/context/subscriber-context';\n\n@customElement('report-news')\nexport class ReportNews extends LitElement {\n static styles = [\n css`\n .news {\n position: relative;\n margin-bottom: 16px;\n }\n\n .overlap-top-right {\n position: absolute;\n top: 0;\n right: 0;\n }\n\n .preview {\n &[source] {\n position: relative;\n }\n\n &[source]:hover {\n outline: black 1px solid;\n }\n\n &[source]:hover::before {\n content: attr(source);\n width: max-content;\n background-color: black;\n outline: black 1px solid;\n color: #fff;\n text-align: center;\n bottom: 0;\n right: 0;\n padding: 1em;\n position: absolute;\n }\n }\n `\n ];\n\n private static editModeCache = new Map();\n\n @consume({context: editModeContext}) public editMode: boolean = false;\n @consume({context: subscriberKeyContext}) public subscriberKey?: number;\n\n @state() reportNews: IReportNews[] = [];\n\n connectedCallback() {\n super.connectedCallback();\n\n const useEditModeCache = this.editMode && !!this.subscriberKey;\n\n if (useEditModeCache) {\n const cachedReportNews = ReportNews.editModeCache.get(this.subscriberKey);\n if (cachedReportNews) {\n this.reportNews = cachedReportNews;\n return;\n }\n }\n\n services.report.news(this.editMode, this.subscriberKey).then((reportNews: IReportNews[]) => {\n this.reportNews = reportNews;\n if (useEditModeCache) {\n ReportNews.editModeCache.set(this.subscriberKey, reportNews);\n }\n });\n }\n\n dismissNews = async (reportKey: number) => {\n this.reportNews = this.reportNews.filter(news => news.reportKey !== reportKey);\n await services.report.dismissNews(reportKey);\n }\n\n render() {\n const classes = {news: true, preview: this.editMode};\n return this.reportNews.length > 0\n ? html`\n
\n \n ${this.reportNews.map((news) =>\n html`\n
\n ${unsafeHTML(news.html)}\n ${!this.editMode ? html`\n {\n e.stopPropagation();\n await this.dismissNews(news.reportKey);\n }}>\n ` : ''}\n
`\n )}\n
`\n : html``;\n }\n}\n","/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\nimport {Routes} from './routes';\n\n\ntype URLParts = {pathname:string,search:string,hash:string}\n// We cache the origin since it can't change\nconst origin = location.origin || location.protocol + '//' + location.host;\n\n/**\n * A root-level router that installs global event listeners to intercept\n * navigation.\n *\n * This class extends Routes so that it can also have a route configuration.\n *\n * There should only be one Router instance on a page, since the Router\n * installs global event listeners on `window` and `document`. Nested\n * routes should be configured with the `Routes` class.\n */\nexport class Router extends Routes {\n // used to detect if it is a hashchange link, because popstate is called(an we want to ignore)\n // when clicking a hash link Data Sources popstate is triggered\n isHashChangeNavigation:boolean= false;\n override hostConnected() {\n super.hostConnected();\n window.addEventListener('click', this._onClick);\n window.addEventListener('popstate', this._onPopState);\n window.addEventListener('lit-routes-goto', this._onGoTo)\n // Kick off routed rendering by going to the current URL\n this.goto(`${window.location.pathname}${window.location.search}${window.location.hash}`);\n }\n\n override hostDisconnected() {\n super.hostDisconnected();\n window.removeEventListener('click', this._onClick);\n window.removeEventListener('popstate', this._onPopState);\n }\n\n private _onClick = (e: MouseEvent) => {\n this.isHashChangeNavigation = false;\n const isNonNavigationClick =\n e.button !== 0 || e.metaKey || e.ctrlKey || e.shiftKey;\n if (e.defaultPrevented || isNonNavigationClick) {\n return;\n }\n\n const anchor = e\n .composedPath()\n .find((n) => (n as HTMLElement).tagName === 'A') as\n | HTMLAnchorElement\n | undefined;\n if (\n anchor === undefined ||\n anchor.target !== '' ||\n anchor.hasAttribute('download') ||\n anchor.getAttribute('rel') === 'external'\n ) {\n return;\n }\n\n const href = anchor.href;\n if (href === '' || href.startsWith('mailto:')) {\n return;\n }\n\n const location = window.location;\n if (anchor.origin !== origin) {\n return;\n }\n\n const path = `${anchor.pathname}${anchor.search}${anchor.hash}` \n if(this.isRouteMatch(path))\n {\n \n if(this.isHashChange(window.location,anchor)){\n // at this point we are going to ignore any \"hash routing\" \n // and let the browser take over\n // maybe be able to change this in the future (once we support child routes)\n console.log(\"router hashchange detected\")\n this.isHashChangeNavigation = true;\n } else {\n e.preventDefault();\n if (href !== location.href) {\n window.history.pushState({}, '', href);\n this.goto(`${anchor.pathname}${anchor.search}${anchor.hash}`);\n }\n } \n \n }\n };\n\n private _onPopState = (_e: PopStateEvent) => {\n if(this.isHashChangeNavigation) { //skip navigation on hashchange event, as currently \"router enter()\" can reload a report\n this.isHashChangeNavigation = false;\n } else {\n this.goto(`${window.location.pathname}${window.location.search}${window.location.hash}`);\n }\n };\n\n private _onGoTo= (_e:RouterGoToEvent) => {\n this.gotoWithPush(_e.url)\n }\n\n isHashChange = (currentUrl:URLParts,newUrl:URLParts) => {\n if(currentUrl.pathname === newUrl.pathname && currentUrl.search === newUrl.search)\n {\n return currentUrl.hash !== newUrl.hash;\n }\n return false;\n }\n}\n\nexport class RouterGoToEvent extends Event {\n static readonly eventName = 'lit-routes-goto';\n onDisconnect?: () => void;\n\n url:string /*| URL*/;\n\n constructor(url:string/*| URL*/) {\n super(RouterGoToEvent.eventName, {\n bubbles: true,\n composed: true,\n cancelable: false,\n });\n this.url = url;\n }\n}\n\ndeclare global {\n interface WindowEventMap {\n [RouterGoToEvent.eventName]:RouterGoToEvent\n }\n}\n","/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\n\n/// \n\nimport type {ReactiveController, ReactiveControllerHost} from 'lit';\n\n// We cache the origin since it can't change\nconst origin = location.origin || location.protocol + '//' + location.host;\n\nexport interface BaseRouteConfig {\n name?: string | undefined;\n render?: (params: {[key: string]: string | undefined}) => unknown;\n enter?: (params: {\n [key: string]: string | undefined;\n }) => Promise | boolean;\n}\n\n/**\n * A RouteConfig that matches against a `path` string. `path` must be a\n * [`URLPattern` compatible pathname pattern](https://developer.mozilla.org/en-US/docs/Web/API/URLPattern/pathname).\n */\nexport interface PathRouteConfig extends BaseRouteConfig {\n path: string;\n}\n\n/**\n * A RouteConfig that matches against a given [`URLPattern`](https://developer.mozilla.org/en-US/docs/Web/API/URLPattern)\n *\n * While `URLPattern` can match against protocols, hostnames, and ports,\n * routes will only be checked for matches if they're part of the current\n * origin. This means that the pattern is limited to checking `pathname` and\n * `search`.\n */\nexport interface URLPatternRouteConfig extends BaseRouteConfig {\n pattern: URLPattern;\n}\n\n/**\n * A description of a route, which path or pattern to match against, and a\n * render() callback used to render a match to the outlet.\n */\nexport type RouteConfig = PathRouteConfig | URLPatternRouteConfig;\n\n// A cache of URLPatterns created for PathRouteConfig.\n// Rather than converting all given RoutConfigs to URLPatternRouteConfig, this\n// lets us make `routes` mutable so users can add new PathRouteConfigs\n// dynamically.\nconst patternCache = new WeakMap();\n\nconst isPatternConfig = (route: RouteConfig): route is URLPatternRouteConfig =>\n (route as URLPatternRouteConfig).pattern !== undefined;\n\nconst getPattern = (route: RouteConfig) => {\n if (isPatternConfig(route)) {\n return route.pattern;\n }\n let pattern = patternCache.get(route);\n if (pattern === undefined) {\n patternCache.set(route, (pattern = new URLPattern({pathname: route.path})));\n }\n return pattern;\n};\n\n/**\n * A reactive controller that performs location-based routing using a\n * configuration of URL patterns and associated render callbacks.\n */\nexport class Routes implements ReactiveController {\n private readonly _host: ReactiveControllerHost & HTMLElement;\n\n /*\n * The currently installed set of routes in precedence order.\n *\n * This array is mutable. To dynamically add a new route you can write:\n *\n * ```ts\n * this._routes.routes.push({\n * path: '/foo',\n * render: () => html`

Foo

`,\n * });\n * ```\n *\n * Mutating this property does not trigger any route transitions. If the\n * changes may result is a different route matching for the current path, you\n * must instigate a route update with `goto()`.\n */\n routes: Array = [];\n\n /**\n * A default fallback route which will always be matched if none of the\n * {@link routes} match. Implicitly matches to the path \"/*\".\n */\n fallback?: BaseRouteConfig;\n\n ignoreUnknownRoutes:boolean =false;\n /*\n * The current set of child Routes controllers. These are connected via\n * the routes-connected event.\n */\n private readonly _childRoutes: Array = [];\n\n private _parentRoutes: Routes | undefined;\n\n /*\n * State related to the current matching route.\n *\n * We keep this so that consuming code can access current parameters, and so\n * that we can propagate tail matches to child routes if they are added after\n * navigation / matching.\n */\n private _currentPathname: string | undefined;\n private _currentRoute: RouteConfig | undefined;\n private _currentParams: {\n [key: string]: string | undefined;\n } = {};\n\n /**\n * Callback to call when this controller is disconnected.\n *\n * It's critical to call this immediately in hostDisconnected so that this\n * controller instance doesn't receive a tail match meant for another route.\n */\n // TODO (justinfagnani): Do we need this now that we have a direct reference\n // to the parent? We can call `this._parentRoutes.disconnect(this)`.\n private _onDisconnect: (() => void) | undefined;\n\n constructor(\n host: ReactiveControllerHost & HTMLElement,\n routes: Array,\n options?: {fallback?: BaseRouteConfig, ignoreUnknownRoutes:boolean}\n ) {\n (this._host = host).addController(this);\n this.routes = [...routes];\n this.fallback = options?.fallback;\n this.ignoreUnknownRoutes = options?.ignoreUnknownRoutes ?? false;\n }\n\n /**\n * Returns a URL string of the current route, including parent routes,\n * optionally replacing the local path with `pathname`.\n */\n link(pathname?: string): string {\n if (pathname?.startsWith('/')) {\n return pathname;\n }\n if (pathname?.startsWith('.')) {\n throw new Error('Not implemented');\n }\n pathname ??= this._currentPathname;\n return (this._parentRoutes?.link() ?? '') + pathname;\n }\n\n\n isActiveRoute = (routeName:string) =>this._currentRoute?.name === routeName\n \n\n async gotoWithPush(pathname: string, data?:any) {\n window.history.pushState(data, null,pathname);\n return this.goto(pathname)\n }\n\n\n\n /**\n * Navigates this routes controller to `pathname`.\n *\n * This does not navigate parent routes, so it isn't (yet) a general page\n * navigation API. It does navigate child routes if pathname matches a\n * pattern with a tail wildcard pattern (`/*`).\n */\n async goto(pathname: string) {\n // TODO (justinfagnani): handle absolute vs relative paths separately.\n // TODO (justinfagnani): do we need to detect when goto() is called while\n // a previous goto() call is still pending?\n\n // TODO (justinfagnani): generalize this to handle query params and\n // fragments. It currently only handles path names because it's easier to\n // completely disregard the origin for now. The click handler only does\n // an in-page navigation if the origin matches anyway.\n let tailGroup: string | undefined;\n\n if (this.routes.length === 0 && this.fallback === undefined) {\n // If a routes controller has none of its own routes it acts like it has\n // one route of `/*` so that it passes the whole pathname as a tail\n // match.\n tailGroup = pathname;\n this._currentPathname = '';\n // Simulate a tail group with the whole pathname\n this._currentParams = {0: tailGroup};\n } else {\n const route = this._getRoute(pathname);\n if (route === undefined) {\n if(this.ignoreUnknownRoutes){\n console.error(`No route found for ${pathname}`)\n return;\n } else {\n throw new Error(`No route found for ${pathname}`);\n }\n }\n\n const pattern = getPattern(route);\n const result = pattern.exec(pathname, origin);\n const params = { ...result?.pathname.groups, ...result?.search.groups } ;\n tailGroup = getTailGroup(params);\n if (typeof route.enter === 'function') {\n const success = await route.enter(params);\n // If enter() returns false, cancel this navigation\n if (success === false) {\n return;\n }\n }\n // Only update route state if the enter handler completes successfully\n this._currentRoute = route;\n this._currentParams = params;\n this._currentPathname =\n tailGroup === undefined\n ? pathname\n : pathname.substring(0, pathname.length - tailGroup.length);\n }\n\n // Propagate the tail match to children\n if (tailGroup !== undefined) {\n for (const childRoutes of this._childRoutes) {\n childRoutes.goto(tailGroup);\n }\n }\n this._host.requestUpdate();\n }\n\n /**\n * The result of calling the current route's render() callback.\n */\n outlet() {\n return this._currentRoute?.render?.(this._currentParams);\n }\n\n /**\n * The current parsed route parameters.\n */\n get params() {\n return this._currentParams;\n }\n\n isRouteMatch = (pathname: string):boolean => this._getRoute(pathname) != undefined;\n \n /**\n * Matches `url` against the installed routes and returns the first match.\n */\n private _getRoute(pathname: string): RouteConfig | undefined {\n const url = new URL(pathname, origin);\n \n const matchedRoute = this.routes.find((r) =>\n getPattern(r).test({pathname:url.pathname,search:url.search})\n );\n if (matchedRoute || this.fallback === undefined) {\n return matchedRoute;\n }\n if (this.fallback) {\n // The fallback route behaves like it has a \"/*\" path. This is hidden from\n // the public API but is added here to return a valid RouteConfig.\n return {...this.fallback, path: '/*'};\n }\n return undefined;\n }\n\n hostConnected() {\n this._host.addEventListener(\n RoutesConnectedEvent.eventName,\n this._onRoutesConnected\n );\n const event = new RoutesConnectedEvent(this);\n this._host.dispatchEvent(event);\n this._onDisconnect = event.onDisconnect;\n }\n\n hostDisconnected() {\n // When this child routes controller is disconnected because a parent\n // outlet rendered a different template, disconnecting will ensure that\n // this controller doesn't receive a tail match meant for another route.\n this._onDisconnect?.();\n this._parentRoutes = undefined;\n }\n\n private _onRoutesConnected = (e: RoutesConnectedEvent) => {\n // Don't handle the event fired by this routes controller, which we get\n // because we do this.dispatchEvent(...)\n if (e.routes === this) {\n return;\n }\n\n const childRoutes = e.routes;\n this._childRoutes.push(childRoutes);\n childRoutes._parentRoutes = this;\n\n e.stopImmediatePropagation();\n e.onDisconnect = () => {\n // Remove route from this._childRoutes:\n // `>>> 0` converts -1 to 2**32-1\n this._childRoutes?.splice(\n this._childRoutes.indexOf(childRoutes) >>> 0,\n 1\n );\n };\n\n const tailGroup = getTailGroup(this._currentParams);\n if (tailGroup !== undefined) {\n childRoutes.goto(tailGroup);\n }\n };\n}\n\n/**\n * Returns the tail of a pathname groups object. This is the match from a\n * wildcard at the end of a pathname pattern, like `/foo/*`\n */\nconst getTailGroup = (groups: {[key: string]: string | undefined}) => {\n let tailKey: string | undefined;\n for (const key of Object.keys(groups)) {\n if (/\\d+/.test(key) && (tailKey === undefined || key > tailKey!)) {\n tailKey = key;\n }\n }\n return tailKey && groups[tailKey];\n};\n\n/**\n * This event is fired from Routes controllers when their host is connected to\n * announce the child route and potentially connect to a parent routes controller.\n */\nexport class RoutesConnectedEvent extends Event {\n static readonly eventName = 'lit-routes-connected';\n readonly routes: Routes;\n onDisconnect?: () => void;\n\n constructor(routes: Routes) {\n super(RoutesConnectedEvent.eventName, {\n bubbles: true,\n composed: true,\n cancelable: false,\n });\n this.routes = routes;\n }\n}\n\ndeclare global {\n interface HTMLElementEventMap {\n [RoutesConnectedEvent.eventName]: RoutesConnectedEvent;\n }\n}","import { html, LitElement } from \"lit\";\nimport { customElement, property } from \"lit/decorators.js\";\n\n/**\n * Attaches to click and calls show on target component\n */\n@customElement(\"show-component-wrapper\")\nexport class ShowComponentWrapper extends LitElement {\n @property() for: string;\n\n clickEventHandler(event: Event) {\n const target = document.getElementById(this.for);\n // todo should deal with target === null or show not existing\n (target as any).show();\n }\n\n render() {\n return html`\n \n `\n }\n}","import { LitElement, html, css, nothing } from 'lit';\nimport { property, customElement } from 'lit/decorators.js';\nimport { Icon } from '@material/mwc-icon';\nIcon;\n\n// todo can panels go on top of each other (dynamic z-index?)\n// todo better sizing (maybe 100% for small screens)\n// todo -- background theme color\n// todo consider moving the the other content\n// todo disablebutton property\n// todo escape closes panel\n\n@customElement('side-panel')\nexport class SidePanel extends LitElement {\n\n @property({ type: Boolean, reflect: true }) open = false;\n @property({ type: Boolean, attribute: \"open-window\" }) openWindow = false;\n @property({ attribute: \"open-window-link\" }) openWindowLink:string;\n\n static styles = css`\n :host { \n display: block; \n position:fixed;\n top:0;\n left:0;\n transition: 0.5s; \n width:min-content;\n min-width:50%;\n max-width:100%;\n left: -100%;\n z-index:1;\n height:100vh;\n overflow:auto;\n background-color:white;\n\n box-sizing: border-box;\n border:2px;\n border-right-style:solid;\n border-right: 2px solid rgb(192, 192, 192);\n\n }\n\n .content-wrapper{\n padding: 2rem;\n isolation:isolate;\n }\n\n .close-button{\n position: sticky;\n top: 14px;\n float: right;\n border-radius: 30px;\n margin: 14px;\n background-color:transparent;\n backdrop-filter: grayscale(1) brightness(1.8) blur(15px);\n\n z-index: 1;\n }\n\n :host([open]) {\n left:0;\n }\n\n `;\n\n show = () => {\n this.open = true;\n }\n\n toggle = () => {\n this.open = !this.open;\n }\n\n hide = () => {\n this.open = false;\n }\n\n render() {\n return html`\n \n ${this.openWindow ? html`{ this.open=false;window.open(this.openWindowLink); }} >`:nothing}\n
\n \n \n
\n `;\n }\n}","import { css, html, LitElement, nothing } from \"lit\";\nimport { customElement, property } from \"lit/decorators.js\";\n\nimport \"@material/mwc-icon\"\n\n@customElement('thalamus-card')\nexport class ThalamusCard extends LitElement {\n\n static styles = css`\n :host {\n\n box-sizing:border-box;\n display: block;\n\n border: 0px solid rgba(0,0,0,.125);\n border-radius: 0.25rem;\n\n background-color: var( --card-background-color);\n box-shadow: var(--card-box-shadow);\n }\n\n .body {\n padding: 1.25rem;\n }\n\n header {\n display:flex;\n flex-direction: row;\n justify-content: space-between;\n\n font-weight: 500;\n line-height: 1.2;\n font-size: 1.25rem;\n align-items: center;\n gap: 1em;\n }\n\n hr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0,0,0,.1);\n }\n`;\n\n @property() title: string;\n @property() icon: string;\n @property({ type:Boolean}) underline: boolean;\n render() {\n return html`\n \n
\n
\n
\n ${this.title}\n
\n \n \n ${this.icon}\n \n
\n ${this.underline? html`
`:nothing}\n \n
\n`\n }\n}","import { LitElement, html, css, nothing } from 'lit';\nimport { customElement, property } from 'lit/decorators.js'\n\n@customElement('thalamus-hero')\nexport class ThalamusHero extends LitElement {\n static styles = [\n css`\n :host {\n display: block;\n \n /* padding: 1em;*/\n\n /*background-color:#dbeeff;*/\n box-shadow:0px 10px 25px -10px rgba(0,0,0,0.52);\n\n \n padding: clamp(1em, 5%, 6em);\n }\n\n :host([short]){\n padding-block: 0;\n }\n\n .grid{\n display:grid;\n grid-template-columns:1fr 1fr;\n gap:1em;\n }\n\n .left {\n display:flex;\n flex-direction: column;\n justify-content: space-evenly;\n gap:0.8em;\n }\n\n .title {\n font-size:2em;\n font-weight:700;\n }\n\n .cta{\n \n }\n .cta fluent-button {\n border-radius:0;\n --control-corner-radius:0;\n /*box-shadow: 5px 10px;*/\n box-shadow:0px 10px 25px -10px rgba(0,0,0,0.52);\n }\n\n img{\n display: block;\n width: 100%; /* or any custom size */\n /*height: 100%; \n object-fit: contain;*/\n }\n\n .image{\n align-self: center;\n justify-self: center;\n }\n\n a {\n //just to make it hidden\n display:contents\n }\n `\n ];\n\n@property({ type: String }) title: string;\n@property({ type: String }) description: string;\n@property({ type: String, attribute:\"call-to-action\" }) callToAction: string;\n@property({ type: String, attribute:\"call-to-action-url\" }) callToActionUrl: string;\n@property({ type: String, attribute:\"src\" }) src: string;\n\n@property({ type: Boolean, attribute:\"short\" }) short:boolean=false;\n\n render() {\n return html`\n \n
\n
\n
${this.title}
\n
\n \n ${this.description}\n \n
\n \n ${this.callToActionUrl != null ? html`\n \n `:nothing} \n \n
\n \n \n
\n \n \n \n
\n\n
\n \n \n `;\n }\n}\n","import { css, html, LitElement } from \"lit\";\nimport { customElement, property, query } from \"lit/decorators.js\";\nimport * as pbi from 'powerbi-client';\nimport appInsights from \"src/application-insights\";\nimport { IEmbedSettings } from \"src/services\";\nimport { EmbeddedPowerBiManager } from \"./embedded-powerbi-manager\";\n\nEmbeddedPowerBiManager;\n@customElement(\"thalamus-powerbi-report\")\nexport class ThalamusPowerBiReport extends LitElement {\n\n static styles = css`\n :host{\n display:flex\n }\n\n embedded-powerbi-manager{\n flex-grow:1\n }\n `;\n\n constructor() {\n super();\n }\n\n @property({ attribute: \"report-key\", type: Number }) reportKey: number;\n @property({ attribute: \"username\", }) username: string;\n @property({ attribute: \"facility-reference\", }) facilityReference?: string;\n @property({ attribute: \"embed-settings\", type: Object }) embedSettings: IEmbedSettings;\n\n @query('#embedded-powerbi-manager-id') protected _powerbiManager: EmbeddedPowerBiManager\n\n private _report: pbi.Report;\n\n\n async firstUpdated() {\n this._report = await this._powerbiManager.loadReport({ reportKey: this.reportKey, username: this.username, facilityReference:this.facilityReference }, this.embedSettings);\n }\n\n getCurrentState = async (): Promise => (await this._report.bookmarksManager.capture()).state;\n\n get report() {\n return this._report;\n }\n\n\n fullscreen = () => this._powerbiManager.fullscreen();\n\n loadContainerDataFromActivePage = async (containerName: string) => {\n const activePage = await this._report.getActivePage();\n const visuals = await activePage.getVisuals();\n // todo this is currently kinda bugged, as there is a ton of incorrectly named pages in the database\n var visual = visuals?.find((visual) => visual.name == containerName);\n if(visual == null)\n {\n appInsights.trackEvent({ name:\"power-bi-report-visual-not-found\", properties: { containerName: containerName, page:activePage?.name, reportId:activePage?.report?.config?.id, error:true } } )\n }\n return await visual.exportData(pbi.models.ExportDataType.Summarized)\n }\n\n render = () => html``;\n}\n","import { LitElement, html } from 'lit';\nimport { property, customElement } from 'lit/decorators.js';\n\nimport '@justinribeiro/lite-youtube';\n@customElement('youtube-element')\nexport class YouTubeElement extends LitElement {\n @property() videoid: string;\n\n render() {\n return html`\n \n `;\n }\n}","import { LitElement, html, css } from 'lit';\nimport { property, customElement } from 'lit/decorators.js';\nimport { YouTubeElement } from './youtube-element';\nYouTubeElement;\n\nimport './thalamus-card';\nimport { bootstrap4Styles } from '../styles/bootstrap4';\n//https://codingyaar.com/bootstrap-video-card/\n//render root is dom and we need bootstrap css for now\n\n@customElement('youtube-card')\nexport class YouTubeCard extends LitElement {\n @property() title: string;\n @property() videoid: string;\n @property() description: string;\n\n static styles = [bootstrap4Styles,\n css`\n h5 {\n margin-block-start: 0;\n }\n `]\n\n render() {\n return html`\n \n \n \n `;\n }\n\n}"],"names":["I","CategoryEdit","show","this","_dialog","event","requestUpdate","async","dispatchEvent","CustomEvent","detail","description","_textField","value","icon","_iconName","myEvent","type","bubbles","composed","render","heading","styles","CategoryItem","updating","editCategory","clickCategory","_categoryEdit","updateCategoryHandler","key","requestDeleteHandler","cancelBubble","hidden","Number","Boolean","CategoryList","categoryItems","createCategoryHandler","console","log","newItem","busy","response","displayCreateCategory","_newCategory","map","cat","attribute","CloseButton","ConfirmationDialog","okHandler","e","ConfirmedEvent","dialog","close","openDialogHandler","stopPropagation","preventDefault","showModal","closeEventHandler","confirmText","String","Event","constructor","super","eventName","cancelable","CtxContentButtonGroup","CtxContentButton","behaviour","_clicked","_renderDisplayContent","displayIcon","displayText","_renderDisplayIcon","newlines","boldSnippet","italicSnippet","linkSnippet","heading1Snippet","heading2Snippet","heading3Snippet","heading4Snippet","heading5Snippet","heading6Snippet","orderedListSnippet","unOrderedListSnippet","tableSnippet","tableOfContentsSnippet","heroSnippet","informationMessageSnippet","warningMessageSnippet","errorMessageSnippet","reportNewsSnippet","colleagueAuditSnippet","documentationSnippet","CtxContentEditor","_value","newValue","_internals","setFormValue","_handlePreviewSlotChange","target","assignedElements","forEach","element","HTMLElement","tagName","toLowerCase","_preview","scrollToCursor","previewPosition","_setPreviewValueAndCursorPosition","cursorPosition","readonly","showPreview","editMode","_handleContentFromToolbar","textArea","handleContentChange","content","_textAreaContentChanged","attachInternals","addEventListener","connectedCallback","hasAttribute","getAttribute","disconnectedCallback","document","removeEventListener","_renderTextAreaAndPreviewSlot","_renderBottomSlot","_renderTextArea","classes","_renderPreviewSlot","formAssociated","context","CtxContentHeadingSelect","CtxContentPreview","grow","htmlContent","_markdownPreviewTask","task","signal","management","markdown","preview","catch","aborted","markup","args","createRenderRoot","_scrollToCursor","bottomOffset","contentLength","length","bottomPosition","scrollIntoView","behavior","block","_renderPerview","initial","pending","complete","error","CtxContentSelectOption","_selected","CtxContentSelect","_handleOutsideClick","showOptions","composedPath","includes","_toggleShowOptions","_optionSelected","_boundHandleOutsideClick","bind","_renderHeading","_renderIcon","_renderOptions","headingIcon","_renderHeadingIcon","CtxContentSnippetButton","currentSnippet","snippet","CtxContentSnippetsSelectOption","insert","CtxContentSnippetsSelect","CtxContentTextArea","initialValue","_contentChanged","editor","selectionStart","_insertContent","_wrapSelectedContent","contentToInsert","setRangeText","selectionEnd","setSelectionRange","focus","start","end","selectedContent","slice","wrappedContent","pre","post","CtxContentToolbar","_selectedToolbarContentChanged","_renderRightSlot","_renderHelpIcon","EditorContentEvent","snippets","bold","wrap","documentLayout","errorAlert","hero","infoAlert","italic","link","orderedList","tableOfContents","unorderedList","warningAlert","reportNews","colleagueAudit","CtxCard","underline","CtxCheckbox","toString","_dispatchChangeEvent","setAttribute","_setValue","attrValue","_toggleState","renderIcon","renderStateContentSlot","slotName","CtxHero","short","title","callToActionUrl","callToAction","src","DcaSelect","required","autofocus","_options","Array","from","querySelectorAll","firstUpdated","internals","_manageRequired","_onInput","match","_findOptionMatch","_input","setValidity","valueMissing","find","option","innerText","placeholder","text","DcaWizard","CompleteLabel","activeStep","canNavigatePrevious","previousStepHandler","_getActiveStep","index","Steps","findIndex","i","previousStep","step","_setLastStep","nextStepHandler","checkValidity","completeStep","nextStep","_getSteps","setSteps","lastStep","currentStep","_isLastStep","DcaWizardStep","isValid","DialogWrapper","DisplaySelect","iconSlotName","buttonClickHandler","menu","togglePopover","menuClickHandler","iconSlot","closest","id","hidePopover","EmbeddedPowerBiManager","reportAccessor","_reportAccessor","_loaded","bootstrap","_firstPowerBiReport","updateComplete","_embeddedList","powerBiType","config","hostname","embedUrl","loadReport","reportRequest","clientEmbedSettings","bookmarkName","initializeDefaultActiveEmbed","reportKey","_tokenUpdater","slowLoadTimeout","window","clearTimeout","stopTrackEvent","action","SetEmbedRequestData","embedResponse","GetCachedEmbedCode","isMobile","layoutType","LayoutType","MobilePortrait","mobileSettings","setOrCreateActiveEmbed","clientGroup","reportId","Map","Object","entries","datasets","getEmbedConfiguration","settings","bookmark","name","startTrackEvent","setTimeout","loadedReport","loadFrame","_report","AttachInterval","expiration","currentEmbed","embed","loadedDatasets","push","_activeEmbed","fullscreen","getCurrentReport","getReportBookmarks","bookmarksManager","getBookmarks","getReportState","capturedBookmark","capture","state","getReport","getPages","getTableColumns","visualDescriptor","exportData","ExportDataType","Summarized","data","split","setReportState","applyState","setAccessToken","accessToken","applyBookmark","apply","getCurrentEmbedElement","shadowRoot","querySelector","getActivePageInfo","activePage","getActivePage","displayName","embedToken","url","Promise","resolve","reject","oldReport","off","report","getId","on","pageChangedEventHandler","selectionChangedEventHandler","visualClickedEventHandler","Error","trackException","exception","trackTrace","message","properties","renderedEventHandler","raiseUserActivityEvent","pageChangeEvent","activityType","activityEvent","item","embedItem","hideReport","defaultEmbed","existingDataset","incomingDatasets","incomingDatasetKey","keys","has","get","EmbeddedPowerBiWrapper","replayEvent","powerbi","reportContainer","FeedbackManager","pageFeedback","showFeedbackHandler","displayFeedbackEvent","feedbackRef","ref","removeFeedback","filter","x","DisplayFeedbackEvent","PageFeedback","reset","_textArea","submit","reportValidity","_RadioButtons","selectedValue","users","sendFeedback","location","href","messages","success","failed","progress","er","selectValue","register","FormInput","stringify","_handleFormDataEvent","_slottedChildren","assignedNodes","flatten","node","nodeType","Node","ELEMENT_NODE","propertyName","property","nodes","query","n","formData","delete","formValue","JSON","append","GroupUserItem","failedState","requestToggleDrillDownHandler","ProgressPromise","groupUserKey","_switch","checked","innerPromise","_progress","indeterminate","username","drilldown","failure","InfoSummary","_infoDetailChangeEventHandler","open","closestDocumentFragment","closestNode","parentNode","isDocumentFragment","getElementById","for","clickEventHandler","InfoDetails","toggle","downloadReportEvent","reflect","predicate","RegisterInput","inputElement","InputSelect","applyRequiredDataListItem","submitFormData","findOption","list","setCustomValidity","inputName","dataset","form","datalist","j","options","DownloadBar","showBuffer","MessageList","_visible","_failed","_getDescriptionText","_downloadReportEvent","reportName","newDownload","dismissTemplate","dismissHandler","failedTemplate","AlertMessage","height","level","MessageManager","Messages","messageHandler","newMessage","showProgress","timer","then","removeMessage","actionMessageHandler","promise","ex","promiseMessageHandler","m","PermissionChanges","expandedItem","toggleExpand","userKey","itemKey","getItemKey","getIconName","changeType","Added","Removed","Updated","permissionChanges","pc","expanded","userName","facilityChanges","fac","decrypt","facilityKey","facilityName","RadioButtonList","valueButton","buttons","rb","selectItem","active","selectedIndex","clickHandler","label","selector","RadioButton","appearance","ReportNews","dismissNews","news","useEditModeCache","subscriberKey","cachedReportNews","editModeCache","set","html","origin","protocol","host","Router","isHashChangeNavigation","_onClick","isNonNavigationClick","button","metaKey","ctrlKey","shiftKey","defaultPrevented","anchor","undefined","startsWith","path","pathname","search","hash","isRouteMatch","isHashChange","history","pushState","goto","_onPopState","_e","_onGoTo","gotoWithPush","currentUrl","newUrl","hostConnected","hostDisconnected","RouterGoToEvent","patternCache","WeakMap","getPattern","route","pattern","isPatternConfig","URLPattern","Routes","routes","ignoreUnknownRoutes","_childRoutes","_currentParams","isActiveRoute","routeName","_currentRoute","_getRoute","_onRoutesConnected","childRoutes","_parentRoutes","stopImmediatePropagation","onDisconnect","splice","indexOf","tailGroup","getTailGroup","_host","addController","fallback","_currentPathname","result","exec","params","groups","enter","substring","outlet","URL","matchedRoute","r","test","RoutesConnectedEvent","_onDisconnect","tailKey","ShowComponentWrapper","SidePanel","openWindow","hide","openWindowLink","ThalamusCard","ThalamusHero","ThalamusPowerBiReport","getCurrentState","_powerbiManager","loadContainerDataFromActivePage","containerName","visuals","getVisuals","visual","trackEvent","page","facilityReference","embedSettings","YouTubeElement","videoid","YouTubeCard","bootstrap4"],"sourceRoot":""}