{
  "version": 3,
  "sources": ["external-global:Serenity", "external-global:Slick", "../Modules/index.ts", "../Modules/ServerTypes/Extensions/ChangePasswordForm.ts", "../Modules/ServerTypes/Extensions/ForgotPasswordForm.ts", "../Modules/ServerTypes/Extensions/ResetPasswordForm.ts", "../Modules/ServerTypes/Extensions/UserPreferenceRow.ts", "../Modules/ServerTypes/Extensions/UserPreferenceService.ts", "../Modules/BulkActions/BasicProgressDialog.tsx", "../../../node_modules/.pnpm/jsx-dom@8.1.4/node_modules/jsx-dom/min/index.js", "../Modules/BulkActions/BulkServiceAction.ts", "../Modules/ExportImport/ExcelExportHelper.ts", "../Modules/ExportImport/PdfExportHelper.ts", "../Modules/Formatters/EnumSelectFormatter.ts", "../Modules/Formatters/SingleLineTextFormatter.ts", "../Modules/GridEditor/GridEditorBase.ts", "../Modules/GridEditor/GridEditorDialog.ts", "../Modules/Reporting/ReportDialog.tsx", "../Modules/Reporting/ReportHelper.ts", "../Modules/Reporting/ReportPage.ts", "../Modules/UserPreference/UserPreferenceStorage.ts", "../Modules/Widgets/DialogUtils.ts", "../Modules/Widgets/PromptDialog.ts", "../Modules/Widgets/SelectableEntityGrid.ts", "../Modules/Widgets/StaticTextBlock.ts", "../Modules/Membership/PasswordStrength/PasswordStrengthValidation.ts"],
  "sourcesContent": ["module.exports = Serenity;", "module.exports = Slick;", "export * from \"./ServerTypes/Extensions\";\nexport * from \"./ServerTypes/Reporting\";\nexport * from \"./BulkActions/BasicProgressDialog\";\nexport * from \"./BulkActions/BulkServiceAction\";\nexport * from \"./ExportImport/ExcelExportHelper\";\nexport * from \"./ExportImport/JsPdfAutoTable\";\nexport * from \"./ExportImport/PdfExportHelper\";\nexport * from \"./Formatters/EnumSelectFormatter\";\nexport * from \"./Formatters/SingleLineTextFormatter\";\nexport * from \"./GridEditor/GridEditorBase\";\nexport * from \"./GridEditor/GridEditorDialog\";\nexport * from \"./Reporting/ReportDialog\";\nexport * from \"./Reporting/ReportHelper\";\nexport * from \"./Reporting/ReportPage\";\nexport * from \"./UserPreference/UserPreferenceStorage\";\nexport * from \"./Widgets/DialogUtils\";\nexport * from \"./Widgets/PromptDialog\";\nexport * from \"./Widgets/SelectableEntityGrid\";\nexport * from \"./Widgets/StaticTextBlock\";\nexport * from \"./Membership/PasswordStrength/PasswordStrengthValidation\";", "\uFEFFimport { PasswordEditor, PrefixedContext, initFormType } from \"@serenity-is/corelib\";\n\nexport interface ChangePasswordForm {\n    OldPassword: PasswordEditor;\n    NewPassword: PasswordEditor;\n    ConfirmPassword: PasswordEditor;\n}\n\nexport class ChangePasswordForm extends PrefixedContext {\n    static readonly formKey = 'Serenity.Extensions.ChangePasswordRequest';\n    private static init: boolean;\n\n    constructor(prefix: string) {\n        super(prefix);\n\n        if (!ChangePasswordForm.init)  {\n            ChangePasswordForm.init = true;\n\n            var w0 = PasswordEditor;\n\n            initFormType(ChangePasswordForm, [\n                'OldPassword', w0,\n                'NewPassword', w0,\n                'ConfirmPassword', w0\n            ]);\n        }\n    }\n}", "\uFEFFimport { EmailAddressEditor, PrefixedContext, initFormType } from \"@serenity-is/corelib\";\n\nexport interface ForgotPasswordForm {\n    Email: EmailAddressEditor;\n}\n\nexport class ForgotPasswordForm extends PrefixedContext {\n    static readonly formKey = 'Serenity.Extensions.ForgotPasswordRequest';\n    private static init: boolean;\n\n    constructor(prefix: string) {\n        super(prefix);\n\n        if (!ForgotPasswordForm.init)  {\n            ForgotPasswordForm.init = true;\n\n            var w0 = EmailAddressEditor;\n\n            initFormType(ForgotPasswordForm, [\n                'Email', w0\n            ]);\n        }\n    }\n}", "\uFEFFimport { PasswordEditor, PrefixedContext, initFormType } from \"@serenity-is/corelib\";\n\nexport interface ResetPasswordForm {\n    NewPassword: PasswordEditor;\n    ConfirmPassword: PasswordEditor;\n}\n\nexport class ResetPasswordForm extends PrefixedContext {\n    static readonly formKey = 'Serenity.Extensions.ResetPasswordRequest';\n    private static init: boolean;\n\n    constructor(prefix: string) {\n        super(prefix);\n\n        if (!ResetPasswordForm.init)  {\n            ResetPasswordForm.init = true;\n\n            var w0 = PasswordEditor;\n\n            initFormType(ResetPasswordForm, [\n                'NewPassword', w0,\n                'ConfirmPassword', w0\n            ]);\n        }\n    }\n}", "\uFEFFimport { fieldsProxy } from \"@serenity-is/corelib\";\n\nexport interface UserPreferenceRow {\n    UserPreferenceId?: number;\n    UserId?: number;\n    PreferenceType?: string;\n    Name?: string;\n    Value?: string;\n}\n\nexport abstract class UserPreferenceRow {\n    static readonly idProperty = 'UserPreferenceId';\n    static readonly nameProperty = 'Name';\n    static readonly localTextPrefix = 'Common.UserPreference';\n    static readonly deletePermission = '';\n    static readonly insertPermission = '';\n    static readonly readPermission = '';\n    static readonly updatePermission = '';\n\n    static readonly Fields = fieldsProxy<UserPreferenceRow>();\n}\n", "\uFEFFimport { ServiceResponse, ServiceOptions, serviceRequest } from \"@serenity-is/corelib\";\nimport { UserPreferenceRetrieveRequest } from \"./UserPreferenceRetrieveRequest\";\nimport { UserPreferenceRetrieveResponse } from \"./UserPreferenceRetrieveResponse\";\nimport { UserPreferenceUpdateRequest } from \"./UserPreferenceUpdateRequest\";\n\nexport namespace UserPreferenceService {\n    export const baseUrl = 'Extensions/UserPreference';\n\n    export declare function Update(request: UserPreferenceUpdateRequest, onSuccess?: (response: ServiceResponse) => void, opt?: ServiceOptions<any>): PromiseLike<ServiceResponse>;\n    export declare function Retrieve(request: UserPreferenceRetrieveRequest, onSuccess?: (response: UserPreferenceRetrieveResponse) => void, opt?: ServiceOptions<any>): PromiseLike<UserPreferenceRetrieveResponse>;\n\n    export const Methods = {\n        Update: \"Extensions/UserPreference/Update\",\n        Retrieve: \"Extensions/UserPreference/Retrieve\"\n    } as const;\n\n    [\n        'Update', \n        'Retrieve'\n    ].forEach(x => {\n        (<any>UserPreferenceService)[x] = function (r, s, o) {\n            return serviceRequest(baseUrl + '/' + x, r, s, o);\n        };\n    });\n}", "import { Decorators, DialogTexts, BaseDialog, WidgetProps, localText } from \"@serenity-is/corelib\";\n\n@Decorators.registerClass(\"Serenity.Extensions.BasicProgressDialog\")\nexport class BasicProgressDialog<P = {}> extends BaseDialog<P> {\n\n    constructor(props?: WidgetProps<P>) {\n        super(props);\n\n        this.dialogTitle = localText('Site.BasicProgressDialog.PleaseWait');\n    }\n\n    declare public cancelled: boolean;\n\n    public get max(): number {\n        return parseInt(this.byId('ProgressBar').attr('aria-valuemax'), 10);\n    }\n\n    public set max(value: number) {\n        this.byId('ProgressBar').attr('aria-valuemax', (value || 100).toString());\n    }\n\n    public get value(): number {\n        return parseInt(this.byId('ProgressBar').attr('aria-valuenow'), 10);\n    }\n\n    public set value(value: number) {\n        this.byId('ProgressBar').attr('aria-valuenow', (value || 0).toString())\n            .text(value + ' / ' + this.max)\n            .getNode().style.width = (((value || 0) / (this.max || 100)) * 100) + '%';\n    }\n\n    public get title(): string {\n        return this.dialogTitle;\n    }\n\n    public set title(value: string) {\n        this.dialogTitle = value;\n    }\n\n    declare public cancelTitle: string;\n\n    getDialogButtons() {\n        return [{\n            text: DialogTexts.CancelButton,\n            class: 'btn btn-danger',\n            click: () => {\n                this.cancelled = true;\n                this.domNode.closest('.ui-dialog')\n                    .querySelectorAll('.ui-dialog-buttonpane .ui-button')?.forEach((el: HTMLElement) => {\n                        el.setAttribute('disabled', 'disabled');\n                        el.style.opacity = '0.5';\n                    });\n\n                this.dialogTitle = this.cancelTitle?.trim() || localText('Site.BasicProgressDialog.CancelTitle');\n            }\n        }];\n    }\n\n    getDialogOptions() {\n        var opt = super.getDialogOptions();\n        opt.width = 600;\n        return opt;\n    }\n\n    initDialog() {\n        super.initDialog();\n        var close = this.domNode.closest('.ui-dialog')?.querySelector('.ui-dialog-titlebar-close') as HTMLElement;\n        close && (close.style.display = 'none');\n    }\n\n    renderContents(): any {\n        const id = this.useIdPrefix();\n        return (\n            <div class=\"s-DialogContent s-BasicProgressDialogContent\">\n                <div id={id.StatusText} class=\"status-text\" ></div>\n                <div id={id.Progress} class=\"progress\" style=\"height: 1.5rem\">\n                    <div id={id.ProgressBar} class=\"progress-bar\" aria-valuenow={0} aria-valuemin={0} aria-valuemax={100}></div>\n                </div>\n            </div>\n        );\n    }\n}", "/* eslint-disable */\nconst keys = Object.keys;\nfunction identity(value) {\n  return value;\n}\nfunction isBoolean(val) {\n  return typeof val === \"boolean\";\n}\nfunction isElement(val) {\n  return val && typeof val.nodeType === \"number\";\n}\nfunction isString(val) {\n  return typeof val === \"string\";\n}\nfunction isNumber(val) {\n  return typeof val === \"number\";\n}\nfunction isObject(val) {\n  return typeof val === \"object\" ? val !== null : isFunction(val);\n}\nfunction isFunction(val) {\n  return typeof val === \"function\";\n}\nfunction isComponentClass(Component) {\n  const { prototype } = Component;\n  return !!(prototype && prototype.isReactComponent);\n}\nfunction isArrayLike(obj) {\n  return (\n    isObject(obj) &&\n    typeof obj.length === \"number\" &&\n    typeof obj.nodeType !== \"number\"\n  );\n}\nfunction forEach(value, fn) {\n  if (!value) return;\n  for (const key of keys(value)) {\n    fn(value[key], key);\n  }\n}\n\nfunction createRef() {\n  return Object.seal({\n    current: null,\n  });\n}\nfunction isRef(maybeRef) {\n  return isObject(maybeRef) && \"current\" in maybeRef;\n}\n\nconst jsxDomType = Symbol.for(\"jsx-dom:type\");\nvar JsxDomType = /*#__PURE__*/ (function (JsxDomType) {\n  JsxDomType[\"ShadowRoot\"] = \"ShadowRoot\";\n  return JsxDomType;\n})(JsxDomType || {});\nfunction ShadowRoot(_ref) {\n  let { children, ref, ...attr } = _ref;\n  return {\n    [jsxDomType]: JsxDomType.ShadowRoot,\n    ref,\n    attr,\n    children,\n  };\n}\nfunction isShadowRoot(el) {\n  return el != null && el[jsxDomType] === JsxDomType.ShadowRoot;\n}\n\nconst SVGNamespace = \"http://www.w3.org/2000/svg\";\n\n// https://facebook.github.io/react/docs/jsx-in-depth.html#booleans-null-and-undefined-are-ignored\n// Emulate JSX Expression logic to ignore certain type of children or className.\nfunction isVisibleChild(value) {\n  return !isBoolean(value) && value != null;\n}\n\n/**\n * Convert a `value` to a className string.\n * `value` can be a string, an array or a `Dictionary<boolean>`.\n */\nfunction className(value) {\n  if (Array.isArray(value)) {\n    return value.map(className).filter(Boolean).join(\" \");\n  } else if (isObject(value)) {\n    if (Symbol.iterator in value) {\n      return className(Array.from(value));\n    }\n    return keys(value)\n      .filter((k) => value[k])\n      .join(\" \");\n  } else if (isVisibleChild(value)) {\n    return \"\" + value;\n  } else {\n    return \"\";\n  }\n}\nfunction createFactory(tag) {\n  return createElement.bind(null, tag);\n}\nfunction Fragment(attr) {\n  const fragment = document.createDocumentFragment();\n  appendChild(attr.children, fragment);\n  return fragment;\n}\nclass Component {\n  constructor(props) {\n    this.props = props;\n  }\n  render() {\n    return null;\n  }\n}\n\n/* @__PURE__ */\nObject.defineProperties(Component.prototype, {\n  isReactComponent: {\n    value: true,\n  },\n});\nfunction initComponentClass(Class, attr, children) {\n  attr = {\n    ...attr,\n    children,\n  };\n  const instance = new Class(attr);\n  const node = instance.render();\n  if (\"ref\" in attr) {\n    attachRef(attr.ref, instance);\n  }\n  return node;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nfunction jsx(tag, _ref) {\n  let { children, ...attr } = _ref;\n  let node;\n  if (isString(tag)) {\n    node = attr.namespaceURI\n      ? document.createElementNS(attr.namespaceURI, tag)\n      : document.createElement(tag);\n    attributes(attr, node);\n    appendChild(children, node);\n\n    // Select `option` elements in `select`\n    if (node instanceof window.HTMLSelectElement && attr.value != null) {\n      if (attr.multiple === true && Array.isArray(attr.value)) {\n        const values = attr.value.map((value) => String(value));\n        node\n          .querySelectorAll(\"option\")\n          .forEach(\n            (option) => (option.selected = values.includes(option.value)),\n          );\n      } else {\n        node.value = attr.value;\n      }\n    }\n    attachRef(attr.ref, node);\n  } else if (isFunction(tag)) {\n    // Custom elements.\n    if (isObject(tag.defaultProps)) {\n      attr = {\n        ...tag.defaultProps,\n        ...attr,\n      };\n    }\n    node = isComponentClass(tag)\n      ? initComponentClass(tag, attr, children)\n      : tag({\n          ...attr,\n          children,\n        });\n  } else {\n    throw new TypeError(`Invalid JSX element type: ${tag}`);\n  }\n  return node;\n}\nfunction createElement(tag, attr) {\n  for (\n    var _len = arguments.length,\n      children = new Array(_len > 2 ? _len - 2 : 0),\n      _key2 = 2;\n    _key2 < _len;\n    _key2++\n  ) {\n    children[_key2 - 2] = arguments[_key2];\n  }\n  if (isString(attr) || Array.isArray(attr)) {\n    children.unshift(attr);\n    attr = {};\n  }\n  attr = attr || {};\n  if (attr.children != null && !children.length) {\n    ({ children, ...attr } = attr);\n  }\n  return jsx(\n    tag,\n    {\n      ...attr,\n      children,\n    },\n    attr.key,\n  );\n}\nfunction attachRef(ref, node) {\n  if (isRef(ref)) {\n    ref.current = node;\n  } else if (isFunction(ref)) {\n    ref(node);\n  }\n}\nfunction appendChild(child, node) {\n  if (isArrayLike(child)) {\n    appendChildren(child, node);\n  } else if (isString(child) || isNumber(child)) {\n    appendChildToNode(document.createTextNode(child), node);\n  } else if (child === null) {\n    appendChildToNode(document.createComment(\"\"), node);\n  } else if (isElement(child)) {\n    appendChildToNode(child, node);\n  } else if (isShadowRoot(child)) {\n    const shadowRoot = node.attachShadow(child.attr);\n    appendChild(child.children, shadowRoot);\n    attachRef(child.ref, shadowRoot);\n  }\n}\nfunction appendChildren(children, node) {\n  for (const child of [...children]) {\n    appendChild(child, node);\n  }\n  return node;\n}\nfunction appendChildToNode(child, node) {\n  if (node instanceof window.HTMLTemplateElement) {\n    node.content.appendChild(child);\n  } else {\n    node.appendChild(child);\n  }\n}\nfunction style(node, value) {\n  if (value == null || value === false);\n  else if (Array.isArray(value)) {\n    value.forEach((v) => style(node, v));\n  } else if (isString(value)) {\n    node.setAttribute(\"style\", value);\n  } else if (isObject(value)) {\n    forEach(value, (val, key) => {\n      if (key.indexOf(\"-\") === 0) {\n        // CSS custom properties (variables) start with `-` (e.g. `--my-variable`)\n        // and must be assigned via `setProperty`.\n        node.style.setProperty(key, val);\n      } else {\n        node.style[key] = val;\n      }\n    });\n  }\n}\nfunction attribute(key, value, node) {\n  switch (key) {\n    case \"htmlFor\":\n      attr(node, \"for\", value);\n      return;\n    case \"dataset\":\n      forEach(value, (dataValue, dataKey) => {\n        if (dataValue != null) {\n          node.dataset[dataKey] = dataValue;\n        }\n      });\n      return;\n    case \"innerHTML\":\n    case \"innerText\":\n    case \"textContent\":\n      if (isVisibleChild(value)) {\n        node[key] = value;\n      }\n      return;\n    case \"dangerouslySetInnerHTML\":\n      if (isObject(value)) {\n        node.innerHTML = value[\"__html\"];\n      }\n      return;\n    case \"value\":\n      if (value == null || node instanceof window.HTMLSelectElement) {\n        // skip nullish values\n        // for `<select>` apply value after appending `<option>` elements\n        return;\n      } else if (node instanceof window.HTMLTextAreaElement) {\n        node.value = value;\n        return;\n      }\n      // use attribute for other elements\n      break;\n    case \"spellCheck\":\n      node.spellcheck = value;\n      return;\n    case \"class\":\n    case \"className\":\n      if (isFunction(value)) {\n        value(node);\n      } else {\n        attr(node, \"class\", className(value));\n      }\n      return;\n    case \"ref\":\n    case \"namespaceURI\":\n      return;\n    case \"style\":\n      style(node, value);\n      return;\n    case \"on\":\n    case \"onCapture\":\n      forEach(value, (eventHandler, eventName) => {\n        node.addEventListener(eventName, eventHandler, key === \"onCapture\");\n      });\n      return;\n    // fallthrough\n  }\n  if (isFunction(value)) {\n    if (key[0] === \"o\" && key[1] === \"n\") {\n      let attribute = key.toLowerCase();\n      const useCapture = attribute.endsWith(\"capture\");\n      if (attribute === \"ondoubleclick\") {\n        attribute = \"ondblclick\";\n      } else if (useCapture && attribute === \"ondoubleclickcapture\") {\n        attribute = \"ondblclickcapture\";\n      }\n      if (!useCapture && node[attribute] === null) {\n        // use property when possible PR #17\n        node[attribute] = value;\n      } else if (useCapture) {\n        node.addEventListener(\n          attribute.substring(2, attribute.length - 7),\n          value,\n          true,\n        );\n      } else {\n        let eventName;\n        if (attribute in window) {\n          // standard event\n          // the JSX attribute could have been \"onMouseOver\" and the\n          // member name \"onmouseover\" is on the window's prototype\n          // so let's add the listener \"mouseover\", which is all lowercased\n          const standardEventName = attribute.substring(2);\n          eventName = standardEventName;\n        } else {\n          // custom event\n          // the JSX attribute could have been \"onMyCustomEvent\"\n          // so let's trim off the \"on\" prefix and lowercase the first character\n          // and add the listener \"myCustomEvent\"\n          // except for the first character, we keep the event name case\n          const customEventName = attribute[2] + key.slice(3);\n          eventName = customEventName;\n        }\n        node.addEventListener(eventName, value);\n      }\n    }\n  } else if (isObject(value)) {\n    node[key] = value;\n  } else if (value === true) {\n    attr(node, key, \"\");\n  } else if (value !== false && value != null) {\n    attr(node, key, value);\n  }\n}\nfunction attr(node, key, value) {\n  node.setAttribute(key, value);\n}\nfunction attributes(attr, node) {\n  for (const key of keys(attr)) {\n    attribute(key, attr[key], node);\n  }\n  return node;\n}\n\nfunction useText(initialValue) {\n  const text = new Text();\n  Object.defineProperty(text, \"toString\", {\n    value() {\n      return this.textContent;\n    },\n  });\n  function setText(value) {\n    text.textContent = value;\n  }\n  if (initialValue != null) {\n    setText(initialValue);\n  }\n  return [text, setText];\n}\nfunction useClassList(initialValue) {\n  const div = document.createElement(\"div\");\n  if (initialValue != null) {\n    div.className = className(initialValue);\n  }\n  let list = div.classList;\n  function ClassList(value) {\n    value.setAttribute(\"class\", list.value);\n    list = value.classList;\n  }\n  Object.defineProperties(\n    ClassList,\n    Object.getOwnPropertyDescriptors({\n      get size() {\n        return list.length;\n      },\n      get value() {\n        return list.value;\n      },\n      add() {\n        list.add(...arguments);\n      },\n      remove() {\n        list.remove(...arguments);\n      },\n      toggle(token, force) {\n        list.toggle(token, force);\n      },\n      contains(token) {\n        return list.contains(token);\n      },\n    }),\n  );\n  return ClassList;\n}\n\nfunction useMemo(factory) {\n  return factory();\n}\nfunction forwardRef(render) {\n  return (_ref) => {\n    let { ref, ...props } = _ref;\n    return render(props, ref ?? createRef());\n  };\n}\nfunction useImperativeHandle(ref, init) {\n  attachRef(ref, init());\n}\n\nconst cache = /* @__PURE__ */ new Map();\nconst createStyledComponent = (name) =>\n  function (list) {\n    for (\n      var _len = arguments.length,\n        interpolations = new Array(_len > 1 ? _len - 1 : 0),\n        _key = 1;\n      _key < _len;\n      _key++\n    ) {\n      interpolations[_key - 1] = arguments[_key];\n    }\n    return (_ref) => {\n      let { style, ...props } = _ref;\n      const lastIndex = list.length - 1;\n      const css =\n        list.slice(0, lastIndex).reduce((p, s, i) => {\n          const interpolation = interpolations[i];\n          const current =\n            typeof interpolation === \"function\"\n              ? interpolation(props)\n              : interpolation;\n          return p + s + current;\n        }, \"\") + list[lastIndex];\n      return createElement(name, {\n        style: [css, style],\n        ...props,\n      });\n    };\n  };\nconst baseStyled = (customComponent) => createStyledComponent(customComponent);\nconst styled = /* @__PURE__ */ new Proxy(baseStyled, {\n  get(_, name) {\n    return setIfAbsent(cache, name, () => createStyledComponent(name));\n  },\n});\nfunction setIfAbsent(map, key, getValue) {\n  if (map.has(key)) {\n    return map.get(key);\n  } else {\n    const value = getValue(key);\n    map.set(key, value);\n    return value;\n  }\n}\n\nvar index = {\n  Component,\n  PureComponent: Component,\n  createElement,\n  Fragment,\n  ShadowRoot,\n};\nfunction preventDefault(event) {\n  event.preventDefault();\n  return event;\n}\nfunction stopPropagation(event) {\n  event.stopPropagation();\n  return event;\n}\n\nexport {\n  Component,\n  Fragment,\n  Component as PureComponent,\n  SVGNamespace,\n  ShadowRoot,\n  Fragment as StrictMode,\n  className,\n  createElement,\n  createFactory,\n  createRef,\n  index as default,\n  forwardRef,\n  createElement as h,\n  isRef,\n  jsx,\n  jsx as jsxs,\n  identity as memo,\n  preventDefault,\n  stopPropagation,\n  styled,\n  identity as useCallback,\n  useClassList,\n  useImperativeHandle,\n  useMemo,\n  createRef as useRef,\n  useText,\n};\n", "\uFEFFimport { Dictionary, ServiceError, confirmDialog, localText, notifyError, notifySuccess, notifyWarning, stringFormat } from \"@serenity-is/corelib\";\nimport { BasicProgressDialog } from \"./BasicProgressDialog\";\n\nexport class BulkServiceAction {\n\n    declare protected keys: string[];\n    declare protected queue: string[];\n    declare protected queueIndex: number;\n    declare protected progressDialog: BasicProgressDialog;\n    declare protected pendingRequests: number;\n    declare protected completedRequests: number;\n    declare protected errorByKey: Dictionary<ServiceError>;\n    declare private successCount: number;\n    declare private errorCount: number;\n    declare public done: () => void;\n\n    protected createProgressDialog() {\n        this.progressDialog = new BasicProgressDialog({});\n        this.progressDialog.dialogOpen();\n        this.progressDialog.max = this.keys.length;\n        this.progressDialog.value = 0;\n    }\n\n    protected getConfirmationFormat() {\n        return localText('Site.BulkServiceAction.ConfirmationFormat');\n    }\n\n    protected getConfirmationMessage(targetCount) {\n        return stringFormat(this.getConfirmationFormat(), targetCount);\n    }\n\n    protected confirm(targetCount, action) {\n        confirmDialog(this.getConfirmationMessage(targetCount), action);\n    }\n\n    protected getNothingToProcessMessage() {\n        return localText('Site.BulkServiceAction.NothingToProcess');\n    }\n\n    protected nothingToProcess() {\n        notifyError(this.getNothingToProcessMessage());\n    }\n\n    protected getParallelRequests() {\n        return 1;\n    }\n\n    protected getBatchSize() {\n        return 1;\n    }\n\n    protected startParallelExecution() {\n        this.createProgressDialog();\n        this.successCount = 0;\n        this.errorCount = 0;\n        this.pendingRequests = 0;\n        this.completedRequests = 0;\n        this.errorCount = 0;\n        this.errorByKey = {};\n        this.queue = this.keys.slice();\n        this.queueIndex = 0;\n        var parallelRequests = this.getParallelRequests();\n        while (parallelRequests-- > 0) {\n            this.executeNextBatch();\n        }\n    }\n\n    protected serviceCallCleanup() {\n        this.pendingRequests--;\n        this.completedRequests++;\n\n        var title = localText((this.progressDialog.cancelled ?\n            'Site.BasicProgressDialog.CancelTitle' : 'Site.BasicProgressDialog.PleaseWait'));\n\n        title += ' (';\n        if (this.successCount > 0) {\n            title += stringFormat(localText('Site.BulkServiceAction.SuccessCount'), this.successCount);\n        }\n\n        if (this.errorCount > 0) {\n            if (this.successCount > 0) {\n                title += ', ';\n            }\n\n            title += stringFormat(localText('Site.BulkServiceAction.ErrorCount'), this.errorCount);\n        }\n\n        this.progressDialog.title = title + ')';\n        this.progressDialog.value = this.successCount + this.errorCount;\n        if (!this.progressDialog.cancelled && this.progressDialog.value < this.keys.length) {\n            this.executeNextBatch();\n        }\n\n        else if (this.pendingRequests === 0) {\n            this.progressDialog.dialogClose(\"done\");\n            this.showResults();\n            if (this.done) {\n                this.done();\n                this.done = null;\n            }\n        }\n    }\n\n    protected executeForBatch(batch: string[]) {\n    }\n\n    protected executeNextBatch() {\n        var batchSize = this.getBatchSize();\n        var batch = [];\n        while (true) {\n            if (batch.length >= batchSize) {\n                break;\n            }\n\n            if (this.queueIndex >= this.queue.length) {\n                break;\n            }\n\n            batch.push(this.queue[this.queueIndex++]);\n        }\n\n        if (batch.length > 0) {\n            this.pendingRequests++;\n            this.executeForBatch(batch);\n        }\n    }\n\n    protected getAllHadErrorsFormat() {\n        return localText('Site.BulkServiceAction.AllHadErrorsFormat');\n    }\n\n    protected showAllHadErrors() {\n        notifyError(stringFormat(this.getAllHadErrorsFormat(), this.errorCount));\n    }\n\n    protected getSomeHadErrorsFormat() {\n        return localText('Site.BulkServiceAction.SomeHadErrorsFormat');\n    }\n\n    protected showSomeHadErrors() {\n        notifyWarning(stringFormat(this.getSomeHadErrorsFormat(), this.successCount, this.errorCount));\n    }\n\n    protected getAllSuccessFormat() {\n        return localText('Site.BulkServiceAction.AllSuccessFormat');\n    }\n\n    protected showAllSuccess() {\n        notifySuccess(stringFormat(this.getAllSuccessFormat(), this.successCount));\n    }\n\n    protected showResults() {\n        if (this.errorCount === 0 && this.successCount === 0) {\n            this.nothingToProcess();\n            return;\n        }\n\n        if (this.errorCount > 0 && this.successCount === 0) {\n            this.showAllHadErrors();\n            return;\n        }\n\n        if (this.errorCount > 0) {\n            this.showSomeHadErrors();\n            return;\n        }\n\n        this.showAllSuccess();\n    }\n\n    public execute(keys: string[]) {\n        this.keys = keys;\n        if (this.keys.length === 0) {\n            this.nothingToProcess();\n            return;\n        }\n        this.confirm(this.keys.length, () => this.startParallelExecution());\n    }\n\n    get_successCount() {\n        return this.successCount;\n    }\n\n    set_successCount(value: number) {\n        this.successCount = value;\n    }\n\n    get_errorCount() {\n        return this.errorCount;\n    }\n\n    set_errorCount(value: number) {\n        this.errorCount = value;\n    }\n}", "import { DataGrid, ListRequest, ToolButton, deepClone, faIcon, postToService } from \"@serenity-is/corelib\";\n\nexport interface ExcelExportOptions {\n    grid: DataGrid<any, any>;\n    service: string;\n    onViewSubmit: () => boolean;\n    editRequest?: (request: ListRequest) => ListRequest;\n    title?: string;\n    hint?: string;\n    separator?: boolean;\n}\n\nexport namespace ExcelExportHelper {\n\n    export function createToolButton(options: ExcelExportOptions): ToolButton {\n\n        return {\n            hint: options.hint ?? 'Excel',\n            title: options.title ?? '',\n            cssClass: 'export-xlsx-button',\n            icon: faIcon(\"file-excel\"),\n            onClick: function () {\n                if (!options.onViewSubmit()) {\n                    return;\n                }\n\n                let grid = options.grid;\n\n                var request = deepClone(grid.getView().params) as ListRequest;\n                request.Take = 0;\n                request.Skip = 0;\n                var sortBy = grid.getView().sortBy;\n                if (sortBy) {\n                    request.Sort = sortBy;\n                }\n\n                request.ExportColumns = [];\n                let columns = grid.getGrid().getColumns();\n                for (let column of columns) {\n                    request.ExportColumns.push(column.id || column.field);\n                }\n\n                if (options.editRequest)\n                    request = options.editRequest(request);\n\n                postToService({ service: options.service, request: request, target: '_blank' });\n            },\n            separator: options.separator\n        };\n    }\n}", "import { DataGrid, Fluent, ListRequest, ListResponse, ToolButton, deepClone, formatDate, resolveUrl, serviceCall, stringFormat } from \"@serenity-is/corelib\";\nimport { Column, FormatterResult, Grid } from \"@serenity-is/sleekgrid\";\n\nexport interface PdfExportOptions {\n    grid: DataGrid<any, any>;\n    onViewSubmit: () => boolean;\n    title?: string;\n    hint?: string;\n    separator?: boolean;\n    reportTitle?: string;\n    titleTop?: number;\n    titleFontSize?: number;\n    fileName?: string;\n    pageNumbers?: boolean;\n    columnTitles?: { [key: string]: string };\n    tableOptions?: jsPDF.AutoTableOptions;\n    output?: string;\n    autoPrint?: boolean;\n    printDateTimeHeader?: boolean;\n}\n\nexport namespace PdfExportHelper {\n\n    function toAutoTableColumns(srcColumns: Column[], columnStyles: { [dataKey: string]: jsPDF.AutoTableStyles; },\n        columnTitles: { [key: string]: string }) {\n        return srcColumns.map(src => {\n            let col: jsPDF.AutoTableColumn = {\n                dataKey: src.id || src.field,\n                title: src.name || ''\n            };\n\n            if (columnTitles && columnTitles[col.dataKey] != null)\n                col.title = columnTitles[col.dataKey];\n\n            let style: jsPDF.AutoTableStyles = {};\n            if ((src.cssClass || '').indexOf(\"align-right\") >= 0)\n                style.halign = 'right';\n            else if ((src.cssClass || '').indexOf(\"align-center\") >= 0)\n                style.halign = 'center';\n\n            columnStyles[col.dataKey] = style;\n\n            return col;\n        });\n    }\n\n    function toAutoTableData(slickGrid: Grid, entities: any[], keys: string[], srcColumns: Column[]) {\n        let el = document.createElement('span');\n        let row = 0;\n        const sanitizer = slickGrid?.getOptions()?.sanitizer;\n        return entities.map(item => {\n            let dst = [];\n            for (let cell = 0; cell < srcColumns.length; cell++) {\n                var col = srcColumns[cell];\n                var format = slickGrid.getFormatter(row, col);\n                var ctx = slickGrid.getFormatterContext(row, cell);\n                ctx.item = item;\n                ctx.value = item[col.field];\n                let html: FormatterResult = format ? format(ctx) : '';\n                if (!html || (!(html instanceof Node) && html.indexOf('<') < 0 && html.indexOf('&') < 0))\n                    dst.push(html);\n                else {\n                    Fluent.empty(el);\n                    if (html instanceof Node) {\n                        el.appendChild(html);\n                    }\n                    else {\n                        if (typeof html === \"string\" && html.length && sanitizer) {\n                            html = sanitizer(html);\n                        }\n                        el.innerHTML = html;\n                    }\n                    if (el.children.length == 1 &&\n                        el.children[0]?.nodeName === 'SELECT') {\n                        dst.push(el.children[0].querySelector(\"[selected]\")?.textContent ?? '');\n                    }\n                    else if (el.children.length == 1 &&\n                        Fluent.isInputLike(el.children[0])) {\n                        dst.push((el.children[0] as any).value);\n                    }\n                    else if (el.children.length == 1 &&\n                        el.children[0].classList.contains('.check-box')) {\n                        dst.push(el.children[0].classList.contains(\"checked\") ? \"X\" : \"\")\n                    }\n                    else\n                        dst.push(el.textContent || '');\n                }\n            }\n            row++;\n            return dst;\n        });\n    }\n\n    export function exportToPdf(options: PdfExportOptions): void {\n\n        var g = options.grid;\n\n        if (!options.onViewSubmit())\n            return;\n\n        var request = deepClone(g.view.params) as ListRequest;\n        request.Take = 0;\n        request.Skip = 0;\n\n        var sortBy = g.view.sortBy;\n        if (sortBy != null)\n            request.Sort = sortBy;\n\n        var gridColumns = g.slickGrid.getColumns();\n        gridColumns = gridColumns.filter(x => x.id !== \"__select__\");\n\n        request.IncludeColumns = [];\n        for (var column of gridColumns)\n            request.IncludeColumns.push(column.id || column.field);\n\n        serviceCall({\n            url: g.view.url,\n            request: request,\n            onSuccess: response => includeAutoTable(() => {\n                // @ts-ignore\n                let doc = new jsPDF('l', 'pt');\n                let srcColumns = gridColumns;\n                let columnStyles: { [dataKey: string]: jsPDF.AutoTableStyles; } = {};\n                let columns = toAutoTableColumns(srcColumns, columnStyles, options.columnTitles);\n                var keys = columns.map(x => x.dataKey);\n                let entities = (<ListResponse<any>>response).Entities || [];\n                let data = toAutoTableData(g.slickGrid, entities, keys, srcColumns);\n\n                doc.setFontSize(options.titleFontSize || 10);\n                doc.setFont('helvetica', 'bold');\n                let reportTitle = options.reportTitle || g.getTitle() || \"Report\";\n\n                doc.autoTableText(reportTitle, doc.internal.pageSize.width / 2,\n                    options.titleTop || 25, { halign: 'center' });\n\n                var totalPagesExp = \"{{T}}\";\n\n                let pageNumbers = options.pageNumbers == null || options.pageNumbers;\n                var autoOptions = Object.assign({\n                    margin: { top: 25, left: 25, right: 25, bottom: pageNumbers ? 25 : 30 },\n                    startY: 60,\n                    styles: {\n                        fontSize: 8,\n                        overflow: 'linebreak',\n                        cellPadding: 2,\n                        valign: 'middle'\n                    },\n                    columnStyles: columnStyles\n                }, options.tableOptions);\n\n                var footer: (data: any) => void;\n                var header: (data: any) => void;\n                if (pageNumbers) {\n                    footer = function (data) {\n                        var str = data.pageCount;\n                        // Total page number plugin only available in jspdf v1.0+\n                        if (typeof doc.putTotalPages === 'function') {\n                            str = str + \" / \" + totalPagesExp;\n                        }\n                        doc.autoTableText(str, doc.internal.pageSize.width / 2,\n                            doc.internal.pageSize.height - autoOptions.margin.bottom, {\n                            halign: 'center'\n                        });\n                    };\n                }\n\n                // Print header of page\n                if (options.printDateTimeHeader == null || options.printDateTimeHeader) {\n                    header = function (data) {\n                        doc.setFont('helvetica', 'normal');\n                        doc.setFontSize(8);\n\n                        // Date and time of the report\n                        doc.autoTableText(formatDate(new Date(), \"dd-MM-yyyy HH:mm\"),\n                            doc.internal.pageSize.width - autoOptions.margin.right, 13,\n                            {\n                                halign: 'right'\n                            });\n                    };\n                }\n\n                autoOptions.didDrawPage = (data) => {\n                    if (!!header) header(data);\n                    if (!!footer) footer(data);\n                };\n\n                autoOptions.head = [columns];\n                autoOptions.body = data;\n\n                doc.autoTable(autoOptions);\n\n                if (typeof doc.putTotalPages === 'function') {\n                    doc.putTotalPages(totalPagesExp);\n                }\n\n\n                if (!options.output || options.output == \"file\") {\n                    var fileName = options.fileName || options.reportTitle || \"{0}_{1}.pdf\";\n                    fileName = stringFormat(fileName, g.getTitle() || \"report\",\n                        formatDate(new Date(), \"yyyyMMdd_HHmm\"));\n                    doc.save(fileName);\n                    return;\n                }\n\n                if (options.autoPrint)\n                    doc.autoPrint();\n\n                var output = options.output;\n                if (output == 'newwindow' || '_blank')\n                    output = 'dataurlnewwindow';\n                else if (output == 'window')\n                    output = 'datauri';\n\n                doc.output(output);\n            })\n        });\n    }\n\n    export function createToolButton(options: PdfExportOptions) {\n\n        return <ToolButton>{\n            title: options.title || '',\n            hint: options.hint || 'PDF',\n            cssClass: 'export-pdf-button',\n            onClick: () => exportToPdf(options),\n            separator: options.separator\n        };\n    }\n\n    function includeJsPDF(then: () => void) {\n        // @ts-ignore\n        if (typeof jsPDF !== \"undefined\")\n            return then();\n\n        var script = document.getElementById(\"jsPDFScript\") as HTMLScriptElement;\n        if (script)\n            return then();\n\n        script = document.createElement(\"script\");\n        script.type = \"text/javascript\";\n        script.async = false;\n        script.id = \"jsPDFScript\";\n        script.addEventListener(\"load\", () => {\n            if (typeof jsPDF === \"undefined\" && typeof jspdf !== \"undefined\") {\n                window.jsPDF = jspdf.jsPDF;\n            }\n            then();\n        });\n        script.src = resolveUrl(\"~/Serenity.Assets/Scripts/jspdf.min.js\");\n        document.head.append(script);\n    }\n\n    function includeAutoTable(then: () => void) {\n        includeJsPDF(() => {\n            // @ts-ignore\n            if (typeof jsPDF === \"undefined\" ||\n                typeof (jsPDF as any).API == \"undefined\" ||\n                typeof (jsPDF as any).API.autoTable !== \"undefined\")\n                return then();\n\n            var script = document.querySelector(\"#jsPDFAutoTableScript\") as HTMLScriptElement;\n            if (script)\n                return then();\n\n            script = document.createElement(\"script\");\n            script.async = false;\n            script.type = \"text/javascript\";\n            script.id = \"jsPDFAutoTableScript\";\n            script.addEventListener(\"load\", () => {\n                then();\n            });\n            script.src = resolveUrl(\"~/Serenity.Assets/Scripts/jspdf.plugin.autotable.min.js\");\n            document.head.append(script);\n        });\n    }\n}", "import { Decorators, EnumTypeRegistry, Formatter, htmlEncode, localText, tryGetText } from \"@serenity-is/corelib\";\nimport { FormatterContext } from \"@serenity-is/sleekgrid\";\n\n@Decorators.registerFormatter('Serenity.Extensions.EnumSelectFormatter')\nexport class EnumSelectFormatter implements Formatter {\n    constructor(public readonly props: { enumKey?: string, allowClear?: boolean, emptyItemText?: string } = {}) {\n        this.props ??= {}\n        this.props.allowClear ??= true;\n    }\n\n    format(ctx: FormatterContext) {\n        var enumType = EnumTypeRegistry.get(this.props.enumKey ?? \"EnumKeyOptionNotSpecified!\");\n\n        var sb = \"<select>\";\n        if (this.props.allowClear) {\n            sb += '<option value=\"\">';\n            sb += htmlEncode(this.props.emptyItemText || localText(\"Controls.SelectEditor.EmptyItemText\"));\n            sb += '</option>';\n        }\n\n        for (var x of Object.keys(enumType).filter(v => !isNaN(parseInt(v, 10)))) {\n            sb += '<option value=\"' + htmlEncode(x) + '\"';\n            if (x == ctx.value)\n                sb += \" selected\";\n            var name = enumType[x];\n            sb += \">\";\n            sb += htmlEncode(tryGetText(\"Enums.\" + this.props.enumKey + \".\" + name) || name);\n            sb += \"</option>\";\n        }\n\n        sb += \"</select>\";\n\n        return sb;\n    }\n\n    get enumKey() { return this.props.enumKey }\n    set enumKey(value) { this.props.enumKey = value }\n\n    get allowClear() { return this.props.allowClear }\n    set allowClear(value) { this.props.allowClear = value }\n\n    get emptyItemText() { return this.props.emptyItemText }\n    set emptyItemText(value) { this.props.emptyItemText = value }\n}", "import { Decorators, Formatter, htmlEncode, toSingleLine } from \"@serenity-is/corelib\";\nimport { FormatterContext } from \"@serenity-is/sleekgrid\";\n\n@Decorators.registerFormatter('Serenity.Extensions.SingleLineTextFormatter')\nexport class SingleLineTextFormatter implements Formatter {\n    format(ctx: FormatterContext) {\n        return SingleLineTextFormatter.formatValue(ctx.value);\n    }\n\n    public static formatValue(value: string) {\n        var div = document.createElement(\"div\");\n        div.innerHTML = value ?? '';\n        return htmlEncode(toSingleLine(div.textContent));\n    }\n}", "import { Decorators, EditorProps, EntityGrid, IGetEditValue, ISetEditValue, SaveRequest, ServiceOptions, ServiceResponse, ToolButton, deepClone, indexOf } from \"@serenity-is/corelib\";\nimport { GridEditorDialog } from \"./GridEditorDialog\";\n\n@Decorators.registerClass(\"Serenity.Extensions.GridEditorBase\", [IGetEditValue, ISetEditValue])\n@Decorators.editor()\n@Decorators.element(\"<div/>\")\nexport abstract class GridEditorBase<TEntity, P = {}> extends EntityGrid<TEntity, P>\n    implements IGetEditValue, ISetEditValue {\n\n    protected getIdProperty() { return \"__id\"; }\n\n    protected nextId = 1;\n\n    constructor(props: EditorProps<P>) {\n        super(props);\n    }\n\n    protected id(entity: TEntity) {\n        return (entity as any)[this.getIdProperty()];\n    }\n\n    protected getNextId() {\n        return \"`\" + this.nextId++;\n    }\n\n    protected setNewId(entity: TEntity) {\n        entity[this.getIdProperty()] = this.getNextId();\n    }\n\n    protected save(opt: ServiceOptions<any>, callback: (r: ServiceResponse) => void) {\n        var request = opt.request as SaveRequest<TEntity>;\n        var row = deepClone(request.Entity);\n\n        var id = this.id(row);\n        if (id == null) {\n            (row as any)[this.getIdProperty()] = this.getNextId();\n        }\n\n        if (!this.validateEntity(row, id)) {\n            return;\n        }\n\n        var items = this.view.getItems().slice();\n        if (id == null) {\n            items.push(row);\n        }\n        else {\n            var index = indexOf(items, x => this.id(x) === id);\n            items[index] = deepClone({} as TEntity, items[index], row);\n        }\n\n        this.setEntities(items);\n        callback({});\n    }\n\n    protected deleteEntity(id: number) {\n        this.view.deleteItem(id);\n        return true;\n    }\n\n    protected validateEntity(row: TEntity, id: number) {\n        return true;\n    }\n\n    protected setEntities(items: TEntity[]) {\n        this.view.setItems(items, true);\n    }\n\n    protected getNewEntity(): TEntity {\n        return {} as TEntity;\n    }\n\n    protected getButtons(): ToolButton[] {\n        var buttons = super.getButtons();\n        var addButton = buttons.find(x => x.action === 'add');\n        if (addButton) {\n            addButton.onClick = () => {\n                this.createEntityDialog(this.getItemType(), dlg => {\n                    var dialog = dlg as GridEditorDialog<TEntity>;\n                    dialog.onSave = (opt, callback) => this.save(opt, callback);\n                    this.transferDialogReadOnly(dialog);\n                    dialog.loadEntityAndOpenDialog(this.getNewEntity());\n                });\n            }\n        }\n\n        return buttons.filter(x => x.action !== \"refresh\");\n    }\n\n    protected editItem(entityOrId: any): void {\n\n        var id = entityOrId;\n        var item = this.view.getItemById(id);\n        this.createEntityDialog(this.getItemType(), dlg => {\n            var dialog = dlg as GridEditorDialog<TEntity>;\n            dialog.onDelete = (opt, callback) => {\n                if (!this.deleteEntity(id)) {\n                    return;\n                }\n                callback({});\n            };\n            this.transferDialogReadOnly(dialog);\n            dialog.onSave = (opt, callback) => this.save(opt, callback);\n            dialog.loadEntityAndOpenDialog(item);\n        });;\n    }\n\n    public getEditValue(property, target) {\n        target[property.name] = this.value;\n    }\n\n    public setEditValue(source, property) {\n        this.value = source[property.name];\n    }\n\n    public get value(): TEntity[] {\n        var p = this.getIdProperty();\n        return this.view.getItems().map(x => {\n            var y = deepClone(x);\n            var id = y[p];\n            if (id && id.toString().charAt(0) == '`')\n                delete y[p];\n            return y;\n        });\n    }\n\n    public set value(value: TEntity[]) {\n        var p = this.getIdProperty();\n        this.view.setItems((value || []).map(x => {\n            var y = deepClone(x);\n            if ((y as any)[p] == null)\n                (y as any)[p] = this.getNextId();\n            return y;\n        }), true);\n    }\n\n    protected getGridCanLoad() {\n        return false;\n    }\n\n    protected usePager() {\n        return false;\n    }\n\n    protected getInitialTitle() {\n        return null;\n    }\n\n    protected createQuickSearchInput() {\n    }\n}", "import { Decorators, DeleteResponse, EntityDialog, SaveResponse, ServiceOptions } from \"@serenity-is/corelib\";\n\n@Decorators.registerClass(\"Serenity.Extensions.GridEditorDialog\")\n@Decorators.panel(false)\nexport abstract class GridEditorDialog<TEntity, P = {}> extends EntityDialog<TEntity, P> {\n    protected getIdProperty() { return \"__id\"; }\n\n    public onSave: (options: ServiceOptions<SaveResponse>,\n        callback: (response: SaveResponse) => void) => void;\n\n    public onDelete: (options: ServiceOptions<DeleteResponse>,\n        callback: (response: DeleteResponse) => void) => void;\n\n    public destroy() {\n        this.onSave = null;\n        this.onDelete = null;\n        super.destroy();\n    }\n\n    protected updateInterface() {\n        super.updateInterface();\n\n        // apply changes button doesn't work properly with in-memory grids yet\n        if (this.applyChangesButton) {\n            this.applyChangesButton.hide();\n        }\n    }\n\n    protected saveHandler(options: ServiceOptions<SaveResponse>,\n        callback: (response: SaveResponse) => void): void {\n        this.onSave && this.onSave(options, callback);\n    }\n\n    protected deleteHandler(options: ServiceOptions<DeleteResponse>,\n        callback: (response: DeleteResponse) => void): void {\n        this.onDelete && this.onDelete(options, callback);\n    }\n}", "import { ReportRetrieveResult } from \"../ServerTypes/Reporting\";\nimport { Decorators, BaseDialog, PropertyGrid, WidgetProps, faIcon, resolveUrl, serviceCall } from \"@serenity-is/corelib\";\nimport { ReportHelper } from \"./ReportHelper\";\n\n@Decorators.registerClass(\"Serenity.Extensions.ReportDialog\")\nexport class ReportDialog<P extends ReportDialogOptions = ReportDialogOptions> extends BaseDialog<P> {\n\n    declare private report: ReportRetrieveResult;\n    declare private propertyGrid: PropertyGrid;\n\n    constructor(props: WidgetProps<P>) {\n        super(props);\n\n        this.updateInterface();\n        this.loadReport(this.options.reportKey);\n    }\n\n    protected getDialogButtons() {\n        return null;\n    }\n\n    protected createPropertyGrid() {\n        this.propertyGrid && this.byId('PropertyGrid').empty().class('');\n        this.propertyGrid = new PropertyGrid({\n            element: this.byId('PropertyGrid'),\n            idPrefix: this.idPrefix,\n            items: this.report.Properties\n        }).init();\n    }\n\n    protected loadReport(reportKey: string) {\n        serviceCall({\n            url: resolveUrl('~/Serenity.Extensions/Report/Retrieve'),\n            request: {\n                ReportKey: reportKey\n            },\n            onSuccess: response => {\n                this.report = response as ReportRetrieveResult;\n                this.dialogTitle = this.report.Title;\n                this.createPropertyGrid();\n                this.propertyGrid.load(this.report.InitialSettings || {});\n                this.updateInterface();\n                this.dialogOpen();\n            }\n        });\n    }\n\n    protected updateInterface() {\n        this.toolbar.findButton('print-preview-button')\n            .toggle(this.report && !this.report.IsDataOnlyReport && !this.report.IsExternalReport);\n\n        this.toolbar.findButton('run-button')\n            .toggle(this.report && this.report.IsExternalReport);\n\n        this.toolbar.findButton('export-pdf-button')\n            .toggle(this.report && !this.report.IsDataOnlyReport && !this.report.IsExternalReport);\n\n        this.toolbar.findButton('export-xlsx-button')\n            .toggle(this.report && this.report.IsDataOnlyReport && !this.report.IsExternalReport);\n    }\n\n    executeReport(target: string, ext: string, download: boolean) {\n        if (!this.validateForm()) {\n            return;\n        }\n\n        var opt = {};\n        this.propertyGrid.save(opt);\n        ReportHelper.execute({\n            download: download,\n            reportKey: this.report.ReportKey,\n            extension: ext as any,\n            target: target,\n            params: opt\n        });\n    }\n\n    getToolbarButtons() {\n        return [\n            {\n                title: 'Preview',\n                cssClass: 'print-preview-button',\n                onClick: () => this.executeReport('_blank', null, false)\n            },\n            {\n                title: 'Run',\n                cssClass: 'run-button',\n                icon: faIcon(\"print\", \"blue\"),\n                onClick: () => this.executeReport('_blank', null, false)\n            },\n            {\n                title: 'PDF',\n                cssClass: 'export-pdf-button',\n                onClick: () => this.executeReport('_blank', 'pdf', true)\n            },\n            {\n                title: 'Excel',\n                cssClass: 'export-xlsx-button',\n                onClick: () => this.executeReport('_blank', 'xlsx', true)\n            }\n        ];\n    }\n\n    renderContents(): any {\n        const id = this.useIdPrefix();\n        return (\n            <div class=\"s-DialogContent\">\n                <div id={id.Toolbar} class=\"s-DialogToolbar\"></div>\n                <div class=\"s-Form\">\n                    <form id={id.Form} action=\"\">\n                        <div id={id.PropertyGrid}></div>\n                    </form>\n                </div>\n            </div>\n        );\n    }\n}\n\nexport interface ReportDialogOptions {\n    reportKey: string;\n}", "import { IconClassName, ToolButton, postToUrl } from \"@serenity-is/corelib\";\n\nexport interface ReportExecuteOptions {\n    reportKey: string;\n    download?: boolean;\n    extension?: 'pdf' | 'htm' | 'html' | 'xlsx' | 'docx';\n    getParams?: () => any;\n    params?: { [key: string]: any }\n    target?: string;\n}\n\nexport interface ReportButtonOptions extends ReportExecuteOptions {\n    title?: string;\n    cssClass?: string;\n    icon?: IconClassName;\n}\n\nexport namespace ReportHelper {\n\n    export function createToolButton(options: ReportButtonOptions): ToolButton {\n        return {\n            title: options.title ?? 'Report',\n            cssClass: options.cssClass ?? 'print-button',\n            icon: options.icon,\n            onClick: () => {\n                ReportHelper.execute(options);\n            }\n        };\n    }\n\n    export function execute(options: ReportExecuteOptions) {\n        var opt = options.getParams ? options.getParams() : options.params;\n\n        postToUrl({\n            url: '~/Serenity.Extensions/Report/' + (options.download ? 'Download' : 'Render'),\n            params: {\n                key: options.reportKey,\n                ext: options.extension ?? 'pdf',\n                opt: opt ? JSON.stringify(opt) : ''\n            },\n            target: options.target ?? '_blank'\n        });\n    }\n}", "import { Decorators, Fluent, QuickSearchInput, Widget, WidgetProps, stripDiacritics } from \"@serenity-is/corelib\";\nimport { ReportDialog } from \"./ReportDialog\";\n\n@Decorators.registerClass(\"Serenity.Extensions.ReportPage\")\nexport class ReportPage<P = {}> extends Widget<P> {\n\n    constructor(props: WidgetProps<P>) {\n        super(props);\n\n        Fluent.on(this.domNode, \"click\", \".report-link\", this.reportLinkClick.bind(this));\n\n        new QuickSearchInput({\n            element: this.domNode.querySelector('.s-QuickSearchBar input') as HTMLElement,\n            onSearch: (field, text, done) => {\n                this.updateMatchFlags(text);\n                done(true);\n            }\n        });\n    }\n\n    protected updateMatchFlags(text: string) {\n        var liList = this.domNode.querySelectorAll('.report-list li');\n        liList.forEach(x => x.classList.remove('non-match'));\n        text = text?.trim();\n        if (!text)\n            return;\n\n        text = stripDiacritics(text).toUpperCase();\n\n        var reportItems = Array.from(liList).filter(x => x.classList.contains('report-item'));\n        reportItems.forEach(function (el) {\n            var title = stripDiacritics((el.textContent ?? '').toUpperCase());\n            if (title.indexOf(text) < 0) {\n                el.classList.add('non-match');\n            }\n        });\n\n        function parents(el: HTMLElement, selector: string) {\n            const parents = [];\n            while ((el = el.parentNode as HTMLElement) && (el as any) !== document) {\n                if (!selector || el.matches(selector))\n                    parents.push(el);\n            }\n            return parents;\n        }\n\n        var matchingItems = reportItems.filter(x => !x.classList.contains('non-match'));\n        var visibles = [...matchingItems];\n        matchingItems.forEach(x => visibles.push(...parents(x as HTMLElement, 'li')));\n        visibles = visibles.filter((x, i) => visibles.indexOf(x) === i);\n        visibles.forEach(v => {\n            v.querySelectorAll(':scope [data-bs-toggle]:not([aria-expanded=true])').forEach(c => {\n                c.setAttribute('aria-expanded', \"true\");\n                c.classList.remove('collapsed');\n            });\n            if (v.parentElement && v.parentElement.classList.contains(\"collapse\") && \n                !v.parentElement.classList.contains(\"show\")) {\n                v.parentElement.classList.add(\"show\");\n            }\n        });\n\n        var nonVisibles = Array.from(liList).filter(x => visibles.indexOf(x) < 0);\n        nonVisibles.forEach(x => x.classList.add('non-match'));\n    }\n\n    protected reportLinkClick(e: Event) {\n        e.preventDefault();\n        new ReportDialog({\n            reportKey: (e.target as HTMLElement).getAttribute('data-key')\n        }).dialogOpen();\n    }\n}\n", "import { SettingStorage } from \"@serenity-is/corelib\";\nimport { UserPreferenceService } from \"../ServerTypes/Extensions/UserPreferenceService\";\nimport { UserPreferenceRetrieveResponse } from \"../ServerTypes/Extensions\";\n\nexport class UserPreferenceStorage implements SettingStorage {\n    async getItem(key: string): Promise<string> {\n        const response = await Promise.resolve(UserPreferenceService.Retrieve({\n            PreferenceType: \"UserPreferenceStorage\",\n            Name: key\n        }) as PromiseLike<UserPreferenceRetrieveResponse>);\n        return response.Value;\n    }\n\n    async setItem(key: string, data: string): Promise<void> {\n        return Promise.resolve(UserPreferenceService.Update({\n            PreferenceType: \"UserPreferenceStorage\",\n            Name: key,\n            Value: data\n        }) as any);\n    }\n}", "import { Dialog, Fluent, confirmDialog, isArrayLike, localText } from \"@serenity-is/corelib\";\n\nexport namespace DialogUtils {\n\n    export function pendingChangesConfirmation(element: ArrayLike<HTMLElement> | HTMLElement, hasPendingChanges: () => boolean) {\n\n        var el = isArrayLike(element) ? element[0] : element;\n        if (!el)\n            return;\n        Dialog.onClose(el, (result, e: Event) => {\n\n            if (result === \"save-and-close\" || result === \"save\" || result === \"delete\" || result === \"done\" ||\n                (el.dataset.ackuntil &&\n                    new Date().getTime() < parseInt(el.dataset.ackuntil, 10)) ||\n                !hasPendingChanges()) {\n                return;\n            }\n\n            e.preventDefault();\n            e.stopImmediatePropagation();\n            confirmDialog(localText('Site.Dialogs.PendingChangesConfirmation'),\n                () => {\n                    el.dataset.ackuntil = \"\" + new Date().getTime() + 1000;\n                    el.querySelector<HTMLElement>('div.save-and-close-button')?.click()\n                },\n                {\n                    onNo: function () {\n                        el.dataset.ackuntil = \"\" + new Date().getTime() + 1000;\n                        Dialog.getInstance(el)?.close(result);\n                    }\n                });\n        }, { before: true });\n\n        function beforeUnload() {\n            if (!Fluent.isVisibleLike(el) || !hasPendingChanges())\n                return;\n\n            return localText(\"Site.Dialogs.PendingChangesUnloadWarning\");\n        }\n\n        Fluent.on(window, \"beforeunload\", beforeUnload);\n        Dialog.onClose(el, (() => Fluent.off(window, \"beforeunload\", beforeUnload)), { oneOff: true });\n    }\n}\n", "import { Decorators, PropertyDialog, Widget, WidgetProps, cancelDialogButton, getTypeFullName, okDialogButton, toggleClass } from \"@serenity-is/corelib\";\n\nexport interface PromptDialogOptions {\n    cssClass?: string;\n    editorType?: string | { new(props?: any): Widget };\n    editorOptions?: any;\n    title?: string;\n    message?: string;\n    isHtml?: boolean;\n    value?: any;\n    required?: boolean;\n    validateValue: (v: any) => boolean;\n}\n\n@Decorators.registerClass(\"Serenity.Extensions.PromptDialog\")\nexport class PromptDialog<P extends PromptDialogOptions = PromptDialogOptions> extends PropertyDialog<any, P> {\n\n    constructor(props: WidgetProps<P>) {\n        super(props);\n\n        if (this.options.cssClass)\n            toggleClass(this.domNode, this.options.cssClass);\n\n        if (this.options.message) {\n            var msg = document.createElement(\"div\");\n            msg.classList.add(\"message\");\n            this.byId(\"PropertyGrid\").prepend(msg);\n            if (this.options.isHtml)\n                msg.innerHTML = this.options.message;\n            else\n                msg.textContent = this.options.message;\n        }\n\n        this.dialogTitle = this.options.title || \"Prompt\";\n\n    }\n\n    protected getDialogButtons() {\n        return [\n            okDialogButton({\n                click: (e: Event) => {\n                    if (!this.validateForm()) {\n                        e.preventDefault();\n                        return;\n                    }\n\n                    if (this.options.validateValue != null && !this.options.validateValue(this.value)) {\n                        e.preventDefault();\n                    }\n                },\n            }),\n            cancelDialogButton()\n        ];\n    }\n\n    protected loadInitialEntity() {\n        this.value = this.options.value;\n    }\n\n    protected getPropertyItems() {\n        return [\n            {\n                name: \"Value\",\n                editorType: typeof this.options.editorType === \"function\" ? getTypeFullName(this.options.editorType) : this.options.editorType || \"String\",\n                required: this.options.required ?? true,\n                editorParams: this.options.editorOptions\n            }\n        ]\n    }\n\n    public get value() {\n        return (this.getSaveEntity() as any).Value;\n    }\n\n    public set value(v: any) {\n        this.propertyGrid.load(\n            {\n                Value: v\n            });\n    }\n\n    public static prompt(title: string, message: string, value: string, validateValue: (string) => boolean) {\n        new PromptDialog({\n            title: title,\n            message: message,\n            value: value,\n            validateValue: v => validateValue(v)\n        }).dialogOpen();\n    }\n}", "import { Decorators, EntityGrid } from \"@serenity-is/corelib\";\nimport { Grid, GridOptions, RowSelectionModel } from \"@serenity-is/sleekgrid\";\n\n@Decorators.registerClass(\"Serenity.Extensions.SelectableEntityGrid\")\nexport class SelectableEntityGrid<TItem, TOptions> extends EntityGrid<TItem, TOptions> {\n\n    protected getSlickOptions(): GridOptions {\n        var opt = super.getSlickOptions();\n        opt.enableTextSelectionOnCells = true;\n        opt.selectedCellCssClass = \"slick-row-selected\";\n        opt.enableCellNavigation = true;\n        return opt;\n    }\n\n    protected createSlickGrid(): Grid {\n        var grid = super.createSlickGrid();\n        grid.setSelectionModel(new RowSelectionModel());\n        return grid;\n    }\n}\n", "import { Decorators, ISetEditValue, PropertyItem, Widget, WidgetProps, localText } from \"@serenity-is/corelib\";\n\n/**\n    * This is an editor widget but it only displays a text, not edits it.\n    *  \n    */\n@Decorators.element(\"<div/>\")\n@Decorators.registerEditor('Serenity.Extensions.StaticTextBlock', [ISetEditValue])\nexport class StaticTextBlock<P extends StaticTextBlockOptions = StaticTextBlockOptions> extends Widget<P>\n    implements ISetEditValue {\n\n    declare private value: string;\n\n    constructor(props: WidgetProps<P>) {\n        super(props);\n\n        // hide the caption label for this editor if in a form. ugly hack\n        if (this.options.hideLabel) {\n            let label = this.domNode.closest('.field')?.querySelector('.caption') as HTMLLabelElement;\n            label && (label.style.display = \"none\");\n        }\n\n        this.updateElementContent();\n    }\n\n    private updateElementContent() {\n        var txt = this.options.text ?? this.value;\n\n        // if isLocalText is set, text is actually a local text key\n        if (this.options.isLocalText)\n            txt = localText(txt);\n\n        // don't html encode if isHtml option is true\n        if (this.options.isHtml)\n            this.domNode.innerHTML = txt;\n        else\n            this.domNode.textContent = txt;\n    }\n\n    /**\n        * By implementing ISetEditValue interface, we allow this editor to display its field value.\n        * But only do this when our text content is not explicitly set in options\n        */\n    public setEditValue(source: any, property: PropertyItem) {\n        if (this.options.text == null) {\n            this.value = this.options.text ?? source[property.name];\n            this.updateElementContent();\n        }\n    }\n}\n\nexport interface StaticTextBlockOptions {\n    text: string;\n    isHtml: boolean;\n    isLocalText: boolean;\n    hideLabel: boolean;\n}\n", "import { PasswordEditor, getRemoteDataAsync, localText, stringFormat } from \"@serenity-is/corelib\";\nimport { PasswordStrengthRules } from \"../../ServerTypes/Extensions/PasswordStrengthRules\";\n\nexport async function getPasswordStrengthRules(): Promise<PasswordStrengthRules> {\n    return await getRemoteDataAsync<PasswordStrengthRules>(\"PasswordStrengthRules\");\n}\n\nexport function addPasswordStrengthValidation(passwordEditor: PasswordEditor, uniqueName?: string) {\n    getPasswordStrengthRules().then((passwordStrengthRules) => {\n        passwordEditor.addValidationRule(() => {\n            if (passwordEditor.value.length < passwordStrengthRules.MinPasswordLength)\n                return stringFormat(localText(\"Validation.MinRequiredPasswordLength\"), passwordStrengthRules.MinPasswordLength);\n        }, uniqueName);\n\n        if (passwordStrengthRules.RequireDigit) {\n            passwordEditor.addValidationRule(() => {\n                if (!(/[0-9]/.test(passwordEditor.value)))\n                    return stringFormat(localText(\"Validation.PasswordStrengthRequireDigit\"));\n            }, uniqueName);\n        }        \n\n        if (passwordStrengthRules.RequireLowercase) {\n            passwordEditor.addValidationRule(() => {\n                if (!(/[a-z\\p{Ll}]/u.test(passwordEditor.value)))\n                    return localText(\"Validation.PasswordStrengthRequireLowercase\");\n            }, uniqueName);\n        }\n\n        if (passwordStrengthRules.RequireUppercase) {\n            passwordEditor.addValidationRule(() => {\n                if (!(/[A-Z\\p{Lu}]/u.test(passwordEditor.value)))\n                    return localText(\"Validation.PasswordStrengthRequireUppercase\");\n            }, uniqueName);\n        }\n\n        if (passwordStrengthRules.RequireNonAlphanumeric) {\n            passwordEditor.addValidationRule(() => {\n                if (!(/[^\\s\\p{L}]/u.test(passwordEditor.value)))\n                    return localText(\"Validation.PasswordStrengthRequireNonAlphanumeric\");\n            }, uniqueName);\n        }\n    });\n}"],
  "mappings": "s5FAAA,IAAAA,EAAAC,GAAA,CAAAC,GAAAC,KAAA,CAAAA,GAAO,QAAU,WCAjB,IAAAC,GAAAC,GAAA,CAAAC,GAAAC,KAAA,CAAAA,GAAO,QAAU,QCAjB,IAAAC,GAAA,GAAAC,GAAAD,GAAA,yBAAAE,GAAA,sBAAAC,GAAA,uBAAAC,GAAA,gBAAAC,GAAA,wBAAAC,GAAA,sBAAAC,GAAA,uBAAAC,GAAA,mBAAAC,GAAA,qBAAAC,GAAA,oBAAAC,GAAA,iBAAAC,GAAA,iBAAAC,GAAA,iBAAAC,GAAA,eAAAC,GAAA,sBAAAC,GAAA,yBAAAC,GAAA,4BAAAC,GAAA,oBAAAC,GAAA,sBAAAC,GAAA,0BAAAC,GAAA,0BAAAC,GAAA,kCAAAC,GAAA,6BAAAC,KCAC,IAAAC,EAA8D,SAQxD,IAAMC,EAAN,MAAMA,UAA2B,iBAAgB,CAIpD,YAAYC,EAAgB,CAGxB,GAFA,MAAMA,CAAM,EAER,CAACD,EAAmB,KAAO,CAC3BA,EAAmB,KAAO,GAE1B,IAAIE,EAAK,oBAET,gBAAaF,EAAoB,CAC7B,cAAeE,EACf,cAAeA,EACf,kBAAmBA,CACvB,CAAC,CACL,CACJ,CACJ,EAnBwDC,EAAAH,EAAA,sBAA3CA,EACO,QAAU,4CADvB,IAAMI,GAANJ,ECRN,IAAAK,EAAkE,SAM5D,IAAMC,EAAN,MAAMA,UAA2B,iBAAgB,CAIpD,YAAYC,EAAgB,CAGxB,GAFA,MAAMA,CAAM,EAER,CAACD,EAAmB,KAAO,CAC3BA,EAAmB,KAAO,GAE1B,IAAIE,EAAK,wBAET,gBAA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AGbC,EAAsB,wBACtBF,EAAe,kBAAkB,IAAM,CACnC,GAAI,CAAE,cAAc,KAAKA,EAAe,KAAK,EACzC,SAAO,aAAU,mDAAmD,CAC5E,EAAGC,CAAU,CAErB,CAAC,CACL,CAnCgBH,EAAAC,GAAA",
  "names": ["require_Serenity", "__commonJSMin", "exports", "module", "require_Slick", "__commonJSMin", "exports", "module", "Modules_exports", "__export", "BasicProgressDialog", "BulkServiceAction", "ChangePasswordForm", "DialogUtils", "EnumSelectFormatter", "ExcelExportHelper", "ForgotPasswordForm", "GridEditorBase", "GridEditorDialog", "PdfExportHelper", "PromptDialog", "ReportDialog", "ReportHelper", "ReportPage", "ResetPasswordForm", "SelectableEntityGrid", "SingleLineTextFormatter", "StaticTextBlock", "UserPreferenceRow", "UserPreferenceService", "UserPreferenceStorage", "addPasswordStrengthValidation", "getPasswordStrengthRules", "import_corelib", "_ChangePasswordForm", "prefix", "w0", "__name", "ChangePasswordForm", "import_corelib", "_ForgotPasswordForm", "prefix", "w0", "__name", "ForgotPasswordForm", "import_corelib", "_ResetPasswordForm", "prefix", "w0", "__name", "ResetPasswordForm", "import_corelib", "_UserPreferenceRow", "__name", "UserPreferenceRow", "import_corelib", "UserPreferenceService", "x", "r", "s", "o", "import_corelib", "keys", "isBoolean", "val", "__name", "isElement", "isString", "isNumber", "isObject", "isFunction", "isComponentClass", "Component", "prototype", "isArrayLike", "obj", "forEach", "value", "fn", "key", "keys", "isRef", "maybeRef", "isObject", "__name", "jsxDomType", "JsxDomType", "isShadowRoot", "el", "jsxDomType", "JsxDomType", "__name", "isVisibleChild", "value", "isBoolean", "__name", "className", "isObject", "keys", "k", "_Component", "props", "__name", "Component", "initComponentClass", "Class", "attr", "children", "__spreadProps", "__spreadValues", "instance", "node", "attachRef", "jsx", "tag", "_ref", "_a", "__objRest", "isString", "attributes", "appendChild", "values", "value", "option", "isFunction", "isObject", "isComponentClass", "attachRef", "ref", "node", "isRef", "isFunction", "__name", "appendChild", "child", "isArrayLike", "appendChildren", "isString", "isNumber", "appendChildToNode", "isElement", "isShadowRoot", "shadowRoot", "children", "style", "value", "v", "isObject", "forEach", "val", "key", "attribute", "attr", "dataValue", "dataKey", "isVisibleChild", "className", "eventHandler", "eventName", "useCapture", "attributes", "keys", "_BasicProgressDialog_decorators", "_init", "_a", "_BasicProgressDialog", "props", "value", "__name", "_b", "el", "opt", "close", "id", "jsx", "__decoratorStart", "__decorateElement", "__runInitializers", "BasicProgressDialog", "import_corelib", "_BulkServiceAction", "BasicProgressDialog", "targetCount", "action", "parallelRequests", "title", "batch", "batchSize", "keys", "value", "__name", "BulkServiceAction", "import_corelib", "ExcelExportHelper", "createToolButton", "options", "_a", "_b", "__name", "grid", "request", "sortBy", "columns", "column", "import_corelib", "PdfExportHelper", "toAutoTableColumns", "srcColumns", "columnStyles", "columnTitles", "src", "col", "style", "__name", "toAutoTableData", "slickGrid", "entities", "keys", "_a", "el", "row", "sanitizer", "item", "_b", "_c", "dst", "cell", "format", "ctx", "html", "exportToPdf", "options", "g", "request", "sortBy", "gridColumns", "x", "column", "response", "includeAutoTable", "doc", "columns", "data", "reportTitle", "totalPagesExp", "pageNumbers", "autoOptions", "footer", "header", "str", "fileName", "output", "createToolButton", "includeJsPDF", "then", "script", "import_corelib", "_EnumSelectFormatter_decorators", "_init", "_EnumSelectFormatter", "props", "_a", "_b", "_c", "ctx", "enumType", "sb", "x", "v", "name", "value", "__decoratorStart", "__decorateElement", "__name", "__runInitializers", "EnumSelectFormatter", "import_corelib", "_SingleLineTextFormatter_decorators", "_init", "_SingleLineTextFormatter", "ctx", "value", "div", "__decoratorStart", "__decorateElement", "__name", "__runInitializers", "SingleLineTextFormatter", "import_corelib", "_GridEditorBase_decorators", "_init", "_a", "_GridEditorBase", "props", "entity", "opt", "callback", "request", "row", "id", "items", "index", "x", "buttons", "addButton", "dlg", "dialog", "entityOrId", "item", "property", "target", "source", "p", "y", "value", "__decoratorStart", "__decorateElement", "__name", "__runInitializers", "GridEditorBase", "import_corelib", "_GridEditorDialog_decorators", "_init", "_a", "_GridEditorDialog", "options", "callback", "__decoratorStart", "__decorateElement", "__name", "__runInitializers", "GridEditorDialog", "import_corelib", "import_corelib", "ReportHelper", "createToolButton", "options", "_a", "_b", "__name", "execute", "opt", "_ReportDialog_decorators", "_init", "_a", "_ReportDialog", "props", "reportKey", "__name", "response", "target", "ext", "download", "opt", "ReportHelper", "id", "jsx", "__decoratorStart", "__decorateElement", "__runInitializers", "ReportDialog", "import_corelib", "_ReportPage_decorators", "_init", "_a", "_ReportPage", "props", "__name", "field", "text", "done", "liList", "x", "reportItems", "el", "title", "parents", "selector", "matchingItems", "visibles", "i", "v", "c", "nonVisibles", "ReportDialog", "__decoratorStart", "__decorateElement", "__runInitializers", "ReportPage", "_UserPreferenceStorage", "key", "UserPreferenceService", "data", "__name", "UserPreferenceStorage", "import_corelib", "DialogUtils", "pendingChangesConfirmation", "element", "hasPendingChanges", "el", "result", "e", "_a", "__name", "beforeUnload", "import_corelib", "_PromptDialog_decorators", "_init", "_a", "_PromptDialog", "props", "msg", "__name", "v", "title", "message", "value", "validateValue", "__decoratorStart", "__decorateElement", "__runInitializers", "PromptDialog", "import_corelib", "import_sleekgrid", "_SelectableEntityGrid_decorators", "_init", "_a", "_SelectableEntityGrid", "opt", "grid", "__decoratorStart", "__decorateElement", "__name", "__runInitializers", "SelectableEntityGrid", "import_corelib", "_StaticTextBlock_decorators", "_init", "_a", "_StaticTextBlock", "props", "label", "txt", "source", "property", "__decoratorStart", "__decorateElement", "__name", "__runInitializers", "StaticTextBlock", "import_corelib", "getPasswordStrengthRules", "__name", "addPasswordStrengthValidation", "passwordEditor", "uniqueName", "passwordStrengthRules"]
}