All Downloads are FREE. Search and download functionalities are using the official Maven repository.

web-interface.assets.app.a0efe310c8d25ed40c76.js Maven / Gradle / Ivy

There is a newer version: 6.1.4
Show newest version
(()=>{(()=>{var af={"xVpy+aBO":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`form:not(.form-inline) .twitter-typeahead {
  width: 100%;
}
.typeahead,
.tt-query,
.tt-hint {
  border: 2px solid #ccc;
  border-radius: 4px;
  outline: none;
}
.typeahead {
  background-color: #fff;
}
.typeahead:focus {
  border: 2px solid #0097cf;
}
.tt-query {
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
}
input[type="text"].tt-hint {
  color: #999;
}
.tt-menu {
  min-width: 160px;
  background-color: #fff;
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: 4px;
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
  width: 100%;
}
.tt-dataset {
  margin-top: 10px;
}
.tt-suggestion {
  font-size: 1rem;
  /* theme.fonts.size.body */
  line-height: 20px;
  padding: 3px 20px;
  cursor: pointer;
}
.tt-suggestion:hover,
.tt-suggestion.tt-cursor {
  color: #ffffff;
  text-decoration: none;
  background-color: #0081c2;
  background-image: linear-gradient(to bottom, #0088cc, #0077b3);
  background-repeat: repeat-x;
  outline: 0;
  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0077b3', GradientType=0);
}
.tt-suggestion p {
  margin: 0;
}
`,"",{version:3,sources:["webpack://./public/stylesheets/typeahead.less"],names:[],mappings:"AAAA;EACE,WAAA;AACF;AAEA;;;EAGE,sBAAA;EACA,kBAAA;EACA,aAAA;AAAF;AAGA;EACE,sBAAA;AADF;AAIA;EACE,yBAAA;AAFF;AAKA;EACE,gDAAA;AAHF;AAMA;EACE,WAAA;AAJF;AAOA;EACE,gBAAA;EACA,sBAAA;EACA,oCAAA;EACA,kBAAA;EACA,yCAAA;EACA,WAAA;AALF;AAQA;EACE,gBAAA;AANF;AASA;EACE,eAAA;EAPA,0BAA0B;EAQ1B,iBAAA;EACA,iBAAA;EACA,eAAA;AANF;AASA;;EAEE,cAAA;EACA,qBAAA;EACA,yBAAA;EACA,8DAAA;EACA,2BAAA;EACA,UAAA;EACA,sHAAA;AAPF;AAUA;EACE,SAAA;AARF",sourcesContent:[`form:not(.form-inline) .twitter-typeahead {
  width: 100%;
}

.typeahead,
.tt-query,
.tt-hint {
  border: 2px solid #ccc;
  border-radius: 4px;
  outline: none;
}

.typeahead {
  background-color: #fff;
}

.typeahead:focus {
  border: 2px solid #0097cf;
}

.tt-query {
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
}

input[type="text"].tt-hint {
  color: #999
}

.tt-menu {
  min-width: 160px;
  background-color: #fff;
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: 4px;
  box-shadow: 0 5px 10px rgba(0,0,0,.2);
  width: 100%;
}

.tt-dataset {
  margin-top: 10px;
}

.tt-suggestion {
  font-size: 1rem; /* theme.fonts.size.body */
  line-height: 20px;
  padding: 3px 20px;
  cursor: pointer;
}

.tt-suggestion:hover,
.tt-suggestion.tt-cursor {
  color: #ffffff;
  text-decoration: none;
  background-color: #0081c2;
  background-image: linear-gradient(to bottom, #0088cc, #0077b3);
  background-repeat: repeat-x;
  outline: 0;
  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0077b3', GradientType=0);
}

.tt-suggestion p {
  margin: 0;
}
`],sourceRoot:""}]);const c=n},"3czfsiiO":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.QCm7R4MwlLoTDwu8SNZB {
    padding-left: 0;
    margin-bottom: 20px;
}

.QCm7R4MwlLoTDwu8SNZB .QCm7R4MwlLoTDwu8SNZB {
    margin-bottom: 0;
}
`,"",{version:3,sources:["webpack://./src/components/common/ExpandableList.css"],names:[],mappings:"AAAA;IACI,eAAe;IACf,mBAAmB;AACvB;;AAEA;IACI,gBAAgB;AACpB",sourcesContent:[`:local(.list) {
    padding-left: 0;
    margin-bottom: 20px;
}

:local(.list) :local(.list) {
    margin-bottom: 0;
}
`],sourceRoot:""}]),n.locals={list:"QCm7R4MwlLoTDwu8SNZB"};const c=n},QTOlkT3a:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.bLH1iAETwjYKFim2_xa9 {
    padding-left: 0;
    padding-right: 0;
}

.bLH1iAETwjYKFim2_xa9 .popover-content {
    min-width: 200px;
    padding: 0;
}

.bLH1iAETwjYKFim2_xa9 .list-group {
    margin-bottom: 0;
}

.bLH1iAETwjYKFim2_xa9 .list-group-item {
    border-right: 0;
    border-left: 0;
    padding: 6px 15px;
}

.bLH1iAETwjYKFim2_xa9 .list-group-item:first-child {
    border-top-right-radius: 0;
    border-top-left-radius: 0;
}

.bLH1iAETwjYKFim2_xa9 .list-group-item:last-child {
    border-bottom: 0;
}

.SOQRgrHWKOcqvbc6z1g7 {
    max-height: 340px; /* 10 items */
    overflow: auto;
}

.tfZVJT0QPa8mTaekvKgt {
    margin-bottom: 0 !important;
    padding: 5px;
}
`,"",{version:3,sources:["webpack://./src/components/common/SelectPopover.css"],names:[],mappings:"AAAA;IACI,eAAe;IACf,gBAAgB;AACpB;;AAEA;IACI,gBAAgB;IAChB,UAAU;AACd;;AAEA;IACI,gBAAgB;AACpB;;AAEA;IACI,eAAe;IACf,cAAc;IACd,iBAAiB;AACrB;;AAEA;IACI,0BAA0B;IAC1B,yBAAyB;AAC7B;;AAEA;IACI,gBAAgB;AACpB;;AAEA;IACI,iBAAiB,EAAE,aAAa;IAChC,cAAc;AAClB;;AAEA;IACI,2BAA2B;IAC3B,YAAY;AAChB",sourcesContent:[`:local(.customPopover) {
    padding-left: 0;
    padding-right: 0;
}

:local(.customPopover) .popover-content {
    min-width: 200px;
    padding: 0;
}

:local(.customPopover) .list-group {
    margin-bottom: 0;
}

:local(.customPopover) .list-group-item {
    border-right: 0;
    border-left: 0;
    padding: 6px 15px;
}

:local(.customPopover) .list-group-item:first-child {
    border-top-right-radius: 0;
    border-top-left-radius: 0;
}

:local(.customPopover) .list-group-item:last-child {
    border-bottom: 0;
}

:local(.scrollableList) {
    max-height: 340px; /* 10 items */
    overflow: auto;
}

:local(.dataFilterInput) {
    margin-bottom: 0 !important;
    padding: 5px;
}
`],sourceRoot:""}]),n.locals={customPopover:"bLH1iAETwjYKFim2_xa9",scrollableList:"SOQRgrHWKOcqvbc6z1g7",dataFilterInput:"tfZVJT0QPa8mTaekvKgt"};const c=n},ykMrd0fI:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.QOxROnWrKzReuEpPEJMw {
    table-layout: fixed;
    overflow-wrap: break-word;
}
`,"",{version:3,sources:["webpack://./src/components/event-notifications/event-notification-types/CommonNotificationSummary.css"],names:[],mappings:"AAAA;IACI,mBAAmB;IACnB,yBAAyB;AAC7B",sourcesContent:[`:local(.fixedTable) {
    table-layout: fixed;
    overflow-wrap: break-word;
}
`],sourceRoot:""}]),n.locals={fixedTable:"QOxROnWrKzReuEpPEJMw"};const c=n},OXMg8s84:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`#toast-container .toast {
  display: grid;
  grid-template-columns: 8fr 0.5fr;
  grid-template-rows: repeat(2, 1fr);
  grid-column-gap: 0;
  grid-row-gap: 0;
}

#toast-container .toast-title {
  grid-area: 1 / 1 / 2 / 1;
}

#toast-container .toast-message {
  grid-area: 2 / 2 / 2 / 1;
}

#toast-container button.toast-close-button {
  font-size: 0.889rem; /* theme.fonts.size.small */
  grid-area: 1 / 2 / 3 / 3;
  height: 100%;
  top: 0;
  right: 0;
  font-weight: normal;
}

#toast-container button.toast-close-button:focus,
#toast-container button.toast-close-button:hover {
  color: #fff;
}
`,"",{version:3,sources:["webpack://./src/util/UserNotification.css"],names:[],mappings:"AAAA;EACE,aAAa;EACb,gCAAgC;EAChC,kCAAkC;EAClC,kBAAkB;EAClB,eAAe;AACjB;;AAEA;EACE,wBAAwB;AAC1B;;AAEA;EACE,wBAAwB;AAC1B;;AAEA;EACE,mBAAmB,EAAE,2BAA2B;EAChD,wBAAwB;EACxB,YAAY;EACZ,MAAM;EACN,QAAQ;EACR,mBAAmB;AACrB;;AAEA;;EAEE,WAAW;AACb",sourcesContent:[`#toast-container .toast {
  display: grid;
  grid-template-columns: 8fr 0.5fr;
  grid-template-rows: repeat(2, 1fr);
  grid-column-gap: 0;
  grid-row-gap: 0;
}

#toast-container .toast-title {
  grid-area: 1 / 1 / 2 / 1;
}

#toast-container .toast-message {
  grid-area: 2 / 2 / 2 / 1;
}

#toast-container button.toast-close-button {
  font-size: 0.889rem; /* theme.fonts.size.small */
  grid-area: 1 / 2 / 3 / 3;
  height: 100%;
  top: 0;
  right: 0;
  font-weight: normal;
}

#toast-container button.toast-close-button:focus,
#toast-container button.toast-close-button:hover {
  color: #fff;
}
`],sourceRoot:""}]),n.locals={};const c=n},"kK/tJf6e":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.jcr2Blo1owtKhor0NDK4 {
    display: inline;
}
`,"",{version:3,sources:["webpack://./src/views/components/common/EditableTitle.css"],names:[],mappings:"AAAA;IACI,eAAe;AACnB",sourcesContent:[`:local(.inlineForm) {
    display: inline;
}
`],sourceRoot:""}]),n.locals={inlineForm:"jcr2Blo1owtKhor0NDK4"};const c=n},"4Dfti3jc":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.Xs05u6g6T94RXQPWqmgX {
    height: 100%;
    /* The grid prop is a workaround to fix
     * horizontal scrolling for safari */
    display: grid;
    display: -ms-grid;
    grid-template-rows: 1fr;
    -ms-grid-rows: 1fr;
    grid-template-columns: 1fr;
    -ms-grid-columns: 1fr;
}

.tezUr3fyRnWnYXoSKy4b {
    overflow: auto;
    grid-row: 1;
    -ms-grid-row: 1;
    grid-column: 1;
    -ms-grid-column: 1;
}

.cUxYxJT0iMrajuP7YHXA {
    left: 0px;
}

@media print {
    table.messages {
        font-size: 1rem !important; /* theme.fonts.size.body */
        min-width: 50%;
        padding-left: 0;
    }

    table.messages th {
        font-weight: bold !important;
        font-size: inherit !important;
    }

    table.messages th,
    table.messages td {
        border: 1px #ccc solid !important;
        left: 0;
        padding: 5px;
        position: static;
    }
}
`,"",{version:3,sources:["webpack://./src/views/components/datatable/DataTable.css"],names:[],mappings:"AAAA;IACI,YAAY;IACZ;wCACoC;IACpC,aAAa;IACb,iBAAiB;IACjB,uBAAuB;IACvB,kBAAkB;IAClB,0BAA0B;IAC1B,qBAAqB;AACzB;;AAEA;IACI,cAAc;IACd,WAAW;IACX,eAAe;IACf,cAAc;IACd,kBAAkB;AACtB;;AAEA;IACI,SAAS;AACb;;AAEA;IACI;QACI,0BAA0B,EAAE,0BAA0B;QACtD,cAAc;QACd,eAAe;IACnB;;IAEA;QACI,4BAA4B;QAC5B,6BAA6B;IACjC;;IAEA;;QAEI,iCAAiC;QACjC,OAAO;QACP,YAAY;QACZ,gBAAgB;IACpB;AACJ",sourcesContent:[`:local(.container) {
    height: 100%;
    /* The grid prop is a workaround to fix
     * horizontal scrolling for safari */
    display: grid;
    display: -ms-grid;
    grid-template-rows: 1fr;
    -ms-grid-rows: 1fr;
    grid-template-columns: 1fr;
    -ms-grid-columns: 1fr;
}

:local(.scrollContainer) {
    overflow: auto;
    grid-row: 1;
    -ms-grid-row: 1;
    grid-column: 1;
    -ms-grid-column: 1;
}

:local(.leftAligned) {
    left: 0px;
}

@media print {
    table.messages {
        font-size: 1rem !important; /* theme.fonts.size.body */
        min-width: 50%;
        padding-left: 0;
    }

    table.messages th {
        font-weight: bold !important;
        font-size: inherit !important;
    }

    table.messages th,
    table.messages td {
        border: 1px #ccc solid !important;
        left: 0;
        padding: 5px;
        position: static;
    }
}
`],sourceRoot:""}]),n.locals={container:"Xs05u6g6T94RXQPWqmgX",scrollContainer:"tezUr3fyRnWnYXoSKy4b",leftAligned:"cUxYxJT0iMrajuP7YHXA"};const c=n},zUghPtuB:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.QSHpvNKPLbhcL9XmEhhU {
    display: flex;
    justify-content: space-between;
}

.j9AR9KIYOoQokjhQgKvg {
    margin-top: 5px;
    margin-bottom: 5px;
}

.OEtwRH8_D2wSh4zSe35P {
    margin-right: 5px;
    width: 100%;
}

.Ptn3S3n2DhOJZlpLxQ8U {
    font-size: 1rem; /* theme.fonts.size.body */
    padding-top: 0px;
    padding-right: 0px;
    float: right;
}

.mWIeXfwAHVUqyO9KpNv8 {
    font-size: 1rem; /* theme.fonts.size.body */
}

.i93VpIsNwxNSYHhnrhdm {
    display: inline-block;
    overflow: visible;
    width: 100%;
}

.Mt_DKChL9e_UySBfolGR {
    margin-top: 2em;
}
`,"",{version:3,sources:["webpack://./src/views/components/messagelist/decorators/decoratorStyles.css"],names:[],mappings:"AAAA;IACI,aAAa;IACb,8BAA8B;AAClC;;AAEA;IACI,eAAe;IACf,kBAAkB;AACtB;;AAEA;IACI,iBAAiB;IACjB,WAAW;AACf;;AAEA;IACI,eAAe,EAAE,0BAA0B;IAC3C,gBAAgB;IAChB,kBAAkB;IAClB,YAAY;AAChB;;AAEA;IACI,eAAe,EAAE,0BAA0B;AAC/C;;AAEA;IACI,qBAAqB;IACrB,iBAAiB;IACjB,WAAW;AACf;;AAEA;IACI,eAAe;AACnB",sourcesContent:[`:local(.decoratorBox) {
    display: flex;
    justify-content: space-between;
}

:local(.addDecoratorButtonContainer) {
    margin-top: 5px;
    margin-bottom: 5px;
}

:local(.addDecoratorSelect) {
    margin-right: 5px;
    width: 100%;
}

:local(.helpLink) {
    font-size: 1rem; /* theme.fonts.size.body */
    padding-top: 0px;
    padding-right: 0px;
    float: right;
}

:local(.helpPopover) {
    font-size: 1rem; /* theme.fonts.size.body */
}

:local(.decoratorListContainer) {
    display: inline-block;
    overflow: visible;
    width: 100%;
}

:local(.noDecoratorsAlert) {
    margin-top: 2em;
}
`],sourceRoot:""}]),n.locals={decoratorBox:"QSHpvNKPLbhcL9XmEhhU",addDecoratorButtonContainer:"j9AR9KIYOoQokjhQgKvg",addDecoratorSelect:"OEtwRH8_D2wSh4zSe35P",helpLink:"Ptn3S3n2DhOJZlpLxQ8U",helpPopover:"mWIeXfwAHVUqyO9KpNv8",decoratorListContainer:"i93VpIsNwxNSYHhnrhdm",noDecoratorsAlert:"Mt_DKChL9e_UySBfolGR"};const c=n},V7bsrEHK:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.FExXmIJ_52cj0vrHyaEp {
    margin: 5px;
}`,"",{version:3,sources:["webpack://./src/views/components/searchbar/saved-search/SavedSearchForm.css"],names:[],mappings:"AAAA;IACI,WAAW;AACf",sourcesContent:[`:local(.button) {
    margin: 5px;
}`],sourceRoot:""}]),n.locals={button:"FExXmIJ_52cj0vrHyaEp"};const c=n},d39qUqyh:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.FNITmrI44QcfwOlSnZnW {
    padding: 0;
    overflow-y: auto;
}

.uWCkwTOVkwo9YrCjUynr {
    font-size: 12px;
    display: table-row;
    white-space: nowrap;
}

.Zy3GorsX2QMvX8NgdDwv {
    display: flex;
}

.NIPxqjCGQchbRQbyrPIR {
    flex-grow: 1;
    margin-right: 5px;
}`,"",{version:3,sources:["webpack://./src/views/components/sidebar/fields/FieldTypeIcon.css"],names:[],mappings:"AAAA;IACI,UAAU;IACV,gBAAgB;AACpB;;AAEA;IACI,eAAe;IACf,kBAAkB;IAClB,mBAAmB;AACvB;;AAEA;IACI,aAAa;AACjB;;AAEA;IACI,YAAY;IACZ,iBAAiB;AACrB",sourcesContent:[`:local(.fieldList) {
    padding: 0;
    overflow-y: auto;
}

:local(.fieldListItem) {
    font-size: 12px;
    display: table-row;
    white-space: nowrap;
}

:local(.filterContainer) {
    display: flex;
}

:local(.filterInputContainer) {
    flex-grow: 1;
    margin-right: 5px;
}`],sourceRoot:""}]),n.locals={fieldList:"FNITmrI44QcfwOlSnZnW",fieldListItem:"uWCkwTOVkwo9YrCjUynr",filterContainer:"Zy3GorsX2QMvX8NgdDwv",filterInputContainer:"NIPxqjCGQchbRQbyrPIR"};const c=n},"H/VBAZHe":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.qWBqb_23sgqkD946642Z {
    position: absolute;
    z-index: 999; /* So it displays below bootstrap dropdowns */
}

.VEeyO9k8vNGGhxOuqVkQ .leaflet-control-container {
    display: none;
}

.leaflet-top, .leaflet-bottom {
    z-index: 999; /* So it displays below bootstrap dropdowns */
}

@media print {
    .KoTenzOWhTf1f7jkioVR {
        margin: 0 auto;
        page-break-inside: avoid;
    }

    /* Hide zoom controls */
    .leaflet-control-container {
        display: none;
    }
}`,"",{version:3,sources:["webpack://./src/views/components/visualizations/worldmap/MapVisualization.css"],names:[],mappings:"AAAA;IACI,kBAAkB;IAClB,YAAY,EAAE,6CAA6C;AAC/D;;AAEA;IACI,aAAa;AACjB;;AAEA;IACI,YAAY,EAAE,6CAA6C;AAC/D;;AAEA;IACI;QACI,cAAc;QACd,wBAAwB;IAC5B;;IAEA,uBAAuB;IACvB;QACI,aAAa;IACjB;AACJ",sourcesContent:[`:local(.overlay) {
    position: absolute;
    z-index: 999; /* So it displays below bootstrap dropdowns */
}

:local(.mapLocked) .leaflet-control-container {
    display: none;
}

.leaflet-top, .leaflet-bottom {
    z-index: 999; /* So it displays below bootstrap dropdowns */
}

@media print {
    :local(.map) {
        margin: 0 auto;
        page-break-inside: avoid;
    }

    /* Hide zoom controls */
    .leaflet-control-container {
        display: none;
    }
}`],sourceRoot:""}]),n.locals={overlay:"qWBqb_23sgqkD946642Z",mapLocked:"VEeyO9k8vNGGhxOuqVkQ",map:"KoTenzOWhTf1f7jkioVR"};const c=n},BcnLA9qD:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`.AGNNVtf0vXX5QH3GraEY {
    margin-right: 15px;
    margin: 3px 15px 0 0;
}
`,"",{version:3,sources:["webpack://./src/views/components/widgets/MessageWidgets.css"],names:[],mappings:"AAAA;IACI,kBAAkB;IAClB,oBAAoB;AACxB",sourcesContent:[`:local(.iconMargin) {
    margin-right: 15px;
    margin: 3px 15px 0 0;
}
`],sourceRoot:""}]),n.locals={iconMargin:"AGNNVtf0vXX5QH3GraEY"};const c=n},"xTTaAS+O":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`/* Restore bootstrap heading margins because our stylesheet is :shit: */
.Qgqa5YAOjl_LIS9aGdk3 h1, .Qgqa5YAOjl_LIS9aGdk3 h2, .Qgqa5YAOjl_LIS9aGdk3 h3 {
    margin-top: 20px;
    margin-bottom: 10px;
}

.Qgqa5YAOjl_LIS9aGdk3 h4, .Qgqa5YAOjl_LIS9aGdk3 h5, .Qgqa5YAOjl_LIS9aGdk3 h6 {
    margin-top: 10px;
    margin-bottom: 10px;
}
`,"",{version:3,sources:["webpack://./src/views/pages/StyleFixups.css"],names:[],mappings:"AAAA,uEAAuE;AACvE;IACI,gBAAgB;IAChB,mBAAmB;AACvB;;AAEA;IACI,gBAAgB;IAChB,mBAAmB;AACvB",sourcesContent:[`/* Restore bootstrap heading margins because our stylesheet is :shit: */
:local(.bootstrapHeading) h1, :local(.bootstrapHeading) h2, :local(.bootstrapHeading) h3 {
    margin-top: 20px;
    margin-bottom: 10px;
}

:local(.bootstrapHeading) h4, :local(.bootstrapHeading) h5, :local(.bootstrapHeading) h6 {
    margin-top: 10px;
    margin-bottom: 10px;
}
`],sourceRoot:""}]),n.locals={bootstrapHeading:"Qgqa5YAOjl_LIS9aGdk3"};const c=n},lM0K4xME:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("pmX897Fv"),s=e.n(t),o=e("DjJvgDaP"),r=e.n(o),n=r()(s());n.push([M.id,`div.plotly-notifier {
    visibility: hidden;
}

.xK5gTnz6x6uLtuCzdS2T .popover-content {
    padding: 0;
}
`,"",{version:3,sources:["webpack://./src/views/components/visualizations/GenericPlot.lazy.css"],names:[],mappings:"AAAA;IACI,kBAAkB;AACtB;;AAEA;IACI,UAAU;AACd",sourcesContent:[`div.plotly-notifier {
    visibility: hidden;
}

:local(.customPopover) .popover-content {
    padding: 0;
}
`],sourceRoot:""}]),n.locals={customPopover:"xK5gTnz6x6uLtuCzdS2T"};const c=n},"62FDaRYn":(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("JnTtTRmZ"),s=e.n(t),o=e("IA3Ku5lS");const n=(0,o.ei)("Errors",()=>s().createActions(["report"]))},NqeDg39C:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("lCPkTODq"),o=e("VPaD/Np4"),r=e("0hhBr0/b"),n=e("s98ZeFHv");const v=(p,E)=>{const a=Object.fromEntries(p.map(u=>[u.key,u.reducer]));return(0,n.xC)({reducer:a,preloadedState:E,middleware:u=>u({serializableCheck:!1,immutableCheck:!1})})},d=({initialQuery:p,children:E,isNew:a,view:u,executionState:f,undoRedoState:y})=>{var T;const P=(0,r.Z)("views.reducers"),O=(0,t.useMemo)(()=>{var x,W,N;const Z=(W=(x=u==null?void 0:u.search)==null?void 0:x.queries)!=null?W:o.Set();return p&&Z.find(j=>j.id===p)!==void 0?p:(N=Z.first())==null?void 0:N.id},[p,(T=u==null?void 0:u.search)==null?void 0:T.queries]),b=(0,t.useMemo)(()=>({view:{view:u,isDirty:!1,isNew:a,activeQuery:O},searchExecution:{widgetsToSearch:void 0,executionState:f,isLoading:!1,result:void 0},...y?{undoRedo:y}:{}}),[f,a,u]),L=(0,t.useMemo)(()=>v(P,b),[b,P]);return t.createElement(s.Provider,{store:L},E)};d.defaultProps={undoRedoState:void 0};const g=d},kwpLVeht:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("U7y/BNwM"),r=e("93yMNhQL");const n=(0,s.default)(o.Alert)(({theme:g})=>(0,s.css)`
  margin: ${g.mantine.spacing.md} 0;
`),c=g=>{switch(g){case"warning":case"danger":return"exclamation-triangle";case"success":return"circle-check";default:return"info-circle"}},v=({children:g,bsStyle:p,title:E,style:a,className:u,onDismiss:f})=>{const y=(0,o.useMantineTheme)(),T=typeof f=="function",P=c(p),O=()=>({root:{border:`1px solid ${y.other.shades.lighter(p)}`},message:{fontSize:y.fontSizes.md},title:{fontSize:y.fontSizes.md,color:y.other.colors.global.textDefault},closeButton:{color:y.other.colors.global.textDefault}});return t.createElement(n,{className:u,color:p,style:a,styles:O,onClose:f,title:E,icon:t.createElement(r.Z,{name:P}),closeButtonLabel:T&&"Close alert",withCloseButton:T},g)};v.defaultProps={className:void 0,onDismiss:void 0,style:void 0,title:void 0,bsStyle:"default"};const d=v},sUEzN8pX:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c,j:()=>r});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("aKyEWaw1");const r=(0,s.default)(o.Badge)(({bsStyle:v,theme:d})=>{if(!v)return;const g=d.colors.variant[v],p=d.utils.readableColor(g);return(0,s.css)`
    background-color: ${g};
    color: ${p};
`}),c=(0,t.forwardRef)(({...v},d)=>t.createElement(r,{ref:d,...v}))},PVMUg5WH:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("rp7UD7rK"),n=e("coBi+lXG"),c=e("gqVHlIxA");const v=({showModal:g,title:p,children:E,cancelButtonDisabled:a,confirmButtonDisabled:u,confirmButtonText:f,onCancel:y,onConfirm:T,...P})=>t.createElement(c.Z,{showModal:g,onHide:y,role:"alertdialog",...P},t.createElement(n.Z.Header,{closeButton:!0},t.createElement(n.Z.Title,null,p)),t.createElement(n.Z.Body,null,E),t.createElement(n.Z.Footer,null,t.createElement(r.Z,{disabledCancel:a,disabledSubmit:u,onCancel:y,onSubmit:T,submitButtonText:f,submitButtonType:"button"})));v.propTypes={showModal:o().bool.isRequired,title:o().oneOfType([o().string,o().element]).isRequired,confirmButtonText:o().string,cancelButtonDisabled:o().bool,confirmButtonDisabled:o().bool,onCancel:o().func.isRequired,onConfirm:o().func.isRequired,children:o().oneOfType([o().string,o().element]).isRequired},v.defaultProps={confirmButtonText:"Confirm",cancelButtonDisabled:!1,confirmButtonDisabled:!1};const d=v},"gTexEe+8":(M,C,e)=>{"use strict";e.d(C,{Z:()=>a});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("kqAR+wt5"),n=e.n(r),c=e("X6P4SH4J"),v=e.n(c),d=e("rp7UD7rK"),g=e("coBi+lXG"),p=e("gqVHlIxA");const E=({backdrop:u,submitButtonDisabled:f,formProps:y,bsSize:T,show:P,submitButtonText:O,onSubmitForm:b,onCancel:L,title:x,children:W,modalTitle:N,...Z})=>{const j=(0,o.useRef)(null),z=ae=>{const ee=j.current,ue=n()(ee);if(typeof ee.checkValidity=="function"&&!ee.checkValidity()||typeof ue.checkValidity=="function"&&!ue.checkValidity()){ae.preventDefault();return}typeof b=="function"&&(ae.preventDefault(),b(ae))},ne=o.createElement("div",{className:"container-fluid"},W),Y=(0,o.useMemo)(()=>v()(x)?x:N,[N,x]);return o.createElement(p.Z,{bsSize:T,showModal:P,backdrop:u,onHide:L,title:Y,...Z},o.createElement(g.Z.Header,{closeButton:!0},o.createElement(g.Z.Title,null,x)),o.createElement("form",{ref:j,onSubmit:z,...y,"data-testid":"modal-form"},o.createElement(g.Z.Body,null,ne),o.createElement(g.Z.Footer,null,o.createElement(d.Z,{disabledSubmit:f,onCancel:L,submitButtonText:O}))))};E.propTypes={backdrop:s().oneOf([!0,!1,"static"]),bsSize:s().oneOf(["lg","large","sm","small"]),title:s().oneOfType([s().string,s().node]).isRequired,children:s().oneOfType([s().arrayOf(s().element),s().element]).isRequired,onSubmitForm:s().func,onCancel:s().func.isRequired,formProps:s().object,submitButtonText:s().oneOfType([s().string,s().node]),submitButtonDisabled:s().bool,show:s().bool.isRequired},E.defaultProps={backdrop:void 0,formProps:{},submitButtonText:"Submit",submitButtonDisabled:!1,onSubmitForm:void 0,bsSize:void 0,modalTitle:void 0};const a=E},gqVHlIxA:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("coBi+lXG");const n=({showModal:v,children:d,onHide:g,bsSize:p,backdrop:E,role:a,...u})=>o.createElement(r.Z,{show:v,onHide:g,bsSize:p,backdrop:E,role:a,...u},d);n.propTypes={showModal:s().bool.isRequired,children:s().oneOfType([s().arrayOf(s().element),s().element]).isRequired,onHide:s().func.isRequired,bsSize:s().oneOf(["large","lg","small","sm"]),backdrop:s().oneOf(["static",!0,!1]),role:s().string},n.defaultProps={bsSize:void 0,backdrop:"static",role:"dialog",title:void 0};const c=n},utbMO9sg:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("J6y4/h8P"),s=e("aKyEWaw1");const r=(0,t.default)(s.Button)(({theme:n})=>(0,t.css)`
  ${n.components.button}
`)},CrIFpfDF:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("aKyEWaw1");const o=t.ButtonToolbar},Ru9ofG0m:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("J6y4/h8P"),s=e("aKyEWaw1");const r=(0,t.default)(s.ControlLabel)(({theme:n})=>(0,t.css)`
  color: ${n.colors.global.textDefault};
  font-weight: bold;
  margin-bottom: 5px;
  display: inline-block;
`)},HB0tOxLI:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("aKyEWaw1"),s=e("J6y4/h8P"),o=e("CCNXj2ra");const r=(0,s.default)(t.FormControl)(({theme:c})=>(0,s.css)`
  &.form-control {
    border-radius: ${o.L$};
  }

  &.form-control:not([type='range']) {
    color: ${c.colors.input.color};
    background-color: ${c.colors.input.background};
    border-color: ${c.colors.input.border};

    &::placeholder {
      color: ${c.colors.input.placeholder};
    }

    &:focus {
      border-color: ${c.colors.input.borderFocus};
      box-shadow: ${c.colors.input.boxShadow};
    }

    &[disabled],
    &[readonly],
    fieldset[disabled] & {
      background-color: ${c.colors.input.backgroundDisabled};
      color: ${c.colors.input.colorDisabled};
    }

    ~ .form-control-feedback.glyphicon {
      display: none;
    }
  }
`);r.Static=t.FormControl.Static,r.Feedback=t.FormControl.Feedback;const n=r},nV9jqFLy:(M,C,e)=>{"use strict";e.d(C,{Z:()=>u});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("aKyEWaw1"),n=e("J6y4/h8P"),c=e("ww+BtWnX"),v=e.n(c),d=e("hhdCSTZj"),g=e("HB0tOxLI"),p=e("f5/t4s9T");const E=(0,n.default)(r.FormGroup)(({theme:f,validationState:y})=>{const T=y==="error"?"danger":y;if(!T)return;const P=f.colors.variant.dark[T],O=f.colors.variant.light[T],b=f.colors.variant.lightest[T];return(0,n.css)`
    &.has-${y} {
      .help-block,
      .control-label,
      .radio,
      .checkbox,
      .radio-inline,
      .checkbox-inline,
      &.radio label,
      &.checkbox label,
      &.radio-inline label,
      &.checkbox-inline label {
        color: ${P};
      }

      ${g.Z}, .${d.K} {
        border-color: ${O};

        &:focus {
          border-color: ${v()(O).darken(.1)};
          box-shadow: inset 0 1px 1px rgb(0 0 0 / 7.5%), 0 0 6px ${v()(O).brighten(.2)};
        }
      }

      ${p.b} {
        color: ${P};
        background-color: ${b};
        border-color: ${O};
      }

      .form-control-feedback {
        color: ${P};
      }
    }
`}),a=(0,t.memo)(({children:f,validationState:y,...T})=>t.createElement(E,{validationState:y,...T},f));a.propTypes={children:o().node.isRequired,validationState:o().oneOf([null,"error","success","warning"])},a.defaultProps={validationState:null};const u=a},yDuYCNwc:(M,C,e)=>{"use strict";e.d(C,{Z:()=>y});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("Kz+u8q89"),n=e("3dj8OEcA"),c=e("Ru9ofG0m"),v=e("HB0tOxLI"),d=e("nV9jqFLy"),g=e("f5/t4s9T"),p=e("8tm/+anU"),E=Object.defineProperty,a=(T,P,O)=>P in T?E(T,P,{enumerable:!0,configurable:!0,writable:!0,value:O}):T[P]=O,u=(T,P,O)=>(a(T,typeof P!="symbol"?P+"":P,O),O);class f extends o.Component{constructor(){super(...arguments),u(this,"getInputDOMNode",()=>this.input),u(this,"getValue",()=>{const{type:P}=this.props;if(!P)throw new Error("Cannot use getValue without specifying input type.");switch(P){case"checkbox":case"radio":return this.getInputDOMNode().checked;default:return this.getInputDOMNode().value}}),u(this,"getChecked",()=>this.getInputDOMNode().checked),u(this,"_renderFormControl",(P,O,b)=>o.createElement(v.Z,{inputRef:L=>{this.input=L},componentClass:P,...O},b)),u(this,"_renderFormGroup",P=>{const{id:O,bsStyle:b,formGroupClassName:L,wrapperClassName:x,inputDescClassName:W,label:N,labelClassName:Z,error:j,help:z,buttonAfter:ne,addonAfter:Y}=this.props;let ae;return Y||ne?ae=o.createElement(g.Z,null,P,ne&&o.createElement(g.Z.Button,null,ne),Y&&o.createElement(g.Z.Addon,null,Y)):ae=P,o.createElement(d.Z,{controlId:O,validationState:j?"error":b,bsClass:L},N&&o.createElement(c.Z,{className:Z},N),o.createElement(p.Z,{className:x},ae,o.createElement(r.Z,{error:j,help:z,className:W})))}),u(this,"_renderCheckboxGroup",P=>{const{id:O,buttonAfter:b,bsStyle:L,formGroupClassName:x,inputDescClassName:W,wrapperClassName:N,label:Z,error:j,help:z}=this.props;return o.createElement(d.Z,{controlId:O,validationState:j?"error":L,bsClass:x},o.createElement(p.Z,{className:N},b?o.createElement(g.Z,null,o.createElement(n.XZ,{inputRef:ne=>{this.input=ne},...P},Z),b&&o.createElement(g.Z.Button,null,b)):o.createElement(n.XZ,{inputRef:ne=>{this.input=ne},...P},Z),o.createElement(r.Z,{error:j,help:z,className:W})))}),u(this,"_renderRadioGroup",P=>{const{id:O,bsStyle:b,formGroupClassName:L,inputDescClassName:x,wrapperClassName:W,label:N,error:Z,help:j}=this.props;return o.createElement(d.Z,{controlId:O,validationState:Z?"error":b,bsClass:L},o.createElement(p.Z,{className:W},o.createElement(n.Y8,{inputRef:z=>{this.input=z},...P},N),o.createElement(r.Z,{error:Z,help:j,className:x})))})}render(){const{id:P,type:O,children:b,label:L,name:x,bsStyle:W,formGroupClassName:N,wrapperClassName:Z,labelClassName:j,inputDescClassName:z,error:ne,help:Y,addonAfter:ae,buttonAfter:ee,...ue}=this.props;if(ue.type=O,ue.label=L,ue.name=x||P,!O)return this._renderFormGroup(b);switch(O){case"text":case"password":case"email":case"number":case"file":case"tel":return this._renderFormGroup(this._renderFormControl("input",ue));case"textarea":return this._renderFormGroup(this._renderFormControl("textarea",ue));case"select":return this._renderFormGroup(this._renderFormControl("select",ue,b));case"checkbox":return this._renderCheckboxGroup(ue);case"radio":return this._renderRadioGroup(ue);default:console.warn(`Unsupported input type ${O}`)}return null}}u(f,"propTypes",{id:s().string.isRequired,type:s().string,name:s().string,label:s().oneOfType([s().element,s().string]),labelClassName:s().string,bsStyle:s().oneOf(["success","warning","error"]),formGroupClassName:s().string,inputDescClassName:s().string,value:s().oneOfType([s().string,s().number]),placeholder:s().string,error:s().oneOfType([s().element,s().string]),help:s().oneOfType([s().element,s().string]),wrapperClassName:s().string,addonAfter:s().oneOfType([s().element,s().string]),buttonAfter:s().oneOfType([s().element,s().string]),children:s().oneOfType([s().array,s().element])}),u(f,"defaultProps",{type:void 0,label:"",labelClassName:void 0,name:void 0,formGroupClassName:void 0,inputDescClassName:void 0,bsStyle:null,value:void 0,placeholder:"",error:void 0,help:void 0,wrapperClassName:void 0,addonAfter:null,buttonAfter:null,children:null});const y=f},"f5/t4s9T":(M,C,e)=>{"use strict";e.d(C,{Z:()=>u,b:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("aKyEWaw1"),n=e("J6y4/h8P"),c=e("uRLsxEc6"),v=e.n(c);const d=({className:f,...y})=>t.createElement(r.InputGroup.Addon,{bsClass:f,...y}),g=(0,n.default)(d)(({theme:f})=>(0,n.css)`
  color: ${f.colors.input.color};
  background-color: ${f.colors.input.background};
  border-color: ${f.colors.input.border};
`),p=({bsClass:f,className:y,...T})=>t.createElement(g,{className:v()(f,y),...T}),E=({bsClass:f,className:y,...T})=>t.createElement(r.InputGroup.Button,{bsClass:v()(f,y),...T}),a=({bsClass:f,className:y,...T})=>t.createElement(r.InputGroup,{bsClass:v()(f,y),...T});a.Addon=p,a.Button=E,d.propTypes={className:o().string},d.defaultProps={className:void 0},a.propTypes={bsClass:o().string,className:o().string,children:o().node.isRequired},a.defaultProps={bsClass:"input-group",className:void 0},p.propTypes={bsClass:o().string,className:o().string,children:o().node.isRequired},p.defaultProps={bsClass:"input-group-addon",className:void 0},E.propTypes={bsClass:o().string,className:o().string,children:o().node.isRequired},E.defaultProps={bsClass:"input-group-btn",className:void 0};const u=a},"8tm/+anU":(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B");const r=({children:c,className:v})=>v?o.createElement("div",{className:v},c):o.createElement("span",null,c);r.propTypes={className:s().string,children:s().node.isRequired},r.defaultProps={className:void 0};const n=r},cB7h3AEX:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("aKyEWaw1"),n=e("J6y4/h8P"),c=e("93yMNhQL");const v=n.default.div`
  display: inline-flex;
  min-width: 20px;
  margin-right: 5px;
  justify-content: center;
  align-items: center;
`,d=({className:p,children:E,icon:a,...u})=>t.createElement(r.MenuItem,{bsClass:p,...u},E&&t.createElement(t.Fragment,null,a&&t.createElement(v,null,t.createElement(c.Z,{name:a})),E));d.propTypes={className:o().string,icon:o().string},d.defaultProps={className:void 0,icon:void 0};const g=d},"coBi+lXG":(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("aKyEWaw1"),s=e("J6y4/h8P");const o=(0,s.css)`
  margin-top: 55px;

  .modal-content {
    background-color: ${({theme:p})=>p.colors.global.contentBackground};
    border-color: ${({theme:p})=>p.colors.variant.light.default};
    height: 100%;
  }
`,r=(0,s.css)`
  border-bottom-color: ${({theme:p})=>p.colors.variant.light.default};

  button.close {
    color: currentColor;
  }
`,n=(0,s.css)`
  font-size: ${({theme:p})=>p.fonts.size.h3};
`,c=(0,s.css)`
  border-top-color: ${({theme:p})=>p.colors.variant.light.default};
`,v=(0,s.css)`
  .form-group {
    margin-bottom: 5px;
  }
`,d=(0,s.default)(t.Modal)`
  .modal-backdrop {
    height: 100000%; /* yes, really. this fixes the backdrop being cut off when the page is scrolled. */
    z-index: 1030;
  }

  form {
    margin-bottom: 0;
  }

  .modal-dialog {
    ${o}
  }

  .modal-header {
    ${r}
  }

  .modal-footer {
    ${c}
  }

  .modal-title {
    ${n}
  }

  .modal-body {
    ${v}
  }
`;d.Dialog=(0,s.default)(t.Modal.Dialog)`
  ${o}
`,d.Header=(0,s.default)(t.Modal.Header)`
  ${r}
`,d.Title=(0,s.default)(t.Modal.Title)`
  ${n}
`,d.Body=(0,s.default)(t.Modal.Body)`
  ${v}
`,d.Footer=(0,s.default)(t.Modal.Footer)`
  ${c}
`;const g=d},agK8h0L2:(M,C,e)=>{"use strict";e.d(C,{J:()=>E,Z:()=>a});var t=e("Z7aTuO5B"),s=e("aKyEWaw1"),o=e("J6y4/h8P"),r=e("ii0bleBb"),n=e.n(r),c=e("NV1/EHMi"),v=e("hcoMM3Vl");class d extends s.NavDropdown{isActive({props:f},y,T){return f.active===!1?!1:f.active||y!=null&&f.eventKey===y||T&&f.href===T?!0:f.active}}const g=(0,o.default)(s.NavDropdown)`
  ${v.Z}
`,p=({title:u,inactiveTitle:f,badge:y,...T})=>{const P=f?f!==u:void 0;return t.createElement(g,{...T,title:t.createElement(c.ZP,null,y?t.createElement(y,{text:u}):u),active:P})};p.propTypes={title:n().oneOfType([n().string,n().object]).isRequired,inactiveTitle:n().string,badge:n().func},p.defaultProps={inactiveTitle:void 0,badge:void 0};const E=(0,o.default)(d)`
  ${v.Z}
`,a=p},"0dOiGFEa":(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("aKyEWaw1"),c=e("jtomkfYT");const v=(0,r.default)(n.Panel.Heading)`
  .panel-title {
    > a {
      display: block;
    }
  }
`,d=(0,r.default)(n.Panel.Footer)(({theme:y})=>(0,r.css)`
  background-color: ${y.colors.gray[90]};
  border-top-color: ${y.colors.gray[80]};
`),g=(0,r.css)(({bsStyle:y="default",theme:T})=>{const P=T.colors.variant.lighter[y],O=T.colors.variant.dark[y];return(0,r.css)`
    border-color: ${O};

    > ${v} {
      color: ${T.utils.readableColor(P)};
      background-color: ${P};
      border-color: ${O};

      + .panel-collapse > .panel-body {
        border-top-color: ${O};
      }

      .badge {
        color: ${P};
        background-color: ${T.colors.variant[y]};
      }
    }

    > ${d} {
      + .panel-collapse > .panel-body {
        border-bottom-color: ${O};
      }
    }
`}),p=(0,r.default)(n.Panel)(({theme:y})=>(0,r.css)`
  background-color: ${y.utils.colorLevel(y.colors.global.background,-4)};

  > ${v} {
    .panel-title,
    .panel-title h3 {
      font-size: ${y.fonts.size.large};
    }
  }

  .panel-group {
    > ${v} {
      + .panel-collapse > .panel-body,
      + .panel-collapse > .list-group {
        border-top-color: ${y.colors.gray[90]};
      }
    }

    > ${d} {
      + .panel-collapse .panel-body {
        border-bottom-color: ${y.colors.gray[90]};
      }
    }
  }

  ${g}
`),E=(0,r.css)(({bsStyle:y="default",theme:T})=>{const P=T.colors.variant.lightest[y],O=T.colors.variant.light[y];return(0,r.css)`
    /** NOTE: Deprecated & should be removed in 4.0 */
    border-color: ${O};
    background: ${T.colors.table.background};

    & > .panel-heading {
      color: ${T.utils.contrastingColor(P)};
      background-color: ${P};
      border-color: ${O};

      > .panel-title,
      > .panel-title > * {
        font-size: ${T.fonts.size.large};
      }

      + .panel-collapse > .panel-body {
        border-top-color: ${O};
      }

      .badge {
        color: ${P};
        background-color: ${T.colors.variant[y]};
      }
    }

    & > .panel-footer {
      + .panel-collapse > .panel-body {
        border-bottom-color: ${O};
      }
    }
`}),a=(0,r.default)(n.Panel)(({theme:y})=>(0,r.css)`
  /** NOTE: Deprecated & should be removed in 4.0 */
  background-color: ${y.utils.colorLevel(y.colors.global.background,-4)};

  .panel-footer {
    background-color: ${y.colors.gray[90]};
    border-top-color: ${y.colors.gray[80]};
  }

  .panel-group {
    .panel-heading {
      + .panel-collapse > .panel-body,
      + .panel-collapse > .list-group {
        border-top-color: ${y.colors.gray[90]};
      }
    }

    .panel-footer {
      + .panel-collapse .panel-body {
        border-bottom-color: ${y.colors.gray[90]};
      }
    }
  }

  ${E}
`),u=({title:y,children:T,collapsible:P,defaultExpanded:O,expanded:b,footer:L,header:x,onToggle:W,...N})=>{const[Z,j]=(0,t.useState)(null),z=(0,t.useRef)(!1);(0,t.useEffect)(()=>{j(ae=>O&&b||!O&&b||O&&ae===b)},[b,O]),(0,t.useEffect)(()=>{z.current=!0},[]);const ne=ae=>{j(ae),W(ae)},Y=typeof T=="string"||Array.isArray(T)&&typeof T[0]=="string";return x||L||y||P||Y?(z.current||(0,c.Z)("You have used a deprecated `Panel` prop, please check the documentation to use the latest `Panel`."),t.createElement(a,{expanded:Z,onToggle:ne,...N},(x||y)&&t.createElement(v,null,x,y&&t.createElement(n.Panel.Title,{toggle:P},y)),t.createElement(a.Body,{collapsible:P},T),L&&t.createElement(a.Footer,null,L))):t.createElement(p,{expanded:Z,onToggle:ne,defaultExpanded:O,...N},T)};u.propTypes={children:o().any.isRequired,collapsible:o().bool,defaultExpanded:o().bool,expanded:o().bool,onToggle:o().func,footer:o().string,header:o().oneOfType([o().string,o().node]),title:o().string},u.defaultProps={collapsible:!1,defaultExpanded:null,expanded:null,footer:void 0,header:void 0,onToggle:()=>{},title:void 0},u.Body=n.Panel.Body,u.Collapse=n.Panel.Collapse,u.Footer=d,u.Heading=v,u.Title=n.Panel.Title,u.Toggle=n.Panel.Toggle;const f=u},liHGlRT1:(M,C,e)=>{"use strict";e.d(C,{M:()=>o,Z:()=>n});var t=e("aKyEWaw1"),s=e("J6y4/h8P");const o=(0,s.css)(({theme:c})=>(0,s.css)`
  background-color: ${c.colors.global.contentBackground};
  border: 1px solid ${c.colors.variant.lighter.default};
  margin-bottom: ${c.spacings.xs};
  border-radius: 4px;
`),n=(0,s.default)(t.Row)`
  &.content {
    ${o}
  }
`},R4k1Ilh4:(M,C,e)=>{"use strict";e.d(C,{K:()=>r,Z:()=>c});var t=e("aKyEWaw1"),s=e("J6y4/h8P");const o=(0,s.css)(({theme:v})=>{const{table:d}=v.colors;let g="";const p={active:{background:d.variant.active,hover:d.variantHover.active},success:{background:d.variant.success,hover:d.variantHover.success},info:{background:d.variant.info,hover:d.variantHover.info},warning:{background:d.variant.warning,hover:d.variantHover.warning},danger:{background:d.variant.danger,hover:d.variantHover.danger}};return Object.keys(p).forEach(E=>{const{background:a,hover:u}=p[E];g+=`
      &.table > thead > tr,
      &.table > tfoot > tr,
      &.table > tbody > tr {
        > td.${E},
        > th.${E},
        &.${E} > td,
        &.${E} > th {
          background-color: ${a};
        }
      }

      &.table-hover > tbody > tr {
        > td.${E}:hover,
        > th.${E}:hover,
        &.${E}:hover > td,
        &:hover > .${E},
        &.${E}:hover > th {
          background-color: ${u};
        }
      }
    `}),(0,s.css)`
    ${g}
`}),r=(0,s.css)(({theme:v})=>(0,s.css)`
  &.table {
    > thead > tr,
    > tbody > tr,
    > tfoot > tr {
      > th,
      > td {
        border-top-color: ${v.colors.gray[80]};
      }
    }

    > thead > tr > th {
      white-space: nowrap;
      border-bottom-color: ${v.colors.table.backgroundAlt};
    }

    > tbody > tr {
      background-color: ${v.colors.table.background};
      transition: background-color 150ms ease-in-out;
    }

    > tbody + tbody {
      border-top-color: ${v.colors.gray[80]};
    }

    .table {
      background-color: ${v.colors.table.background};
    }
  }

  &.table-bordered {
    border-color: ${v.colors.gray[80]};

    > thead > tr,
    > tfoot > tr,
    > tbody > tr {
      > td,
      > th {
        border-color: ${v.colors.gray[80]};
      }
    }
  }

  &.table-striped > tbody > tr:nth-of-type(odd) {
    background-color: ${v.colors.table.backgroundAlt};
  }

  &.table-hover > tbody > tr:hover {
    background-color: ${v.colors.table.backgroundHover};
  }

  ${o}
  
  @media print {
    &.table > thead > tr > th {
      white-space: break-spaces;
      word-break: break-all;
    }
  }
`),c=(0,s.default)(t.Table)`
  ${r}
`},"Fg5/d7Qn":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("aKyEWaw1"),s=e("J6y4/h8P");const r=(0,s.default)(t.Well)(({theme:n})=>(0,s.css)`
  background-color: ${n.colors.variant.lightest.default};
  border-color: ${n.colors.variant.light.default};
  color: ${n.colors.variant.darker.default};
`)},"3dj8OEcA":(M,C,e)=>{"use strict";e.d(C,{JX:()=>t.Col,Lt:()=>t.Dropdown,O7:()=>t.Clearfix,XZ:()=>t.Checkbox,Y8:()=>t.Radio,eh:()=>t.PanelGroup,hE:()=>t.ButtonGroup,rj:()=>t.Grid});var t=e("aKyEWaw1")},"uZqmR+ju":(M,C,e)=>{"use strict";e.d(C,{Alert:()=>t.Z,Badge:()=>s.Z,BootstrapModalConfirm:()=>o.Z,BootstrapModalForm:()=>r.Z,BootstrapModalWrapper:()=>n.Z,Button:()=>c.Z,ButtonGroup:()=>Bn.hE,ButtonToolbar:()=>v.Z,Checkbox:()=>Bn.XZ,Clearfix:()=>Bn.O7,Col:()=>Bn.JX,ControlLabel:()=>d.Z,Dropdown:()=>Bn.Lt,DropdownButton:()=>u,FormControl:()=>f.Z,FormGroup:()=>y.Z,Grid:()=>Bn.rj,HelpBlock:()=>P,Input:()=>O.Z,InputGroup:()=>b.Z,InputWrapper:()=>L.Z,Jumbotron:()=>Z,KeyboardKey:()=>ne,Label:()=>ue,ListGroup:()=>ut,ListGroupItem:()=>me,MenuItem:()=>re.Z,Modal:()=>ce.Z,Nav:()=>ge,NavDropdown:()=>fe.Z,NavItem:()=>nt,Navbar:()=>$e,Panel:()=>Ot.Z,PanelGroup:()=>Bn.eh,Popover:()=>Tt,Radio:()=>Bn.Y8,Row:()=>Lt.Z,Tab:()=>Rt,Table:()=>zt.Z,Tabs:()=>nn,Tooltip:()=>On,Well:()=>rt.Z});var t=e("kwpLVeht"),s=e("sUEzN8pX"),o=e("PVMUg5WH"),r=e("gTexEe+8"),n=e("gqVHlIxA"),c=e("utbMO9sg"),v=e("CrIFpfDF"),d=e("Ru9ofG0m"),g=e("aKyEWaw1"),p=e("J6y4/h8P"),E=e("hcoMM3Vl");const u=(0,p.default)(g.DropdownButton)(({theme:de})=>(0,p.css)`
  ${de.components.button}
  & ~ {
    ${E.Z}
  }
`);var f=e("HB0tOxLI"),y=e("nV9jqFLy");const P=(0,p.default)(g.HelpBlock)(({theme:de})=>(0,p.css)`
  display: block;
  margin-top: 5px;
  margin-bottom: 10px;
  color: ${de.colors.gray[50]};
`);var O=e("yDuYCNwc"),b=e("f5/t4s9T"),L=e("8tm/+anU"),x=e("Z7aTuO5B");const W=(0,p.default)(g.Jumbotron)(({theme:de})=>(0,p.css)`
  color: ${de.colors.global.textDefault};
  background-color: ${de.colors.global.contentBackground};
  
  h2 {
    font-weight: bold;
  }

  p {
    margin-bottom: 9px;
    font-size: 20px;
    font-weight: normal;
  }
`),Z=(0,x.forwardRef)((de,pt)=>x.createElement(W,{ref:pt,...de}));var j=e("U7y/BNwM");const ne=({children:de})=>x.createElement(j.Kbd,null,de),Y=(de,pt)=>{if(!pt)return"";const Gt=de.colors.variant[pt],gn=de.utils.contrastingColor(Gt);return(0,p.css)`
    background-color: ${Gt};
    color: ${gn};
`},ae=(0,p.default)(g.Label)(({bsStyle:de,theme:pt})=>(0,p.css)`
  ${Y(pt,de)}
  padding: 0.3em 0.6em;
`),ue=(0,x.forwardRef)(({...de},pt)=>x.createElement(ae,{ref:pt,...de}));var H=e("ii0bleBb"),ye=e.n(H);const we=({className:de,...pt})=>x.createElement(g.ListGroup,{bsClass:de,...pt});we.propTypes={className:ye().string},we.defaultProps={className:void 0};const ut=we,ht=p.default.span(({theme:de})=>`
  display: block;
  border: 1px solid ${de.colors.variant.lighter.default};
  margin-bottom: -1px;

  &:first-child {
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
  }

  &:last-child {
    margin-bottom: 0;
    border-bottom-right-radius: 4px;
    border-bottom-left-radius: 4px;
  }
`),Je=(0,p.css)(({bsStyle:de,theme:pt})=>{if(!de)return;const Gt=pt.colors.variant.lighter[de],gn=pt.utils.readableColor(Gt);return(0,p.css)`
    &.list-group-item-${de} {
      color: ${gn};
      background-color: ${Gt};

      a&,
      button& {
        color: ${gn};

        .list-group-item-heading {
          color: inherit;
          font-weight: bold;
        }

        &:hover,
        &:focus {
          color: ${gn};
          background-color: ${pt.colors.variant.light[de]};
        }

        &.active,
        &.active:hover,
        &.active:focus {
          color: ${pt.utils.readableColor(pt.colors.variant.light[de])};
          background-color: ${pt.colors.variant.light[de]};
          border-color: ${pt.colors.variant.light[de]};
        }
      }
    }
`}),Re=(0,p.default)(g.ListGroupItem)(({theme:de})=>(0,p.css)`
  background-color: ${de.colors.global.contentBackground};
  border: 0;
  padding: 5px 10px;

  .list-group-item-heading {
    font-size: ${de.fonts.size.h5};
  }

  .list-group-item-text {
    margin-bottom: 5px;
  }

  a&,
  button& {
    color: ${de.colors.global.textDefault};

    .list-group-item-heading {
      color: ${de.colors.variant.darkest.default};
    }

    &:hover:not(.disabled),
    &:focus:not(.disabled) {
      background-color: ${de.colors.variant.lightest.default};

      &.active {
        color: ${de.colors.variant.darkest.default};
        background-color: ${de.colors.variant.lightest.default};
        border-color: ${de.colors.variant.lightest.default};
      }

      .list-group-item-heading {
        color: ${de.utils.readableColor(de.colors.variant.lightest.default)};
      }
    }
  }

  &.disabled,
  &.disabled:hover,
  &.disabled:focus {
    color: ${de.colors.variant.default};
    background-color: ${de.colors.variant.lightest.default};

    .list-group-item-heading {
      color: inherit;
    }

    .list-group-item-text {
      color: ${de.colors.variant.default};
    }
  }

  &.active,
  &.active:hover,
  &.active:focus {
    color: ${de.colors.variant.darker.default};
    background-color: ${de.colors.variant.lightest.info};
    border-color: ${de.colors.variant.lightest.info};
    z-index: auto;

    .list-group-item-heading,
    .list-group-item-heading > small,
    .list-group-item-heading > .small {
      color: inherit;
    }

    .list-group-item-text {
      color: ${de.colors.variant.light.primary};
    }
  }

  ${Je}
`),le=(0,x.forwardRef)(({containerProps:de,...pt},Gt)=>x.createElement(ht,{ref:Gt,...de},x.createElement(Re,{...pt})));le.propTypes={containerProps:ye().object},le.defaultProps={containerProps:{}};const me=le;var re=e("cB7h3AEX"),ce=e("coBi+lXG");const J=(0,p.css)(({theme:de})=>(0,p.css)`
  .nav-tabs {
    border-bottom-color: ${de.colors.variant.default};

    > li {
      > a {
        transition: background-color 150ms ease-in-out;
        color: ${de.colors.global.textDefault};
        border-color: ${de.colors.variant.lighter.default} ${de.colors.variant.lighter.default} ${de.colors.variant.default};

        &:hover {
          background-color: ${de.colors.variant.lightest.default};
          color: ${de.colors.global.textDefault};
        }
      }

      &.active > a {
        &,
        &:hover,
        &:focus {
          color: ${de.colors.variant.darkest.default};
          background-color: ${de.colors.global.contentBackground};
          border-color: ${de.colors.variant.default};
          border-bottom-color: transparent;
        }
      }

      &.disabled > a {
        &,
        &:hover,
        &:focus {
          color: ${de.colors.gray[60]};
          background-color: ${de.colors.gray[100]};
          border-color: ${de.colors.gray[100]} ${de.colors.gray[100]} ${de.colors.variant.default};
          cursor: not-allowed;
        }
      }
    }
  }

  &.nav-justified {
    > .active > a {
      &,
      &:hover,
      &:focus {
        border-color: ${de.colors.variant.default};
      }
    }

    @media (min-width: ${de.breakpoints.min.sm}) {
      > li > a {
        border-bottom-color: ${de.colors.variant.default};
      }

      > .active > a,
      > .active > a:hover,
      > .active > a:focus {
        border-bottom-color: ${de.colors.gray[100]};
      }
    }
  }
`),ge=(0,p.default)(g.Nav)(({theme:de})=>(0,p.css)`
  &.nav {
    > li {
      > a {
        transition: background-color 150ms ease-in-out;

        &:hover,
        &:focus {
          background-color: ${de.colors.variant.lightest.default};
        }
      }

      &.disabled > a {
        color: ${de.colors.variant.light.default};

        &:hover,
        &:focus {
          color: ${de.colors.variant.light.default};
        }
      }
    }

    .open > a {
      &,
      &:hover,
      &:focus {
        background-color: ${de.colors.variant.lightest.default};
        border-color: ${de.colors.variant.primary};
      }
    }

    &.nav-pills {
      > li {
        &.active > a {
          &,
          &:hover,
          &:focus {
            color: ${de.utils.contrastingColor(de.colors.global.link)};
            background-color: ${de.colors.global.link};
          }
        }
      }
    }
    
    &.nav-sm {
      > li > a {
        padding: 8px 12px;
        font-size: ${de.fonts.size.small};
      }
    };

    &.nav-xs {
      > li > a {
        padding: 2px 6px;
        font-size: ${de.fonts.size.small};
      }
    };

    &.nav-lg {
      > li > a {
        padding: 14px 18px;
        font-size: ${de.fonts.size.large};
      }
    };

    &${J} /* This is a known non-issue that stylelint won't ignore but will hopefully be patched soon https://github.com/stylelint/stylelint/issues/4574 */
  }
`);var fe=e("agK8h0L2"),Ce=e("NV1/EHMi");const Oe=({children:de,...pt})=>x.createElement(g.NavItem,{...pt},x.createElement(Ce.ZP,null,de));Oe.displayName="NavItem";const nt=Oe;var et=e("ww+BtWnX"),Fe=e.n(et);const $e=(0,p.default)(g.Navbar)(({theme:de})=>(0,p.css)`
  position: relative;
  min-height: auto;
  background-color: ${de.colors.global.navigationBackground};
  border: 0;
  box-shadow: 0 3px 3px ${de.colors.global.navigationBoxShadow};
  margin-bottom: 0;

  .navbar-text {
    color: ${de.colors.global.textDefault};
  }

  @media (max-width: ${de.breakpoints.max.md}) {
    && .navbar-collapse {
      position: absolute;
      background-color: ${de.colors.global.navigationBackground};
      width: 100%;
    }
  }

  .navbar-nav {
    > li > a,
    > li > .btn-link {
      color: ${de.colors.global.textDefault};

      &:hover,
      &:focus {
        color: ${de.colors.variant.darker.default};
        background-color: transparent;
      }
    }

    > .active > a,
    > .active > .btn-link {
      color: ${de.colors.global.textDefault};
      background-color: transparent;
      
      &:hover,
      &:focus {
        color: ${de.colors.variant.darkest.default};
        background-color: transparent;
      }
    }

    > .disabled > a,
    > .disabled > .btn-link {
      &,
      &:hover,
      &:focus {
        color: ${de.colors.gray[70]};
        background-color: transparent;
      }
    }

    > .open > a,
    > .open > .btn-link {
      &,
      &:hover,
      &:focus {
        color: ${de.colors.variant.darkest.default};
        background-color: transparent;
      }
    }

    @media (max-width: ${de.breakpoints.max.md}) {
      padding-left: 50px;

      > li > a,
      > li > .btn-link {
        &:hover,
        &:focus {
          color: ${de.colors.variant.darker.default};
          background-color: transparent;
        }
      }

      .open .dropdown-menu {
        > li > a,
        > li > .btn-link {
          color: ${de.colors.variant.darkest.default};

          &:hover,
          &:focus {
            color: ${de.colors.variant.darker.default};
            background-color: ${de.colors.variant.lightest.default};
          }
        }

        > .active > a,
        > .active > .btn-link {
          color: ${de.colors.variant.darkest.default};
          background-color: ${de.colors.gray[90]};
          
          &:hover,
          &:focus {
            color: ${de.colors.variant.darkest.default};
            background-color: ${de.colors.gray[80]};
          }
        }

        > .disabled > a,
        > .disabled > .btn-link {
          &,
          &:hover,
          &:focus {
            color: ${de.colors.gray[70]};
            background-color: transparent;
          }
        }
      }
    }
  }

  .navbar-toggle {
    background-color: ${de.colors.global.navigationBackground};
    border-color: ${de.colors.variant.dark.default};
    transition: background-color 150ms ease-in-out,
      border-color 150ms ease-in-out;
    position: relative;

    &:not(.collapsed) {
      .icon-bar:nth-last-child(1),
      .icon-bar:nth-last-child(3) {
        transition: transform 150ms ease-in 150ms,
          top 150ms ease-in 0s;
      }

      .icon-bar:nth-last-child(1) {
        transform: rotate(-45deg) translate(4px, -4px);
      }

      .icon-bar:nth-last-child(3) {
        transform: rotate(45deg) translate(4px, 4px);
      }

      .icon-bar:nth-last-child(2) {
        transition: opacity 0s ease 150ms;
        opacity: 0;
      }
    }

    .icon-bar {
      background-color: ${de.colors.variant.default};
      transition: background-color 150ms ease-in-out,
        transform 150ms ease-in 0s,
        opacity 300ms ease-in 0s;
      transform: rotate(0deg);
      position: relative;
      opacity: 1;
    }

    &:hover,
    &:focus,
    &:not(.collapsed) {
      background-color: ${de.colors.variant.lighter.default};
      border-color: ${de.colors.variant.default};
      
      .icon-bar {
        background-color: ${de.colors.variant.dark.default};
      }
    }
  }

  .navbar-collapse,
  .navbar-form {
    border-color: ${Fe()(de.colors.gray[90]).darken(.065)};
  }

  .navbar-link {
    color: ${de.colors.variant.default};

    &:hover {
      color: ${Fe()(de.colors.variant.default).darken(.25)};
    }
  }

  .btn-link {
    color: ${de.colors.variant.default};

    &:hover,
    &:focus {
      color: ${de.colors.variant.dark.default};
    }

    &[disabled],
    fieldset[disabled] & {
      &:hover,
      &:focus {
        color: ${de.colors.gray[80]};
      }
    }
  }

  .dropdown-header {
    margin-top: 4px;
    text-transform: uppercase;
    padding: 0 15px !important;
    font-weight: bold;
  }
`);var Ot=e("0dOiGFEa");const Tt=(0,p.default)(g.Popover)(({theme:de})=>{const pt=de.colors.variant.light.default,Gt=de.colors.variant.lightest.default,gn=de.colors.global.contentBackground;return(0,p.css)`
    background-color: ${gn};
    border-color: ${pt};
    padding: 0;

    .popover-title {
      background-color: ${Gt};
      border-color: ${pt};
      color: ${de.colors.variant.darkest.default};
    }

    &.top {
      > .arrow {
        border-top-color: ${pt};

        &::after {
          border-top-color: ${Gt};
        }
      }
    }

    &.right {
      > .arrow {
        border-right-color: ${pt};

        &::after {
          border-right-color: ${Gt};
          z-index: 1;
        }
      }
    }

    &.bottom {
      > .arrow {
        border-bottom-color: ${pt};

        &::after {
          border-bottom-color: ${Gt};
        }
      }
    }

    &.left {
      > .arrow {
        border-left-color: ${pt};

        &::after {
          border-left-color: ${Gt};
        }
      }
    }
`});var Lt=e("liHGlRT1");const Be=(0,p.default)(g.SplitButton)(({theme:de})=>(0,p.css)`
  ${de.components.button}
  ~ .btn.dropdown-toggle {
    ${de.components.button}
    & ~ {
      ${E.Z}
    }
  }
`),lt=null,Rt=(0,p.default)(g.Tab)(({theme:de})=>(0,p.css)`
  background-color: ${de.colors.global.contentBackground};
  border: 1px solid ${de.colors.variant.default};
  border-top: 0;
  border-radius: 0 0 4px 4px;
  padding: 9px;
`);var zt=e("R4k1Ilh4");const nn=(0,p.default)(g.Tabs)`
  ${J}
`,Vt=10,jn=(0,p.default)(g.Tooltip)(({theme:de})=>(0,p.css)`
  &.in {
    opacity: 1;
    filter: drop-shadow(0 0 3px ${de.colors.variant.lighter.default});
  }

  &.top {
    .tooltip-arrow {
      border-top-color: ${de.colors.global.contentBackground};
      border-width: ${Vt}px ${Vt}px 0;
      margin-left: -${Vt}px;
      bottom: -${Vt/2}px;
    }
  }
  
  &.right {
    .tooltip-arrow {
      border-right-color: ${de.colors.global.contentBackground};
      border-width: ${Vt}px ${Vt}px ${Vt}px 0;
      margin-top: -${Vt}px;
      left: -${Vt/2}px;
    }
  }

  &.bottom {
    .tooltip-arrow {
      border-bottom-color: ${de.colors.global.contentBackground};
      border-width: 0 ${Vt}px ${Vt}px;
      margin-left: -${Vt}px;
      top: -${Vt/2}px;
    }
  }
  
  &.left {
    .tooltip-arrow {
      border-left-color: ${de.colors.global.contentBackground};
      border-width: ${Vt}px 0 ${Vt}px ${Vt}px;
      margin-top: -${Vt}px;
      right: -${Vt/2}px;
    }
  }
  
  .tooltip-inner {
    color: ${de.colors.global.textDefault};
    background-color: ${de.colors.global.contentBackground};
    max-width: 300px;
    opacity: 1;

    .datapoint-info {
      text-align: left;

      .date {
        color: ${de.colors.variant.darkest.default};
      }
    }
  }
`),Mt=({children:de,className:pt,id:Gt,placement:gn,positionTop:Jt,positionLeft:An,arrowOffsetTop:xe,arrowOffsetLeft:Pn,show:sn})=>x.createElement(jn,{className:`${pt} ${sn?"in":""}`,id:Gt,placement:gn,positionTop:Jt,positionLeft:An,arrowOffsetTop:xe,arrowOffsetLeft:Pn},de);Mt.propTypes={className:ye().string,children:ye().node.isRequired,id:ye().oneOfType([ye().string,ye().number]).isRequired,placement:ye().oneOf(["top","right","bottom","left"]),positionTop:ye().oneOfType([ye().number,ye().string]),positionLeft:ye().oneOfType([ye().number,ye().string]),arrowOffsetTop:ye().oneOfType([ye().number,ye().string]),arrowOffsetLeft:ye().oneOfType([ye().number,ye().string]),show:ye().bool},Mt.defaultProps={className:"",placement:"right",positionTop:void 0,positionLeft:void 0,arrowOffsetTop:void 0,arrowOffsetLeft:void 0,show:!0};const On=Mt;var rt=e("Fg5/d7Qn"),Bn=e("3dj8OEcA")},hcoMM3Vl:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("J6y4/h8P");const o=(0,t.css)(({theme:r})=>(0,t.css)`
  .dropdown-menu {
    background-color: ${r.colors.global.contentBackground};
    box-shadow: 0 3px 3px ${r.colors.global.navigationBoxShadow};
    
    .dropdown-header {
      padding: 3px 10px;
    }
    
    > li > a {
      padding: 3px 10px;
      display: flex;
      color: ${r.colors.global.textDefault};

      &:hover,
      &:focus {
        color: ${r.colors.variant.darker.default};
        background-color: ${r.colors.variant.lightest.default};
      }
    }

    > .active > a {
      color: ${r.colors.variant.darker.default};
      background-color: ${r.colors.variant.lightest.default};

      &:hover,
      &:focus {
        color: ${r.colors.variant.darkest.default};
        background-color: ${r.colors.variant.lighter.default};
      }
    }

    > .disabled > a {
      color: ${r.colors.variant.dark.default};
      background-color: ${r.colors.variant.lightest.default};

      &:hover,
      &:focus {
        color: ${r.colors.variant.dark.default};
        background-color: ${r.colors.variant.lightest.default};
      }
    }
  }
`)},SLtHYqXc:(M,C,e)=>{"use strict";e.d(C,{Z:()=>a});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("V5KdrmCp"),n=e.n(r),c=e("ys/4WHo5"),v=e("uZqmR+ju"),d=Object.defineProperty,g=(u,f,y)=>f in u?d(u,f,{enumerable:!0,configurable:!0,writable:!0,value:y}):u[f]=y,p=(u,f,y)=>(g(u,typeof f!="symbol"?f+"":f,y),y);class E extends o.Component{constructor(f){super(f),p(this,"_onSuccess",y=>{const{onSuccess:T}=this.props;this.setState({tooltipMessage:"Copied!"}),T(y),y.clearSelection()}),p(this,"_onError",y=>{const T=y.action==="cut"?"K":"C";this.setState({tooltipMessage:o.createElement("span",null,"Press Ctrl+",T,"\u2009/\u2009\u2318",T," to ",y.action)})}),p(this,"_getFilteredProps",()=>{const{className:y,style:T,bsStyle:P,bsSize:O,disabled:b,buttonTitle:L}=this.props;return{className:y,style:T,bsStyle:P,bsSize:O,disabled:b,title:L}}),this.state={tooltipMessage:""}}componentDidMount(){const{container:f}=this.props,y={};f&&(y.container=f),this.clipboard=new(n())("[data-gl-clipboard-button]",y),this.clipboard.on("success",this._onSuccess),this.clipboard.on("error",this._onError)}componentWillUnmount(){this.clipboard&&this.clipboard.destroy()}render(){const{action:f,title:y,text:T,target:P}=this.props,{tooltipMessage:O}=this.state,b=this._getFilteredProps(),L=o.createElement(v.Tooltip,{id:"copy-button-tooltip",show:!0},O);return T?b["data-clipboard-text"]=T:b["data-clipboard-target"]=P,o.createElement(c.Z,{placement:"top",trigger:"click",overlay:L,rootClose:!0},o.createElement(v.Button,{"data-gl-clipboard-button":!0,"data-clipboard-action":f,...b},y))}}p(E,"propTypes",{title:s().oneOfType([s().node,s().string]).isRequired,action:s().oneOf(["copy","cut"]),text:s().string,target:s().string,onSuccess:s().func,className:s().string,style:s().object,bsStyle:s().string,bsSize:s().string,disabled:s().bool,buttonTitle:s().string,container:s().any}),p(E,"defaultProps",{action:"copy",disabled:!1,buttonTitle:void 0,container:void 0,text:void 0,target:void 0,className:void 0,style:void 0,bsStyle:void 0,bsSize:void 0,onSuccess:()=>{}});const a=E},"6nsVPoEI":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("KC5O6lbB");const n=({onChange:v,...d})=>{const g=(0,t.useCallback)((p,E)=>{v(p.hex,E)},[v]);return t.createElement(r.FJ,{...d,onChange:g})};n.propTypes={color:o().string,colors:o().array,height:o().number,width:o().number,onChange:o().func.isRequired},n.defaultProps={color:void 0,colors:void 0,height:310,width:250};const c=n},t7jeigEY:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("ii0bleBb"),s=e.n(t),o=e("yAXMqwrl"),r=e("Z7aTuO5B"),n=e("RCNj0OY4");const c=(g,p,E)=>p.pathname!==g.pathname?!window.confirm(E):!1,v=({question:g})=>{const p=(0,r.useCallback)(E=>n.Z.gl2DevMode()?null:(E.returnValue=g,g),[g]);return(0,r.useEffect)(()=>(window.addEventListener("beforeunload",p),()=>{window.removeEventListener("beforeunload",p)}),[p]),(0,o.unstable_useBlocker)(E=>!n.Z.gl2DevMode()&&c(E.currentLocation,E.nextLocation,g)),null};v.propTypes={question:s().string},v.defaultProps={question:"Are you sure?"};const d=v},iDUHYfT2:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("uRLsxEc6"),c=e.n(n),v=e("uZqmR+ju");const d=(0,r.default)(v.Row)(({theme:E})=>(0,r.css)`
  padding-bottom: 0;

  p {
    margin-top: 15px;
  }

  .actions-lg {
    float: right;
  }

  .actions-sm {
    padding-bottom: 15px;
  }

  .btn-lg {
    font-size: ${E.fonts.size.large};
  }
`),g=({children:E,className:a,...u})=>t.createElement(d,{className:c()("content-head",a),...u},E);g.propTypes={children:o().node.isRequired,className:o().string},g.defaultProps={className:void 0};const p=g},"9gxkERa8":(M,C,e)=>{"use strict";e.d(C,{Z:()=>a});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("uZqmR+ju"),n=e("J6y4/h8P");const c=(0,n.default)(r.ListGroupItem)(({theme:u})=>(0,n.css)`
  background-color: ${u.colors.variant.lightest.default};
  font-size: ${u.fonts.size.body};
  color: ${u.utils.contrastingColor(u.colors.variant.lightest.default)};
  padding: 0 15px;

  .form-group {
    margin: 0;
  }
`),v=n.default.div`
  padding: 10px 0;
  min-height: 40px;
`,d=({children:u})=>{const y=typeof u=="string"?(T=>t.createElement(v,null,T))(u):u;return t.createElement(c,null,y)};d.propTypes={children:o().node},d.defaultProps={children:""};const g=d;var p=e("9tOV9VDw");const E=({children:u})=>{let f;return u.length===0?f=t.createElement(p.Z,null,"No items to display"):f=u,t.createElement("div",null,t.createElement(r.ListGroup,null,f))};E.Header=g,E.Item=p.Z,E.propTypes={children:o().node.isRequired};const a=E},"9tOV9VDw":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("uZqmR+ju");const n=({className:v,children:d})=>t.createElement(r.ListGroupItem,{className:v},d);n.propTypes={children:o().node.isRequired,className:o().string},n.defaultProps={className:void 0};const c=n},"Zzc2+UR0":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("Z6NUVhuV");const c=r.default.div`
  .control-label {
    padding-top: 0;
  }
`,v=({children:g,displayKey:p,filterBy:E,filterKeys:a,filterSuggestions:u,id:f,label:y,onDataFiltered:T,rows:P})=>a.length!==0?t.createElement(c,{className:"row"},t.createElement("div",{className:"col-md-8"},t.createElement(n.Z,{id:`${f}-data-filter`,label:y,data:P,displayKey:p,filterBy:E,filterSuggestions:u,searchInKeys:a,onDataFiltered:T})),g&&t.createElement("div",{className:"col-md-4"},g)):null;v.propTypes={children:o().node,displayKey:o().string,filterBy:o().string,filterKeys:o().array,filterSuggestions:o().array,id:o().string.isRequired,label:o().string,onDataFiltered:o().func.isRequired,rows:o().array.isRequired},v.defaultProps={children:void 0,displayKey:void 0,filterBy:void 0,filterKeys:void 0,filterSuggestions:void 0,label:void 0};const d=v},"uoAlNf/n":(M,C,e)=>{"use strict";e.d(C,{Z:()=>W});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("+KM7MH1U"),n=e.n(r),c=e("J6y4/h8P"),v=e("R4k1Ilh4"),d=e("Zzc2+UR0"),g=Object.defineProperty,p=(N,Z,j)=>Z in N?g(N,Z,{enumerable:!0,configurable:!0,writable:!0,value:j}):N[Z]=j,E=(N,Z,j)=>(p(N,typeof Z!="symbol"?Z+"":Z,j),j);class a extends o.Component{render(){const{formatter:Z,element:j,index:z}=this.props;return Z(j,z)}}E(a,"propTypes",{element:s().any,formatter:s().func.isRequired,index:s().number}),E(a,"defaultProps",{element:void 0,index:void 0});const u=a;var f=e("G8YcST+s"),y=Object.defineProperty,T=(N,Z,j)=>Z in N?y(N,Z,{enumerable:!0,configurable:!0,writable:!0,value:j}):N[Z]=j,P=(N,Z,j)=>(T(N,typeof Z!="symbol"?Z+"":Z,j),j);const O=c.default.table`
  ${v.K}
`,b=({noDataText:N})=>typeof N=="string"?o.createElement(f.Z,null,N):N;class L extends o.Component{constructor(Z){super(Z),P(this,"getFormattedHeaders",()=>{let z=0;const{headerCellFormatter:ne,headers:Y}=this.props,ae=Y.map(ee=>{const ue=o.createElement(u,{key:`header-${z}`,element:ee,index:z,formatter:ne});return z+=1,ue});return o.createElement("tr",null,ae)}),P(this,"getFormattedDataRows",()=>{let z=0;const{sortByKey:ne,sortBy:Y,dataRowFormatter:ae,useNumericSort:ee}=this.props;let ue=this._getEffectiveRows();return ne?ue=ue.sort((ye,we)=>ye[ne].localeCompare(we[ne],void 0,{numeric:ee})):Y&&(ue=ue.sort((ye,we)=>Y(ye).localeCompare(Y(we),void 0,{numeric:ee}))),ue.map(ye=>{const we=o.createElement(u,{key:`row-${z}`,element:ye,index:z,formatter:ae});return z+=1,we})}),P(this,"filterDataRows",z=>{this.setState({filteredRows:z})}),P(this,"_getEffectiveRows",()=>{const{filteredRows:z}=this.state,{filterKeys:ne,rows:Y}=this.props;return ne.length===0?Y:z.filter(ae=>Y.some(ee=>n()(ee,ae)))});const{rows:j}=this.props;this.state={filteredRows:j}}render(){const{customFilter:Z,filterKeys:j,id:z,filterLabel:ne,filterBy:Y,displayKey:ae,filterSuggestions:ee,children:ue,noDataText:H,className:ye,rowClassName:we,useResponsiveTable:ut,rows:ht}=this.props,Je=this._getEffectiveRows();let Re;return ht.length===0?Re=o.createElement(b,{noDataText:H}):Je.length===0?Re=o.createElement("p",null,"Filter does not match any data."):Re=o.createElement(O,{className:`table ${ye!=null?ye:""}`},o.createElement("thead",null,this.getFormattedHeaders()),o.createElement("tbody",null,this.getFormattedDataRows())),o.createElement("div",null,Z||o.createElement(d.Z,{label:ne,rows:ht,id:z,displayKey:ae,filterBy:Y,filterSuggestions:ee,filterKeys:j,onDataFiltered:this.filterDataRows},ue),o.createElement("div",{className:`row ${we}`},o.createElement("div",{className:"col-md-12"},o.createElement("div",{id:z,className:`data-table ${ut?"table-responsive":""}`},Re))))}}P(L,"propTypes",{children:s().node,className:s().string,customFilter:s().node,rowClassName:s().string,displayKey:s().string,dataRowFormatter:s().func.isRequired,filterBy:s().string,filterLabel:s().string,filterKeys:s().array,filterSuggestions:s().array,headerCellFormatter:s().func,headers:s().array.isRequired,id:s().string.isRequired,noDataText:s().oneOfType([s().string,s().node]),rows:s().array.isRequired,sortByKey:s().string,sortBy:s().func,useResponsiveTable:s().bool,useNumericSort:s().bool}),P(L,"defaultProps",{customFilter:void 0,children:void 0,className:"",filterBy:"",filterSuggestions:[],filterKeys:[],filterLabel:"Filter",displayKey:"value",noDataText:"No data available.",rowClassName:"",useResponsiveTable:!0,headerCellFormatter:N=>o.createElement("th",null,N),sortByKey:void 0,sortBy:void 0,useNumericSort:!1});const W=L},rRqvmggl:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s);const r=({children:c,delay:v})=>{const[d,g]=(0,t.useState)(v<=0);return(0,t.useEffect)(()=>{if(v<=0)return()=>{};const p=window.setTimeout(()=>g(!0),v);return()=>clearTimeout(p)},[]),d?t.createElement(t.Fragment,null,c):null};r.propTypes={children:o().node.isRequired,delay:o().number.isRequired};const n=r},qQvt58D8:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s);const r=({children:c,title:v})=>{const d="Graylog";return(0,t.useEffect)(()=>(document.title=`${document.title} - ${v}`,()=>{document.title=d}),[v]),t.createElement(t.Fragment,null,c)};r.propTypes={title:o().string.isRequired,children:o().oneOfType([o().arrayOf(o().element),o().element]).isRequired};const n=r},IdpefXWm:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("a5C0HdYb");const o=({children:n,className:c,resizeDelay:v})=>{const d=(0,t.useRef)(null),g=(0,s.Z)(d,v);return t.createElement("div",{ref:d,className:c},n(g))};o.defaultProps={className:void 0,resizeDelay:void 0};const r=o},Z2BtcgLJ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("cB7h3AEX"),o=e("uZqmR+ju");const n=({selectedEntities:c,setSelectedEntities:v,children:d})=>{const g=(0,t.useCallback)(()=>v([]),[v]);return t.createElement(o.DropdownButton,{bsSize:"small",title:"Bulk actions",id:"bulk-actions-dropdown",disabled:!(c!=null&&c.length)},d,!!t.Children.count(d)&&t.createElement(s.Z,{divider:!0}),t.createElement(s.Z,{onClick:g},"Cancel selection"))}},HhRuy6uH:(M,C,e)=>{"use strict";e.d(C,{TB:()=>o,V:()=>c,ne:()=>r,pK:()=>t,z3:()=>s,zN:()=>n});const t=5,s=20,o=150,r=1,n="More",c="More actions"},"Nm+SUS6U":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.ExpandedSectionsContext",()=>o)},Dg3D5NJi:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("Diig6WAv");const r=({entityTableId:n,defaultSort:c,defaultPageSize:v,defaultDisplayedAttributes:d})=>{const{data:g={},isInitialLoading:p}=(0,s.Z)(n);return(0,t.useMemo)(()=>{var E,a,u;return{layoutConfig:{pageSize:(E=g.perPage)!=null?E:v,sort:(a=g.sort)!=null?a:c,displayedAttributes:(u=g==null?void 0:g.displayedAttributes)!=null?u:d},isInitialLoading:p}},[d,v,c,p,g==null?void 0:g.displayedAttributes,g.perPage,g.sort])}},qO9czYNI:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("DUKaTDO2"),s=e("eFxcQyPT"),o=e("MdYBRjRJ"),r=e("jAGDuYSC"),n=e("Diig6WAv");const c=({displayedAttributes:g,sort:p,perPage:E})=>({displayed_attributes:g,sort:p?{order:p.direction,field:p.attributeId}:void 0,per_page:E}),d=g=>{const p=(0,t.useQueryClient)(),{data:E={}}=(0,n.Z)(g),a=f=>(0,s.ZP)("POST",(0,o.DC)(`/entitylists/preferences/${g}`),c({...E,...f})),{mutate:u}=(0,t.useMutation)({mutationFn:a,onError:f=>{r.Z.error(`Updating table layout preferences failed with error: ${f}`)},onMutate:f=>{p.setQueriesData(["table-layout",g],y=>({...y!=null?y:{},...f}))}});return{mutate:u}}},Diig6WAv:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("DUKaTDO2"),s=e("eFxcQyPT"),o=e("MdYBRjRJ"),r=e("jAGDuYSC");const n={},c=({displayed_attributes:p,sort:E,per_page:a})=>({displayedAttributes:p,sort:E?{attributeId:E.field,direction:E.order}:void 0,perPage:a}),v=p=>(0,s.ZP)("GET",(0,o.DC)(`/entitylists/preferences/${p}`)).then(E=>c(E!=null?E:{})),g=p=>{const{data:E,isInitialLoading:a}=(0,t.useQuery)(["table-layout",p],()=>v(p),{onError:u=>{r.Z.error(`Loading layout preferences for "${p}" overview failed with ${u}`)},keepPreviousData:!0,staleTime:36e5});return{data:E!=null?E:n,isInitialLoading:a}}},fkNiwXiR:(M,C,e)=>{"use strict";e.d(C,{Z:()=>Zt});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("wXrUUKFq"),r=e.n(o),n=e("uZqmR+ju"),c=e("0TVxnHwi"),v=e("q2j1bVbz"),d=e("M04itGxI"),g=e("4E3oowBb"),p=e("cB7h3AEX");const E=(0,s.default)(n.DropdownButton)`
  ~ .dropdown-menu {
    min-width: auto;
    max-width: 180px;
  }
`,a=(0,s.default)(n.Checkbox)`
  &.checkbox {
    margin: 0 5px 0 0;

    label {
      display: flex;
      align-items: center;
      padding: 0;

      input {
        margin: 0;
        position: relative;
      }
    }
  }
`,u=(0,s.default)(p.Z)`
  padding: 3px 0;
  cursor: pointer;
  display: flex;
`,f=(0,s.default)(d.Z)`
  display: inline;
`,y=({allColumns:Me,column:Ye,onClick:Ke,selectedColumns:dt})=>{const it=dt.includes(Ye.id),gt=()=>{const It=Me.reduce((ot,yt)=>{const Xt=Ye.id===yt.id;return Xt&&!it||!Xt&&dt.includes(yt.id)?[...ot,yt.id]:ot},[]);Ke(It)};return t.createElement(u,{onSelect:gt,title:`${it?"Hide":"Show"} ${Ye.title}`},t.createElement(a,{checked:it,onChange:gt}),t.createElement(f,null,Ye.title))},P=({onChange:Me,selectedColumns:Ye,allColumns:Ke})=>{const dt=(0,t.useMemo)(()=>Ke.sort((it,gt)=>(0,g.S)(it.title,gt.title)),[Ke]);return t.createElement(E,{title:"Columns",bsSize:"small",pullRight:!0,"aria-label":"Configure visible columns",id:"columns-visibility-select",bsStyle:"default"},dt.map(it=>t.createElement(y,{column:it,onClick:Me,key:it.id,allColumns:Ke,selectedColumns:Ye})))};var O=e("/GOzvPf6");const L={types:{DATE:{renderCell:Me=>t.createElement(O.EK,{dateTime:Me}),staticWidth:160},STRING:{renderCell:Me=>t.createElement(d.Z,null,Me)}},attributes:{description:{width:2},summary:{width:1.5},owner:{staticWidth:120},favorite:{renderHeader:()=>"",staticWidth:30}}};var x=e("HhRuy6uH");const W=({tableWidth:Me,actionsColWidth:Ye,bulkSelectColWidth:Ke,columnsIds:dt,columnRenderersByAttribute:it})=>{const gt=dt.reduce((It,ot)=>{var yt,Xt;return It+((Xt=(yt=it[ot])==null?void 0:yt.staticWidth)!=null?Xt:0)},0);return Me-Ke-Ye-gt},N=({assignableWidth:Me,columnsIds:Ye,columnRenderersByAttribute:Ke})=>{const dt=Ye.reduce((gt,It)=>{var ot;const{staticWidth:yt,width:Xt=x.ne}=(ot=Ke[It])!=null?ot:{};return yt?gt:gt+Xt},0),it=Me/dt;return Object.fromEntries(Ye.map(gt=>{var It;const{staticWidth:ot,width:yt=x.ne,minWidth:Xt=x.TB}=(It=Ke[gt])!=null?It:{},rn=ot!=null?ot:it*yt;return[gt,!ot&&rn{const[gt,It]=(0,t.useState)({});return(0,t.useLayoutEffect)(()=>{if(!it)return;const ot=W({actionsColWidth:Me,columnRenderersByAttribute:Ke,columnsIds:dt,bulkSelectColWidth:Ye,tableWidth:it});It(N({assignableWidth:ot,columnsIds:dt,columnRenderersByAttribute:Ke}))},[Me,Ye,Ke,dt,it]),gt};var z=e("a5C0HdYb"),ne=e("Ofda/4py"),Y=e("Nm+SUS6U");const ae=s.default.tr(({theme:Me})=>(0,s.css)`
  &&&& {
    background-color: ${Me.colors.global.contentBackground};
  }
`),ee=s.default.div`
  display: flex;
  justify-content: space-between;
  margin-bottom: 5px;
`,ue=(0,s.default)(n.ButtonToolbar)`
  display: flex;
  align-items: center;
`,H=(0,s.default)(ne.Z)`
  margin-left: 5px;
`,we=({expandedSectionsRenderer:Me,entity:Ye})=>{const{expandedSections:Ke,toggleSection:dt}=(0,t.useContext)(Y.Z),it=Ke==null?void 0:Ke[Ye.id];return it!=null&&it.length?t.createElement(ae,null,t.createElement("td",{colSpan:1e3},Object.entries(Me!=null?Me:{}).map(([gt,It])=>{var ot;if(!it.includes(gt))return null;const yt=()=>dt(Ye.id,gt),Xt=(ot=It.actions)==null?void 0:ot.call(It,Ye);return t.createElement("div",{key:`${gt}-${Ye.id}`},t.createElement(ee,null,t.createElement("h3",null,It.title),t.createElement(ue,null,Xt,t.createElement(H,{name:"times",onClick:yt,title:"Hide section"}))),It.content(Ye))}))):null};var ut=e("87D/Fijl"),ht=e.n(ut);const Re=(Me,Ye)=>{const[Ke,dt]=(0,t.useState)(Me||[]),it=(0,t.useCallback)(gt=>{const It=ht()(gt)?gt(Ke):gt;dt(It),Ye&&Ye(It)},[Ye,Ke]);return[Ke,it]};var le=e("TJOheZRu");const me=s.default.div`
  display: flex;
  align-items: center;
`,re=s.default.div`
  margin-left: 5px;
`,Q=({selectedEntities:Me,setSelectedEntities:Ye,bulkActions:Ke})=>t.createElement(me,null,Ke(Me,Ye),!!Me.length&&t.createElement(re,null,Me.length," ",le.Z.pluralize(Me.length,"item","items")," selected"));var J=e("yKXoRDZT");const ie=(0,s.default)(J.Z)`
  display: inline-block;
  margin-left: 6px;
  padding: 0;
  cursor: pointer;
`,ge={ASC:"asc",DESC:"desc"},fe={asc:"ascending",desc:"descending"},Oe=({onChange:Me,activeSort:Ye,column:Ke})=>{const dt=(Ye==null?void 0:Ye.attributeId)===Ke.id,it=!dt||Ye.direction===ge.DESC?ge.ASC:ge.DESC,gt=`Sort ${Ke.title.toLowerCase()} ${fe[it]}`,It=()=>{Me({attributeId:Ke.id,direction:it})};return t.createElement(ie,{activeDirection:dt?Ye.direction:void 0,onChange:It,title:gt,ascId:ge.ASC,descId:ge.DESC})};var nt=e("efAt+LzL"),et=e.n(nt);const Pe=(0,s.default)(n.Checkbox)`
  &.checkbox {
    margin: 0;
  
    label {
      display: flex;
      align-items: center;
      padding: 0;
      
      input {
        width: 14px;
        height: 14px;
        cursor: pointer;
        margin: 0;
        position: relative;
      }
    }
  }
`,$e=(Me,Ye)=>{const Ke=(0,t.useRef)(),dt=(0,t.useMemo)(()=>{const it=Me.filter(({id:gt})=>Ye.includes(gt));return it.length===0?"UNCHECKED":it.length===Me.length?"CHECKED":"PARTIAL"},[Me,Ye]);return(0,t.useEffect)(()=>{if(Ke.current){if(dt==="PARTIAL"){Ke.current.indeterminate=!0;return}Ke.current.indeterminate=!1}},[dt]),{checkboxRef:Ke,checkboxStatus:dt}},ft=({data:Me,setSelectedEntities:Ye,selectedEntities:Ke})=>{const{checkboxRef:dt,checkboxStatus:it}=$e(Me,Ke),gt=`${it==="CHECKED"?"Deselect":"Select"} all visible entities`,It=()=>{Ye(ot=>{const yt=Me.map(({id:Xt})=>Xt);return it==="CHECKED"?ot.filter(Xt=>!yt.includes(Xt)):et()([...ot,...yt])})};return t.createElement("td",{style:{width:`${x.z3}px`}},t.createElement(Pe,{inputRef:ot=>{dt.current=ot},onChange:It,checked:it==="CHECKED",title:gt,disabled:!(Me!=null&&Me.length)}))},Tt=s.default.th(({$width:Me})=>(0,s.css)`
  width: ${Me?`${Me}px`:"auto"};
`),Lt=({activeSort:Me,column:Ye,columnRenderer:Ke,onSortChange:dt,colWidth:it})=>{const gt=(0,t.useMemo)(()=>typeof(Ke==null?void 0:Ke.renderHeader)=="function"?Ke.renderHeader(Ye):Ye.title,[Ye,Ke]);return t.createElement(Tt,{$width:it},gt,Ye.sortable&&t.createElement(Oe,{onChange:dt,column:Ye,activeSort:Me}))},Be=s.default.th(({$width:Me})=>(0,s.css)`
  text-align: right;
  width: ${Me?`${Me}px`:"auto"};
`),mt=({actionsColWidth:Me,activeSort:Ye,columns:Ke,columnsOrder:dt,columnRenderersByAttribute:it,columnsWidths:gt,data:It,displayActionsCol:ot,displayBulkSelectCol:yt,onSortChange:Xt,selectedEntities:rn,setSelectedEntities:Cn})=>{const bn=(0,t.useMemo)(()=>Ke.sort((hn,ao)=>dt.indexOf(hn.id)-dt.indexOf(ao.id)),[Ke,dt]);return t.createElement("thead",null,t.createElement("tr",null,yt&&t.createElement(ft,{data:It,selectedEntities:rn,setSelectedEntities:Cn}),bn.map(hn=>{const ao=it[hn.id];return t.createElement(Lt,{columnRenderer:ao,column:hn,colWidth:gt[hn.id],onSortChange:Xt,activeSort:Ye,key:hn.title})}),ot?t.createElement(Be,{$width:Me},"Actions"):null))};var Rt=e("CrIFpfDF"),zt=e("WoBpjwwo"),xt=e.n(zt);const nn=s.default.td`
  word-break: break-word;
`,jn=({column:Me,columnRenderer:Ye,entity:Ke,entityAttributesAreCamelCase:dt})=>{const it=dt?xt()(Me.id):Me.id,gt=Ke[it],It=typeof(Ye==null?void 0:Ye.renderCell)=="function"?Ye.renderCell(gt,Ke,Me):gt;return t.createElement(nn,null,It)},Mt=s.default.th`
  text-align: right;

  .btn-toolbar {
    display: inline-flex;
  }
`,On=s.default.div`
  display: inline-flex;
`,rt=({columns:Me,columnRenderersByAttribute:Ye,displaySelect:Ke,displayActions:dt,entity:it,isSelected:gt,onToggleEntitySelect:It,rowActions:ot,index:yt,actionsRef:Xt,entityAttributesAreCamelCase:rn})=>{const Cn=(0,t.useCallback)(()=>It(it.id),[it.id,It]),bn=dt?t.createElement(Rt.Z,null,ot(it)):null;return t.createElement("tr",null,Ke&&t.createElement("td",null,t.createElement(Pe,{onChange:Cn,title:`${gt?"Deselect":"Select"} entity`,checked:gt})),Me.map(hn=>{const ao=Ye[hn.id];return t.createElement(jn,{columnRenderer:ao,entityAttributesAreCamelCase:rn,entity:it,column:hn,key:`${it.id}-${hn.id}`})}),dt?t.createElement(Mt,null,yt===0?t.createElement(On,{ref:Xt},bn):bn):null)};rt.defaultProps={rowActions:void 0};const Bn=t.memo(rt);var de=e("ii0bleBb"),pt=e.n(de);const Gt=({children:Me})=>{const[Ye,Ke]=(0,t.useState)(),dt=(0,t.useCallback)((gt,It)=>Ke(ot=>{var yt,Xt;const rn={...ot!=null?ot:{}};if((yt=rn[gt])!=null&&yt.includes(It)){const Cn=rn[gt].filter(bn=>bn!==It);return Cn.length===0?(delete rn[gt],rn):{...rn,[gt]:Cn}}return{...rn,[gt]:[...(Xt=rn[gt])!=null?Xt:[],It]}}),[]),it=(0,t.useMemo)(()=>({expandedSections:Ye,toggleSection:dt}),[Ye,dt]);return t.createElement(Y.Z.Provider,{value:it},Me)};Gt.propTypes={children:pt().node.isRequired};const gn=Gt,Jt=s.default.div`
  width: 100%;
  overflow-x: auto;
`,An=(0,s.default)(n.Table)(({theme:Me})=>(0,s.css)`
  table-layout: fixed;

  thead > tr > th,
  tbody > tr > td {
    padding: ${x.pK}px;
  }

  && {
    > tbody:nth-of-type(even) > tr {
      background-color: ${Me.colors.table.background};
    }

    > tbody:nth-of-type(odd) > tr {
      background-color: ${Me.colors.table.backgroundAlt};
    }
  }
`),xe=s.default.div`
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  min-height: 22px;
`,Pn=s.default.div`
  display: flex;
  align-items: center;
  gap: 5px;
`,sn=(Me,Ye)=>Me.filter(({permissions:Ke,anyPermissions:dt,hidden:it})=>it?!1:Ke!=null&&Ke.length?dt?(0,c.Tv)(Ye,Ke):(0,c.rq)(Ye,Ke):!0),no=(Me,Ye)=>Ye.map(Ke=>Me.find(({id:dt})=>dt===Ke)).filter(Ke=>!!Ke),Co=({columns:Me,columnRenderersByAttribute:Ye,displayBulkSelectCol:Ke,fixedActionsCellWidth:dt})=>{var it,gt;const It=(0,t.useRef)(),ot=(0,t.useRef)(),{width:yt}=(0,z.Z)(It),Xt=(0,t.useMemo)(()=>Me.map(({id:hn})=>hn),[Me]),rn=dt!=null?dt:(gt=(it=ot.current)==null?void 0:it.offsetWidth)!=null?gt:0,Cn=rn?rn+x.pK*2:0,bn=j({actionsColWidth:Cn,bulkSelectColWidth:Ke?x.z3:0,columnRenderersByAttribute:Ye,columnsIds:Xt,tableWidth:yt});return{tableRef:It,actionsRef:ot,columnsWidths:bn,actionsColWidth:Cn}},Go=(Me,Ye)=>{const Ke=r()({},L,Ye);return Object.fromEntries(Me.map(({id:it,type:gt})=>{var It,ot;const yt=(It=Ke.types)==null?void 0:It[gt],Xt=(ot=Ke.attributes)==null?void 0:ot[it],rn=r()({},yt,Xt);return[it,rn]}))},Mo=({actionsCellWidth:Me,activeSort:Ye,entityAttributesAreCamelCase:Ke,bulkSelection:{actions:dt,onChangeSelection:it,initialSelection:gt},columnDefinitions:It,columnRenderers:ot,columnsOrder:yt,data:Xt,expandedSectionsRenderer:rn,onColumnsChange:Cn,onPageSizeChange:bn,onSortChange:hn,pageSize:ao,rowActions:Xn,visibleColumns:vo})=>{const Kn=(0,v.Z)(),[Jn,Wn]=Re(gt,it),bo=typeof Xn=="function",ds=typeof dt=="function",zo=typeof it=="function"||typeof dt=="function",Xo=typeof bn=="function",Do=(0,t.useMemo)(()=>sn(It,Kn.permissions),[It,Kn.permissions]),Jo=(0,t.useMemo)(()=>no(Do,vo),[Do,vo]),Zo=(0,t.useMemo)(()=>Go(Jo,ot),[Jo,ot]),{tableRef:yo,actionsRef:Vo,actionsColWidth:_s,columnsWidths:Cs}=Co({columns:Jo,columnRenderersByAttribute:Zo,displayBulkSelectCol:zo,fixedActionsCellWidth:Me}),ms=(0,t.useCallback)(Yn=>{Wn(xo=>xo.includes(Yn)?xo.filter(Ls=>Ls!==Yn):[...xo,Yn])},[Wn]);return t.createElement(gn,null,t.createElement(xe,null,t.createElement("div",null,ds&&t.createElement(Q,{bulkActions:dt,selectedEntities:Jn,setSelectedEntities:Wn})),t.createElement(Pn,null,"Show",t.createElement(n.ButtonGroup,null,Xo&&t.createElement(O.IE,{pageSize:ao,showLabel:!1,onChange:bn}),t.createElement(P,{allColumns:Do,selectedColumns:vo,onChange:Cn})))),t.createElement(Jt,{id:"scroll-container",ref:yo},t.createElement(An,{striped:!0,condensed:!0,hover:!0},t.createElement(mt,{columns:Jo,columnsOrder:yt,actionsColWidth:_s,columnsWidths:Cs,selectedEntities:Jn,setSelectedEntities:Wn,data:Xt,columnRenderersByAttribute:Zo,onSortChange:hn,displayBulkSelectCol:zo,activeSort:Ye,displayActionsCol:bo}),Xt.map((Yn,xo)=>t.createElement("tbody",{key:`table-row-${Yn.id}`,"data-testid":`table-row-${Yn.id}`},t.createElement(Bn,{entity:Yn,index:xo,entityAttributesAreCamelCase:Ke,actionsRef:Vo,onToggleEntitySelect:ms,columnRenderersByAttribute:Zo,isSelected:!!(Jn!=null&&Jn.includes(Yn.id)),rowActions:Xn,displaySelect:zo,displayActions:bo,columns:Jo}),t.createElement(we,{key:`expanded-sections-${Yn.id}`,expandedSectionsRenderer:rn,entity:Yn}))))))};Mo.defaultProps={actionsCellWidth:void 0,activeSort:void 0,columnRenderers:void 0,columnsOrder:[],expandedSectionsRenderer:void 0,onPageSizeChange:void 0,pageSize:void 0,rowActions:void 0,entityAttributesAreCamelCase:!0,bulkSelection:{}};const Zt=Mo},gn61rwrR:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("J6y4/h8P"),n=e("uZqmR+ju");const c=r.default.ul`
  padding: 0;
  margin: 0;
`,v=({bsNoItemsStyle:g,items:p,noItemsText:E})=>p.length===0?o.createElement(n.Alert,{bsStyle:g},E):o.createElement(c,null,p);v.defaultProps={bsNoItemsStyle:"info",noItemsText:"No items available"},v.propTypes={bsNoItemsStyle:s().oneOf(["info","success","warning"]),noItemsText:s().oneOfType([s().string,s().element]),items:s().array.isRequired};const d=v},KDUSw0C6:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("J6y4/h8P"),n=e("uZqmR+ju");const c=r.default.li(({theme:g})=>(0,r.css)`
  display: block;
  padding: 15px 0;

  h2 {
    font-family: ${g.fonts.family.body};
  }

  h2 .label {
    margin-left: 5px;
    line-height: 1;
    vertical-align: baseline;
  }

  .item-description {
    min-height: 17px;
    margin: 5px 0;
  }

  .item-actions > .btn,
  .item-actions > .btn-group,
  .item-actions > span > .btn {
    margin-left: 5px;
    margin-bottom: 5px;
  }

  &:not(:last-child) {
    border-bottom: 1px solid ${g.colors.gray[90]};
  }
`),v=({actions:g,contentRow:p,description:E,title:a,titleSuffix:u})=>{const f=u?o.createElement("small",null,u):null,y=o.createElement("div",{className:"item-actions text-right"},g);return o.createElement(c,null,o.createElement(n.Row,{className:"row-sm"},o.createElement(n.Col,{md:12},o.createElement("div",{className:"pull-right hidden-xs"},y),o.createElement("h2",null,a," ",f),E&&o.createElement("div",{className:"item-description"},o.createElement("span",null,E))),o.createElement(n.Col,{sm:12,lgHidden:!0,mdHidden:!0,smHidden:!0},y)),p&&o.createElement(n.Row,{className:"row-sm"},p))};v.propTypes={title:s().oneOfType([s().string,s().node]).isRequired,titleSuffix:s().any,description:s().any,actions:s().oneOfType([s().array,s().node]),contentRow:s().node},v.defaultProps={actions:void 0,contentRow:void 0,description:void 0,titleSuffix:void 0};const d=v},myNaa1PZ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("UiXZqrDE"),n=e("uZqmR+ju");const c=p=>({defaultChecked:p!=null?p:!1}),v=p=>({value:p!=null?p:""}),d=({name:p,type:E,help:a,validate:u,onChange:f,error:y,...T})=>{const{validateOnChange:P}=(0,r.useFormikContext)();return t.createElement(r.Field,{name:p,validate:u},({field:{value:O,onChange:b,onBlur:L},meta:{error:x,touched:W}})=>{const N=E==="checkbox"?c(O):v(O),j=(P?!!(x&&W):!!x)?x:y,z=ne=>{typeof f=="function"&&f(ne),b(ne)};return t.createElement(n.Input,{...T,...N,onBlur:L,help:a,id:p,error:j,onChange:z,type:E})})};d.propTypes={autoComplete:o().string,bsSize:o().string,buttonAfter:o().oneOfType([o().string,o().element]),children:o().oneOfType([o().array,o().element]),disabled:o().bool,error:o().oneOfType([o().string,o().element]),formGroupClassName:o().string,help:o().oneOfType([o().string,o().element]),label:o().oneOfType([o().string,o().element]),labelClassName:o().string,maxLength:o().number,minLength:o().number,name:o().string.isRequired,onChange:o().func,placeholder:o().string,required:o().bool,type:o().string,validate:o().func,wrapperClassName:o().string,autoFocus:o().bool},d.defaultProps={autoComplete:void 0,bsSize:void 0,buttonAfter:void 0,children:null,disabled:!1,error:void 0,formGroupClassName:void 0,help:void 0,label:void 0,labelClassName:void 0,maxLength:void 0,minLength:void 0,onChange:void 0,placeholder:void 0,required:!1,type:"text",validate:()=>{},wrapperClassName:void 0,autoFocus:!1};const g=d},"6tmAsyUP":(M,C,e)=>{"use strict";e.d(C,{Z:()=>a});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("/GOzvPf6"),c=e("uZqmR+ju"),v=e("93yMNhQL");const d=(0,r.default)(c.Popover)(({theme:u})=>(0,r.css)`
  ul {
    padding-left: 0;
  }

  li {
    margin-bottom: 5px;

    &:last-child {
      margin-bottom: 0;
    }
  }

  h4 {
    font-size: ${u.fonts.size.large};
  }
`),g=(0,r.default)(v.Z)(({theme:u,$type:f,$displayLeftMargin:y})=>(0,r.css)`
  color: ${f==="error"?u.colors.variant.danger:"inherit"};
  margin-left: ${y?"0.3em":0};
`),p=u=>{switch(u){case"error":return"circle-exclamation";case"info":default:return"question-circle"}},E=({children:u,className:f,displayLeftMargin:y,title:T,id:P,pullRight:O,placement:b,testId:L,type:x,iconSize:W,trigger:N})=>t.createElement(n.Ox,{trigger:N,placement:b,overlay:t.createElement(d,{title:T,id:P},u),testId:L},t.createElement(g,{className:`${f} ${O?"pull-right":""}`,name:p(x),$type:x,$displayLeftMargin:y,size:W}));E.propTypes={displayLeftMargin:o().bool,children:o().any.isRequired,className:o().string,id:o().string,placement:o().oneOf(["top","right","bottom","left"]),pullRight:o().bool,title:o().string,testId:o().string,trigger:o().arrayOf(o().oneOf(["click","focus","hover"]))||o().oneOf(["click","focus","hover"])},E.defaultProps={id:"help-popover",className:"",pullRight:!0,placement:"bottom",testId:void 0,title:void 0,type:"info",iconSize:void 0,trigger:["hover","focus"],displayLeftMargin:!1};const a=E},"93yMNhQL":(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("Z7aTuO5B"),s=e("alU4HbhK"),o=e.n(s),r=e("jtomkfYT"),n=e("8jTixuP6");const v=[{v4:"address-book-o",v5:"address-book"},{v4:"address-card-o",v5:"address-card"},{v4:"area-chart",v5:"chart-area"},{v4:"arrow-circle-o-down",v5:"arrow-alt-circle-down"},{v4:"arrow-circle-o-left",v5:"arrow-alt-circle-left"},{v4:"arrow-circle-o-right",v5:"arrow-alt-circle-right"},{v4:"arrow-circle-o-up",v5:"arrow-alt-circle-up"},{v4:"arrows",v5:"arrows-alt"},{v4:"arrows-alt",v5:"expand-arrows-alt"},{v4:"arrows-h",v5:"arrows-alt-h"},{v4:"arrows-v",v5:"arrows-alt-v"},{v4:"asl-interpreting",v5:"american-sign-language-interpreting"},{v4:"automobile",v5:"car"},{v4:"bank",v5:"university"},{v4:"bar-chart",v5:"chart-bar"},{v4:"bar-chart-o",v5:"chart-bar"},{v4:"bathtub",v5:"bath"},{v4:"battery",v5:"battery-full"},{v4:"battery-0",v5:"battery-empty"},{v4:"battery-1",v5:"battery-quarter"},{v4:"battery-2",v5:"battery-half"},{v4:"battery-3",v5:"battery-three-quarters"},{v4:"battery-4",v5:"battery-full"},{v4:"bell-o",v5:"bell"},{v4:"bell-slash-o",v5:"bell-slash"},{v4:"bookmark-o",v5:"bookmark"},{v4:"building-o",v5:"building"},{v4:"cab",v5:"taxi"},{v4:"calendar",v5:"calendar-alt"},{v4:"calendar-check-o",v5:"calendar-check"},{v4:"calendar-minus-o",v5:"calendar-minus"},{v4:"calendar-o",v5:"calendar"},{v4:"calendar-plus-o",v5:"calendar-plus"},{v4:"calendar-times-o",v5:"calendar-times"},{v4:"caret-square-o-down",v5:"caret-square-down"},{v4:"caret-square-o-left",v5:"caret-square-left"},{v4:"caret-square-o-right",v5:"caret-square-right"},{v4:"caret-square-o-up",v5:"caret-square-up"},{v4:"cc",v5:"closed-captioning"},{v4:"chain",v5:"link"},{v4:"chain-broken",v5:"unlink"},{v4:"check-circle-o",v5:"check-circle"},{v4:"check-square-o",v5:"check-square"},{v4:"circle-o",v5:"circle"},{v4:"circle-o-notch",v5:"circle-notch"},{v4:"circle-thin",v5:"circle"},{v4:"clock-o",v5:"clock"},{v4:"close",v5:"times"},{v4:"cloud-download",v5:"cloud-download-alt"},{v4:"cloud-upload",v5:"cloud-upload-alt"},{v4:"cny",v5:"yen-sign"},{v4:"code-fork",v5:"code-branch"},{v4:"comment-o",v5:"comment"},{v4:"commenting",v5:"comment-dots"},{v4:"commenting-o",v5:"comment-dots"},{v4:"comments-o",v5:"comments"},{v4:"credit-card-alt",v5:"credit-card"},{v4:"cutlery",v5:"utensils"},{v4:"dashboard",v5:"tachometer-alt"},{v4:"deafness",v5:"deaf"},{v4:"dedent",v5:"outdent"},{v4:"diamond",v5:"gem"},{v4:"dollar",v5:"dollar-sign"},{v4:"dot-circle-o",v5:"dot-circle"},{v4:"drivers-license",v5:"id-card"},{v4:"drivers-license-o",v5:"id-card"},{v4:"envelope-o",v5:"envelope"},{v4:"envelope-open-o",v5:"envelope-open"},{v4:"eur",v5:"euro-sign"},{v4:"euro",v5:"euro-sign"},{v4:"exchange",v5:"exchange-alt"},{v4:"external-link",v5:"external-link-alt"},{v4:"external-link-square",v5:"external-link-square-alt"},{v4:"eye",v5:"eye"},{v4:"eye-slash",v5:"eye-slash"},{v4:"eyedropper",v5:"eye-dropper"},{v4:"feed",v5:"rss"},{v4:"file-archive-o",v5:"file-archive"},{v4:"file-audio-o",v5:"file-audio"},{v4:"file-code-o",v5:"file-code"},{v4:"file-excel-o",v5:"file-excel"},{v4:"file-image-o",v5:"file-image"},{v4:"file-movie-o",v5:"file-video"},{v4:"file-o",v5:"file"},{v4:"file-pdf-o",v5:"file-pdf"},{v4:"file-photo-o",v5:"file-image"},{v4:"file-picture-o",v5:"file-image"},{v4:"file-powerpoint-o",v5:"file-powerpoint"},{v4:"file-sound-o",v5:"file-audio"},{v4:"file-text",v5:"file-alt"},{v4:"file-text-o",v5:"file-alt"},{v4:"file-video-o",v5:"file-video"},{v4:"file-word-o",v5:"file-word"},{v4:"file-zip-o",v5:"file-archive"},{v4:"files-o",v5:"copy"},{v4:"flag-o",v5:"flag"},{v4:"flash",v5:"bolt"},{v4:"floppy-o",v5:"save"},{v4:"folder-o",v5:"folder"},{v4:"folder-open-o",v5:"folder-open"},{v4:"frown-o",v5:"frown"},{v4:"futbol-o",v5:"futbol"},{v4:"gbp",v5:"pound-sign"},{v4:"gear",v5:"cog"},{v4:"gears",v5:"cogs"},{v4:"glass",v5:"glass-martini"},{v4:"group",v5:"users"},{v4:"hand-grab-o",v5:"hand-rock"},{v4:"hand-lizard-o",v5:"hand-lizard"},{v4:"hand-o-down",v5:"hand-point-down"},{v4:"hand-o-left",v5:"hand-point-left"},{v4:"hand-o-right",v5:"hand-point-right"},{v4:"hand-o-up",v5:"hand-point-up"},{v4:"hand-paper-o",v5:"hand-paper"},{v4:"hand-peace-o",v5:"hand-peace"},{v4:"hand-pointer-o",v5:"hand-pointer"},{v4:"hand-rock-o",v5:"hand-rock"},{v4:"hand-scissors-o",v5:"hand-scissors"},{v4:"hand-spock-o",v5:"hand-spock"},{v4:"hand-stop-o",v5:"hand-paper"},{v4:"handshake-o",v5:"handshake"},{v4:"hard-of-hearing",v5:"deaf"},{v4:"hdd-o",v5:"hdd"},{v4:"header",v5:"heading"},{v4:"heart-o",v5:"heart"},{v4:"hospital-o",v5:"hospital"},{v4:"hotel",v5:"bed"},{v4:"hourglass-1",v5:"hourglass-start"},{v4:"hourglass-2",v5:"hourglass-half"},{v4:"hourglass-3",v5:"hourglass-end"},{v4:"hourglass-o",v5:"hourglass"},{v4:"id-badge",v5:"id-badge"},{v4:"id-card-o",v5:"id-card"},{v4:"ils",v5:"shekel-sign"},{v4:"image",v5:"image"},{v4:"inr",v5:"rupee-sign"},{v4:"institution",v5:"university"},{v4:"intersex",v5:"transgender"},{v4:"jpy",v5:"yen-sign"},{v4:"keyboard-o",v5:"keyboard"},{v4:"krw",v5:"won-sign"},{v4:"legal",v5:"gavel"},{v4:"lemon-o",v5:"lemon"},{v4:"level-down",v5:"level-down-alt"},{v4:"level-up",v5:"level-up-alt"},{v4:"life-bouy",v5:"life-ring"},{v4:"life-buoy",v5:"life-ring"},{v4:"life-ring",v5:"life-ring"},{v4:"life-saver",v5:"life-ring"},{v4:"lightbulb-o",v5:"lightbulb"},{v4:"line-chart",v5:"chart-line"},{v4:"list-alt",v5:"list-alt"},{v4:"long-arrow-down",v5:"long-arrow-alt-down"},{v4:"long-arrow-left",v5:"long-arrow-alt-left"},{v4:"long-arrow-right",v5:"long-arrow-alt-right"},{v4:"long-arrow-up",v5:"long-arrow-alt-up"},{v4:"mail-forward",v5:"share"},{v4:"mail-reply",v5:"reply"},{v4:"mail-reply-all",v5:"reply-all"},{v4:"map-marker",v5:"map-marker-alt"},{v4:"map-o",v5:"map"},{v4:"meh-o",v5:"meh"},{v4:"minus-square-o",v5:"minus-square"},{v4:"mobile",v5:"mobile-alt"},{v4:"mobile-phone",v5:"mobile-alt"},{v4:"money",v5:"money-bill-alt"},{v4:"moon-o",v5:"moon"},{v4:"mortar-board",v5:"graduation-cap"},{v4:"navicon",v5:"bars"},{v4:"newspaper-o",v5:"newspaper"},{v4:"object-group",v5:"object-group"},{v4:"object-ungroup",v5:"object-ungroup"},{v4:"paper-plane-o",v5:"paper-plane"},{v4:"paste",v5:"clipboard"},{v4:"pause-circle-o",v5:"pause-circle"},{v4:"pencil",v5:"pencil-alt"},{v4:"pencil-square",v5:"pen-square"},{v4:"pencil-square-o",v5:"edit"},{v4:"photo",v5:"image"},{v4:"picture-o",v5:"image"},{v4:"pie-chart",v5:"chart-pie"},{v4:"play-circle-o",v5:"play-circle"},{v4:"plus-square-o",v5:"plus-square"},{v4:"question-circle-o",v5:"question-circle"},{v4:"refresh",v5:"sync"},{v4:"registered",v5:"registered"},{v4:"remove",v5:"times"},{v4:"reorder",v5:"bars"},{v4:"repeat",v5:"redo"},{v4:"rmb",v5:"yen-sign"},{v4:"rotate-left",v5:"undo"},{v4:"rotate-right",v5:"redo"},{v4:"rouble",v5:"ruble-sign"},{v4:"rub",v5:"ruble-sign"},{v4:"ruble",v5:"ruble-sign"},{v4:"rupee",v5:"rupee-sign"},{v4:"s15",v5:"bath"},{v4:"scissors",v5:"cut"},{v4:"send",v5:"paper-plane"},{v4:"send-o",v5:"paper-plane"},{v4:"share-square-o",v5:"share-square"},{v4:"shekel",v5:"shekel-sign"},{v4:"sheqel",v5:"shekel-sign"},{v4:"shield",v5:"shield-alt"},{v4:"sign-in",v5:"sign-in-alt"},{v4:"sign-out",v5:"sign-out-alt"},{v4:"signing",v5:"sign-language"},{v4:"sliders",v5:"sliders-h"},{v4:"smile-o",v5:"smile"},{v4:"snowflake-o",v5:"snowflake"},{v4:"soccer-ball-o",v5:"futbol"},{v4:"sort-alpha-asc",v5:"sort-alpha-down"},{v4:"sort-alpha-desc",v5:"sort-alpha-up"},{v4:"sort-amount-asc",v5:"sort-amount-down"},{v4:"sort-amount-desc",v5:"sort-amount-up"},{v4:"sort-asc",v5:"sort-up"},{v4:"sort-desc",v5:"sort-down"},{v4:"sort-numeric-asc",v5:"sort-numeric-down"},{v4:"sort-numeric-desc",v5:"sort-numeric-up"},{v4:"spoon",v5:"utensil-spoon"},{v4:"square-o",v5:"square"},{v4:"star-half-empty",v5:"star-half"},{v4:"star-half-full",v5:"star-half"},{v4:"star-half-o",v5:"star-half"},{v4:"star-o",v5:"star"},{v4:"sticky-note-o",v5:"sticky-note"},{v4:"stop-circle-o",v5:"stop-circle"},{v4:"sun-o",v5:"sun"},{v4:"support",v5:"life-ring"},{v4:"tablet",v5:"tablet-alt"},{v4:"tachometer",v5:"tachometer-alt"},{v4:"television",v5:"tv"},{v4:"thermometer",v5:"thermometer-full"},{v4:"thermometer-0",v5:"thermometer-empty"},{v4:"thermometer-1",v5:"thermometer-quarter"},{v4:"thermometer-2",v5:"thermometer-half"},{v4:"thermometer-3",v5:"thermometer-three-quarters"},{v4:"thermometer-4",v5:"thermometer-full"},{v4:"thumb-tack",v5:"thumbtack"},{v4:"thumbs-o-down",v5:"thumbs-down"},{v4:"thumbs-o-up",v5:"thumbs-up"},{v4:"ticket",v5:"ticket-alt"},{v4:"times-circle-o",v5:"times-circle"},{v4:"times-rectangle",v5:"window-close"},{v4:"times-rectangle-o",v5:"window-close"},{v4:"toggle-down",v5:"caret-square-down"},{v4:"toggle-left",v5:"caret-square-left"},{v4:"toggle-right",v5:"caret-square-right"},{v4:"toggle-up",v5:"caret-square-up"},{v4:"trash",v5:"trash-alt"},{v4:"trash-o",v5:"trash-alt"},{v4:"try",v5:"lira-sign"},{v4:"turkish-lira",v5:"lira-sign"},{v4:"unsorted",v5:"sort"},{v4:"usd",v5:"dollar-sign"},{v4:"user-circle-o",v5:"user-circle"},{v4:"user-o",v5:"user"},{v4:"vcard",v5:"address-card"},{v4:"vcard-o",v5:"address-card"},{v4:"video-camera",v5:"video"},{v4:"volume-control-phone",v5:"phone-volume"},{v4:"warning",v5:"exclamation-triangle"},{v4:"window-close-o",v5:"window-close"},{v4:"window-maximize",v5:"window-maximize"},{v4:"window-restore",v5:"window-restore"},{v4:"won",v5:"won-sign"},{v4:"yen",v5:"yen-sign"}],d=(0,n.Z)(()=>Promise.all([e.e("1255d548-3703"),e.e("1255d548-2236")]).then(e.bind(e,"5yeF0VOU"))),g=y=>y.replace(/^fa-/,""),p=y=>{const T=o()(v,{v4:y}),P=T&&T.v5||y;return T&&(0,r.Z)(`You have used a deprecated \`Icon\` name. \`${y}\` should be \`${P}\``),P},E=(y,T)=>{const P=g(y);return T!=="brand"?p(P):P},a=y=>{switch(y){case"brand":return"fab";case"regular":return"far";case"solid":default:return"fas"}},u=({name:y,type:T,size:P,className:O,rotation:b,spin:L,fixedWidth:x,inverse:W,style:N,"data-testid":Z,onClick:j,onMouseEnter:z,onMouseLeave:ne,onFocus:Y,tabIndex:ae,title:ee})=>{const ue=E(y,T),H=a(T);return t.createElement(d,{className:O,"data-testid":Z,fixedWidth:x,icon:{prefix:H,iconName:ue},inverse:W,rotation:b,size:P,spin:L,style:N,onClick:j,onMouseEnter:z,onMouseLeave:ne,tabIndex:ae,title:ee,onFocus:Y})};u.defaultProps={className:void 0,"data-testid":void 0,fixedWidth:!1,inverse:!1,rotation:void 0,size:void 0,spin:!1,style:void 0,type:"solid",onClick:void 0,onMouseEnter:void 0,onMouseLeave:void 0,onFocus:void 0,tabIndex:void 0,title:void 0};const f=u},"Ofda/4py":(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("93yMNhQL");const c=r.default.button(({theme:p,disabled:E})=>(0,r.css)`
  display: inline-flex;
  justify-content: center;
  align-items: center;
  height: 25px;
  width: 25px;
  border: 0;
  background-color: transparent;
  cursor: pointer;
  color: ${E?p.colors.gray[90]:p.colors.gray[60]};
  font-size: ${p.fonts.size.large};

  &:hover {
    background-color: ${p.colors.gray[80]};
  }

  &:active {
    background-color: ${p.colors.gray[70]};
  }
`),v=p=>{typeof p=="function"&&p()},d=({title:p,onClick:E,focusable:a,className:u,disabled:f,...y})=>t.createElement(c,{tabIndex:a?0:-1,title:p,onClick:()=>v(E),className:u,type:"button",disabled:f},t.createElement(n.Z,{...y}));d.propTypes={className:o().string,title:o().string,onClick:o().func,name:o().string},d.defaultProps={className:void 0,focusable:!0,onClick:void 0,title:void 0,name:void 0,disabled:!1};const g=d},rzOX6PZw:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("q2j1bVbz"),n=e("0TVxnHwi");const c=(g,p,E)=>p?(0,n.Tv)(E.permissions,g):(0,n.rq)(E.permissions,g),v=({children:g,permissions:p,anyPermissions:E,...a})=>{const u=(0,r.Z)();return!p||p.length===0||u&&c(p,E,u)?t.createElement(t.Fragment,null,t.Children.map(g,f=>{if(t.isValidElement(f)){const y=f&&f.props?Object.keys(f.props):[],T=Object.entries(a).filter(P=>!y.includes(P[0])).reduce((P,[O,b])=>({...P,[O]:b}),{});return t.cloneElement(f,T)}return f})):null};v.propTypes={children:o().node.isRequired,permissions:o().oneOfType([o().string,o().arrayOf(o().string)]).isRequired,anyPermissions:o().bool},v.defaultProps={anyPermissions:!1};const d=v},"Kz+u8q89":(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("uZqmR+ju");const c=r.default.span(({theme:p})=>(0,r.css)`
  color: ${p.colors.variant.danger};
`),v=r.default.span(({theme:p,$hasError:E})=>(0,r.css)`
  color: ${E?p.colors.gray[50]:"inherit"};
`),d=({className:p,error:E,help:a})=>!a&&!E?null:t.createElement(n.HelpBlock,{className:`${p!=null?p:""} input-description`},E&&t.createElement(c,null,E),!!E&&!!a&&t.createElement("br",null),a&&t.createElement(v,{$hasError:!!E},a));d.propTypes={className:o().string,error:o().oneOfType([o().element,o().string]),help:o().oneOfType([o().element,o().string])},d.defaultProps={className:void 0,error:void 0,help:void 0};const g=d},hHVzGgmW:(M,C,e)=>{"use strict";e.d(C,{Z:()=>N});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("tfZpVkE/"),n=e("J6y4/h8P"),c=e("Mx+G+HdB"),v=e.n(c),d=e("uZqmR+ju"),g=e("93yMNhQL");const p={width:450,height:400},E=Math.ceil(window.innerWidth/2-p.width/2),a=Math.ceil(window.innerHeight/2-p.height/2),u=a<0?55:a,f={x:E,y:u},y=n.default.div`
  position: fixed;
  inset: 0;
  z-index: 1030;
  pointer-events: none;
`,T=(0,n.default)(r.s)(({theme:Z})=>(0,n.css)`
  box-shadow: 0 0 9px ${Z.colors.global.navigationBoxShadow},
    0 0 6px ${Z.colors.global.navigationBoxShadow},
    0 0 3px ${Z.colors.global.navigationBoxShadow};
  background-color: ${Z.colors.global.contentBackground};
  border: 1px solid ${Z.colors.variant.lightest.default};
  border-radius: 3px;
  flex-direction: column;
  display: flex !important;
  pointer-events: auto;
`),P=n.default.div`
  flex: 1;
  padding: 0 15px;
`,O=n.default.header(({theme:Z})=>(0,n.css)`
  padding: 6px 12px 9px;
  display: flex;
  align-items: center;
  background-color: ${Z.colors.variant.lightest.default};
  border-bottom: 1px solid ${Z.colors.variant.lighter.default};
  border-top-left-radius: 3px;
  border-top-right-radius: 3px;
  cursor: move;
`),b=n.default.h3(({theme:Z})=>(0,n.css)`
  color: ${Z.colors.global.textDefault};
  flex: 1;
`),L=(0,n.default)(g.Z)(({theme:Z})=>(0,n.css)`
  color: ${Z.colors.variant.darker.default};
  margin-right: 9px;
`),x=(0,n.default)(d.Button)(({theme:Z})=>(0,n.css)`
  && {
    color: ${Z.colors.variant.light.default};
    
    &:hover {
      color: ${Z.colors.variant.default};
    }
  }
`),W=({children:Z,className:j,minHeight:z,minWidth:ne,onClose:Y,onDrag:ae,onResize:ee,position:ue,size:H,title:ye,wrapperClassName:we})=>{const ut=(0,t.useRef)(null),[ht,Je]=(0,t.useState)(null),[Re,le]=(0,t.useState)(ue),[me,re]=(0,t.useState)(H),ce=(ie,{x:ge,y:fe})=>{le({x:ge,y:fe}),ae({x:ge,y:fe})},Q=(ie,ge,fe)=>{const Ce={width:fe.style.width,height:fe.style.height};let Oe={...Re};switch(ge){case"left":case"topLeft":case"top":Oe={x:Re.x-(parseFloat(fe.style.width)-parseFloat(me.width)),y:Re.y-(parseFloat(fe.style.height)-parseFloat(me.height))};break;case"bottomLeft":Oe={x:Re.x-(parseFloat(fe.style.width)-parseFloat(me.width)),y:Re.y};break;case"topRight":Oe={x:Re.x,y:Re.y-(parseFloat(fe.style.height)-parseFloat(me.height))};break;default:break}re(Ce),ee(Ce),ce(null,Oe)},J=v()(()=>{const{x:ie,y:ge}=Re,{width:fe,height:Ce}=me,{innerWidth:Oe,innerHeight:nt}=window,et={top:0,bottom:parseFloat(Ce),left:0,right:parseFloat(fe)},Fe={},Pe=Oe-et.right,$e=nt-et.bottom;Fe.x=Math.max(Math.min(Pe,ie),et.left),Fe.y=Math.max(Math.min($e,ge),et.top),ce(null,Fe)},150);return(0,t.useEffect)(()=>{Je(ut.current.classList[0])},[]),(0,t.useEffect)(()=>(window.addEventListener("resize",J,!1),()=>{window.removeEventListener("resize",J)}),[Re,J]),t.createElement(y,{className:we,role:"dialog"},t.createElement(T,{default:{...ue,...H},minHeight:z,minWidth:ne,maxHeight:window.innerHeight,maxWidth:window.innerWidth,dragHandleClassName:ht,onDragStop:ce,onResizeStop:Q,position:Re,size:me,className:j,bounds:"window"},t.createElement(O,{ref:ut},t.createElement(b,null,t.createElement(L,{name:"bars"}),ye),t.createElement(x,{bsStyle:"link",onClick:Y,bsSize:"small",title:"Close"},t.createElement(g.Z,{name:"times",size:"lg"}))),t.createElement(P,null,Z)))};W.propTypes={className:o().string,children:o().node.isRequired,minHeight:o().number,minWidth:o().number,onClose:o().func,onDrag:o().func,onResize:o().func,position:o().shape({x:o().number,y:o().number}),size:o().shape({height:o().oneOfType([o().string,o().number]),width:o().oneOfType([o().string,o().number])}),title:o().string,wrapperClassName:o().string},W.defaultProps={className:void 0,minHeight:p.height,minWidth:p.width,onClose:()=>{},onDrag:()=>{},onResize:()=>{},position:f,size:p,title:"",wrapperClassName:void 0};const N=W},"k7aCBAx/":(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("uZqmR+ju"),c=e("dsvqAVKU"),v=e("rRqvmggl");const d=r.default.div(({theme:a})=>(0,r.css)`
  background-color: ${a.colors.global.contentBackground};
  position: fixed;
  min-width: 200px;
  top: 60px;
  left: 50%;
  transform: translateX(-50%);
  box-shadow: 0 2px 10px rgb(0 0 0 / 20%);
  z-index: 2000;
`),g=(0,r.default)(n.Alert)`
  margin: 0;
  height: 32px;
  padding: 5px 20px;
  text-align: center;
`,p=({text:a})=>t.createElement(v.Z,{delay:500},t.createElement(d,null,t.createElement(g,{bsStyle:"info"},t.createElement(c.Z,{delay:0,text:a}))));p.propTypes={text:o().string},p.defaultProps={text:"Loading..."};const E=p},s14Hze4o:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("XtvWbNyo"),o=e("AbA4Yk3R"),r=e.n(o);const c=({text:v})=>{const d=(0,t.useMemo)(()=>r().sanitize((0,s.TU)(v!=null?v:"")),[v]);return t.createElement("div",{dangerouslySetInnerHTML:{__html:d}})}},rp7UD7rK:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("utbMO9sg"),r=e("CrIFpfDF"),n=e("93yMNhQL"),c=e("dsvqAVKU");const v=(0,s.default)(r.Z)`
  display: flex;
  justify-content: flex-end;
  align-items: end;
`,d=p=>{const{isAsyncSubmit:E,bsSize:a,className:u,displayCancel:f,disabledSubmit:y,formId:T,leftCol:P,onSubmit:O,submitButtonText:b,submitButtonType:L,submitIcon:x}=p;return t.createElement(v,{className:u},P,f&&t.createElement(o.Z,{type:"button",bsSize:a,onClick:p.onCancel,title:"Cancel","aria-label":"Cancel",disabled:p.disabledCancel||E&&p.isSubmitting},"Cancel"),t.createElement(o.Z,{bsStyle:"success",bsSize:a,disabled:y||E&&p.isSubmitting,form:T,title:b,"aria-label":b,type:L,onClick:O},x&&!(E&&p.isSubmitting)&&t.createElement(t.Fragment,null,t.createElement(n.Z,{name:x})," "),E&&p.isSubmitting?t.createElement(c.Z,{text:p.submitLoadingText,delay:0}):b))};d.defaultProps={bsSize:void 0,className:void 0,disabledSubmit:!1,displayCancel:!0,isAsyncSubmit:!1,formId:void 0,isSubmitting:!1,leftCol:void 0,onSubmit:void 0,submitButtonType:"submit",submitIcon:void 0};const g=d},kTp6yg80:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("hhdCSTZj");class o extends t.Component{constructor(){super(...arguments),this._select=void 0,this.getValue=()=>this._select.getValue()}render(){return t.createElement(s.Z,{ref:c=>{this._select=c},multi:!0,...this.props})}}o.propTypes=s.Z.propTypes;const r=o},"NV1/EHMi":(M,C,e)=>{"use strict";e.d(C,{A7:()=>v,RF:()=>c,ZP:()=>p});var t=e("Z7aTuO5B"),s=e("J6y4/h8P");const o="nav-item-state-indicator",r="::before",n=`.${o}${r}`,c=E=>(0,s.css)`
  ${n} {
    border-color: ${E.colors.gray[70]};
  }
`,v=E=>(0,s.css)`
  ${n} {
    border-color: ${E.colors.gray[50]};
  }
`,d=s.default.div`
  display: inline;
  position: relative;
  
  &${r} {
    content: ' ';
    position: absolute;
    border-bottom: 1px solid transparent;
    left: 0;
    width: 100%;
    bottom: -4px;
  }
`,p=({children:E})=>t.createElement(d,{className:o},E)},"G8YcST+s":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("uZqmR+ju");const n=({children:v})=>t.createElement(r.Alert,{className:"no-bm"},v);n.propTypes={children:o().oneOfType([o().node])},n.defaultProps={children:"No entities exist."};const c=n},F3uT4N0K:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("VgplIV7d"),c=e("/GOzvPf6");const v=r.default.span`
  cursor: pointer;

  .caret {
    visibility: hidden;
  }

  &:hover .caret {
    visibility: visible;
  }
`,d={left:"right",right:"left"},g=({children:a,style:u})=>t.createElement(t.Fragment,null,t.Children.map(a,f=>t.cloneElement(f,{style:{...u,...f.props.style}})));g.defaultProps={style:{}};const p=({children:a,closeOnSelect:u,dropdownMinWidth:f,dropdownZIndex:y,menuContainer:T,onToggle:P,placement:O,renderToggle:b,show:L,toggleChild:x})=>{const[W,N]=(0,t.useState)(O),Z=(0,t.useRef)(),j=z=>{const ne=z.offsetLeft,Y=z.offsetWidth,ae=ne+Y>=document.body.clientWidth;(ne<0&&W==="left"||ae&&W==="right")&&N(d[W])};return t.createElement(t.Fragment,null,typeof b=="function"?b({onToggle:P,toggleTarget:Z}):t.createElement(v,{onClick:P,ref:Z,role:"presentation"},x),L&&t.createElement(n.aV,{show:L,container:T,containerPadding:10,placement:W,shouldUpdatePosition:!0,rootClose:!0,onHide:P,target:()=>Z.current,transition:n.uT,onEntering:j},t.createElement(g,null,t.createElement(c.h_,{show:L,onMenuItemSelect:u?P:void 0,zIndex:y,minWidth:f},a))))};p.propTypes={children:o().node.isRequired,closeOnSelect:o().bool,dropdownZIndex:o().number,menuContainer:o().object,onToggle:o().func.isRequired,placement:o().string,show:o().bool.isRequired,toggleChild:o().oneOfType([o().string,o().node])},p.defaultProps={closeOnSelect:!0,dropdownMinWidth:void 0,dropdownZIndex:void 0,menuContainer:document.body,placement:"bottom",renderToggle:void 0,toggleChild:"Toggle"};const E=p},HQjpSCKK:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("utbMO9sg"),o=e("F3uT4N0K");const r=({bsSize:c,buttonTitle:v,children:d,closeOnSelect:g,disabled:p,dropdownMinWidth:E,dropdownZIndex:a,onToggle:u,title:f})=>{const[y,T]=(0,t.useState)(!1),P=()=>{typeof u=="function"&&u(!y),T(O=>!O)};return t.createElement(o.Z,{show:y,closeOnSelect:g,dropdownZIndex:a,dropdownMinWidth:E,renderToggle:({onToggle:O,toggleTarget:b})=>t.createElement("div",{className:`dropdown btn-group ${y?"open":""}`},t.createElement(s.Z,{bsSize:c,className:"dropdown-toggle",ref:b,"aria-label":v,title:v,disabled:p,onClick:O},f," ",t.createElement("span",{className:"caret"}))),placement:"bottom",onToggle:P},typeof d=="function"?d({toggleDropdown:P}):d)};r.defaultProps={bsSize:void 0,buttonTitle:void 0,closeOnSelect:!0,disabled:!1,dropdownMinWidth:void 0,dropdownZIndex:void 0,onToggle:void 0};const n=r},"ys/4WHo5":(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("Z7aTuO5B"),s=e("VgplIV7d"),o=e("J6y4/h8P");const r=o.default.span`
  display: inline-block;
`,n=o.default.div`
  display: inline-block;
`;class c extends t.Component{constructor(g){super(g),this.targetRef=(0,t.createRef)(),this.containerRef=(0,t.createRef)(),this.state={show:!1}}hide(){this.setState({show:!1})}render(){let g;const{children:p,container:E,placement:a,overlay:u,rootClose:f,trigger:y,testId:T,className:P,...O}=this.props,{show:b}=this.state,L=N=>this.setState({show:N}),x=()=>L(!b),W={click:{onClick:x},hover:{onMouseEnter:()=>L(!0),onMouseLeave:()=>L(!1)},focus:{onFocus:()=>L(!0),onBlur:()=>L(!1)}};if(Array.isArray(y)){const N={};y.forEach(Z=>{g=Object.assign(N,W[Z])})}else g=W[y];return t.createElement(n,{ref:()=>this.containerRef,"data-testid":T,className:P},t.createElement(r,{ref:this.targetRef,className:p.props.className,role:"button"},t.cloneElement(p,{...g,className:""})),b&&t.createElement(s.aV,{show:b,container:E!=null?E:this.containerRef.current,containerPadding:10,placement:a,shouldUpdatePosition:!0,rootClose:f,target:this.targetRef.current,transition:s.uT,onHide:x,...O},u))}}c.defaultProps={trigger:"click",rootClose:!1,container:null,testId:void 0,className:void 0};const v=c},"/W/x1zfW":(M,C,e)=>{"use strict";e.d(C,{Z:()=>L});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("Dg7SLLbb"),n=e.n(r),c=e("J6y4/h8P"),v=e("uZqmR+ju"),d=e("/GOzvPf6"),g=e("7dh0vSOR"),p=e("iDUHYfT2");const E=c.default.div`
  display: flex;
  gap: 3px;
  flex-direction: column;
`,a=c.default.div(({theme:x})=>(0,c.css)`
  display: flex;
  justify-content: space-between;
  gap: 5px;

  @media (max-width: ${x.breakpoints.max.md}) {
    flex-wrap: wrap;
  }
`),u=c.default.span(({theme:x})=>(0,c.css)`
  cursor: help;
  margin-left: 5px;
  font-size: ${x.fonts.size.body};
  line-height: 20px;
  vertical-align: text-top;
`),f=c.default.div(({$hasMultipleChildren:x})=>(0,c.css)`
  display: flex;
  gap: 10px;
  align-items: ${x?"center":"flex-start"};
`),y=c.default.div`
  display: flex !important;
  align-items: flex-end;
  
  .btn-toolbar {
    display: flex;
  }
`,T=c.default.p`
  &&&& {
    margin-top: 0;
  }
`,P={experimental:"This Graylog feature is new and should be considered experimental.",legacy:"This feature has been discontinued and will be removed in a future Graylog version."},O=({lifecycle:x,lifecycleMessage:W})=>{if(x===void 0)return null;const N=n()(x),Z=x==="experimental"?P.experimental:P.legacy,j=t.createElement(v.Tooltip,{id:x},W||Z);return t.createElement(u,null,t.createElement(d.Ox,{placement:"bottom",overlay:j},t.createElement(v.Label,{bsStyle:"primary"},N)))},b=({children:x,subpage:W,title:N,actions:Z,topActions:j,lifecycle:z,lifecycleMessage:ne,documentationLink:Y})=>{const ae=W?"":"content";return t.createElement(p.Z,{className:ae},t.createElement(v.Col,{sm:12},t.createElement(E,null,t.createElement(a,null,t.createElement("h1",null,N," ",t.createElement("small",null,t.createElement(O,{lifecycle:z,lifecycleMessage:ne}))),(Y||j)&&t.createElement(f,{$hasMultipleChildren:!!Y&&!!j},Y&&t.createElement(g.Z,{text:Y.title,page:Y.path,displayIcon:!0}),j)),t.createElement(a,null,x&&t.createElement(T,{className:"description no-bm"},x),Z&&t.createElement(y,null,Z)))))};b.propTypes={title:o().node.isRequired,children:o().node,actions:o().node,lifecycle:o().oneOf(["experimental","legacy"]),lifecycleMessage:o().node,subpage:o().bool,documentationLink:o().object},b.defaultProps={children:[],lifecycle:void 0,lifecycleMessage:void 0,topActions:void 0,actions:void 0,subpage:!1,documentationLink:void 0};const L=b},FDzjarsJ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("uZqmR+ju"),c=e("rVdVsuGH");const v=(0,r.default)(n.DropdownButton)`
  ~ .dropdown-menu {
    min-width: auto;
  }
`,d=r.default.div`
  display: flex;
  align-items: center;
  gap: 3px;
`,g=({pageSizes:E,pageSize:a,onChange:u,className:f,showLabel:y})=>{const T=t.createElement(v,{className:f,id:"page-size-select",title:`${a} Rows`,"aria-label":"Configure page size",pullRight:!0,bsSize:"small",bsStyle:"default"},E.map(P=>t.createElement(n.MenuItem,{key:`option-${P}`,onSelect:()=>u(P)},P)));return y?t.createElement(d,{className:f},"Show",T):T};g.propTypes={className:o().string,onChange:o().func.isRequired,pageSize:o().number.isRequired,pageSizes:o().arrayOf(o().number),showLabel:o().bool},g.defaultProps={className:"",pageSizes:c.VZ,showLabel:!0};const p=g},"a/tXGb/M":(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("ii0bleBb"),r=e.n(o),n=e("Ofda/4py");const c=s.default.span(({theme:a})=>(0,s.css)`
  display: flex;
  padding: 10px;
  background-color: ${a.colors.table.background};

  &:nth-of-type(even) {
    background-color: ${a.colors.table.backgroundAlt};
  }
`),v=s.default.div`
  flex: 1;
  margin-right: 5px;
`,d=s.default.span`
  flex: 2;
`,g=(0,s.default)(n.Z)`
  flex: 0;
`,p=({item:{name:a,description:u},onDeleteItem:f,item:y})=>{const T=typeof f=="function"?t.createElement(g,{onClick:()=>f(y),name:"times",title:`Remove ${a}`}):null;return t.createElement(c,null,t.createElement(v,null,a),t.createElement(d,null,u),T)};p.defaultProps={onDeleteItem:void 0},p.propTypes={onDeleteItem:r().func};const E=p},xfUIbHjs:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p,_:()=>d});var t=e("Z7aTuO5B"),s=e("/GOzvPf6"),o=e("qfE6wAsD"),r=e("TMaijZ0a"),n=e("dsvqAVKU"),c=e("a/tXGb/M");const v=[5,10,30],d={page:o.q,perPage:v[0],query:""},g=({onLoad:E,overrideList:a,onDeleteItem:u,queryHelper:f,noDataText:y,resultsWrapperComponent:T,overrideItemComponent:P})=>{var O,b;const[L,x]=(0,t.useState)(),[W,N]=(0,t.useState)(d);if((0,t.useEffect)(()=>a&&x(a),[a]),(0,t.useEffect)(()=>{let z=!0;return E(W,z).then(ne=>{z&&x(ne)}),()=>{z=!1}},[W,E]),!L)return t.createElement(n.Z,null);const Z=t.createElement(s.pJ,null,y);let j;return L.list&&L.list.size>=1&&(j=L.list.toArray().map(z=>P?t.createElement(P,{key:z.id,onDeleteItem:u,item:z}):t.createElement(c.Z,{key:z.id,onDeleteItem:u,item:z}))),t.createElement(o.Z,{onChange:(z,ne)=>N({...W,page:z,perPage:ne}),pageSize:W.perPage,totalItems:(b=(O=L==null?void 0:L.pagination)==null?void 0:O.total)!=null?b:0,pageSizes:v,activePage:W.page,useQueryParameter:!1},t.createElement(r.Z,{onSearch:z=>N({...W,page:o.q,query:z}),label:"Filter",queryWidth:300,wrapperClass:"has-bm",placeholder:"Enter query to filter",queryHelpComponent:f}),t.createElement(T,{isEmptyResult:!j},j!=null?j:Z))};g.defaultProps={onDeleteItem:void 0,overrideList:void 0,noDataText:"No items found to display.",queryHelper:void 0,resultsWrapperComponent:({children:E})=>t.createElement("div",null,E),overrideItemComponent:void 0};const p=g},qfE6wAsD:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E,q:()=>c});var t=e("Z7aTuO5B"),s=e("wfOnu0E0"),o=e("rVdVsuGH"),r=e("wl9DHqUO"),n=e("FDzjarsJ");const c=1,v=({children:a,className:u,currentPage:f,currentPageSize:y,hideFirstAndLastPageLinks:T,hidePreviousAndNextPageLinks:P,onChange:O,pageSizes:b,setPagination:L,showPageSizeSelect:x,totalItems:W})=>{const N=(0,t.useMemo)(()=>y>0?Math.ceil(W/y):0,[y,W]),Z=(0,t.useCallback)(z=>{L({page:c,pageSize:z}),O&&O(c,z)},[O,L]),j=(0,t.useCallback)(z=>{L({page:z,pageSize:y}),O&&O(z,y)},[L,y,O]);return(0,t.useEffect)(()=>{N>0&&f>N&&j(N)},[f,N,j]),t.createElement(t.Fragment,null,x&&t.createElement(n.Z,{pageSizes:b,pageSize:y,showLabel:!0,onChange:Z,className:"pull-right"}),a,t.createElement(s.Z,null,t.createElement("div",{className:`text-center pagination-wrapper ${u!=null?u:""}`},t.createElement(r.Z,{totalPages:N,currentPage:f,hidePreviousAndNextPageLinks:P,hideFirstAndLastPageLinks:T,onChange:j}))))},d=({pageSizes:a,...u})=>{const{page:f,pageSize:y,setPagination:T}=(0,o.ZP)(a,u.pageSize,u.showPageSizeSelect);return t.createElement(v,{...u,currentPage:f,currentPageSize:y,setPagination:T,pageSizes:a})},g=({activePage:a,pageSize:u,...f})=>{const[y,T]=(0,t.useState)(Math.max(a,c)),[P,O]=(0,t.useState)(u);(0,t.useEffect)(()=>{a>0&&T(a)},[a]),(0,t.useEffect)(()=>{O(u)},[u]);const b=(0,t.useCallback)(({page:L,pageSize:x})=>{O(x),T(L)},[]);return t.createElement(v,{...f,currentPage:y,currentPageSize:P,setPagination:b})},p=({activePage:a,children:u,className:f,hideFirstAndLastPageLinks:y,hidePreviousAndNextPageLinks:T,onChange:P,pageSize:O,pageSizes:b,showPageSizeSelect:L,totalItems:x,useQueryParameter:W})=>W?t.createElement(d,{className:f,hideFirstAndLastPageLinks:y,hidePreviousAndNextPageLinks:T,onChange:P,pageSizes:b,pageSize:O,showPageSizeSelect:L,totalItems:x},u):t.createElement(g,{className:f,hideFirstAndLastPageLinks:y,hidePreviousAndNextPageLinks:T,onChange:P,pageSizes:b,pageSize:O,showPageSizeSelect:L,totalItems:x,activePage:a},u);p.defaultProps={activePage:1,className:void 0,hideFirstAndLastPageLinks:!1,hidePreviousAndNextPageLinks:!1,pageSizes:o.VZ,pageSize:o.VZ[0],showPageSizeSelect:!0,onChange:void 0,useQueryParameter:!0};const E=p},wl9DHqUO:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("aKyEWaw1"),n=e("TvwLkrAx"),c=e("J6y4/h8P"),v=e("93yMNhQL");const d=(0,c.default)(r.Pagination)(({theme:a})=>(0,c.css)`
  &.pagination {
    font-size: ${a.fonts.size.small};
    margin-top: 10px;
    margin-bottom: 0;

    > li {
      > a,
      > span {
        color: ${a.utils.contrastingColor(a.colors.global.contentBackground)};
        background-color: ${a.colors.global.contentBackground};
        border-color: ${a.colors.variant.light.default};
        border-radius: 0;

        &:hover,
        &:focus {
          color: ${a.utils.contrastingColor(a.colors.variant.lighter.default)};
          background-color: ${a.colors.variant.lighter.default};
          border-color: ${a.colors.variant.light.default};
        }
      }

      &.active > a,
      &.active > span {
        &,
        &:hover,
        &:focus {
          color: ${a.utils.contrastingColor(a.colors.variant.lightest.info)};
          background-color: ${a.colors.variant.lightest.info};
          border-color: ${a.colors.variant.lighter.info};
          z-index: 1;
        }
      }

      &.disabled {
        > a,
        > a:hover,
        > a:focus,
        > span,
        > span:hover,
        > span:focus {
          color: ${a.colors.variant.light.default};
          background-color: ${a.colors.global.contentBackground};
          border-color: ${a.colors.variant.lighter.default};
        }
      }
    }
  }
`),g=(0,n.YM)({WrapperComponent:d,itemTypeToComponent:{[n.iB.PAGE]:({value:a,isActive:u,onClick:f})=>{const y=u?"Active page":`Open page ${a}`;return t.createElement(r.Pagination.Item,{active:u,onClick:f,title:y,"aria-label":y},a)},[n.iB.ELLIPSIS]:({isActive:a,onClick:u})=>{const f="Open following page";return t.createElement(r.Pagination.Ellipsis,{disabled:a,onClick:u,title:f,"aria-label":f},t.createElement(v.Z,{name:"ellipsis-h"}))},[n.iB.FIRST_PAGE_LINK]:({isActive:a,onClick:u})=>{const f="Open first page";return t.createElement(r.Pagination.First,{disabled:a,onClick:u,title:f,"aria-label":f},t.createElement(v.Z,{name:"angle-double-left"}))},[n.iB.PREVIOUS_PAGE_LINK]:({isActive:a,onClick:u})=>{const f="Open previous page";return t.createElement(r.Pagination.Prev,{disabled:a,onClick:u,title:f,"aria-label":f},t.createElement(v.Z,{name:"angle-left"}))},[n.iB.NEXT_PAGE_LINK]:({isActive:a,onClick:u})=>{const f="Open next page";return t.createElement(r.Pagination.Next,{disabled:a,onClick:u,title:f,"aria-label":f},t.createElement(v.Z,{name:"angle-right"}))},[n.iB.LAST_PAGE_LINK]:({isActive:a,onClick:u})=>{const f="Open last page";return t.createElement(r.Pagination.Last,{disabled:a,onClick:u,title:f,"aria-label":f},t.createElement(v.Z,{name:"angle-double-right"}))}}}),p=({currentPage:a,totalPages:u,boundaryPagesRange:f,siblingPagesRange:y,hideEllipsis:T,hidePreviousAndNextPageLinks:P,hideFirstAndLastPageLinks:O,disabled:b,onChange:L})=>u<=1?null:a>u?(console.warn("Graylog Pagination: `currentPage` prop should not be larger than `totalPages` prop."),null):t.createElement(g,{currentPage:a,totalPages:u,boundaryPagesRange:f,siblingPagesRange:y,hideEllipsis:T,hidePreviousAndNextPageLinks:P,hideFirstAndLastPageLinks:O,disabled:b,onChange:L,"data-testid":"graylog-pagination"});p.propTypes={currentPage:o().number.isRequired,totalPages:o().number.isRequired,boundaryPagesRange:o().number,siblingPagesRange:o().number,hideEllipsis:o().bool,hidePreviousAndNextPageLinks:o().bool,hideFirstAndLastPageLinks:o().bool,disabled:o().bool,onChange:o().func},p.defaultProps={boundaryPagesRange:1,siblingPagesRange:1,hideEllipsis:!1,hidePreviousAndNextPageLinks:!1,hideFirstAndLastPageLinks:!1,disabled:!1,onChange:()=>{}};const E=p},e5reO9iR:(M,C,e)=>{"use strict";e.d(C,{$:()=>a,Z:()=>f});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("ww+BtWnX"),c=e.n(n);const v={animated:!1,bsStyle:"info",label:void 0,striped:!1,value:0},d=y=>(0,r.css)`
  box-shadow: ${y} ${({theme:T})=>c()(T.colors.brand.secondary).alpha(.1).css()};
`,g=(0,r.keyframes)`
  from {
    background-position: 40px 0;
  }

  to {
    background-position: 0 0;
  }
`,p=(0,r.css)(({$bsStyle:y,theme:T})=>{if(y)return(0,r.css)`
    background-color: ${T.colors.variant[y]};
    color: ${T.utils.readableColor(T.colors.variant[y])};
`}),E=r.default.div(({theme:y})=>(0,r.css)`
  height: 20px;
  margin-bottom: 20px;
  overflow: hidden;
  background-color: ${y.colors.gray[90]};
  border-radius: 4px;
  ${d("inset 0 1px 2px")}
  display: flex;
  align-items: center;
`),a=r.default.div(({$animated:y,$striped:T,theme:P,value:O})=>{const b=c()(P.colors.global.contentBackground).alpha(.25).css();return(0,r.css)`
    height: 100%;
    font-size: ${P.fonts.size.small};
    text-align: center;
    ${d("inset 0 -1px 0")}
    transition: width 500ms ease-in-out;
    width: ${O}%;
    max-width: 100%;
    text-shadow: 0 1px 2px ${c()(P.colors.gray[10]).alpha(.4).css()}, 2px -1px 3px ${c()(P.colors.gray[100]).alpha(.5).css()};
    ${(y||T)&&(0,r.css)`
      background-image: linear-gradient(
        45deg,
        ${b} 25%,
        transparent 25%,
        transparent 50%,
        ${b} 50%,
        ${b} 75%,
        transparent 75%,
        transparent
      );
      background-size: 40px 40px;
    `}
    ${y&&(0,r.css)`
      animation: ${g} 2s linear infinite;
    `}
    ${p}
`}),u=({bars:y,className:T})=>t.createElement(E,{className:T},y.map((P,O)=>{const{label:b,animated:L,bsStyle:x,striped:W,value:N}={...v,...P};return t.createElement(a,{role:"progressbar","aria-valuenow":N,"aria-valuemin":0,"aria-valuemax":100,"aria-valuetext":b,key:`bar-${O}`,$animated:L,$bsStyle:x,$striped:W,value:N},b)}));u.propTypes={bars:o().arrayOf(o().shape({animated:o().bool,bsStyle:o().string,label:o().string,striped:o().bool,value:o().number})),className:o().string},u.defaultProps={bars:[v],className:void 0};const f=u},fV39EiaT:(M,C,e)=>{"use strict";e.d(C,{Z:()=>T});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("ii0bleBb"),r=e.n(o),n=e("0hhBr0/b"),c=e("kwpLVeht"),v=e("utbMO9sg"),d=e("RCNj0OY4");const g=s.default.div`
  display: flex;
  align-items: center;
`,p=s.default.p`
  flex: 1;
  margin: 0;
  font-weight: bold;
`,E=s.default.div(({$visible:P})=>(0,s.css)`
  white-space: pre-wrap;
  display: ${P?"block":"none"};
  padding-top: 12px;
`),a=(0,s.default)(c.Z)`
  margin-bottom: 6px;
  padding-right: 9px;
`,u=s.default.div`
  width: 90%;
  margin: 0 auto 15px;
`,f={usePublicNotifications:()=>({notifications:void 0,dismissedNotifications:void 0,onDismissPublicNotification:void 0})},y=({readFromConfig:P})=>{var O;const b=(0,n.Z)("customization.publicNotifications"),{usePublicNotifications:L}=((O=b[0])==null?void 0:O.hooks)||f,[x,W]=(0,t.useState)(void 0),{notifications:N,dismissedNotifications:Z,onDismissPublicNotification:j}=L(),z=P?d.Z.publicNotifications():N;if(!z&&!Z&&!j)return null;const ne=Object.keys(z).map(Y=>{if(Z!=null&&Z.has(Y))return null;const ae=()=>{W(x?void 0:Y)},ee=z[Y],{variant:ue,hiddenTitle:H,isActive:ye,isDismissible:we,title:ut,shortMessage:ht,longMessage:Je}=ee;if(!ye)return null;const Re=()=>j(Y);return t.createElement(a,{bsStyle:ue,onDismiss:we?Re:void 0,key:ut,title:!H&&ut},t.createElement(g,null,t.createElement(p,null,ht),Je&&t.createElement(v.Z,{bsStyle:"link",onClick:ae},"Read ",x===Y?"Less":"More")),Je&&t.createElement(E,{$visible:x===Y},Je))}).filter(Y=>Y);return ne.length?t.createElement(u,null,ne):null};y.propTypes={readFromConfig:r().bool},y.defaultProps={readFromConfig:!1};const T=y},rlwexfKi:(M,C,e)=>{"use strict";e.d(C,{Z:()=>a});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("/GOzvPf6"),r=e("uZqmR+ju");const n={id:u=>`Id of the ${u}, which is a unique reference.`,title:u=>`Title of the ${u}.`,name:u=>`Name of the ${u}.`,description:u=>`Short description of the ${u}.`,summary:u=>`Long summary of the ${u}.`},c=(0,s.default)(r.Popover)`
  max-width: 500px;
`,v=(0,s.default)(r.Button)`
  padding: 6px 8px;
`,d=(u,f)=>t.createElement("tr",{key:`row-field-${u}`},t.createElement("td",null,u),t.createElement("td",null,f)),g=t.createElement(t.Fragment,null,t.createElement("p",null,"Find entities with a description containing security:",t.createElement("br",null),t.createElement("code",null,"description:security"),t.createElement("br",null)),t.createElement("p",null,"Find a entities with the id 5f4dfb9c69be46153b9a9a7b:",t.createElement("br",null),t.createElement("code",null,"id:5f4dfb9c69be46153b9a9a7b"),t.createElement("br",null))),p=(u,f,y,T)=>t.createElement(c,{id:"team-search-query-help",title:"Search Syntax Help"},t.createElement("p",null,t.createElement("strong",null,"Available search fields")),t.createElement(r.Table,{condensed:!0},t.createElement("thead",null,t.createElement("tr",null,t.createElement("th",null,"Field"),t.createElement("th",null,"Description"))),t.createElement("tbody",null,u.map(P=>d(P,n[P](T))),Object.keys(f).map(P=>d(P,f[P])))),t.createElement("p",null,t.createElement("strong",null,"Examples")),y||g),E=({commonFields:u,fieldMap:f,example:y,entityName:T})=>t.createElement(o.Ox,{trigger:"click",rootClose:!0,placement:"right",overlay:p(u,f,y,T)},t.createElement(v,{bsStyle:"link"},t.createElement(o.JO,{name:"question-circle"})));E.defaultProps={commonFields:["id","title","description"],fieldMap:{},example:void 0,entityName:"entity"};const a=E},g6WV7s1k:(M,C,e)=>{"use strict";e.d(C,{Z:()=>x});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("V09ZIpgK"),c=e.n(n),v=e("F1COPdMR"),d=e("m4vN8cs/"),g=e("hKs41owK");const p=(0,n.WidthProvider)(n.Responsive),E=W=>{const{width:N}=W;return N?t.createElement(n.Responsive,{...W}):t.createElement(p,{...W})};E.propTypes={width:o().number},E.defaultProps={width:void 0};const a=(0,r.default)(E)(({theme:W})=>(0,r.css)`
  &.locked {
    .widget-drag-handle {
      display: none;
    }
  }

  &.unlocked {
    .react-draggable {
      cursor: move;
    }
  }

  .react-grid-item.react-grid-placeholder {
    background: ${W.colors.variant.info};
  }

  .actions {
    cursor: default;
  }
`),u=175,f=100,y={xxl:12,xl:10,lg:8,md:6,sm:4,xs:2},T={xxl:u*y.xxl,xl:u*y.xl,lg:u*y.lg,md:u*y.md,sm:u*y.sm,xs:u*y.xs},P=(W,N,Z,j)=>{const z=`${j}`;return W||!N?`${z} locked`:Z?z:`${z} unlocked`},O=(W,N)=>{if(typeof N!="function")return;const Z=(0,g.LU)(W.filter(({i:j})=>!j.startsWith("gap")));return N(Z)},b=W=>{const N=[];W.forEach((Z,j)=>{Z.i.startsWith("gap")&&N.push(j)}),N.reverse().forEach(Z=>W.splice(Z,1))},L=({children:W,className:N,columns:Z,draggableHandle:j,isResizable:z,locked:ne,measureBeforeMount:Y,onPositionsChange:ae,onSyncLayout:ee,positions:ue,rowHeight:H,width:ye})=>{const ut=(0,r.useTheme)().spacings.px.xs,ht=(0,t.useCallback)(me=>O(me,ae),[ae]),Je=(0,t.useCallback)(me=>O(me,ee),[ee]),Re=P(ne,z,j,N),le=(0,t.useMemo)(()=>(0,g.q1)(ue),[ue]);return t.createElement(a,{className:Re,width:ye,breakpoints:T,cols:Z,layouts:{xxl:le,xl:le,lg:le,md:le,sm:le,xs:le},rowHeight:H,containerPadding:[0,0],margin:[ut,ut],isResizable:!ne&&z,isDraggable:!ne,measureBeforeMount:Y,draggableCancel:".actions",onDragStart:b,onDragStop:ht,onResizeStart:b,onResizeStop:ht,onLayoutChange:Je,useCSSTransforms:!1,draggableHandle:ne?"":j},W)};L.propTypes={children:o().node.isRequired,className:o().string,onPositionsChange:o().func.isRequired,positions:o().object.isRequired,locked:o().bool,isResizable:o().bool,rowHeight:o().number,columns:o().object,draggableHandle:o().string,measureBeforeMount:o().bool,width:o().number},L.defaultProps={className:void 0,columns:y,isResizable:!0,locked:!1,measureBeforeMount:!1,rowHeight:f,draggableHandle:void 0,width:void 0,onSyncLayout:void 0};const x=L},"4IfE3Ihm":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("IZYxBTgT");const n=({dateTime:v})=>{const d=v!=null?v:new Date,g=(0,r.Qc)(d),p=(0,r.Od)(d,"internal");return t.createElement("time",{dateTime:p,title:p},g)};n.propTypes={dateTime:o().oneOfType([o().string,o().object,o().number])},n.defaultProps={dateTime:void 0};const c=n},TMaijZ0a:(M,C,e)=>{"use strict";e.d(C,{Z:()=>O});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("J6y4/h8P"),n=e("Mx+G+HdB"),c=e.n(n),v=e("dsvqAVKU"),d=e("Ofda/4py");const g=300,p=r.default.div(({$buttonLeftMargin:b})=>(0,r.css)`
  > :not(:last-child) {
    margin-right: ${b}px;
  }

  > * {
    display: inline-block;
    vertical-align: top;
    margin-bottom: 5px;
  }
`),E=r.default.div`
  position: absolute;
  right: 0;
  top: 0;
  display: flex;
  align-items: center;
  min-height: 34px;
  padding-right: 3px;
`,a=r.default.div(({$topMargin:b})=>(0,r.css)`
  margin-top: ${b}px;
`),u=r.default.input(({$queryWidth:b,$feedbackContainerWidth:L})=>(0,r.css)`
  width: ${b}px;
  padding-right: ${L!=null?L:12}px;
`),f=r.default.label`
  margin-right: 5px;
`,y=r.default.div`
  display: inline-block;
  position: relative;
`,T=c()(({query:b,onSearch:L,useLoadingState:x,setLoadingState:W,resetLoadingState:N})=>{x?W().then(()=>{L(b,N)}):L(b)},g),P=({useLoadingState:b,queryHelpComponent:L,queryWidth:x,focusAfterMount:W,children:N,className:Z,placeholder:j,buttonLeftMargin:z,label:ne,onReset:Y,onSearch:ae,wrapperClass:ee,topMargin:ue,onQueryChange:H,query:ye})=>{var we;const[ut,ht]=(0,o.useState)(ye),[Je,Re]=(0,o.useState)(!1),le=(0,o.useRef)(void 0);(0,o.useEffect)(()=>{ht(ye)},[ye]);const me=()=>new Promise(J=>{b&&Re(!0),J()}),re=()=>{b&&Re(!1)},ce=()=>{re(),ht(ye),typeof H=="function"&&H(ye),typeof Y=="function"&&Y()},Q=J=>{J.preventDefault(),J.stopPropagation();const ie=J.target.value;ht(ie),typeof H=="function"&&H(ie),typeof ae=="function"&&T({query:ie,onSearch:ae,useLoadingState:b,setLoadingState:me,resetLoadingState:re})};return o.createElement(a,{className:`${ee} ${Z}`,$topMargin:ue},o.createElement(p,{$buttonLeftMargin:z},o.createElement("div",{className:"form-group"},ne&&o.createElement(f,{htmlFor:"common-search-form-query-input",className:"control-label"},ne),o.createElement(y,{className:"input-container"},o.createElement(u,{id:"common-search-form-query-input",autoFocus:W,onChange:Q,value:ut,placeholder:j,type:"text",$queryWidth:x,className:"query form-control",autoComplete:"off",spellCheck:"false",$feedbackContainerWidth:(we=le.current)==null?void 0:we.scrollWidth}),o.createElement(E,{ref:le},Je&&o.createElement(v.Z,{text:""}),ut&&typeof Y=="function"&&o.createElement(d.Z,{name:"xmark",title:"Reset search",onClick:ce}),L))),N))};P.propTypes={query:s().string,onQueryChange:s().func,onSearch:s().func,onReset:s().func,label:s().string,className:s().string,placeholder:s().string,wrapperClass:s().string,queryWidth:s().any,topMargin:s().number,buttonLeftMargin:s().number,useLoadingState:s().bool,queryHelpComponent:s().element,children:s().oneOfType([s().arrayOf(s().element),s().element]),focusAfterMount:s().bool},P.defaultProps={query:"",className:"",onQueryChange:void 0,onSearch:null,onReset:null,label:null,placeholder:"Enter search query...",wrapperClass:"search",queryWidth:400,topMargin:0,buttonLeftMargin:5,useLoadingState:!1,queryHelpComponent:null,children:null,focusAfterMount:!1};const O=P},QBkUz07U:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g,s:()=>c});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("dsvqAVKU"),r=e("uZqmR+ju");const n=s.default.div`
  display: flex;
  justify-content: space-between;
  align-items: flex-start;

  *:not(:first-child) {
    margin-left: 10px;
  }
`,c=s.default.h2`
  margin-bottom: 5px;
  display: inline;
`,v=(0,s.default)(o.Z)(({theme:p})=>(0,s.css)`
  margin-left: 10px;
  font-size: ${p.fonts.size.h3};
`),d=({children:p,title:E,showLoading:a=!1,headerActions:u,className:f})=>t.createElement(r.Row,{className:`content ${f}`},t.createElement(r.Col,{xs:12},t.createElement(n,null,t.createElement(c,null,E,a&&t.createElement(v,{text:"",delay:0})),u),p));d.defaultProps={className:"",showLoading:!1,headerActions:void 0};const g=d},"3yfJIRSb":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("J6y4/h8P");const o=t.default.div(({$columns:r,theme:n})=>(0,t.css)`
  display: grid;
  grid-template-columns: ${r!=null?r:"1fr 1fr"};
  grid-column-gap: 40px;

  @media (max-width: ${n.breakpoints.max.md}) {
    grid-template-columns: 1fr;
  }
`)},"0nTDFiNq":(M,C,e)=>{"use strict";e.d(C,{K:()=>ne,Z:()=>Fe});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("sjyzE3AD"),n=e("jSc1B5HX"),c=e("/Mx+Tiep"),v=e("+KM7MH1U"),d=e.n(v),g=e("J6y4/h8P"),p=e("fyiLrVbn"),E=e("8RmZXjGq"),a=e("a5C0HdYb");const u=1e3,f=300,y=g.default.div`
  flex: 1 1 auto;
  height: ${Pe=>(Pe==null?void 0:Pe.height)||f}px;
`,T=({data:Pe,index:$e,setSize:Ot,style:ft,containerWidth:Tt})=>{const Lt=(0,t.useRef)(null);return(0,t.useEffect)(()=>{Ot($e,Lt.current.getBoundingClientRect().height)},[Ot,$e,Tt]),t.createElement("div",{ref:Lt,"data-testid":"react-window-list-item",style:ft},Pe[$e])},P=({children:Pe,listRef:$e,...Ot})=>{const ft=(0,t.useRef)(null),Tt=(0,t.useRef)(null),Lt=(0,t.useRef)({}),Be=(0,a.Z)(ft),{width:lt}=Be,mt=(0,t.useCallback)((xt,nn)=>{var Vt;Lt.current={...Lt.current,[xt]:nn},(Vt=($e||Tt).current)==null||Vt.resetAfterIndex(xt)},[$e]),Rt=Object.entries(Pe).reduce((xt,[nn])=>Lt.current[nn]&&xtLt.current[xt]||36,[Lt]);return t.createElement(y,{ref:ft,height:Rt,"data-testid":"infinite-loader-container"},t.createElement(E.S_,{ref:$e||Tt,height:Rt||300,itemCount:Pe.length,itemSize:zt,itemData:Pe,width:lt,...Ot},({data:xt,index:nn,style:Vt})=>t.createElement(T,{data:xt,style:Vt,index:nn,setSize:mt,containerWidth:lt})))};P.defaultProps={listRef:void 0,onItemsRendered:void 0};const b=({children:Pe,innerProps:$e,...Ot})=>!(Pe!=null&&Pe.length)||Pe.lengtht.createElement(N,{key:"noOptions",className:"menu-notice menu-notice--no-options"},"No Options"),z=({children:Pe,selectProps:{loadOptions:$e,total:Ot}})=>{const ft=Pe!=null&&Pe.length?Pe:[Z()];return t.createElement(W.Z,{isItemLoaded:Tt=>Ttt.createElement(P,{listRef:Lt,onItemsRendered:Tt},ft))},ne="common-select-control",Y=({children:Pe,...$e})=>t.createElement(r.c.MultiValueRemove,{...$e},Pe),ae=()=>null,ee=Pe=>{const{children:$e=t.createElement(L.Z,{name:"caret-down"}),getStyles:Ot,innerProps:{ref:ft,...Tt}}=Pe;return t.createElement("div",{style:Ot("dropdownIndicator",Pe),ref:ft,...Tt},$e)},ue=({children:Pe,...$e})=>t.createElement(r.c.Control,{...$e,className:ne},Pe),H=Pe=>$e=>{const{data:Ot,isSelected:ft}=$e;return t.createElement(r.c.Option,{...$e},Pe(Ot,ft))},ye=Pe=>$e=>{const{data:Ot}=$e;return t.createElement(r.c.SingleValue,{...$e},Pe(Ot))},we=Pe=>$e=>t.createElement(r.c.Input,{...$e,...Pe}),ut=(Pe,$e)=>({...Pe,padding:"0px",fontSize:"150%",marginRight:"1rem",transform:$e.selectProps.menuIsOpen&&"rotate(180deg)"}),ht=Pe=>({...Pe,padding:"5px"}),Je=({theme:Pe})=>$e=>({...$e,border:`1px solid ${Pe.colors.variant.lighter.info}`}),Re=({theme:Pe})=>$e=>({...$e,padding:"2px 5px",fontSize:Pe.fonts.size.small}),le=({theme:Pe})=>$e=>({...$e,borderLeft:`1px solid ${Pe.colors.variant.lighter.info}`,paddingLeft:"5px",paddingRight:"5px",borderRadius:"0"}),me={minHeight:"29px",height:"29px"},re={minHeight:"34px"},ce=Pe=>({...Pe,zIndex:5}),Q=Pe=>({...Pe,zIndex:"auto"}),J=({theme:Pe})=>$e=>({...$e,lineHeight:"28px",fontFamily:Pe.fonts.family.body,fontSize:Pe.fonts.size.body,fontWeight:400}),ie=({theme:Pe})=>$e=>({...$e,color:Pe.colors.input.placeholder,lineHeight:"28px",fontFamily:Pe.fonts.family.body,fontSize:Pe.fonts.size.body,fontWeight:400,whiteSpace:"nowrap",textOverflow:"ellipsis",overflow:"hidden",maxWidth:"100%",paddingRight:"20px"}),ge=({size:Pe,theme:$e})=>(Ot,{isFocused:ft})=>{const Tt=ft?1:Ot.borderWidth,Lt=ft?0:Ot.outline,Be=ft?$e.colors.input.boxShadow:null;return{...Ot,...Pe==="small"?me:re,borderWidth:Tt,boxShadow:Be,outline:Lt,borderRadius:x.L$,alignItems:"center"}},fe=({size:Pe})=>$e=>({...$e,padding:Pe==="small"?"0 8px":"2px 10px"}),Ce={DropdownIndicator:ee,MultiValueRemove:Y,IndicatorSeparator:ae,Control:ue},Oe=({size:Pe,theme:$e})=>({dropdownIndicator:ut,clearIndicator:ht,multiValue:Je({theme:$e}),multiValueLabel:Re({theme:$e}),multiValueRemove:le({theme:$e}),menu:ce,menuPortal:Q,singleValue:J({theme:$e}),placeholder:ie({theme:$e}),control:ge({size:Pe,theme:$e}),valueContainer:fe({size:Pe})}),nt=(Pe,$e,Ot,ft)=>{const Tt={};return Pe&&(Tt.Input=we(Pe)),$e&&(Tt.Option=H($e)),Ot&&(Tt.SingleValue=ye(Ot)),Tt.MenuList=ft?z:b,Tt};class et extends t.Component{constructor($e){super($e),this.getValue=()=>{const{value:lt}=this.state;return lt},this.clearValue=()=>{this.setState({value:void 0})},this._extractOptionValue=lt=>{const{multi:mt,valueKey:Rt,delimiter:zt}=this.props;return lt?mt&&Array.isArray(lt)?lt.map(xt=>xt[Rt]).join(zt):lt[Rt||""]:""},this._onChange=lt=>{const mt=this._extractOptionValue(lt);this.props.persistSelection&&this.setState({value:mt});const{onChange:Rt=()=>{}}=this.props;Rt(mt)},this._formatInputValue=lt=>{const{options:mt,displayKey:Rt,valueKey:zt,delimiter:xt,allowCreate:nn,async:Vt}=this.props;return lt==null||typeof lt=="string"&<===""?[]:(nn||Vt)&&typeof lt=="string"?lt.split(xt).map(jn=>{const Mt={[zt]:jn,[Rt]:jn};return mt.find(rt=>rt[zt]===jn)||Mt}):(typeof lt=="string"?(lt!=null?lt:"").split(xt):[lt]).map(jn=>{const Mt=mt.find(On=>On[zt||""]===jn);return Mt!=null?Mt:{[Rt]:String(lt),[zt]:lt}})},this._selectTheme=lt=>{const{theme:mt}=this.props;return{...lt,colors:{...lt.colors,primary:mt.colors.input.borderFocus,primary75:mt.colors.variant.light.default,primary50:mt.colors.variant.lighter.default,primary25:mt.colors.variant.lightest.default,danger:mt.colors.variant.darker.info,dangerLight:mt.colors.variant.lighter.info,neutral0:mt.colors.input.background,neutral5:mt.colors.input.backgroundDisabled,neutral10:mt.colors.variant.lightest.info,neutral20:mt.colors.input.border,neutral30:mt.colors.gray[70],neutral40:mt.colors.gray[60],neutral50:mt.colors.gray[50],neutral60:mt.colors.gray[40],neutral70:mt.colors.gray[30],neutral80:mt.colors.gray[20],neutral90:mt.colors.gray[10]}}},this.createCustomFilter=lt=>{const{matchProp:mt,ignoreAccents:Rt}=this.props,zt={ignoreAccents:Rt};return mt==="any"?(0,n.c)(zt):(0,n.c)({...zt,stringify:lt})};const{inputProps:Ot,optionRenderer:ft,value:Tt,valueRenderer:Lt,async:Be}=$e;this.state={customComponents:nt(Ot,ft,Lt,Be),value:Tt}}UNSAFE_componentWillReceiveProps($e){const{inputProps:Ot,optionRenderer:ft,value:Tt,valueRenderer:Lt,async:Be}=this.props;Tt!==$e.value&&this.setState({value:$e.value}),(!d()(Ot,$e.inputProps)||ft!==$e.optionRenderer||Lt!==$e.valueRenderer)&&this.setState({customComponents:nt(Ot,ft,Lt,Be)})}render(){const{allowCreate:$e=!1,displayKey:Ot,components:ft,valueKey:Tt,onReactSelectChange:Lt,size:Be,theme:lt}=this.props,{customComponents:mt,value:Rt}=this.state,zt=this._formatInputValue(Rt),{multi:xt,disabled:nn,clearable:Vt,inputProps:jn,matchProp:Mt,optionRenderer:On,valueRenderer:rt,menuPortalTarget:Bn,async:de,total:pt,onInputChange:Gt,loadOptions:gn,...Jt}=this.props,An=no=>no[Mt],xe=this.createCustomFilter(An),Pn={...Ce,...ft,...mt},sn={...Jt,onChange:Lt||this._onChange,onInputChange:Gt,async:de,isMulti:xt,isDisabled:nn,isClearable:Vt,loadOptions:gn,getOptionLabel:no=>no[Ot]||no.label,getOptionValue:no=>no[Tt],filterOption:xe,components:Pn,menuPortalTarget:Bn,isOptionDisabled:no=>!!no.disabled,styles:Oe({size:Be,theme:lt}),theme:this._selectTheme,total:pt,value:zt};return $e?t.createElement(p.Z,{ref:Jt.forwardedRef,...sn}):t.createElement(c.ZP,{ref:Jt.forwardedRef,...sn})}}et.propTypes={allowCreate:o().bool,className:o().string,clearable:o().bool,components:o().objectOf(o().elementType),delimiter:o().string,disabled:o().bool,displayKey:o().string,id:o().string,inputId:o().string,ignoreAccents:o().bool,inputProps:o().object,matchProp:o().oneOf(["any","label","value"]),multi:o().bool,name:o().string,onBlur:o().func,onChange:o().func.isRequired,onInputChange:o().func,options:o().array.isRequired,optionRenderer:o().func,required:o().bool,size:o().oneOf(["normal","small"]),theme:o().object.isRequired,value:o().oneOfType([o().string,o().number,o().object,o().arrayOf(o().object)]),valueKey:o().string,valueRenderer:o().func,addLabelText:o().string,autoFocus:o().bool,onReactSelectChange:o().func,placeholder:o().string,persistSelection:o().bool,menuPlacement:o().oneOf(["top","bottom","auto"]),maxMenuHeight:o().number,async:o().bool,total:o().number,loadOptions:o().func},et.defaultProps={addLabelText:void 0,allowCreate:!1,autoFocus:!1,className:void 0,clearable:!0,components:null,delimiter:",",disabled:!1,displayKey:"label",persistSelection:!0,id:void 0,ignoreAccents:!0,inputId:void 0,onBlur:void 0,inputProps:void 0,matchProp:"any",multi:!1,name:void 0,openMenuOnFocus:void 0,onReactSelectChange:void 0,onMenuClose:void 0,optionRenderer:void 0,placeholder:void 0,required:!1,size:"normal",value:void 0,valueKey:"value",valueRenderer:void 0,menuPlacement:"auto",maxMenuHeight:300,async:!1,total:0,onInputChange:void 0,loadOptions:void 0,menuPortalTarget:void 0,forwardedRef:void 0};const Fe=(0,g.withTheme)(et)},hhdCSTZj:(M,C,e)=>{"use strict";e.d(C,{K:()=>t.K,Z:()=>s});var t=e("0nTDFiNq");const s=t.Z},yKXoRDZT:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("J6y4/h8P"),s=e("Z7aTuO5B"),o=e("93yMNhQL");const r=t.default.button(({theme:d})=>(0,t.css)`
  border: 0;
  background: transparent;
  padding: 5px;
  cursor: pointer;
  position: relative;
  color: ${d.colors.gray[70]};

  &.active {
    color: ${d.colors.gray[20]};
  }
`),n=t.default.span(({theme:d})=>(0,t.css)`
  position: absolute;
  top: 0;
  right: 0;
  font-size: ${d.fonts.size.small};
  font-weight: 600;
`),c=({activeDirection:d,onChange:g,title:p,order:E,ascId:a,descId:u,className:f})=>{const y=(0,s.useCallback)(()=>g(d),[d,g]),T=d===a&&d!==u?"arrow-up-short-wide":"arrow-down-wide-short",P=!!d;return s.createElement(r,{className:`${f} ${P?"active":""}`,title:p,type:"button","aria-label":p,onClick:y},s.createElement(o.Z,{name:T,"data-testid":"sort-icon-svg"}),E&&s.createElement(n,null,E))};c.defaultProps={title:"Sort",order:void 0,ascId:"Ascending",descId:"Descending",className:""};const v=c},"K/dyB2Jn":(M,C,e)=>{"use strict";e.d(C,{Z:()=>L});var t=e("Z7aTuO5B"),s=e("GWCZ8ww5"),o=e("ii0bleBb"),r=e.n(o),n=e("J6y4/h8P"),c=e("/GOzvPf6"),v=e("uZqmR+ju");const d=(0,n.default)(v.ListGroupItem)(({$alignItemContent:x})=>(0,n.css)`
  display: flex;
  align-items: ${x};
`),g=n.default.div`
  margin-right: 5px;
`,p=(0,t.forwardRef)(({alignItemContent:x,item:W,index:N,className:Z,customListItemRender:j,customContentRender:z,disableDragging:ne,draggableProps:Y,dragHandleProps:ae},ee)=>{const ue=z?z({item:W,index:N}):W.title;return j?t.createElement(t.Fragment,null,j({className:Z,disableDragging:ne,draggableProps:Y,dragHandleProps:ae,index:N,item:W,ref:ee})):t.createElement(d,{$alignItemContent:x,ref:ee,className:Z,containerProps:{...Y}},!ne&&t.createElement(g,{...ae,"data-testid":`sortable-item-${W.id}`},t.createElement(c.JO,{name:"bars"})),ue)});p.defaultProps={alignItemContent:"flex-start",className:void 0,disableDragging:!1,customListItemRender:void 0,customContentRender:void 0};const E=p,a=(0,n.default)(E)(({$isDragging:x})=>(0,n.css)`
  box-shadow: ${x?"rgba(0, 0, 0, 0.24) 0px 3px 8px":"none"};
`),u=({alignItemContent:x,className:W,customContentRender:N,customListItemRender:Z,disableDragging:j,displayOverlayInPortal:z,index:ne,item:Y})=>t.createElement(s._l,{draggableId:Y.id,index:ne},({draggableProps:ae,dragHandleProps:ee,innerRef:ue},{isDragging:H})=>{const ye=t.createElement(a,{alignItemContent:x,item:Y,index:ne,className:W,ref:ue,customContentRender:N,customListItemRender:Z,disableDragging:j,displayOverlayInPortal:z,draggableProps:ae,dragHandleProps:ee,$isDragging:H});return z&&H?t.createElement(c.Uv,null,ye):ye});u.defaultProps={alignItemContent:void 0,className:void 0,customContentRender:void 0,customListItemRender:void 0,disableDragging:!1};const f=u,y=({alignItemContent:x,customContentRender:W,customListItemRender:N,disableDragging:Z,displayOverlayInPortal:j,items:z=[]})=>t.createElement(t.Fragment,null,z.map((ne,Y)=>t.createElement(f,{alignItemContent:x,item:ne,index:Y,key:ne.id,customContentRender:W,customListItemRender:N,disableDragging:Z,displayOverlayInPortal:j})));y.defaultProps={displayOverlayInPortal:!1,alignItemContent:void 0,disableDragging:!1,customContentRender:void 0,customListItemRender:void 0};const T=t.memo(y),P=(x,W,N)=>{const Z=Array.from(x),[j]=Z.splice(W,1);return Z.splice(N,0,j),Z},O=({alignItemContent:x,customContentRender:W,customListItemRender:N,disableDragging:Z,displayOverlayInPortal:j,items:z,onMoveItem:ne})=>{const Y=(0,t.useCallback)(ae=>{if(ae.destination&&ae.source.index!==ae.destination.index){const ee=P(z,ae.source.index,ae.destination.index);ne(ee,ae.source.index,ae.destination.index)}},[z,ne]);return t.createElement(s.Z5,{onDragEnd:Y},t.createElement(s.bK,{droppableId:"droppable"},({droppableProps:ae,innerRef:ee,placeholder:ue})=>t.createElement("div",{...ae,ref:ee},t.createElement(T,{alignItemContent:x,items:z,disableDragging:Z,displayOverlayInPortal:j,customContentRender:W,customListItemRender:N}),ue)))};O.propTypes={disableDragging:r().bool,items:r().arrayOf(r().object),onMoveItem:r().func.isRequired,customContentRender:r().func,customListItemRender:r().func},O.defaultProps={alignItemContent:void 0,items:[],disableDragging:!1,displayOverlayInPortal:!1,customContentRender:void 0,customListItemRender:void 0};const L=O},dsvqAVKU:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("93yMNhQL"),c=e("rRqvmggl");const v=(0,r.default)(n.Z)(({$displayMargin:p})=>p?"margin-right: 6px;":""),d=({name:p,text:E,delay:a,...u})=>t.createElement(c.Z,{delay:a},t.createElement(v,{...u,name:p,$displayMargin:!!(E!=null&&E.trim()),spin:!0}),E);d.propTypes={delay:o().number,name:o().string,text:o().string},d.defaultProps={name:"spinner",text:"Loading...",delay:200};const g=d},M04itGxI:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("J6y4/h8P");const o=s.default.div`
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
`,r=({children:c,titleOverride:v,className:d})=>t.createElement(o,{title:v||c,className:d},c);r.defaultProps={className:void 0,titleOverride:void 0};const n=r},ATOIS62c:(M,C,e)=>{"use strict";e.d(C,{Z:()=>N,l:()=>x});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("D4SbLiE/"),n=e.n(r),c=e("WgCNywL/"),v=e.n(c),d=e("+KM7MH1U"),g=e.n(d),p=e("w7+AQV2V"),E=e.n(p),a=e("/74ZcNtc"),u=e.n(a),f=e("9oVghaOd"),y=e.n(f),T=e("uZqmR+ju"),P=e("S6FuRS7B");const O=["NANOSECONDS","MICROSECONDS","MILLISECONDS","SECONDS","MINUTES","HOURS","DAYS","MONTHS","YEARS"],b=["NANOSECONDS","MICROSECONDS","MILLISECONDS","SECONDS","MINUTES","HOURS","DAYS"],L=s().oneOf(O),x=(Z,j)=>{if(Z===void 0)return{duration:1,unit:E()(j)};const z=y().duration(Z),ne=j.find(ae=>{const ee=z.as(ae);return u()(ee)&&ee!==0})||E()(j);return{duration:z.as(ne),unit:ne}},N=n()({displayName:"TimeUnitInput",propTypes:{update:s().func.isRequired,label:s().string,help:s().string,required:s().bool,enabled:s().bool,defaultEnabled:s().bool,value:s().number,defaultValue:s().number,unit:L,units:s().arrayOf(L),labelClassName:s().string,wrapperClassName:s().string,hideCheckbox:s().bool,pullRight:s().bool,clearable:s().bool,name:s().string,unitName:s().string},getDefaultProps(){return{defaultValue:1,value:void 0,unit:"SECONDS",units:b,label:"",help:"",name:null,unitName:null,required:!1,enabled:void 0,defaultEnabled:!1,labelClassName:void 0,wrapperClassName:void 0,hideCheckbox:!1,pullRight:!1,clearable:!1}},getInitialState(){const{defaultEnabled:Z,enabled:j,units:z}=this.props;return{enabled:v()(j,Z),unitOptions:this._getUnitOptions(z)}},UNSAFE_componentWillReceiveProps(Z){const{units:j}=this.props;g()(j,Z.units)||this.setState({unitOptions:this._getUnitOptions(Z.units)})},_getEffectiveValue(){const{defaultValue:Z,value:j,clearable:z}=this.props;return z?j:v()(j,Z)},_getUnitOptions(Z){return O.filter(j=>Z.includes(j)).map(j=>({value:j,label:j.toLowerCase()}))},_isChecked(){const{required:Z,enabled:j}=this.props;if(Z)return Z;const{enabled:z}=this.state;return v()(j,z)},_propagateInput(Z){const{update:j,unit:z}=this.props,Y={...{value:this._getEffectiveValue(),unit:z,checked:this._isChecked()},...Z};j(Y.value,Y.unit,Y.checked)},_onToggleEnable(Z){const j=Z.target.checked;this.setState({enabled:j}),this._propagateInput({checked:j})},_onUpdate(Z){const{defaultValue:j,clearable:z}=this.props;let ne;z?ne=P.n6(Z.target):ne=v()(P.n6(Z.target),j),this._propagateInput({value:ne})},_onUnitSelect(Z){this._propagateInput({unit:Z})},render(){const{unitOptions:Z}=this.state,{label:j,wrapperClassName:z,help:ne,labelClassName:Y,unit:ae,required:ee,hideCheckbox:ue,pullRight:H}=this.props,ye=Z.map(ut=>o.createElement(T.MenuItem,{key:ut.value,onSelect:()=>this._onUnitSelect(ut.value),active:ae===ut.value},ut.label)),we=o.createElement(T.InputGroup.Addon,null,o.createElement("input",{type:"checkbox",checked:this._isChecked(),onChange:this._onToggleEnable}));return o.createElement(T.FormGroup,null,j&&o.createElement(T.ControlLabel,{className:Y},j),o.createElement(T.InputWrapper,{className:z},o.createElement(T.InputGroup,null,!ee&&!ue&&we,o.createElement(T.FormControl,{type:"number",name:this.props.name,disabled:!this._isChecked(),"aria-label":j||"Time unit input",onChange:this._onUpdate,value:v()(this._getEffectiveValue(),"")}),o.createElement(T.DropdownButton,{componentClass:T.InputGroup.Button,id:"input-dropdown-addon",name:this.props.unitName,pullRight:H,title:Z.filter(ut=>ut.value===ae)[0].label,disabled:!this._isChecked()},ye)),ne&&o.createElement(T.HelpBlock,null,ne)))}})},"Ex+j8X3w":(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("O/XpfGnR"),n=e("IZYxBTgT");const c=({dateTime:d,field:g,format:p,render:E,tz:a,className:u})=>{const{formatTime:f}=(0,r.Z)(),y=d!=null?d:new Date,T=a?(0,n.Od)(y,p,a):f(y,p),P=(0,n.Od)(y,"internal");return o.createElement("time",{dateTime:P,title:P,className:u},o.createElement(E,{value:T,field:g}))};c.propTypes={dateTime:s().oneOfType([s().string,s().object,s().number]),format:s().string,field:s().string,tz:s().string,render:s().func},c.defaultProps={dateTime:void 0,field:void 0,format:"default",render:({value:d})=>d,tz:void 0,className:void 0};const v=c},Z6NUVhuV:(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("VPaD/Np4"),n=e.n(r),c=e("+KM7MH1U"),v=e.n(c),d=e("uZqmR+ju"),g=e("YzrsREPQ"),p=Object.defineProperty,E=(y,T,P)=>T in y?p(y,T,{enumerable:!0,configurable:!0,writable:!0,value:P}):y[T]=P,a=(y,T,P)=>(E(y,typeof T!="symbol"?T+"":T,P),P);class u extends o.Component{constructor(T){super(T),a(this,"_onSearchTextChanged",O=>{O.preventDefault(),O.stopPropagation(),this.setState({filterText:this.typeAheadInput.getValue()},this.filterData)}),a(this,"_onFilterAdded",(O,b)=>{const{filters:L}=this.state,{displayKey:x}=this.props;this.setState({filters:L.add(b[x]),filterText:""},this.filterData),this.typeAheadInput.clear()}),a(this,"_onFilterRemoved",O=>{const{filters:b}=this.state;O.preventDefault(),this.setState({filters:b.delete(O.target.getAttribute("data-target"))},this.filterData)}),a(this,"_matchFilters",O=>{const{filters:b,filterByKey:L}=this.state,{filterSuggestionAccessor:x}=this.props;return b.every(W=>{let N=O[L];return x?N=N.map(Z=>Z[x].toLocaleLowerCase()):N=N.map(Z=>Z.toLocaleLowerCase()),N.indexOf(W.toLocaleLowerCase())!==-1},this)}),a(this,"_matchStringSearch",O=>{const{filterText:b}=this.state,{searchInKeys:L}=this.props;return L.some(x=>{const W=O[x],N=b;if(W===null)return!1;const Z=(j,z)=>typeof j>"u"?!1:j.toLocaleLowerCase().indexOf(z.toLocaleLowerCase())!==-1;return typeof W=="object"?W.some(j=>Z(j,N)):Z(W,N)},this)}),a(this,"_resetFilters",()=>{this.typeAheadInput.clear(),this.setState({filterText:"",filters:n().OrderedSet()},this.filterData)}),a(this,"filterData",()=>{const{filterData:O,data:b,onDataFiltered:L}=this.props,{filterText:x}=this.state;if(typeof O=="function")return O(b);const W=b.filter(N=>this._matchFilters(N)&&this._matchStringSearch(N),this);return L(W,x),!0});const{filterBy:P}=this.props;this.state={filterText:"",filters:n().OrderedSet(),filterByKey:`${P}s`}}componentDidUpdate(T){const{data:P}=this.props;v()(T.data,P)||this.filterData()}render(){const{filters:T,filterText:P}=this.state,{id:O,label:b,displayKey:L,filterBy:x,filterSuggestionAccessor:W,filterSuggestions:N}=this.props,Z=T.map(z=>o.createElement("li",{key:`li-${z}`},o.createElement("span",{className:"pill label label-default"},x,": ",z,o.createElement("button",{type:"button",className:"tag-remove","data-target":z,onClick:this._onFilterRemoved,"aria-label":`Remove filter ${z}`}))));let j;return W?j=N.map(z=>z[W].toLocaleLowerCase()):j=N.map(z=>z.toLocaleLowerCase()),j.filter(z=>!T.includes(z)),o.createElement("div",{className:"filter"},o.createElement("form",{className:"form-inline",onSubmit:this._onSearchTextChanged,style:{display:"inline-flex",alignItems:"flex-end"}},o.createElement(g.Z,{id:O,ref:z=>{this.typeAheadInput=z},onSuggestionSelected:this._onFilterAdded,formGroupClassName:"",suggestionText:`Filter by ${x}: `,suggestions:j,label:b,displayKey:L}),o.createElement(d.Button,{type:"submit",style:{marginLeft:5}},"Filter"),o.createElement(d.Button,{type:"button",style:{marginLeft:5},onClick:this._resetFilters,disabled:T.count()===0&&P===""},"Reset")),o.createElement("ul",{className:"pill-list"},Z))}}a(u,"propTypes",{id:s().string,data:s().array,displayKey:s().string,filterBy:s().string,filterData:s().func,filterSuggestionAccessor:s().string,filterSuggestions:s().array,label:s().string,onDataFiltered:s().func,searchInKeys:s().array}),a(u,"defaultProps",{id:"",data:[],displayKey:"",filterBy:"",filterData:void 0,filterSuggestionAccessor:"",filterSuggestions:[],label:"",onDataFiltered:void 0,searchInKeys:[]});const f=u},YzrsREPQ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>b});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("zKLlqmvB"),n=e("dAwvwWxL"),c=e.n(n),v=e("kqAR+wt5"),d=e.n(v),g=e("4ukn9ADr"),p=e.n(g),E=e("J6y4/h8P"),a=e("jsQWU+f2"),u=e("uZqmR+ju"),f=Object.defineProperty,y=(L,x,W)=>x in L?f(L,x,{enumerable:!0,configurable:!0,writable:!0,value:W}):L[x]=W,T=(L,x,W)=>(y(L,typeof x!="symbol"?x+"":x,W),W);const P=(0,E.default)(u.Input)`
  input&.tt-hint {
    background-color: transparent !important;
  }
`;class O extends o.Component{constructor(){super(...arguments),T(this,"getValue",()=>d()(this.fieldInput).typeahead("val")),T(this,"clear",()=>{d()(this.fieldInput).typeahead("val","")}),T(this,"_destroyTypeahead",()=>{d()(this.fieldInput).typeahead("destroy"),d()(this.fieldFormGroup).off("typeahead:select typeahead:autocomplete")}),T(this,"_updateTypeahead",({suggestions:x,displayKey:W,suggestionText:N,onTypeaheadLoaded:Z,onSuggestionSelected:j})=>{this.fieldInput=this.fieldInputElem.getInputDOMNode(),this.fieldFormGroup=r.findDOMNode(this.fieldInputElem);const z=d()(this.fieldInput);z.typeahead({hint:!0,highlight:!0,minLength:1},{name:"dataset-name",displayKey:W,source:a.Z.substringMatcher(x,W,6),templates:{suggestion:ne=>N?`
${c()(N)} ${c()(ne[W])}
`:`
${c()(ne[W])}
`}}),typeof Z=="function"&&(Z(),z.typeahead("close")),d()(this.fieldFormGroup).on("typeahead:select typeahead:autocomplete",(ne,Y)=>{j&&j(ne,Y)})})}componentDidMount(){const{suggestions:x,displayKey:W,suggestionText:N,onTypeaheadLoaded:Z,onSuggestionSelected:j}=this.props;this._updateTypeahead({suggestions:x,displayKey:W,suggestionText:N,onTypeaheadLoaded:Z,onSuggestionSelected:j})}UNSAFE_componentWillReceiveProps(x){this._destroyTypeahead(),this._updateTypeahead(x)}componentWillUnmount(){this._destroyTypeahead()}render(){const{id:x,label:W,onKeyPress:N,formGroupClassName:Z}=this.props;return o.createElement(P,{id:x,type:"text",ref:j=>{this.fieldInputElem=j},wrapperClassName:"typeahead-wrapper",formGroupClassName:Z,label:W,onKeyPress:N})}}T(O,"propTypes",{id:s().string.isRequired,label:s().string.isRequired,onKeyPress:s().func,displayKey:s().string,formGroupClassName:s().string,suggestions:s().array,suggestionText:s().string,onTypeaheadLoaded:s().func,onSuggestionSelected:s().func}),T(O,"defaultProps",{displayKey:"suggestion",formGroupClassName:void 0,onKeyPress:()=>{},onTypeaheadLoaded:()=>{},onSuggestionSelected:()=>{},suggestions:[],suggestionText:void 0});const b=O},"1e+nFvZs":(M,C,e)=>{"use strict";e.d(C,{Z:()=>T});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("alU4HbhK"),n=e.n(r),c=e("J6y4/h8P"),v=e("uZqmR+ju"),d=e("93yMNhQL");const g=(0,c.default)(v.Col)(({theme:P})=>(0,c.css)` border-right: ${P.colors.gray[80]} solid 1px; `),p=(0,c.default)(v.Col)` margin-bottom: 15px; `,E=(0,c.default)(v.Nav)(({theme:P})=>(0,c.css)` &.nav { > li { border: 1px solid ${P.colors.variant.lighter.default}; border-left: 0; &:first-child { border-left: 1px solid ${P.colors.variant.lighter.default}; border-radius: 4px 0 0 4px; > a { border-radius: 4px 0 0 4px; } } &:last-child { border-radius: 0 4px 4px 0; > a { border-radius: 0 4px 4px 0; } } &:not(:last-child) > a { &::after { transition: background-color 150ms ease-in-out; background-color: ${P.colors.global.contentBackground}; border-color: ${P.colors.variant.lighter.default}; border-style: solid; border-width: 0 1px 1px 0; content: ''; display: block; height: 15px; position: absolute; right: -1px; top: 50%; transform: translateY(-50%) translateX(50%) rotate(-45deg); width: 15px; z-index: 2; } &:hover::after { background-color: ${P.colors.variant.lightest.default}; } } &.active a { &, &:hover, &::after, &:hover::after { background-color: ${P.colors.global.link}; } } > a { border-radius: 0; } } } @media (max-width: ${P.breakpoints.max.md}) { &.nav { > li { border-right: 0; border-left: 0; &:last-child a, &:first-child a { border-radius: 0; } &:not(:last-child) { border-bottom: 0; } &:not(:last-child) > a { &::after { bottom: 0; left: 50%; top: auto; width: 10px; height: 10px; transform: translateY(50%) translateX(-50%) rotate(45deg); } } } &.nav-justified > li > a { margin-bottom: 0; } } } `),a=(0,c.default)(v.ButtonToolbar)` padding: 7px; `,u=(P,O)=>P==null?!1:n()(O,{key:P}),f=(P,O)=>{P!=null&&(u(P,O)||console.warn(`activeStep ${P} is not a key in any element of the 'steps' prop!`))};class y extends t.Component{constructor(O){super(O),this._getSelectedStep=()=>{const{activeStep:b,steps:L}=this.props,{selectedStep:x}=this.state;return u(b,L)?b:x},this._wizardChanged=b=>{const{activeStep:L,onStepChange:x}=this.props;x(b),L||this.setState({selectedStep:b})},this._disableButton=b=>{const{steps:L}=this.props,x=this._getSelectedStep(),W=L.length,N=b==="next"?W-1:0,Z=L.findIndex(ne=>ne.key===this._getSelectedStep()),j=b==="next"?Z+1:Z-1,z=L[j];return L[N].key===x||(z==null?void 0:z.disabled)},this._onNext=()=>{const{steps:b}=this.props;this._wizardChanged(b[this._getSelectedIndex()+1].key)},this._onPrevious=()=>{const{steps:b}=this.props;this._wizardChanged(b[this._getSelectedIndex()-1].key)},this._getSelectedIndex=()=>{const{steps:b}=this.props,L=this._getSelectedStep();return b.map(x=>x.key).indexOf(L)},this._renderVerticalStepNav=()=>{const{justified:b,steps:L,hidePreviousNextButtons:x}=this.props,W=this._getSelectedStep();return t.createElement(g,{md:2},t.createElement(v.Nav,{stacked:!0,bsStyle:"pills",activeKey:W,onSelect:this._wizardChanged,justified:b},L.map(N=>t.createElement(v.NavItem,{key:N.key,eventKey:N.key,disabled:N.disabled},N.title))),!x&&t.createElement(t.Fragment,null,t.createElement("br",null),t.createElement(v.Row,null,t.createElement(v.Col,{xs:6},t.createElement(v.Button,{onClick:this._onPrevious,bsSize:"small",bsStyle:"info",disabled:this._disableButton("previous")},"Previous")),t.createElement(v.Col,{className:"text-right",xs:6},t.createElement(v.Button,{onClick:this._onNext,bsSize:"small",bsStyle:"info",disabled:this._disableButton("next")},"Next")))))},this._renderHorizontalStepNav=()=>{const b=this._getSelectedStep(),{justified:L,steps:x,hidePreviousNextButtons:W}=this.props;return t.createElement(p,{sm:12},!W&&t.createElement("div",{className:"pull-right"},t.createElement(a,null,t.createElement(v.Button,{onClick:this._onPrevious,bsSize:"xsmall",bsStyle:"info",disabled:this._disableButton("previous")},t.createElement(d.Z,{name:"caret-left"})),t.createElement(v.Button,{onClick:this._onNext,bsSize:"xsmall",bsStyle:"info",disabled:this._disableButton("next")},t.createElement(d.Z,{name:"caret-right"})))),t.createElement(E,{bsStyle:"pills",activeKey:b,onSelect:this._wizardChanged,justified:L},x.map(N=>t.createElement(v.NavItem,{key:N.key,eventKey:N.key,disabled:N.disabled},N.title))))},f(O.activeStep,O.steps),this.state={selectedStep:O.steps[0].key}}componentDidUpdate(){const{activeStep:O,steps:b}=this.props;f(O,b)}render(){const{steps:O,horizontal:b,containerClassName:L,children:x}=this.props;let W;x?W=7:W=b?12:10;const N=b?5:3;return t.createElement(v.Row,{className:L},b?this._renderHorizontalStepNav():this._renderVerticalStepNav(),t.createElement(v.Col,{md:W},O[this._getSelectedIndex()].component),x&&t.createElement(v.Col,{md:N},x))}}y.propTypes={steps:o().arrayOf(o().object).isRequired,activeStep:o().oneOfType([o().string,o().number]),onStepChange:o().func,children:o().element,horizontal:o().bool,justified:o().bool,containerClassName:o().string,hidePreviousNextButtons:o().bool},y.defaultProps={children:void 0,activeStep:void 0,onStepChange:()=>{},horizontal:!1,justified:!1,containerClassName:"content",hidePreviousNextButtons:!1};const T=y},UEhMhaHZ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("0jxx8Inx");const r=s.default.div(({$size:p,$gap:E,theme:a})=>(0,s.css)` flex: 0 0 ${p!=null?p:"24%"}; min-width: 0; min-height: 100px; margin-right: ${E!=null?E:a.spacings.sm}; position: relative; `),n=({children:p,size:E,gap:a})=>t.createElement(r,{$size:E,$gap:a},p);n.defaultProps={children:void 0,size:void 0,gap:void 0};const c=n,v=s.default.div` &.carousel { overflow: hidden; .carousel-container { backface-visibility: hidden; display: flex; flex-direction: row; height: auto; } } `,d=({children:p})=>{const[E]=(0,o.Z)({containScroll:"trimSnaps"});return t.createElement(v,{className:"carousel",ref:E},t.createElement("div",{className:"carousel-container"},p))};d.Slide=c;const g=d},"/GOzvPf6":(M,C,e)=>{"use strict";e.d(C,{UQ:()=>g,Qd:()=>T,a$:()=>Z,lr:()=>Y.Z,M5:()=>ne,mU:()=>ae.Z,h4:()=>ut,QH:()=>Re,oU:()=>le.Z,_g:()=>re.Z,dr:()=>ce.Z,Z2:()=>fe,wQ:()=>Ce.Z,Mt:()=>Ot,$4:()=>ft.Z,h_:()=>mt,Yz:()=>nn,ai:()=>rt,VL:()=>sn,$E:()=>me.Z,XO:()=>no.Z,S6:()=>Co.Z,hW:()=>Zt,BR:()=>Kn,oL:()=>Vo,dL:()=>Yn,bd:()=>Ls,q:()=>Ts,Ow:()=>Tr,Fe:()=>Lo,jc:()=>Us.Z,kF:()=>te.Z,$1:()=>st,JO:()=>Jt.Z,hU:()=>St.Z,AE:()=>$t.Z,d2:()=>cn.Z,QA:()=>Ct,Sr:()=>Zn,Ii:()=>fn,Vs:()=>Ss,vu:()=>Wr,Qj:()=>Ps,Zv:()=>Ut,Vf:()=>Oo,pb:()=>Fn,os:()=>ht.Z,NU:()=>To.Z,dX:()=>Bn.Z,pJ:()=>pt,Ox:()=>Ro.Z,nR:()=>ca,mr:()=>Pr.Z,IE:()=>Js.Z,BN:()=>Fi.Z,l9:()=>Fr.Z,tl:()=>Ki.Z,qX:()=>mr,Uv:()=>vl,ko:()=>Ys.Z,y8:()=>yl.Z,mv:()=>Tl,ij:()=>Sl.Z,xE:()=>Ao,UI:()=>bl.Z,Ph:()=>vn.Z,vA:()=>Fs,eR:()=>Il,Tz:()=>Ua,fz:()=>zl.Z,cm:()=>wa.Z,KB:()=>Qa,$j:()=>os.Z,iI:()=>Wa.Z,j1:()=>Na,AX:()=>Za.Z,EK:()=>Qr.Z,Cc:()=>Er,ZD:()=>ka,jY:()=>Zl,zX:()=>ya,en:()=>vr.Z});var t=e("8jTixuP6"),s=e("Z7aTuO5B"),o=e("ii0bleBb"),r=e.n(o),n=e("J6y4/h8P"),c=e("3dj8OEcA");const v=(0,n.default)(c.eh)` margin-bottom: 0; `,d=({activeKey:k,children:$,id:q,onSelect:Ne,...Ge})=>{const tt=k==null?void 0:k.replace(/[^0-9a-zA-Z-]/g,"-").toLowerCase();return s.createElement(v,{...Ge,activeKey:tt,id:q,onSelect:Ne,accordion:!0},$)};d.propTypes={activeKey:r().string,children:r().node.isRequired,id:r().string.isRequired,onSelect:r().func},d.defaultProps={activeKey:void 0,defaultActiveKey:void 0,onSelect:()=>{}};const g=d;var p=e("0dOiGFEa");const E=(0,n.default)(p.Z)` border: 0; border-radius: 0; box-shadow: none; `,a=(0,n.default)(p.Z.Heading)(({theme:k})=>(0,n.css)` && { padding: 0; border-radius: 0; background-color: ${k.colors.variant.lightest.default}; } `),u=(0,n.default)(p.Z.Title)(({theme:k})=>(0,n.css)` font-size: ${k.fonts.size.small}; color: ${k.colors.global.link}; > a { padding: 3px 9px; display: block; } `),f=(0,n.default)(p.Z.Body)(({theme:k})=>(0,n.css)` ${E} > ${a} + .panel-collapse > & { background-color: ${k.colors.global.contentBackground}; border-top-color: ${k.colors.variant.lighter.default}; border-bottom-width: 0; color: ${k.colors.variant.darkest.default}; } `),y=({children:k,name:$,id:q,...Ne})=>{const Ge=q!=null?q:$.replace(/[^0-9a-zA-Z]/g,"-").toLowerCase();return s.createElement(E,{...Ne,id:q,eventKey:Ge},s.createElement(a,null,s.createElement(u,{toggle:!0},$)),s.createElement(p.Z.Collapse,null,s.createElement(f,null,k)))};y.propTypes={name:r().node.isRequired,id:r().string,children:r().node.isRequired},y.defaultProps={id:void 0};const T=y;var P=e("UiXZqrDE");const O=n.default.label` font-weight: bold; margin-bottom: 5px; display: inline-block; font-size: 14px; background: none; `,b=n.default.span` color: ${k=>k.theme.colors.gray[50]}; `,L=({fieldName:k,label:$,clearable:q,required:Ne,helpText:Ge,options:tt})=>s.createElement(P.Field,{name:k,help:Ge},({field:{name:wt,value:Un,onChange:Tn}})=>s.createElement(s.Fragment,null,s.createElement(O,null,$),s.createElement(vn.Z,{id:k,name:wt,clearable:q,required:Ne,allowCreate:!0,onChange:kn=>Tn({target:{value:kn,name:wt}}),options:tt,value:Un}),Ge&&s.createElement("span",{className:"help-block"},s.createElement(b,null,Ge))));L.defaultProps={clearable:!1,required:!1,helpText:"",options:[]};const x=null;var W=e("IZYxBTgT");const N=({dateTime:k,format:$})=>{const q=k!=null?k:new Date,Ne=(0,W.Od)(q,"internal"),Ge=(0,W.zG)(q,$);return s.createElement("time",{dateTime:Ne,title:Ne},Ge)};N.propTypes={dateTime:r().oneOfType([r().string,r().object,r().number]),format:r().string},N.defaultProps={format:"default",dateTime:void 0};const Z=N,j=n.default.div(({$fullHeight:k})=>` display: flex; height: ${k?"100%":"auto"}; justify-content: center; align-items: center; `),z=({children:k,fullHeight:$})=>s.createElement(j,{$fullHeight:$},k);z.defaultProps={fullHeight:!0};const ne=z;var Y=e("UEhMhaHZ"),ae=e("SLtHYqXc"),ee=e("6nsVPoEI"),ue=e("VgplIV7d"),H=e("uZqmR+ju");const ye=(0,n.default)(H.Popover)` .popover-content { padding: 0; } `,we=({id:k,placement:$,title:q,triggerNode:Ne,onChange:Ge,...tt})=>{const[wt,Un]=(0,s.useState)(!1),Tn=(0,s.useRef)(),kn=()=>{Un(!wt)},Eo=(eo,fo)=>{Ge(eo,fo,kn)};return s.createElement(s.Fragment,null,(0,s.cloneElement)(Ne,{onClick:kn,ref:Tn}),wt&&s.createElement(ue.aV,{show:wt,containerPadding:10,placement:$,shouldUpdatePosition:!0,target:Tn.current,rootClose:!0,onHide:kn},s.createElement(ye,{id:k,title:q},s.createElement(ee.Z,{onChange:Eo,...tt}))))};we.propTypes={id:r().string.isRequired,placement:r().oneOf(["top","right","bottom","left"]),title:r().string,triggerNode:r().node.isRequired,onChange:r().func.isRequired},we.defaultProps={placement:"bottom",title:"Pick a color",colors:void 0};const ut=we;var ht=e("rp7UD7rK");const Je=({show:k,title:$,children:q,onCancel:Ne,onConfirm:Ge,btnConfirmDisabled:tt,btnConfirmText:wt,hideCancelButton:Un})=>{const Tn=Un?Ge:Ne;return s.createElement(H.Modal,{show:k,onHide:Tn},s.createElement(H.Modal.Header,{closeButton:!0},s.createElement(H.Modal.Title,null,$)),s.createElement(H.Modal.Body,null,q),s.createElement(H.Modal.Footer,null,s.createElement(ht.Z,{onCancel:Ne,onSubmit:Ge,submitButtonType:"button",disabledSubmit:tt,submitButtonText:wt,displayCancel:Un})))};Je.propTypes={show:r().bool,hideCancelButton:r().bool,title:r().oneOfType([r().string,r().element]).isRequired,btnConfirmText:r().oneOfType([r().string,r().element]),btnConfirmDisabled:r().bool,onCancel:r().func,onConfirm:r().func.isRequired,children:r().oneOfType([r().string,r().element]).isRequired},Je.defaultProps={btnConfirmText:"Confirm",btnConfirmDisabled:!1,show:!1,hideCancelButton:!1,onCancel:()=>{}};const Re=Je;var le=e("t7jeigEY"),me=e("fkNiwXiR"),re=e("iDUHYfT2"),ce=e("9gxkERa8");const Q=s.forwardRef(({formatSelection:k,children:$,className:q},Ne)=>{const Ge=tt=>{const wt=k(document.getSelection());tt.clipboardData.setData("text/plain",wt),tt.preventDefault()};return s.createElement("div",{className:q,ref:Ne,onCopy:Ge},$)});Q.defaultProps={className:void 0};const J=null,ie=n.default.span(({theme:k})=>` background-color: ${k.colors.variant.light.info}; `),ge=(0,s.forwardRef)(({children:k,onClick:$,className:q,title:Ne},Ge)=>s.createElement(ie,{className:`badge ${q}`,onClick:$,ref:Ge,title:Ne},k));ge.defaultProps={onClick:void 0,className:"",title:void 0};const fe=ge;var Ce=e("uoAlNf/n"),Oe=e("awUYZK9l"),nt=e("OeoQZrS6"),et=e("O/XpfGnR");const Fe=(0,n.default)(Oe.ZP)(({theme:k})=>(0,n.css)` width: 100%; .DayPicker-Day { min-width: 34px; max-width: 34px; min-height: 34px; max-height: 34px; &--selected:not(.DayPicker-Day--disabled, .DayPicker-Day--outside) { background-color: ${k.colors.variant.lighter.primary}; color: ${k.colors.variant.darkest.primary}; } &--today { color: ${k.colors.variant.info}; } &:focus { outline-color: ${k.colors.variant.primary}; } } &:not(.DayPicker--interactionDisabled) .DayPicker-Day:not(.DayPicker-Day--disabled, .DayPicker-Day--selected, .DayPicker-Day--outside) { &:focus { outline-color: ${k.colors.variant.primary}; } &:hover { background-color: ${k.colors.variant.lightest.primary}; color: ${k.colors.variant.darker.primary}; } } `),Pe=k=>{const{toUserTimezone:$}=(0,et.Z)();if((0,W.qb)(k))return $(k)},$e=({date:k,fromDate:$,onChange:q,showOutsideDays:Ne})=>{const{formatTime:Ge}=(0,et.Z)(),tt=Pe(k),wt=(0,s.useMemo)(()=>({selected:Un=>tt?Ge(tt,"date")===Ge(Un,"date"):!1,disabled:{before:new Date($)}}),[Ge,$,tt]);return s.createElement(Fe,{initialMonth:tt?tt.toDate():void 0,onDayClick:q,modifiers:wt,showOutsideDays:Ne})};$e.propTypes={date:r().oneOfType([r().object,r().string]),onChange:r().func.isRequired,fromDate:r().instanceOf(Date),showOutsideDays:r().bool},$e.defaultProps={date:void 0,fromDate:void 0,showOutsideDays:!1};const Ot=$e;var ft=e("qQvt58D8");const Tt=n.default.ul.attrs(()=>({className:"dropdown-menu"}))(({$show:k,theme:$,$zIndex:q,$minWidth:Ne})=>(0,n.css)` display: ${k?"block":"none"}; color: ${$.colors.variant.dark.default}; background-color: ${$.colors.variant.lightest.default}; box-shadow: 0 3px 3px ${$.colors.global.navigationBoxShadow}; z-index: ${q}; min-width: ${Ne?`${Ne}px`:"max-content"}; .dropdown-header { color: ${$.colors.variant.dark.default}; padding: 3px 10px; } > li { > a { padding: 3px 10px; color: ${$.colors.variant.darker.default}; display: flex; align-items: center; &:hover { color: ${$.colors.variant.darkest.default}; background-color: ${$.colors.variant.lighter.default}; } } &.disabled { > a { color: ${$.colors.variant.light.default}; } } } `);function Lt(k,$,q){var Ne,Ge;return(Ne=k.props)!=null&&Ne.onSelect?{onSelect:(tt,wt)=>{k.props.onSelect(),q(wt)}}:(Ge=k.props)!=null&&Ge.children?{children:Be(k.props.children,$+1,q)}:{}}function Be(k,$,q){return $>2?k:s.Children.map(k,Ge=>Ge!=null&&Ge.props?s.cloneElement(Ge,{...Ge.props,...Lt(Ge,$+1,q)}):Ge)}const lt=({show:k,children:$,zIndex:q,onMenuItemSelect:Ne,minWidth:Ge,...tt})=>{const wt=Be($,0,Ne);return s.createElement(Tt,{...tt,$show:k,$zIndex:q,$minWidth:Ge},wt)};lt.propTypes={children:r().node.isRequired,zIndex:r().number,show:r().bool,minWidth:r().number},lt.defaultProps={show:!1,zIndex:1050,minWidth:void 0,onMenuItemSelect:()=>{}};const mt=lt,Rt=n.default.a.attrs({href:"#"})(({theme:k})=>(0,n.css)` &::after { display: block; content: ' '; float: right; width: 0; height: 0; border-color: transparent; border-style: solid; border-width: 5px 0 5px 5px; border-left-color: ${k.colors.gray[80]}; margin-top: 5px; margin-right: -10px; } `),zt=(0,n.default)(H.Dropdown)(({$left:k,theme:$})=>(0,n.css)` position: relative; > .dropdown-menu { top: 0; left: ${k?"auto":"100%"}; right: ${k?"98%":"auto"}; margin-top: -6px; margin-left: ${k?"10px":"-1px"}; border-radius: ${k?"6px 0 6px 6px":"0 6px 6px 6px"}; } &:hover > .dropdown-menu { display: block; } &:hover > ${String(Rt)}::after { border-left-color: ${$.colors.gray[100]}; } `),xt=({children:k,left:$,title:q})=>s.createElement(zt,{$left:$,as:"li"},q&&s.createElement(Rt,null,q),s.createElement(H.Dropdown.Menu,null,k));xt.propTypes={children:r().node.isRequired,left:r().bool,title:r().string},xt.defaultProps={left:!1,title:void 0};const nn=xt;var Vt=e("IdpefXWm");const jn=n.default.div` display: flex; flex-direction: column; align-items: center; p { text-align: center; } `,Mt=n.default.h2` margin-top: 5px; margin-bottom: 10px; text-align: center; `,On=({children:k,title:$})=>s.createElement(jn,null,s.createElement(Mt,null,$),k);On.propTypes={title:r().oneOfType([r().string,r().node]),children:r().node.isRequired},On.defaultProps={title:"Looks like there is nothing here, yet!"};const rt=On;var Bn=e("G8YcST+s");const de=({children:k,className:$})=>s.createElement(H.Alert,{className:`${$!=null?$:""} no-bm`},k||"No data available.");de.defaultProps={className:void 0};const pt=de;var Gt=e("E+CaPsQD"),gn=e("7dh0vSOR"),Jt=e("93yMNhQL");const An=(0,n.default)(p.Z.Title)` display: flex; align-items: center; `,xe=(0,n.default)(Jt.Z)` margin-right: 5px; margin-top: -1px; `,Pn=({featureName:k,wrapperClassName:$})=>s.createElement(p.Z,{bsStyle:"info",className:$},s.createElement(p.Z.Heading,null,s.createElement(An,null,s.createElement(xe,{name:"crown"}),"Enterprise Feature")),s.createElement(p.Z.Body,null,"To use the ",s.createElement("b",null,k)," functionality you need the ",s.createElement("a",{href:"https://www.graylog.org/products/enterprise",rel:"noopener noreferrer",target:"_blank"},"Graylog Enterprise license")," and the ",s.createElement(gn.Z,{page:Gt.Z.PAGES.ENTERPRISE_SETUP,text:"Graylog Enterprise plugin"}),"."));Pn.propTypes={featureName:r().string.isRequired,wrapperClassName:r().string},Pn.defaultProps={wrapperClassName:"no-bm"};const sn=Pn;var no=e("gn61rwrR"),Co=e("KDUSw0C6");const Go=(0,n.default)(H.Row)` margin-bottom: 0 !important; `,Mo=n.default.div(({margin:k})=>` margin-top: ${k}px; margin-bottom: ${k}px; `),jo=({children:k,onClose:$,bsStyle:q="warning",marginTopBottom:Ne=15,runtimeError:Ge})=>{const tt=Ge?"danger":q;return k?s.createElement(Mo,{margin:Ne},s.createElement(H.Alert,{bsStyle:tt},s.createElement(Go,null,s.createElement(H.Col,{md:11},Ge&&s.createElement("h4",null,"Runtime Error"),k),s.createElement(H.Col,{md:1},s.createElement(H.Button,{bsSize:"xsmall",bsStyle:tt,className:"pull-right",onClick:()=>$(void 0)},s.createElement(Jt.Z,{name:"times"})))))):null};jo.propTypes={bsStyle:r().string,runtimeError:r().bool,marginTopBottom:r().number,children:r().oneOfType([r().arrayOf(r().element),r().element,r().string]),onClose:r().func},jo.defaultProps={bsStyle:"warning",runtimeError:!1,marginTopBottom:15,children:null,onClose:()=>{}};const Zt=jo;var Me=e("dFpwyWHg"),Ye=e.n(Me),Ke=e("C2ikvoS0"),dt=e.n(Ke),it=e("1IntWRSu"),gt=e.n(it),It=e("8nGWeFnd"),ot=e.n(It),yt=e("TeAcaicX"),Xt=e.n(yt),rn=e("eE3+5goe"),Cn=e.n(rn),bn=e("3czfsiiO"),hn={};hn.styleTagTransform=Cn(),hn.setAttributes=ot(),hn.insert=gt().bind(null,"head"),hn.domAPI=dt(),hn.insertStyleElement=Xt();var ao=Ye()(bn.Z,hn);const Xn=bn.Z&&bn.Z.locals?bn.Z.locals:void 0,vo=({children:k,className:$})=>s.createElement("ul",{className:$?`${Xn.list} ${$}`:Xn.list},k);vo.defaultProps={className:""},vo.propTypes={className:r().string};const Kn=vo,Jn=n.default.li(({$padded:k})=>(0,n.css)` padding: ${k?"10px 5px":""}; `),Wn=n.default.div(({theme:k})=>(0,n.css)` display: flex; font-size: ${k.fonts.size.body}; line-height: 20px; label { min-height: 20px; margin-bottom: 2px; margin-right: 5px; * { cursor: pointer; } } `),bo=n.default.div` display: inline-block; width: 20px; margin-right: 5px; `,ds=n.default.div(({theme:k})=>(0,n.css)` &.fa-stack { cursor: pointer; font-size: ${k.fonts.size.large}; line-height: 20px; width: 1em; height: 1em; vertical-align: text-top; &:hover [class*='fa-'] { color: ${k.colors.variant.primary}; opacity: 1; } } [class*='fa-']:first-child { opacity: 0; ~ [class*='fa-']:hover { color: ${k.colors.global.contentBackground}; } } `),zo=n.default.span(({theme:k})=>(0,n.css)` font-size: ${k.fonts.size.large}; `),Xo=n.default.button` display: flex; border: 0; padding: 0; text-align: left; background: transparent; `,Do=n.default.span(({theme:k})=>(0,n.css)` font-size: ${k.fonts.size.body}; margin-left: 0.5em; color: ${k.colors.gray[70]}; `),Jo=n.default.div(({theme:k})=>(0,n.css)` border-left: 1px ${k.colors.gray[90]} solid; margin-left: 35px; margin-top: 10px; padding-left: 5px; `),Zo=k=>{const{expanded:$,indetermined:q,stayExpanded:Ne,padded:Ge,...tt}=k;return tt};class yo extends s.Component{constructor($){super($),this._toggleExpand=()=>{const{stayExpanded:q}=this.props,{expanded:Ne}=this.state;q?this.setState({expanded:!0}):this.setState({expanded:!Ne})},this._clickOnHeader=()=>{this._checkbox&&this._checkbox.click()},this.state={expanded:$.expanded}}componentDidMount(){const{indetermined:$}=this.props;$&&this._checkbox&&(this._checkbox.indeterminate=$)}componentDidUpdate($){const{expanded:q,indetermined:Ne}=this.props;$.expanded!==q&&this._toggleExpand(),this._checkbox&&(this._checkbox.indeterminate=Ne)}render(){const{expanded:$}=this.state,{padded:q}=this.props,{checked:Ne,expandable:Ge,selectable:tt,header:wt,subheader:Un,children:Tn,...kn}=this.props,Eo=tt?s.createElement(Xo,{type:"button",tabIndex:0,onClick:this._clickOnHeader},wt):wt,eo=Zo(kn);return s.createElement(Jn,{$padded:q},s.createElement(Wn,null,tt&&s.createElement(H.Checkbox,{inputRef:fo=>{this._checkbox=fo},inline:!0,checked:Ne,...eo}),Ge&&s.createElement(bo,null,s.createElement(ds,{className:"fa-stack",tabIndex:0,onClick:this._toggleExpand},s.createElement(Jt.Z,{name:"circle",className:"fa-stack-1x"}),s.createElement(Jt.Z,{name:`angle-${$?"down":"up"}`,className:"fa-stack-1x"}))),s.createElement(zo,{className:"header"},Eo,Un&&s.createElement(Do,null,Un))),s.createElement(Jo,null,$&&Tn))}}yo.propTypes={checked:r().bool,indetermined:r().bool,selectable:r().bool,expandable:r().bool,expanded:r().bool,stayExpanded:r().bool,header:r().oneOfType([r().string,r().element]).isRequired,subheader:r().oneOfType([r().string,r().element]),children:r().oneOfType([r().element,r().arrayOf(r().element)]),padded:r().bool,readOnly:r().bool,onChange:r().func},yo.defaultProps={checked:!1,indetermined:!1,expandable:!0,expanded:!1,selectable:!0,children:[],subheader:void 0,stayExpanded:!1,padded:!0,readOnly:!1,onChange:()=>{}};const Vo=yo;var _s=e("sWSSTOXR"),Cs=e.n(_s);const ms=({children:k,className:$,href:q,iconClass:Ne,target:Ge})=>{const tt=s.createElement("span",null,k,"\xA0",s.createElement(Jt.Z,{name:Ne}));return Cs()(q)===""?tt:s.createElement("a",{href:q,target:Ge,className:$,rel:"noopener noreferrer"},tt)};ms.defaultProps={href:"",target:"_blank",iconClass:"external-link-alt",className:""},ms.propTypes={href:r().string,children:r().node.isRequired,target:r().string,iconClass:r().string,className:r().string};const Yn=ms,xo=({iconClass:k,children:$,...q})=>s.createElement(H.Button,{...q},s.createElement(Yn,{iconClass:k},$));xo.propTypes={href:r().string.isRequired,children:r().node.isRequired,bsStyle:r().string,bsSize:r().string,target:r().string,iconClass:r().string,className:r().string,disabled:r().bool},xo.defaultProps={bsStyle:"default",bsSize:void 0,target:"_blank",iconClass:"external-link-alt",className:"",disabled:!1};const Ls=xo;var Vs=e("liHGlRT1");const Ts=n.default.div` ${Vs.M} padding: 9px; margin-left: -15px; margin-right: -15px; `;var Us=e("myNaa1PZ");const ws=({labelClassName:k,wrapperClassName:$,label:q,name:Ne,onChange:Ge,...tt})=>s.createElement(Us.Z,{...tt,label:q,id:Ne,onChange:Ge,name:Ne,labelClassName:k,wrapperClassName:$});ws.defaultProps={autoComplete:void 0,bsSize:void 0,buttonAfter:void 0,children:null,disabled:!1,onChange:void 0,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9",formGroupClassName:void 0,type:void 0,error:void 0,placeholder:void 0,help:void 0,minLength:void 0,maxLength:void 0,required:!1,validate:()=>{},rows:void 0,autoFocus:!1};const Lo=ws;var co=e("CrIFpfDF"),ns=e("utbMO9sg"),os=e("dsvqAVKU");const Ws=(0,n.default)(Jt.Z)` margin-right: 0.2em; `,ps=k=>{const{bsSize:$,className:q,centerCol:Ne,displayCancel:Ge,disabledSubmit:tt,formId:wt,isAsyncSubmit:Un,onSubmit:Tn,submitButtonText:kn,submitButtonType:Eo,submitIcon:eo}=k;return s.createElement(co.Z,{className:q},s.createElement(ns.Z,{bsStyle:"success",bsSize:$,disabled:tt||Un&&k.isSubmitting,form:wt,title:kn,"aria-label":kn,type:Eo,onClick:Tn},eo&&!(Un&&k.isSubmitting)&&s.createElement(Ws,{name:eo}),Un&&k.isSubmitting?s.createElement(os.Z,{text:k.submitLoadingText,delay:0}):kn),Ne,Ge===!0&&s.createElement(ns.Z,{type:"button",bsSize:$,onClick:k.onCancel,title:"Cancel","aria-label":"Cancel",disabled:k.disabledCancel||Un&&k.isSubmitting},"Cancel"))};ps.defaultProps={bsSize:void 0,centerCol:void 0,className:void 0,disabledSubmit:!1,displayCancel:!0,formId:void 0,isAsyncSubmit:!1,onSubmit:void 0,submitButtonType:"submit",submitIcon:void 0};const Tr=ps;var Ns=e("Q1zRxDOP"),gs=e("q2j1bVbz");const Ho=({children:k,id:$,type:q,hideChildren:Ne})=>{const Ge=(0,gs.Z)(),wt=`entity:own:${(0,Ns.L)(q,$)}`,Un="*";if(Ge){const{grnPermissions:Tn=[],permissions:kn}=Ge,Eo=kn.includes(Un);if(Tn.includes(wt)||Eo)return!Ne&&typeof k=="function"?s.createElement(s.Fragment,null,k({disabled:!1})," "):s.createElement(s.Fragment,null,"children")}return!Ne&&typeof k=="function"?s.createElement(s.Fragment,null,k({disabled:!0})," "):null};Ho.propTypes={children:r().oneOfType([r().node,r().func]).isRequired,id:r().string,type:r().string.isRequired,hideChildren:r().bool},Ho.defaultProps={hideChildren:!1,id:void 0};const Yo=Ho;var te=e("6tmAsyUP"),Te=e("HvPssUok");class Le extends s.Component{constructor($){super($),this._onUpdate=()=>{let q=this.isoDuration.getValue().toUpperCase();q.startsWith("P")||(q=`P${q}`),this.setState({duration:q}),Te.jO(q,this.props.validator)&&this.props.update(q)},this.state={duration:this.props.duration}}render(){return s.createElement(H.Input,{id:this.props.id,type:"text",ref:$=>{this.isoDuration=$},label:this.props.label,onChange:this._onUpdate,value:this.state.duration,help:this.props.help,addonAfter:Te.g0(this.state.duration,this.props.validator,this.props.errorText),bsStyle:Te.El(this.state.duration,this.props.validator),autoFocus:this.props.autoFocus,required:this.props.required,disabled:this.props.disabled})}}Le.propTypes={id:r().string.isRequired,duration:r().string.isRequired,update:r().func.isRequired,label:r().string,help:r().string,validator:r().func,errorText:r().string,autoFocus:r().bool,required:r().bool,disabled:r().bool},Le.defaultProps={label:"Duration",help:"as ISO8601 Duration",validator:()=>!0,errorText:"invalid",autoFocus:!1,required:!1,disabled:!1};const st=Le;var St=e("Ofda/4py"),$t=e("rzOX6PZw"),cn=e("Kz+u8q89");const In=n.default.span(({theme:k})=>` color: ${k.colors.gray[60]}; font-weight: normal; `),Zn=()=>s.createElement(In,null,"(Opt.)");var qn=e("fyiLrVbn"),be=e("CCNXj2ra");const Ve=k=>{const $=(0,n.useTheme)(),q={...$,colors:{...$.colors,primary:$.colors.input.borderFocus,primary75:$.colors.variant.light.default,primary50:$.colors.variant.lighter.default,primary25:$.colors.variant.lightest.default,danger:$.colors.variant.darker.info,dangerLight:$.colors.variant.lighter.info,neutral0:$.colors.input.background,neutral5:$.colors.input.backgroundDisabled,neutral10:$.colors.variant.lightest.info,neutral20:$.colors.input.border,neutral30:$.colors.gray[70],neutral40:$.colors.gray[60],neutral50:$.colors.gray[50],neutral60:$.colors.gray[40],neutral70:$.colors.gray[30],neutral80:$.colors.gray[20],neutral90:$.colors.gray[10]}};return{inputListTheme:q,styles:Ge=>({valueContainer:tt=>({...tt,padding:k==="small"?"0 8px":"2px 12px"}),control:(tt,{isFocused:wt})=>({...tt,borderWidth:wt?1:tt.borderWidth,outline:wt?0:tt.outline,boxShadow:wt?q.colors.input.boxShadow:null,...k==="small"?{minHeight:29,height:29}:{minHeight:34},borderRadius:be.L$,alignItems:"center",borderColor:Ge?tt.borderColor:q.colors.brand.primary}),placeHolder:tt=>({...tt,color:q.colors.input.placeholder,lineHeight:"28px",fontFamily:q.fonts.family.body,fontSize:q.fonts.size.body,fontWeight:400,whiteSpace:"nowrap",textOverflow:"ellipsis",overflow:"hidden",maxWidth:"100%",paddingRight:"20px"}),multiValue:tt=>({...tt,border:`1px solid ${q.colors.variant.lighter.info}`}),multiValueLabel:tt=>({...tt,color:Ge?tt.color:q.colors.brand.primary,padding:"2px 5px",fontSize:q.fonts.size.small}),multiValueRemove:tt=>({...tt,borderLeft:`1px solid ${q.colors.variant.lighter.info}`,paddingLeft:"5px",paddingRight:"5px",borderRadius:"0"})})}};class We extends Event{set target($){this._target=$}get target(){return this._target}set currentTarget($){this._target=$}get currentTarget(){return this._target}preventDefault(){super.preventDefault(),this._defaultPrevented=!0}isDefaultPrevented(){return this._defaultPrevented}stopPropagation(){super.stopPropagation(),this._propagationStopped=!0}isPropagationStopped(){return this._propagationStopped}persist(){this._persisted=!0}}const vt=k=>({label:k,value:k}),Et=({name:k,values:$,onChange:q,label:Ne,size:Ge,bsStyle:tt,error:wt,help:Un,...Tn})=>{const{inputListTheme:kn,styles:Eo}=Ve(Ge),eo=s.useRef(null),[fo,to]=s.useState(""),[cs,us]=s.useState($.map(po=>vt(po)));s.useLayoutEffect(()=>us($.map(po=>vt(po))),[$]);const Is=po=>{const Ks=po.map(Ms=>Ms.value),ho=new We("change");eo.current.value=Ks,eo.current.name=k,ho.target=eo.current,q(ho)},nr=po=>{if(fo&&(po.key==="Enter"||po.key==="Tab")){const Ks=[...cs,vt(fo)];us(Ks),Is(Ks),to(""),po.preventDefault()}},or=po=>{us(po),Is(po)};return s.createElement(H.FormGroup,{controlId:Tn.id?Tn.id:k,validationState:wt?"error":tt},Ne&&s.createElement(H.ControlLabel,null,Ne),s.createElement(qn.Z,{ref:eo,components:{DropdownIndicator:null},inputValue:fo,isMulti:!0,menuIsOpen:!1,onChange:or,onInputChange:po=>to(po),onKeyDown:nr,value:cs,styles:Eo(!wt),theme:po=>({...po,...kn}),...Tn}),s.createElement(cn.Z,{error:wt,help:Un}))};Et.defaultProps={label:null,size:"normal",bsStyle:null,error:null,help:null};const Ct=Et;var Kt=e("hHVzGgmW"),en=Object.defineProperty,dn=(k,$,q)=>$ in k?en(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,En=(k,$,q)=>(dn(k,typeof $!="symbol"?$+"":$,q),q);const xn=[{value:"STRING",label:"string"},{value:"NUMBER",label:"number"},{value:"OBJECT",label:"object"},{value:"ARRAY",label:"array"},{value:"BOOLEAN",label:"boolean"},{value:"NULL",label:"null"}];class zn extends s.Component{constructor($){super($),En(this,"_computeInitialState",()=>({value:this.props.value,valueType:this.props.valueType})),En(this,"_propagateState",()=>{this.props.update(this.state.value,this.state.valueType)}),En(this,"_onUpdate",q=>{const{value:Ne}=q.target;this.setState({value:Ne},this._propagateState)}),En(this,"_onValueTypeSelect",q=>{this.setState({valueType:q},this._propagateState)}),this.state=this._computeInitialState()}UNSAFE_componentWillReceiveProps(){this.setState(this._computeInitialState())}render(){const $=xn.filter(q=>this.props.allowedTypes.indexOf(q.value)>-1).map(q=>s.createElement(H.MenuItem,{key:q.value,onSelect:()=>this._onValueTypeSelect(q.value)},q.label));return s.createElement(H.FormGroup,{validationState:this.props.validationState},this.props.label&&s.createElement(H.ControlLabel,{className:this.props.labelClassName},this.props.label),s.createElement(H.InputWrapper,{className:this.props.wrapperClassName},s.createElement(H.InputGroup,null,s.createElement(H.FormControl,{type:"text",onChange:this._onUpdate,onBlur:this.props.onBlur,value:this.state.value,required:this.props.required}),s.createElement(H.DropdownButton,{componentClass:H.InputGroup.Button,id:"input-dropdown-addon",bsStyle:this.props.validationState==="error"?"danger":"default",title:xn.filter(q=>q.value===this.props.valueType)[0].label},$)),this.props.help&&s.createElement(H.HelpBlock,null,this.props.help)))}}zn.propTypes={update:r().func.isRequired,onBlur:r().func,label:r().string,help:r().oneOfType([r().string,r().object]),required:r().bool,validationState:r().string,value:r().string,valueType:r().oneOf(xn.map(k=>k.value)),allowedTypes:(k,$,q)=>{const Ne=xn.map(tt=>tt.value),Ge=[];return k[$]instanceof Array?(k[$].forEach(tt=>{Ne.indexOf(tt)<0&&Ge.push(tt)}),Ge.length>0?new Error(`Invalid prop ${$} supplied to ${q}. Expected array of ${Ne} but got invalid ${Ge}`):null):new Error(`Invalid prop ${$} supplied to ${q}. Expected an array but got ${k[$]}`)},labelClassName:r().string,wrapperClassName:r().string},zn.defaultProps={value:"",valueType:"STRING",allowedTypes:xn.map(k=>k.value),label:"",help:"",required:!1,validationState:null,labelClassName:void 0,wrapperClassName:void 0,onBlur:void 0};const fn=zn;var Dn=e("D/X+X5ed");const Hn=({shortcut:k})=>((0,Dn.Z)(k),null),_o=({children:k,shortcuts:$})=>s.createElement(s.Fragment,null,$.map(q=>s.createElement(Hn,{key:`${q.scope}.${q.actionKey}`,shortcut:q})),k);_o.defaultProps={children:null};const Ss=_o;var As=e("QdZ7Yq43"),Hs=Object.defineProperty,Fo=(k,$,q)=>$ in k?Hs(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,uo=(k,$,q)=>(Fo(k,typeof $!="symbol"?$+"":$,q),q);const De=n.default.div` .form-group { margin-left: 0; margin-right: 0; } `;class ss extends s.Component{constructor($){super($),uo(this,"_onPairsChange",q=>{this.props.onChange&&this.props.onChange(q)}),uo(this,"_bindValue",q=>{const Ne={};Ne[q.target.name]=q.target.value,this.setState(Ne)}),uo(this,"_addRow",()=>{const q=As.Z.clone(this.props.pairs);q[this.state.newKey]=this.state.newValue,this._onPairsChange(q),this.setState({newKey:"",newValue:""})}),uo(this,"_deleteRow",q=>()=>{if(window.confirm(`Are you sure you want to delete property '${q}'?`)){const Ne=As.Z.clone(this.props.pairs);delete Ne[q],this._onPairsChange(Ne)}}),uo(this,"_formattedHeaders",q=>s.createElement("tr",null,q.map((Ne,Ge)=>{const tt={};if(Ge===q.length-1){if(!this.props.editable)return null;tt.width=75}return s.createElement("th",{key:Ne,style:tt},Ne)}))),uo(this,"_formattedRows",q=>Object.keys(q).sort().map(Ne=>{let Ge;if(this.props.editable){const tt=[];tt.push(s.createElement(H.Button,{key:`delete-${Ne}`,bsStyle:"danger",bsSize:this.props.actionsSize,onClick:this._deleteRow(Ne)},"Delete")),Ge=s.createElement("td",null,tt)}return s.createElement("tr",{key:Ne},s.createElement("td",null,Ne),s.createElement("td",null,q[Ne]),Ge)})),uo(this,"_newRow",()=>{if(!this.props.editable)return null;const q=!this.state.newKey||!this.state.newValue;return s.createElement("tr",null,s.createElement("td",null,s.createElement(De,null,s.createElement(H.Input,{type:"text",name:"newKey",id:"newKey","data-testid":"newKey",bsSize:"small",placeholder:this.props.headers[0],value:this.state.newKey,onChange:this._bindValue}))),s.createElement("td",null,s.createElement(De,null,s.createElement(H.Input,{type:"text",name:"newValue",id:"newValue","data-testid":"newValue",bsSize:"small",placeholder:this.props.headers[1],value:this.state.newValue,onChange:this._bindValue}))),s.createElement("td",null,s.createElement(H.Button,{bsStyle:"success",bsSize:"small",onClick:this._addRow,disabled:q},"Add")))}),this.state={newKey:"",newValue:""}}render(){return s.createElement("div",{className:"key-value-table-component"},s.createElement("div",{className:`table-responsive ${this.props.containerClassName}`},s.createElement(H.Table,{className:`table table-striped ${this.props.className}`},s.createElement("thead",null,this._formattedHeaders(this.props.headers)),s.createElement("tbody",null,this._formattedRows(this.props.pairs),this._newRow()))))}}uo(ss,"propTypes",{pairs:r().object.isRequired,headers:r().array,editable:r().bool,onChange:r().func,className:r().string,containerClassName:r().string,actionsSize:r().oneOf(["large","medium","small","xsmall"])}),ss.defaultProps={headers:["Name","Value","Actions"],editable:!1,actionsSize:"xsmall",className:"",containerClassName:"",onChange:()=>{}};const Wr=ss;var Sr=e("yAXMqwrl");const ir=({to:k,target:$,onClick:q,...Ne})=>{const Ge=(0,Sr.useNavigate)(),tt=(0,s.useCallback)(wt=>{$==="_self"?Ge(k):window.open(k,$),q&&q(wt)},[$,q,Ge,k]);return s.createElement(H.Button,{onClick:tt,...Ne})};ir.defaultProps={target:"_self"};const Ps=ir;var Nr=e("ty2gyrHp"),cr=e("d4kzUuQm"),Bo=e("RCNj0OY4"),ks=e("8wYeYPUw"),ia=e("Vg8s2y9S"),Es=e("8fnsnG21"),Ar=Object.defineProperty,Ie=(k,$,q)=>$ in k?Ar(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,Qe=(k,$,q)=>(Ie(k,typeof $!="symbol"?$+"":$,q),q);class bt extends s.PureComponent{render(){const{nodes:$}=this.props;if(!$)return s.createElement(os.Z,null);const q=$[this.props.nodeId];if(q){const Ne=q.is_leader?"star":"code-branch",Ge=q.is_leader?"leader-node":"",tt=q.is_leader?"This is the leader node in the cluster":"",wt=s.createElement(s.Fragment,null,s.createElement(Jt.Z,{name:Ne,className:Ge,title:tt})," ",q.short_node_id,s.createElement(ks.Z,null," / ",q.hostname));return Bo.Z.isCloud()?wt:s.createElement(Nr.r,{to:cr.ZP.SYSTEM.NODES.SHOW(this.props.nodeId)},wt)}return s.createElement("i",null,"Unknown Node")}}Qe(bt,"propTypes",{nodeId:r().string.isRequired,nodes:r().object}),bt.defaultProps={nodes:void 0};const Ut=(0,Es.Z)(bt,{nodeStore:ia.S},({nodeStore:k,...$})=>({...$,nodes:k.nodes})),Qt=n.default.div` text-overflow: ellipsis; white-space: nowrap; overflow: hidden; `,un=({count:k,listing:$})=>React.createElement(Qt,{title:String($)},React.createElement(CountBadge,null,k)," ",$),Ln=null;var Vn=e("k7aCBAx/"),vn=e("hhdCSTZj"),Nn=e("9xj2LQzD");const Uo=k=>{const $=Object.values(k).filter(q=>q.language_tag!=="und").map(q=>({value:q.language_tag,label:q.display_name})).sort((q,Ne)=>{const Ge=q.label.toUpperCase(),tt=Ne.label.toUpperCase();return Gett?1:0});return[{value:"und",label:"Default locale"}].concat($)},Ko=k=>s.createElement("span",{key:k.value,title:"{option.value} [{option.value}]"},k.label," [",k.value,"]"),Oo=k=>{const{locales:$}=(0,Es.o)(Nn.B);if(!$)return s.createElement(os.Z,null);const q=Uo($);return s.createElement(vn.Z,{...k,placeholder:"Pick a locale",options:q,optionRenderer:Ko})};var Zs=e("s14Hze4o");const Fn=n.default.dl(({theme:k})=>(0,n.css)` margin-top: 10px; margin-bottom: 0; dt { font-weight: bold; margin-left: 1px; } dd { margin-bottom: 5px; padding-bottom: 5px; margin-left: 1px; /* Ensures that italic text is not cut */ &.stream-list ul { list-style-type: disc; padding-left: 25px; li { margin-top: 3px; } } div.message-field-actions { padding-left: 10px; position: relative; top: -10px; } } &.message-details-fields span:not(:last-child) dd { border-bottom: 1px solid ${k.colors.gray[90]}; } &.message-details-fields dd { white-space: pre-wrap; } &.message-details-fields .field-value { font-family: ${k.fonts.family.monospace}; } &.message-details-fields dd.message-field .field-value { max-height: 500px; overflow: auto; } `);var To=e("kTp6yg80"),Ro=e("ys/4WHo5"),fs=Object.defineProperty,hs=(k,$,q)=>$ in k?fs(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,ur=(k,$,q)=>(hs(k,typeof $!="symbol"?$+"":$,q),q);class Xs extends s.Component{render(){const{overlay:$,useOverlay:q,placement:Ne,trigger:Ge,className:tt,children:wt}=this.props;return $&&q?s.createElement(Ro.Z,{placement:Ne,trigger:Ge,overlay:$,rootClose:!0,className:tt},s.createElement("span",null,wt)):this.props.children}}ur(Xs,"propTypes",{overlay:r().element,placement:r().oneOf(["top","bottom","right","left"]),trigger:r().oneOfType([r().oneOf(["click","hover","focus"]),r().arrayOf(r().oneOf(["click","hover","focus"]))]),useOverlay:r().bool,children:r().oneOfType([r().arrayOf(r().element),r().element]).isRequired,className:r().string}),ur(Xs,"defaultProps",{overlay:void 0,placement:void 0,trigger:void 0,useOverlay:void 0,className:void 0});const gl=null;var Zr=e("m5sCWlWB");const dr=({errors:k})=>{const $=k?k.map(Ne=>s.createElement("li",{key:`key-${Ne.toString()}`},Ne.toString())):[],q=s.createElement("p",null,"We had trouble fetching some data required to build this page, so here is a picture instead.");return s.createElement(Zr.Z,{title:"Error getting data",description:q,displayPageLayout:!1},s.createElement("ul",null,$,s.createElement("li",null,"Check your Graylog logs for more information.")))};dr.propTypes={errors:r().array.isRequired};const ca=dr;var Pr=e("/W/x1zfW"),Js=e("FDzjarsJ"),Fr=e("qfE6wAsD"),Kr=e("Zzc2+UR0");const mo=({setFilteredRows:k,resetPagination:$,rows:q,...Ne})=>{const Ge=(tt,wt)=>{k(wt&&wt!==""?tt:q),$()};return s.createElement(Kr.Z,{...Ne,rows:q,onDataFiltered:Ge})};mo.defaultProps={id:void 0,filterKeys:void 0,displayKey:void 0,filterBy:void 0,filterLabel:void 0};const ua=mo,El={page:1,perPage:10,query:""},Ni=(k,$,q)=>{const Ne=$*(q-1),Ge=Ne+$;return k.slice(Ne,Ge)},fl=({rows:k=[],pagination:$,filterKeys:q,filterLabel:Ne,displayKey:Ge,filterBy:tt,id:wt,...Un})=>{const[{perPage:Tn,page:kn},Eo]=(0,s.useState)($),[eo,fo]=(0,s.useState)(k),to=Ni(eo,Tn,kn);(0,s.useEffect)(()=>{fo(k),Eo($)},[k,$]);const cs=(Is,nr)=>{Eo({page:Is,perPage:nr})},us=()=>{Eo({perPage:Tn,page:$.page})};return s.createElement(Fr.Z,{totalItems:eo.length,pageSize:Tn,activePage:kn,onChange:cs,showPageSizeSelect:!0,useQueryParameter:!1},s.createElement(Ce.Z,{...Un,id:wt,customFilter:s.createElement(ua,{id:wt,filterKeys:q,setFilteredRows:fo,rows:k,resetPagination:us,displayKey:Ge,filterBy:tt,filterLabel:Ne}),rows:to}))};fl.defaultProps={className:void 0,displayKey:void 0,filterBy:void 0,filterKeys:void 0,filterLabel:"Filter",headerCellFormatter:void 0,noDataText:void 0,pagination:El,rowClassName:void 0,useResponsiveTable:!1},fl.propTypes={pagination:r().object};const Zi=null,$r=null;var Fi=e("xfUIbHjs"),Ki=e("wl9DHqUO"),$i=e("TJOheZRu"),hl=Object.defineProperty,vs=(k,$,q)=>$ in k?hl(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,So=(k,$,q)=>(vs(k,typeof $!="symbol"?$+"":$,q),q);class Da extends s.Component{render(){return s.createElement("span",null,$i.Z.pluralize(this.props.value,this.props.singular,this.props.plural))}}So(Da,"propTypes",{singular:r().string.isRequired,plural:r().string.isRequired,value:r().oneOfType([r().number,r().string]).isRequired});const mr=Da;var Ys=e("e5reO9iR"),Oa=e("zKLlqmvB");const da=({children:k,container:$})=>s.createElement(s.Fragment,null,(0,Oa.createPortal)(k,$));da.defaultProps={container:document.body};const vl=da;var yl=e("rlwexfKi"),_l=e("g6WV7s1k");const Cl=(0,n.default)(H.Row)` &:not(:last-child) { margin-bottom: 7px; } `,Ra=(0,n.default)(H.Col)(({theme:k})=>(0,n.css)` font-weight: bold; @media (min-width: ${k.breakpoints.min.md}) { text-align: right; } `),Gi=(0,n.default)(Jt.Z)(({theme:k,value:$})=>(0,n.css)` color: ${$?k.colors.variant.success:k.colors.variant.danger}; `),pr=({value:k})=>s.createElement(s.Fragment,null,s.createElement(Gi,{name:k?"check-circle":"times-circle",value:k})," ",k?"yes":"no"),Eu=k=>typeof k=="boolean"?s.createElement(pr,{value:k}):k||"-",br=({label:k,value:$,help:q,className:Ne})=>s.createElement(Cl,{className:Ne},s.createElement(Ra,{sm:3},k),s.createElement(H.Col,{sm:9,className:"read-only-value-col"},Eu($),q&&s.createElement(H.HelpBlock,null,q)));br.defaultProps={help:void 0,className:void 0};const Tl=br;var Sl=e("4IfE3Ihm"),fu=Object.defineProperty,Al=(k,$,q)=>$ in k?fu(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,qs=(k,$,q)=>(Al(k,typeof $!="symbol"?$+"":$,q),q);const ji=n.default.button(({theme:k})=>(0,n.css)` opacity: 0.3; background-color: ${k.colors.variant.primary}; width: 40px; height: 40px; position: fixed; bottom: 60px; right: 20px; border-radius: 5px; border: none; &:hover { opacity: 1; } &.middle { right: 35%; } `),Pl=(0,n.default)(Jt.Z)(({theme:k})=>(0,n.css)` color: ${k.utils.readableColor(k.colors.variant.primary)}; position: absolute; top: 50%; left: 50%; margin-top: -9px; margin-left: -5px; `);class Ia extends s.Component{constructor(){super(),qs(this,"showButton",()=>{this.setState({hideButton:window.scrollY===0})}),qs(this,"scrollStep",()=>{const{intervalId:$}=this.state,{scrollSteps:q}=this.props;window.pageYOffset===0&&clearInterval($),window.scroll(0,window.pageYOffset-q)}),qs(this,"scrollToTop",()=>{const{delay:$}=this.props,q=setInterval(this.scrollStep.bind(this),$);this.setState({intervalId:q})}),this.state={intervalId:0,hideButton:!0}}componentDidMount(){window.addEventListener("scroll",this.showButton)}componentWillUnmount(){window.removeEventListener("scroll",this.showButton)}render(){const{position:$}=this.props,{hideButton:q}=this.state;return q?s.createElement("span",null):s.createElement(ji,{title:"Back to top",type:"button",className:$,onClick:this.scrollToTop},s.createElement(Pl,{name:"chevron-up"}))}}qs(Ia,"propTypes",{delay:r().number,scrollSteps:r().number,position:r().string}),qs(Ia,"defaultProps",{delay:5,scrollSteps:50,position:""});const Ao=Ia;var bl=e("TMaijZ0a"),Dl=e("u1Q00LVl"),hu=e.n(Dl),zi=e("+KM7MH1U"),er=e.n(zi),rs=e("LLTH+mT+"),tr=e.n(rs),oo=e("pVin5tMh"),as=e.n(oo),Wo=e("QTOlkT3a"),bs={};bs.styleTagTransform=Cn(),bs.setAttributes=ot(),bs.insert=gt().bind(null,"head"),bs.domAPI=dt(),bs.insertStyleElement=Xt();var ma=Ye()(Wo.Z,bs);const Gr=Wo.Z&&Wo.Z.locals?Wo.Z.locals:void 0;var Ol=Object.defineProperty,jr=(k,$,q)=>$ in k?Ol(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,$o=(k,$,q)=>(jr(k,typeof $!="symbol"?$+"":$,q),q);class zr extends s.Component{constructor($){super($),$o(this,"handleSelectionChange",q=>{const{onItemSelect:Ne}=this.props;this.setState({selectedItems:q}),Ne(q,()=>this.overlay.hide())}),$o(this,"clearItemSelection",()=>{this.handleSelectionChange([])}),$o(this,"handleItemSelection",q=>()=>{const{multiple:Ne}=this.props,{selectedItems:Ge}=this.state;let tt;Ne?tt=Ge.includes(q)?tr()(Ge,q):hu()(Ge,q):tt=[q],this.handleSelectionChange(tt)}),$o(this,"filterData",(q,Ne)=>{const Ge=Ne.filter(tt=>tt.match(new RegExp(q,"i")));this.setState({filterText:q,filteredItems:Ge})}),$o(this,"handleFilterChange",q=>Ne=>{const Ge=Ne.target.value.trim();this.filterData(Ge,q)}),$o(this,"renderDataFilter",q=>{const{filterPlaceholder:Ne}=this.props,{filterText:Ge}=this.state;return s.createElement(H.FormGroup,{controlId:"dataFilterInput",className:Gr.dataFilterInput},s.createElement(H.FormControl,{type:"text",placeholder:Ne,value:Ge,onChange:this.handleFilterChange(q)}))}),$o(this,"renderClearSelectionItem",()=>{const{clearSelectionText:q}=this.props;return s.createElement(H.ListGroupItem,{onClick:this.clearItemSelection},s.createElement(Jt.Z,{name:"times",fixedWidth:!0,className:"text-danger"})," ",q)}),this.state={filterText:"",filteredItems:$.items,selectedItems:$.selectedItems}}UNSAFE_componentWillReceiveProps($){const{items:q,selectedItems:Ne}=this.props,{filterText:Ge}=this.state;er()(Ne,$.selectedItems)||this.setState({selectedItems:$.selectedItems}),q!==$.items&&this.filterData(Ge,$.items)}render(){const{displayDataFilter:$,itemFormatter:q,items:Ne,placement:Ge,triggerAction:tt,triggerNode:wt,disabled:Un,id:Tn,title:kn}=this.props,{filteredItems:Eo,selectedItems:eo}=this.state,fo=s.createElement(H.Popover,{id:Tn,title:kn,placement:Ge,className:Gr.customPopover},$&&this.renderDataFilter(Ne),eo.length>0&&this.renderClearSelectionItem(),s.createElement(as(),{className:Gr.scrollableList},s.createElement(H.ListGroup,null,Eo.map(to=>s.createElement(H.ListGroupItem,{key:to,onClick:Un?()=>{}:this.handleItemSelection(to),active:eo.includes(to),disabled:Un},q(to))))));return s.createElement(Ro.Z,{ref:to=>{this.overlay=to},trigger:tt,placement:Ge,overlay:fo,rootClose:!0},wt)}}$o(zr,"propTypes",{id:r().string.isRequired,placement:r().oneOf(["top","right","bottom","left"]),title:r().string.isRequired,triggerNode:r().node.isRequired,triggerAction:r().oneOf(["click","hover","focus"]),items:r().arrayOf(r().string),itemFormatter:r().func,multiple:r().bool,selectedItems:r().arrayOf(r().string),onItemSelect:r().func.isRequired,displayDataFilter:r().bool,filterPlaceholder:r().string,clearSelectionText:r().string,disabled:r().bool}),$o(zr,"defaultProps",{placement:"bottom",triggerAction:"click",items:[],itemFormatter:k=>k,multiple:!1,selectedItems:[],displayDataFilter:!0,filterPlaceholder:"Type to filter",clearSelectionText:"Clear selection",disabled:!1});const Fs=zr;var Ma=Object.defineProperty,Vr=(k,$,q)=>$ in k?Ma(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,gr=(k,$,q)=>(Vr(k,typeof $!="symbol"?$+"":$,q),q);const Rl=(0,n.default)(H.ListGroupItem)` display: flex; justify-content: space-between; `;class Hr extends s.Component{constructor(){super(...arguments),gr(this,"_getOptionId",$=>typeof $=="string"?$:$[this.props.idKey]),gr(this,"_getOptionDisplayValue",$=>typeof $=="string"?$:$[this.props.displayKey]),gr(this,"_onAddOption",$=>{if($==="")return;const q=this.props.selectedOptions.slice();this.props.selectedOptionsType==="string"?q.push($):q.push(this.props.options.filter(Ne=>this._getOptionId(Ne)===$)[0]),typeof this.props.onChange=="function"&&this.props.onChange(q)}),gr(this,"_onRemoveOption",$=>()=>{const q=this.props.selectedOptions.filter((Ne,Ge)=>Ge!==$);typeof this.props.onChange=="function"&&this.props.onChange(q)})}UNSAFE_componentWillReceiveProps($){this.props.selectedOptions!==$.selectedOptions&&this.select.clearValue()}render(){const $=this.props.selectedOptions.map((q,Ne)=>s.createElement(Rl,{key:`${this._getOptionId(q)}-${Ne}`},s.createElement("div",null,this._getOptionDisplayValue(q)),s.createElement(H.Button,{bsStyle:"danger",bsSize:"xsmall",onClick:this._onRemoveOption(Ne)},"Remove")));return s.createElement("div",null,s.createElement(vn.Z,{ref:q=>{this.select=q},autoFocus:this.props.autoFocus,options:this.props.options,onChange:this._onAddOption,clearable:!1}),$.length>0&&s.createElement(H.ListGroup,{style:{marginTop:10}},$))}}gr(Hr,"propTypes",{options:r().array,selectedOptionsType:r().oneOf(["string","object"]),selectedOptions:r().arrayOf(r().oneOfType([r().string,r().object])),displayKey:r().string,idKey:r().string,onChange:r().func,autoFocus:r().bool}),gr(Hr,"defaultProps",{autoFocus:void 0,displayKey:"label",idKey:"value",onChange:void 0,options:void 0,selectedOptions:void 0,selectedOptionsType:"string"});const Il=Hr,xa=(0,n.default)(k=>s.createElement(te.Z,{...k}))` margin-left: 8px; `,La=({type:k,description:$})=>{const q=Ne=>Ne.replaceAll("_"," ");return s.createElement(xa,{title:"Sharing not possible",pullRight:!1},$||`Only owners of this ${q(k)} are allowed to share it.`)};La.defaultProps={description:void 0};const Ba=La,pa=({bsStyle:k,bsSize:$,entityId:q,entityType:Ne,onClick:Ge,disabledInfo:tt})=>s.createElement(Yo,{id:q,type:Ne},({disabled:wt})=>s.createElement(ns.Z,{bsStyle:k,bsSize:$,onClick:Ge,disabled:!!tt||wt,title:"Share"},s.createElement(Jt.Z,{name:"user-plus"})," Share ",(!!tt||wt)&&s.createElement(Ba,{type:Ne,description:tt})));pa.defaultProps={bsStyle:"default",disabledInfo:void 0,bsSize:void 0};const Ua=pa;var wa=e("K/dyB2Jn"),Wa=e("M04itGxI"),Ml=e("D4SbLiE/"),kr=e.n(Ml);const Na=kr()({displayName:"TimeUnit",propTypes:{value:r().number.isRequired,unit:r().oneOf(["NANOSECONDS","MICROSECONDS","MILLISECONDS","SECONDS","MINUTES","HOURS","DAYS"]).isRequired,zeroIsNever:r().bool},getDefaultProps(){return{zeroIsNever:!0}},UNITS:{NANOSECONDS:"nanoseconds",MICROSECONDS:"microseconds",MILLISECONDS:"milliseconds",SECONDS:"seconds",MINUTES:"minutes",HOURS:"hours",DAYS:"days"},render(){return this.props.value===0&&this.props.zeroIsNever?s.createElement("span",null,"Never"):s.createElement("span",null,this.props.value,"\xA0",this.UNITS[this.props.unit])}});var Za=e("ATOIS62c"),Qr=e("Ex+j8X3w"),Fa=e("ASBo/Til"),xl=e.n(Fa),Dr=e("efAt+LzL"),ls=e.n(Dr),Xr=Object.defineProperty,Ds=(k,$,q)=>$ in k?Xr(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,is=(k,$,q)=>(Ds(k,typeof $!="symbol"?$+"":$,q),q);class Ll extends s.Component{constructor(){super(...arguments),is(this,"_UNCLASSIFIED_AREA","Unclassified"),is(this,"getValue",()=>this.timezone.getValue()),is(this,"_formatTimezones",()=>{const $={};xl().tz.names().forEach(Ne=>{const Ge=Ne.split("/"),tt=Ge.length>1?Ge[0]:this._UNCLASSIFIED_AREA,wt=Ge.length>1?Ge[1]:Ge[0];$[tt]||($[tt]=[]),$[tt].push(wt)});const q=[];return Object.keys($).sort().forEach(Ne=>{q.push({label:Ne,disabled:!0,value:Ne});const tt=ls()($[Ne]).sort().map(wt=>({value:Ne===this._UNCLASSIFIED_AREA?wt:`${Ne}/${wt}`,label:wt.replace("_"," ")}));q.push(...tt)}),q}),is(this,"_renderOption",$=>$.disabled?s.createElement("span",{key:$.value,title:$.value},$.label):s.createElement("span",{key:$.value,title:$.value},"\xA0 ",$.label))}render(){const $=this._formatTimezones(),{onChange:q,...Ne}=this.props;return s.createElement(vn.Z,{ref:Ge=>{this.timezone=Ge},...Ne,inputId:"timezone-select",onChange:q,placeholder:"Pick a time zone",options:$,optionRenderer:this._renderOption})}}is(Ll,"propTypes",{onChange:r().func}),is(Ll,"defaultProps",{onChange:()=>{}});const Er=Ll;var Bl=e("Z6NUVhuV"),Ea=e("VPaD/Np4"),Ul=e.n(Ea),fa=e("kqAR+wt5"),fr=e.n(fa),wl=e("4ukn9ADr"),Ka=e("jsQWU+f2"),Wl=e("U1Iufsob"),Or=e("MdYBRjRJ"),$a=e("eFxcQyPT"),Nl=Object.defineProperty,ha=(k,$,q)=>$ in k?Nl(k,$,{enumerable:!0,configurable:!0,writable:!0,value:q}):k[$]=q,va=(k,$,q)=>(ha(k,typeof $!="symbol"?$+"":$,q),q);class Po extends s.Component{constructor(){super(...arguments),va(this,"_getFilteredProps",()=>{let $=Ul().fromJS(this.props);return["valueLink","onChange"].forEach(q=>{$.has(q)&&($=$.delete(q))}),$.toJS()})}componentDidMount(){if(this.fieldInput){const{autoFocus:$,valueLink:q,onChange:Ne}=this.props,Ge=fr()(this.fieldInput.getInputDOMNode());(0,$a.ZP)("GET",(0,Or.DC)(Wl.Z.SystemApiController.fields().url)).then(wt=>{Ge.typeahead({hint:!0,highlight:!0,minLength:1},{name:"fields",displayKey:"value",source:Ka.Z.substringMatcher(wt.fields,"value",6)}),$&&(Ge.focus(),Ge.typeahead("close"))});const tt=Oa.findDOMNode(this.fieldInput);fr()(tt).on("typeahead:change typeahead:selected",wt=>{Ne&&Ne(wt),q&&q.requestChange(wt.target.value)})}}componentWillUnmount(){if(this.fieldInput){fr()(this.fieldInput.getInputDOMNode()).typeahead("destroy");const q=Oa.findDOMNode(this.fieldInput);fr()(q).off("typeahead:change typeahead:selected")}}render(){const{id:$,label:q,valueLink:Ne,error:Ge,onBlur:tt}=this.props;return s.createElement(H.Input,{id:$,ref:wt=>{this.fieldInput=wt},label:q,onBlur:tt,error:Ge,wrapperClassName:"typeahead-wrapper",defaultValue:Ne?Ne.value:null,...this._getFilteredProps()})}}va(Po,"propTypes",{id:r().string.isRequired,valueLink:r().object,label:r().string,autoFocus:r().bool,onChange:r().func,onBlur:r().func,error:r().string}),va(Po,"defaultProps",{valueLink:void 0,autoFocus:!1,label:void 0,onChange:()=>{},onBlur:()=>{},error:void 0});const Zl=Po;var Vi=e("YzrsREPQ"),Fl=e("gTexEe+8"),Kl=e("nQTsOTNU"),hr=e("ibdPvtmL"),qo=e("0TVxnHwi"),$l=e("iltCXley"),Ga=e("8OvTct/Z"),Os=e("v4GbOr/o");const Rs="org.graylog2.system.urlwhitelist.UrlWhitelist",ja=({newUrlEntry:k,urlType:$,onUpdate:q})=>{const Ne=(0,s.useRef)(),[Ge,tt]=(0,s.useState)({entries:[],disabled:!1}),[wt,Un]=(0,s.useState)(!1),[Tn,kn]=(0,s.useState)(),[Eo,eo]=(0,s.useState)(!1),{configuration:fo}=(0,Es.o)(hr.i),to=fo[Rs],cs=(0,gs.Z)(),us=(0,Ga.Z)();(0,s.useEffect)(()=>{(0,qo.rq)(cs.permissions,["urlwhitelist:read"])&&hr.h.listWhiteListConfig(Rs)},[cs]);const Is=(0,s.useCallback)(ho=>{const Ms=(0,$l.Z)(),Jr={entries:[...ho.entries,{id:Ms,title:"",value:k,type:$!=null?$:"literal"}],disabled:ho.disabled};kn(Ms),tt(Jr)},[k,$]);(0,s.useEffect)(()=>{const{entries:ho}=Ge;to&&(ho.length===0||Ne.current!==k)&&Is(to),Ne.current=k},[Is,to,Ge,k,$]);const nr=()=>{eo(!0)},or=()=>{eo(!1),Is(to)},po=(ho,Ms)=>{tt(ho),Un(Ms)},Ks=ho=>{ho&&(ho.preventDefault(),ho.stopPropagation()),us(Os.A.URLWHITELIST_CONFIGURATION_UPDATED,{app_section:"urlwhitelist",app_action_value:"configuration-update"}),wt&&hr.h.updateWhitelist(Rs,Ge).then(()=>{q(),or()})};if(to){const{entries:ho,disabled:Ms}=Ge;return s.createElement(s.Fragment,null,s.createElement($t.Z,{permissions:"urlwhitelist:write"},s.createElement(H.Button,{bsStyle:"info",bsSize:"xs",onClick:nr},"Add to URL Whitelist")),s.createElement(Fl.Z,{show:Eo,bsSize:"lg",title:"Update Whitelist Configuration",onCancel:or,onSubmitForm:Ks,submitButtonDisabled:!wt,submitButtonText:"Update configuration"},s.createElement("h3",null,"Whitelist URLs"),s.createElement(Kl.Z,{key:Tn,urls:ho,disabled:Ms,onUpdate:po,newEntryId:Tn})))}return null};ja.propTypes={newUrlEntry:r().string,onUpdate:r().func,urlType:r().oneOf(["regex","literal"])},ja.defaultProps={newUrlEntry:"",onUpdate:()=>{},urlType:void 0};const Gl=ja;var za=e("yTnlRDNA"),jl=e("S6FuRS7B");const Va=({label:k,onChange:$,validationMessage:q,validationState:Ne,url:Ge,onValidationChange:tt,labelClassName:wt,wrapperClassName:Un,urlType:Tn,autofocus:kn})=>{const[Eo,eo]=(0,s.useState)(!1),[fo,to]=(0,s.useState)(Ne),[cs,us]=(0,s.useState)(q),Is=($s,Gs)=>{const js="${key}";return Gs&&Gs==="regex"&&(0,Or.K2)($s)?za.Z.urlWhiteListGenerateRegex($s,js):$s},[nr,or]=(0,s.useState)(Ge),po=()=>fo==="error"&&(0,Or.K2)(Ge),Ks=(0,s.useRef)(),ho=(0,s.useCallback)(()=>{Ge&&za.Z.urlWhiteListCheck(Ge).then(Gs=>{if(!Gs.is_whitelisted&&Ne===null){to("error"),tt("error");const js=(0,Or.K2)(Ge)?`URL ${Ge} is not whitelisted`:`URL ${Ge} is not a valid URL.`;us(js)}else us(q),to(Ne),tt(Ne);eo(Gs.is_whitelisted)})},[Ge,q,Ne,tt]),Ms=()=>{(0,jl._X)(Ks.current.getInputDOMNode()),ho()};(0,s.useEffect)(()=>{const $s=()=>{if(Ge){const js=Is(Ge,Tn);typeof js=="object"?js.then(kl=>{or(kl.regex)}):or(Ge)}},Gs=setTimeout(()=>$s(),250);return()=>clearTimeout(Gs)},[Ge,Tn]),(0,s.useEffect)(()=>{const $s=setTimeout(()=>ho(),250);return()=>clearTimeout($s)},[Ge,Ne,ho]);const Jr=po()&&!Eo?s.createElement(Gl,{newUrlEntry:nr,onUpdate:Ms,urlType:Tn}):"",Vl=s.createElement(s.Fragment,null,Ne===null?cs:q," ",Jr),Hl=fo===""?null:fo;return s.createElement(H.Input,{type:"text",id:"url",name:"url",label:k,ref:Ks,autoFocus:kn,required:!0,onChange:$,help:Vl,bsStyle:Hl,value:Ge,labelClassName:wt,wrapperClassName:Un})};Va.propTypes={autofocus:r().bool,label:r().string.isRequired,onChange:r().func.isRequired,validationState:r().string,validationMessage:r().oneOfType([r().object,r().string]),url:r().string,onValidationChange:r().func,labelClassName:r().string,wrapperClassName:r().string,urlType:r().oneOf(["regex","literal"])},Va.defaultProps={autofocus:!0,url:"",validationState:"",validationMessage:"",labelClassName:"",wrapperClassName:"",urlType:"literal",onValidationChange:()=>{}};const ya=Va;var vr=e("1e+nFvZs"),zl=e("yKXoRDZT");const ka=n.default.label(({theme:k})=>(0,n.css)` display: flex; align-items: center; margin: 0; input { border: 0; clip: rect(0 0 0 0); clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; white-space: nowrap; &:checked + .slider { background-color: ${k.colors.variant.dark.default}; &::before { transform: translate(16px, -50%); } } &:disabled + .slider { opacity: 0.5; cursor: not-allowed; &::before { background-color: ${k.colors.variant.light.default}; } } } .slider { box-sizing: border-box; margin: 0 9px; width: 36px; height: 22px; border-radius: 30px; background-color: ${k.colors.gray[80]}; box-shadow: inset 0 1px 3px 0 rgb(0 0 0 / 20%); display: inline-block; position: relative; cursor: pointer; &::before { transition: transform 75ms ease-in-out; content: ''; display: block; width: 18px; height: 18px; background-color: ${k.colors.brand.secondary}; box-shadow: 0 2px 3px 0 rgb(0 0 0 / 25%), 0 2px 8px 0 rgb(32 37 50 / 16%); position: absolute; border-radius: 100%; top: 11px; transform: translate(2px, -50%); } } `),Qa=(0,t.Z)(()=>Promise.all([e.e("1255d548-3618"),e.e("1255d548-2341"),e.e("1255d548-3521")]).then(e.bind(e,"DWNbF6Hg")))},ty2gyrHp:(M,C,e)=>{"use strict";e.d(C,{J:()=>g,r:()=>o.rU});var t=e("Z7aTuO5B"),s=e("yAXMqwrl"),o=e("1jSicls3");const r=["Button","NavItem"],n=p=>String(p).split(/[?#]/)[0],c=(p,E,a,u,f)=>{const y=n(E),T=f?p.startsWith(y):y===p;return r.includes(u)&&T?`active ${a!=null?a:""}`:a},v=p=>p.button===0,d=p=>!!(p.metaKey||p.altKey||p.ctrlKey||p.shiftKey),g=({children:p,onClick:E,to:a,relativeActive:u,...f})=>{const{pathname:y}=(0,s.useLocation)(),{props:{onClick:T,className:P,disabled:O},type:{displayName:b}}=t.Children.only(p),L=typeof a=="object"&&"pathname"in a?a.pathname:a,x=(0,t.useMemo)(()=>c(y,L,P,b,u),[y,L,P,b,u]),W=(0,o.gs)(L),N=(0,t.useCallback)(Z=>{!v(Z)||d(Z)||O||(Z.preventDefault(),Z.stopPropagation(),T&&T(),E&&E(),O||W(Z))},[O,T,E,W]);return t.cloneElement(t.Children.only(p),{...f,className:x,onClick:N,disabled:!!O,href:O?void 0:L})};g.defaultProps={relativeActive:!1}},"+qc3iAHh":(M,C,e)=>{"use strict";e.d(C,{Ig:()=>v,fI:()=>E,nz:()=>u,$O:()=>O,Hi:()=>N,Xu:()=>ne,NJ:()=>ee,Ki:()=>ye,nv:()=>ut,$H:()=>Je});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("S6FuRS7B"),n=e("uZqmR+ju");const c=({autoFocus:Re,field:le,onChange:me,title:re,typeName:ce,value:Q})=>{const J=ie=>{const ge=(0,r.n6)(ie.target);me(re,ge)};return t.createElement(n.Input,{id:`${ce}-${re}`,name:`configuration[${re}]`,type:"checkbox",label:le.human_name,checked:Q,help:le.description,onChange:J,autoFocus:Re})};c.propTypes={autoFocus:o().bool,field:o().object.isRequired,onChange:o().func.isRequired,title:o().string.isRequired,typeName:o().string.isRequired,value:o().bool},c.defaultProps={autoFocus:!1,value:!1};const v=c;var d=e("gTexEe+8");const g=["text","inline_binary"],p=(0,t.forwardRef)(({cancelAction:Re,configFields:le,children:me,titleHelpText:re,includeTitleField:ce,submitAction:Q,title:J,titleValue:ie,typeName:ge,values:fe,wrapperComponent:Ce,submitButtonText:Oe},nt)=>{const[et,Fe]=(0,t.useState)(!1),[Pe,$e]=(0,t.useState)(void 0),[Ot,ft]=(0,t.useState)(void 0),[Tt,Lt]=(0,t.useState)({});(0,t.useEffect)(()=>{const de={};le&&Object.keys(le).forEach(pt=>{de[pt]=le[pt].default_value}),ft({...de,...fe}),Lt({})},[et,le,fe]),(0,t.useEffect)(()=>{$e(ie)},[ie,et]);const Be=()=>{const de={type:ge,configuration:{}};return ce&&(de.title=Pe),Object.keys(le).forEach(pt=>{de.configuration[pt]=Ot[pt]===void 0?null:Ot[pt]}),de},lt=(de,pt)=>{const gn=le[de.name].position||100,Jt=le[pt.name].position||100;let An=gn-Jt;if(!An){const xe=Pn=>Pn?1:0;An=xe(le[de.name].is_optional)-xe(le[pt.name].is_optional)}return An||(An=de.pos-pt.pos),An},mt=de=>g.includes(de.type)?de.is_encrypted:!1,Rt=de=>{const pt=Object.entries(de.configuration).map(([Gt,gn])=>{const Jt=le[Gt],An=Tt[Gt];return mt(Jt)&&!(An!=null&&An.dirty)&&gn&&gn.is_set!==void 0?[Gt,{keep_value:!0}]:[Gt,gn]});return{...de,configuration:Object.fromEntries(pt)}},zt=()=>{Fe(!1),Re&&Re()},xt=()=>{const de=Be();Q(Rt(de)),Fe(!1)};(0,t.useImperativeHandle)(nt,()=>({open(){Fe(!0)},getValue(){return Be()}}));const nn=(de,pt)=>{$e(pt)},Vt=(de,pt,Gt=!0)=>{ft({...Ot,[de]:pt}),Lt({...Tt,[de]:{dirty:Gt}})},jn=(de,pt,Gt)=>{var gn;if(!Ot)return null;const Jt=Ot[pt];return t.createElement(u,{key:pt,typeName:ge,configField:de,configKey:pt,configValue:Jt,autoFocus:Gt,dirty:(gn=Tt[pt])==null?void 0:gn.dirty,onChange:Vt})};let Mt=!0,On;ce&&(On=t.createElement(Je,{key:`${ge}-title`,typeName:ge,value:Pe,onChange:nn,helpText:re}),Mt=!1);const Bn=Object.keys(le).map((de,pt)=>({name:de,pos:pt})).sort(lt).map(de=>{const pt=jn(le[de.name],de.name,Mt);return Mt&&(Mt=!1),pt});return t.createElement(Ce,{show:et,title:J,onCancel:zt,onSubmitForm:xt,submitButtonText:Oe},t.createElement("fieldset",null,t.createElement("input",{type:"hidden",name:"type",value:ge}),me,On,Bn))});p.propTypes={cancelAction:o().func,configFields:o().object,children:o().node,titleHelpText:o().string,includeTitleField:o().bool,submitAction:o().func.isRequired,title:o().node,titleValue:o().string,typeName:o().string,values:o().object,wrapperComponent:o().elementType,submitButtonText:o().string.isRequired},p.defaultProps={cancelAction:()=>{},configFields:{},children:null,titleHelpText:"",title:null,includeTitleField:!0,titleValue:"",typeName:void 0,values:{},wrapperComponent:d.Z};const E=p,a=({typeName:Re,configField:le,configKey:me,configValue:re,dirty:ce,autoFocus:Q,onChange:J})=>{const ie=`${Re}-${me}`;switch(le.type){case"text":return t.createElement(ut,{key:ie,typeName:Re,title:me,field:le,value:re,dirty:ce,onChange:J,autoFocus:Q});case"number":return t.createElement(ye,{key:ie,typeName:Re,title:me,field:le,value:re,onChange:J,autoFocus:Q});case"boolean":return t.createElement(v,{key:ie,typeName:Re,title:me,field:le,value:re,onChange:J,autoFocus:Q});case"dropdown":return t.createElement(N,{key:ie,typeName:Re,title:me,field:le,value:re,onChange:J,autoFocus:Q,addPlaceholder:!0});case"list":return t.createElement(ee,{key:ie,typeName:Re,title:me,field:le,value:re,onChange:J,autoFocus:Q});case"inline_binary":return le.is_encrypted?t.createElement(ne,{key:ie,typeName:Re,title:me,field:le,value:re,dirty:ce,onChange:J,autoFocus:Q}):null;default:return null}};a.propTypes={typeName:o().string.isRequired,configField:o().object.isRequired,configKey:o().string.isRequired,configValue:o().any,autoFocus:o().bool,onChange:o().func.isRequired,dirty:o().bool},a.defaultProps={configValue:void 0,autoFocus:!1,dirty:!1};const u=a;var f=Object.defineProperty,y=(Re,le,me)=>le in Re?f(Re,le,{enumerable:!0,configurable:!0,writable:!0,value:me}):Re[le]=me,T=(Re,le,me)=>(y(Re,typeof le!="symbol"?le+"":le,me),me);class P extends t.Component{constructor(){super(...arguments),T(this,"PASSWORD_PLACEHOLDER","********"),T(this,"_formatRegularField",(le,me)=>{const{id:re}=this.props;let ce;return le==null||le===""||Array.isArray(le)&&le.length===0?ce=t.createElement("i",null,""):ce=Array.isArray(le)?le.join(", "):String(le),t.createElement("li",{key:`${re}-${me}`},t.createElement("div",{className:"key"},me,":")," ",t.createElement("div",{className:"value"},ce))}),T(this,"_formatEncryptedField",(le,me)=>{const{id:re}=this.props;let ce;return le.is_set?ce=this.PASSWORD_PLACEHOLDER:ce=t.createElement("i",null,""),t.createElement("li",{key:`${re}-${me}`},t.createElement("div",{className:"key"},me,":")," ",t.createElement("div",{className:"value"},ce))}),T(this,"_formatPasswordField",(le,me)=>{const{id:re}=this.props;return t.createElement("li",{key:`${re}-${me}`},t.createElement("div",{className:"key"},me,":"),t.createElement("div",{className:"value"},this.PASSWORD_PLACEHOLDER))}),T(this,"_formatConfiguration",(le,me,re)=>{if(!me)return"";const ce=Object.keys(me).sort().map(Q=>{const J=me[Q],ie=re&&re.requested_configuration?re.requested_configuration[Q]:void 0;return ie&&(ie.attributes.indexOf("is_password")>-1||ie.attributes.indexOf("is_sensitive")>-1)?this._formatPasswordField(J,Q):ie&&ie.is_encrypted?this._formatEncryptedField(J,Q):this._formatRegularField(J,Q)});return ce.length<1&&ce.push(t.createElement("li",{key:"placeholder"},"-- no configuration --")),t.createElement("ul",null,ce)})}render(){const{id:le,configuration:me,typeDefinition:re}=this.props;return t.createElement(n.Well,{bsSize:"small",className:"configuration-well react-configuration-well"},this._formatConfiguration(le,me,re))}}T(P,"propTypes",{id:o().string.isRequired,configuration:o().any,typeDefinition:o().object}),T(P,"defaultProps",{configuration:void 0,typeDefinition:{}});const O=P,b=(Re,le)=>Re.find(me=>me.toLowerCase()===le.toLowerCase())!==void 0,L=Re=>Re.is_optional&&Re.type!=="boolean"?t.createElement("span",{className:"configuration-field-optional"},"(optional)"):null,x={hasAttribute:b,optionalMarker:L},W=({autoFocus:Re,field:le,onChange:me,title:re,typeName:ce,value:Q,addPlaceholder:J})=>{const ie=(Oe,nt,et=!1)=>t.createElement("option",{key:`${ce}-${re}-${Oe}`,value:Oe,id:Oe,disabled:et},nt),ge=Oe=>{me(re,Oe.target.value)},fe=Object.entries(le.additional_info.values).map(([Oe,nt])=>ie(Oe,nt));J&&fe.unshift(ie("",`Select ${le.human_name||re}`,!0));const Ce=t.createElement(t.Fragment,null,le.human_name," ",L(le));return t.createElement(n.Input,{id:`${ce}-${re}`,name:`configuration[${re}]`,label:Ce,type:"select",value:Q,help:le.description,onChange:ge,autoFocus:Re,required:!le.is_optional},fe)};W.propTypes={autoFocus:o().bool,field:o().object.isRequired,onChange:o().func.isRequired,title:o().string.isRequired,typeName:o().string.isRequired,value:o().string,addPlaceholder:o().bool},W.defaultProps={autoFocus:!1,addPlaceholder:!1,value:""};const N=W;var Z=e("J6y4/h8P");const j=Z.default.span` vertical-align: middle; `,z=({field:Re,title:le,typeName:me,dirty:re,onChange:ce,value:Q,autoFocus:J})=>{const[ie,ge]=(0,t.useState)(void 0),[fe,Ce]=(0,t.useState)(!1),Oe=Q.is_set,nt=!Re.is_optional,et=!re&&Oe,Fe=`${me}-${le}`,Pe=t.createElement(t.Fragment,null,Re.human_name," ",L(Re)),$e=(zt,xt)=>{const nn=zt.result;if(nn&&typeof nn=="string"){const Vt=nn.replace(/^data:[\s\S]+\/[\s\S]+;base64,/,"");ge(xt.name),Re.is_encrypted?ce(le,{set_value:Vt}):ce(le,Vt)}},Ot=()=>{Ce(!0),ce(le,{delete_value:!0})},ft=()=>{Ce(!1),ge(void 0),ce(le,{is_set:!0},!1)},Tt=()=>Oe?t.createElement(n.Button,{type:"button",onClick:Ot},"Reset"):null,Lt=()=>fe?t.createElement(n.Button,{type:"button",onClick:ft},"Undo Reset"):null,Be=()=>ie?t.createElement(n.Button,{type:"button",onClick:()=>{ge(void 0),ce(le,"")}},"Remove"):null,lt=zt=>{const xt=new FileReader;xt.onloadend=nn=>$e(xt,zt),zt&&xt.readAsDataURL(zt)};return et?(()=>t.createElement(n.Input,{id:Fe,type:"password",name:`configuration[${le}]`,label:Pe,required:nt,readOnly:!0,help:Re.description,value:"encrypted value",buttonAfter:Tt(),autoFocus:J}))():(()=>ie?t.createElement(n.Input,{id:Fe,name:`configuration[${le}]`,label:Pe,required:nt,help:Re.description,autoFocus:J,buttonAfter:t.createElement(t.Fragment,null,Be(),Lt())},t.createElement(j,null,ie)):t.createElement(n.Input,{id:Fe,type:"file",name:`configuration[${le}]`,label:Pe,required:nt,help:Re.description,buttonAfter:Lt(),onChange:zt=>lt(zt.target.files[0]),autoFocus:J}))()};z.propTypes={autoFocus:o().bool,dirty:o().bool,field:o().object.isRequired,onChange:o().func.isRequired,title:o().string.isRequired,typeName:o().string.isRequired,value:o().object},z.defaultProps={autoFocus:!1,dirty:!1,value:{}};const ne=z;var Y=e("/GOzvPf6");const ae=({autoFocus:Re,field:le,onChange:me,title:re,typeName:ce,value:Q})=>{var J;const ie=Fe=>{const Pe=Fe===""?[]:Fe.split(",");me(re,Pe)},ge=!le.is_optional,fe=le.attributes.includes("allow_create"),Ce=((J=le.additional_info)==null?void 0:J.values)||{},Oe=Object.entries(Ce).map(([Fe,Pe])=>({value:Pe,label:Fe})),nt=t.createElement(t.Fragment,null,le.human_name," ",L(le)),et=Array.isArray(Q)?Q.join(","):Q;return t.createElement(n.Input,{id:`${ce}-${re}`,label:nt,help:le.description},t.createElement(Y.NU,{inputId:`${ce}-${re}`,name:`configuration[${re}]`,required:ge,autoFocus:Re,options:Oe,value:et,placeholder:`${fe?"Add":"Select"} ${le.human_name}`,onChange:ie,allowCreate:fe}))};ae.propTypes={autoFocus:o().bool,field:o().object.isRequired,onChange:o().func.isRequired,title:o().string.isRequired,typeName:o().string.isRequired,value:o().oneOfType([o().array,o().string])},ae.defaultProps={autoFocus:!1,value:void 0};const ee=ae;var ue=e("yDuYCNwc");const H=({autoFocus:Re,field:le,onChange:me,title:re,typeName:ce,value:Q})=>{const J=()=>({min:Number.MIN_SAFE_INTEGER,max:Number.MAX_SAFE_INTEGER}),ie=et=>{const{min:Fe,max:Pe}=J();switch(et.toUpperCase()){case"ONLY_NEGATIVE":return{min:Fe,max:-1};case"ONLY_POSITIVE":return{min:0,max:Pe};case"IS_PORT_NUMBER":return{min:0,max:65535};default:return{min:Fe,max:Pe}}},ge=()=>{const et=le.attributes.map(ie);return et.length>0?et[0]:J()},fe=({target:et})=>{const Fe=(0,r.n6)(et);me(re,Fe)},Ce=!le.is_optional,Oe=ge(),nt=t.createElement(t.Fragment,null,le.human_name," ",L(le));return t.createElement(ue.Z,{id:`${ce}-${re}`,label:nt,type:"number",name:`configuration[${re}]`,required:Ce,onChange:fe,value:Q||0,help:le.description,...Oe,autoFocus:Re})};H.propTypes={autoFocus:o().bool,field:o().object.isRequired,onChange:o().func.isRequired,title:o().string.isRequired,typeName:o().string.isRequired,value:o().number},H.defaultProps={autoFocus:!1,value:0};const ye=H,we=({field:Re,title:le,typeName:me,dirty:re,onChange:ce,value:Q,autoFocus:J})=>{const ie=!Re.is_optional,ge=Re.is_encrypted&&!re&&typeof Q!="string"&&Q.is_set,fe=!b(Re.attributes,"textarea")&&(b(Re.attributes,"is_password")||ge)?"password":"text",Ce=`${me}-${le}`,[Oe,nt]=(0,t.useState)(!1),et=t.createElement(t.Fragment,null,Re.human_name," ",L(Re)),Fe=()=>ge?"encrypted placeholder":typeof Q=="string"?Q:Q&&Q.set_value?Q.set_value:"",Pe=({target:Tt})=>{const Lt=(0,r.n6)(Tt);Re.is_encrypted?ce(le,{set_value:Lt}):ce(le,Lt)},$e=()=>{nt(!0),ce(le,{delete_value:!0})},Ot=()=>{nt(!1),ce(le,{is_set:!0},!1)},ft=()=>Oe?t.createElement(n.Button,{type:"button",onClick:Ot},"Undo Reset"):ge?t.createElement(n.Button,{type:"button",onClick:$e},"Reset"):null;return b(Re.attributes,"textarea")?t.createElement(n.Input,{id:Ce,type:"textarea",rows:10,label:et,name:`configuration[${le}]`,required:ie,help:Re.description,value:Fe(),onChange:Pe,autoFocus:J}):t.createElement(n.Input,{id:Ce,type:fe,name:`configuration[${le}]`,label:et,required:ie,help:Re.description,value:Fe(),readOnly:ge,onChange:Pe,buttonAfter:ft(),autoFocus:J})};we.propTypes={autoFocus:o().bool,dirty:o().bool,field:o().object.isRequired,onChange:o().func.isRequired,title:o().string.isRequired,typeName:o().string.isRequired,value:o().oneOfType([o().string,o().object])},we.defaultProps={autoFocus:!1,dirty:!1,value:""};const ut=we,ht=({typeName:Re,helpText:le,value:me,onChange:re})=>{const ce={is_optional:!1,attributes:[],human_name:"Title",description:le,is_encrypted:!1,additional_info:{},default_value:"",position:0,type:"text"};return t.createElement(ut,{key:`${Re}-title`,typeName:Re,title:"title",field:ce,value:me,onChange:re,autoFocus:!0})};ht.propTypes={helpText:o().string,onChange:o().func,typeName:o().string.isRequired,value:o().string},ht.defaultProps={helpText:"",onChange:()=>{},value:""};const Je=ht},"i+sOEQiN":(M,C,e)=>{"use strict";e.d(C,{I:()=>s,c:()=>t});var t=(o=>(o.SEARCHES_CLUSTER_CONFIG="org.graylog2.indexer.searches.SearchesClusterConfig",o.MESSAGE_PROCESSORS_CONFIG="org.graylog2.messageprocessors.MessageProcessorsConfig",o.SIDECAR_CONFIG="org.graylog.plugins.sidecar.system.SidecarConfiguration",o.EVENTS_CONFIG="org.graylog.events.configuration.EventsConfiguration",o.INDEX_SETS_DEFAULTS_CONFIG="org.graylog2.configuration.IndexSetsDefaultConfiguration",o.URL_WHITELIST_CONFIG="org.graylog2.system.urlwhitelist.UrlWhitelist",o.PERMISSIONS_CONFIG="org.graylog2.users.UserAndTeamsConfig",o.USER_CONFIG="org.graylog2.users.UserConfiguration",o.CERTIFICATE_RENEWAL_POLICY_CONFIG="org.graylog2.plugin.certificates.RenewalPolicy",o))(t||{}),s=(o=>(o.COLLECTORS_SYSTEM="org.graylog.plugins.collector.system.CollectorSystemConfiguration",o.AWS="org.graylog.aws.config.AWSPluginConfiguration",o.THREAT_INTEL="org.graylog.plugins.threatintel.ThreatIntelPluginConfiguration",o.FAILURE_PROCESSING="org.graylog.plugins.failure.config.EnterpriseFailureHandlingConfiguration",o.TRAFFIC_LIMIT_VIOLATION="org.graylog.plugins.license.violations.TrafficLimitViolationSettings",o.GEO_LOCATION="org.graylog.plugins.map.config.GeoIpResolverConfig",o))(s||{})},nQTsOTNU:(M,C,e)=>{"use strict";e.d(C,{Z:()=>N});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("IW7priiX"),n=e.n(r),c=e("Mx+G+HdB"),v=e.n(c),d=e("Pd5CUaTj"),g=e.n(d),p=e("J6y4/h8P"),E=e("yDuYCNwc"),a=e("hhdCSTZj"),u=e("93yMNhQL"),f=e("uZqmR+ju"),y=e("S6FuRS7B"),T=e("yTnlRDNA"),P=e("MdYBRjRJ"),O=e("iltCXley");const b=(0,p.default)(f.Table)` margin-top: 10px; `,L=async(Z,j,z)=>{const ne={title:{valid:!1},value:{valid:!1}};ne.title=j.title.trim().length<=0?{valid:!1}:{valid:!0};let Y={valid:!1};return j.type==="literal"?Y=(0,P.K2)(j.value)?{valid:!0}:{valid:!1}:j.type==="regex"&&j.value.trim().length>0&&(Y=(await T.Z.testRegexValidity(j.value)).is_valid?{valid:!0}:{valid:!1}),ne.value=Y,typeof z=="function"&&z(Z,j,ne),ne},x=v()(L,200),W=({urls:Z,onUpdate:j,disabled:z,newEntryId:ne})=>{const Y="literal",ae="regex",ee=[{value:Y,label:"Exact match"},{value:ae,label:"Regex"}];let ue={};const[H,ye]=(0,t.useState)({entries:Z,disabled:z}),[we,ut]=(0,t.useState)({errors:[]}),ht=(0,t.useRef)(!1),Je=fe=>{fe.preventDefault(),ye({...H,entries:[...H.entries,{id:(0,O.Z)(),title:"",value:"",type:Y}]})},Re=(fe,Ce)=>{fe.preventDefault();let Oe=n()(H);const nt=n()(we);nt.errors[Ce]=null,ut(nt),Oe.entries.splice(Ce,1),ye(Oe)},le=(0,t.useCallback)(()=>{let fe=!0;return we.errors.length>0&&we.errors.find(Ce=>(Ce&&Ce.title&&Ce.title.valid)===!1||Ce&&Ce.value&&Ce.value.valid===!1)&&(fe=!1),fe},[we]),me=(fe,Ce)=>{const Oe=n()(H);Oe.entries[fe]=Ce,ye(Oe)},re=(fe,Ce,Oe)=>{ut(nt=>{const et=n()(nt);return et.errors[fe]=Oe,et}),me(fe,Ce)},ce=async(fe,Ce,Oe)=>{const nt={...H.entries[Ce],[fe]:Oe};await x(Ce,nt,re)},Q=(fe,Ce)=>{ce(fe.target.name,Ce,(0,y.n6)(fe.target))},J=(fe,Ce)=>{ce("type",fe,Ce)},ie=fe=>fe===ae?"Not a valid Java regular expression":"Not a valid URL",ge=()=>H.entries.map((fe,Ce)=>t.createElement("tr",{key:fe.id},t.createElement("td",{style:{verticalAlign:"middle",textAlign:"center"}},Ce+1),t.createElement("td",null,t.createElement(E.Z,{type:"text",id:`title-input${Ce}`,ref:Oe=>{ue[`title${Ce}`]=Oe},help:we.errors[Ce]&&we.errors[Ce].title&&!we.errors[Ce].title.valid?"Required field":null,name:"title",bsStyle:we.errors[Ce]&&we.errors[Ce].title&&!we.errors[Ce].title.valid?"error":null,onChange:Oe=>Q(Oe,Ce),defaultValue:fe.title,required:!0})),t.createElement("td",null,t.createElement(E.Z,{type:"text",id:`value-input${Ce}`,ref:Oe=>{ue[`value${Ce}`]=Oe},help:we.errors[Ce]&&we.errors[Ce].value&&!we.errors[Ce].value.valid?ie(fe.type):null,name:"value",bsStyle:we.errors[Ce]&&we.errors[Ce].value&&!we.errors[Ce].value.valid?"error":null,onChange:Oe=>Q(Oe,Ce),defaultValue:fe.value,required:!0})),t.createElement("td",null,t.createElement(E.Z,{id:`url-input-type-${Ce}`,required:!0,autoFocus:!0},t.createElement(a.Z,{clearable:!1,options:ee,matchProp:"label",placeholder:"Select url type",onChange:Oe=>J(Ce,Oe),value:fe.type}))),t.createElement("td",null,t.createElement(f.Button,{onClick:Oe=>Re(Oe,Ce)},t.createElement(u.Z,{name:"trash-alt"}),t.createElement("span",{className:"sr-only"},"Delete entry")))));return(0,t.useEffect)(()=>{const fe=async()=>{const Oe=H.entries.findIndex(Fe=>Fe.id===ne);if(Oe<0)return!1;const nt=H.entries[Oe],et=await L(Oe,nt,re);return g()(et,"valid").some(Fe=>!!Fe)};(async Oe=>{const nt=Oe&&ne?await fe():le();j(H,nt)})(!ht.current),ht.current||(ht.current=!0)},[H]),t.createElement(t.Fragment,null,t.createElement(E.Z,{type:"checkbox",id:"whitelist-disabled",label:"Disable Whitelist",checked:H.disabled,onChange:()=>ye({...H,disabled:!H.disabled}),help:"Disable the whitelist functionality. Warning: Disabling this option will allow users to enter any URL in Graylog entities, which may pose a security risk."}),t.createElement(f.Button,{bsSize:"sm",onClick:fe=>Je(fe)},"Add Url"),t.createElement(b,{striped:!0,bordered:!0},t.createElement("thead",null,t.createElement("tr",null,t.createElement("th",null,"#"),t.createElement("th",null,"Title"),t.createElement("th",null,"URL"),t.createElement("th",null,"Type"),t.createElement("th",null,"Actions"))),t.createElement("tbody",null,ge())),t.createElement(f.Button,{bsSize:"sm",onClick:fe=>Je(fe)},"Add Url"))};W.propTypes={urls:o().array,disabled:o().bool,onUpdate:o().func,newEntryId:o().string},W.defaultProps={urls:[],disabled:!1,onUpdate:()=>{},newEntryId:void 0};const N=W},m5sCWlWB:(M,C,e)=>{"use strict";e.d(C,{Z:()=>L});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P");const n=e.p+"a991861284654f43baeb.jpg";var c=e("0eB11aFj"),v=e("qQvt58D8"),d=e("ww+BtWnX"),g=e.n(d),p=e("uZqmR+ju");const E=r.default.h1(({theme:x})=>(0,r.css)` font-size: ${x.fonts.size.extraLarge}; margin-bottom: 15px; `),a=(0,r.default)(p.Row)` height: 82vh; `,u=(0,r.default)(p.Jumbotron)(({theme:x})=>(0,r.css)` background-color: ${g()(x.colors.global.contentBackground).alpha(.8).css()}; text-align: center; `),f=({children:x,title:W})=>t.createElement(a,null,t.createElement(p.Col,{mdOffset:2,md:8},t.createElement(u,null,t.createElement(E,null,W),x)));f.propTypes={children:o().node.isRequired,title:o().string.isRequired};const y=f,T=()=>(0,r.css)` body { background: url(${({backgroundImage:x})=>x}) no-repeat center center fixed; background-size: cover; } `,P=r.default.div(({theme:x})=>(0,r.css)` margin-left: auto; margin-right: auto; text-align: left; dt { font-size: ${x.fonts.size.body}; font-weight: normal; overflow: auto; } p { font-size: inherit; } `),O=(0,r.createGlobalStyle)` ${T()} `,b=({children:x,title:W,description:N,backgroundImage:Z,displayPageLayout:j})=>{const z=j?c.Z:t.Fragment;return t.createElement(v.Z,{title:W},t.createElement(z,null,t.createElement(O,{backgroundImage:Z}),t.createElement(y,{title:W},N,x&&t.createElement(P,null,x))))};b.propTypes={children:o().node,description:o().node.isRequired,displayPageLayout:o().bool,title:o().string.isRequired,backgroundImage:o().string},b.defaultProps={children:void 0,displayPageLayout:!0,backgroundImage:n};const L=b},"KNFOZ/rv":(M,C,e)=>{"use strict";e.d(C,{Z:()=>z});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("uZqmR+ju"),n=e("/GOzvPf6"),c=e("dFpwyWHg"),v=e.n(c),d=e("C2ikvoS0"),g=e.n(d),p=e("1IntWRSu"),E=e.n(p),a=e("8nGWeFnd"),u=e.n(a),f=e("TeAcaicX"),y=e.n(f),T=e("eE3+5goe"),P=e.n(T),O=e("ykMrd0fI"),b={};b.styleTagTransform=P(),b.setAttributes=u(),b.insert=E().bind(null,"head"),b.domAPI=g(),b.insertStyleElement=y();var L=v()(O.Z,b);const x=O.Z&&O.Z.locals?O.Z.locals:void 0;var W=Object.defineProperty,N=(ne,Y,ae)=>Y in ne?W(ne,Y,{enumerable:!0,configurable:!0,writable:!0,value:ae}):ne[Y]=ae,Z=(ne,Y,ae)=>(N(ne,typeof Y!="symbol"?Y+"":Y,ae),ae);class j extends t.Component{constructor(){super(...arguments),Z(this,"state",{displayDetails:!1}),Z(this,"toggleDisplayDetails",()=>{const{displayDetails:Y}=this.state;this.setState({displayDetails:!Y})})}render(){const{type:Y,notification:ae,definitionNotification:ee,children:ue}=this.props,{displayDetails:H}=this.state;return t.createElement(t.Fragment,null,t.createElement("h4",null,ae.title||ee.notification_id),t.createElement("dl",null,t.createElement("dd",null,Y),t.createElement("dd",null,t.createElement(r.Button,{bsStyle:"link",className:"btn-text",bsSize:"xsmall",onClick:this.toggleDisplayDetails},t.createElement(n.JO,{name:`caret-${H?"down":"right"}`}),"\xA0",H?"Less details":"More details"),H&&t.createElement(r.Table,{condensed:!0,hover:!0,className:x.fixedTable},t.createElement("tbody",null,t.createElement("tr",null,t.createElement("td",null,"Description"),t.createElement("td",null,ae.description||"No description given")),ue)))))}}Z(j,"propTypes",{type:o().string.isRequired,notification:o().object.isRequired,definitionNotification:o().object.isRequired,children:o().element.isRequired});const z=j},"0eB11aFj":(M,C,e)=>{"use strict";e.d(C,{Z:()=>L});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("yAXMqwrl"),c=e("l4nHKZ4j"),v=e("uZqmR+ju"),d=e("QL8i6bcz"),g=e("kbGtT3aS"),p=e("8fnsnG21"),E=e("9xj2LQzD");const a=({system:x})=>{const[W,N]=(0,t.useState)();return(0,t.useEffect)(()=>{let Z=!0;return E.B.jvm().then(j=>{Z&&N(j)}),()=>{Z=!1}},[]),x&&W?t.createElement(t.Fragment,null,"Graylog ",x.version," on ",x.hostname," (",W.info,")"):t.createElement(t.Fragment,null,"Graylog ",(0,g.VV)())};a.propTypes={system:o().shape({version:o().string,hostname:o().string})},a.defaultProps={system:void 0};const u=(0,p.Z)(a,{system:E.B},({system:{system:x}={system:void 0}})=>({system:x})),f=r.default.footer(({theme:x})=>(0,r.css)` text-align: center; font-size: ${x.fonts.size.small}; color: ${x.colors.gray[70]}; height: 20px; /* This combination of padding and box-sizing is required to fix a firefox flexbox bug */ box-sizing: content-box; padding-bottom: ${x.spacings.sm}; @media print { display: none; } `),y=()=>{const x=d.G.exports("pageFooter");if(x.length===1){const W=x[0].component;return t.createElement(f,null,t.createElement(W,null))}return t.createElement(f,null,t.createElement(u,null))};y.propTypes={};const T=y,P=r.default.div(({theme:x})=>` display: flex; flex-direction: column; overflow: auto; height: 100%; width: 100%; /* Bottom gap is defined by the footer */ padding: ${x.spacings.sm} ${x.spacings.sm} 0 ${x.spacings.sm}; `),O=(0,r.default)(v.Grid)` width: 100%; flex: 1; margin-bottom: 10px; `,b=({children:x,className:W,FooterComponent:N,NotificationsComponent:Z})=>t.createElement(P,{className:W},t.createElement(Z,null,t.createElement(O,{fluid:!0,className:"page-content-grid"},x||t.createElement(n.Outlet,null)),t.createElement(N,null)));b.propTypes={children:o().node,className:o().string},b.defaultProps={children:void 0,className:void 0,FooterComponent:T,NotificationsComponent:c.Z};const L=b},UnR9x6QB:(M,C,e)=>{"use strict";e.d(C,{Z:()=>W});var t=e("Z7aTuO5B"),s=e("J6y4/h8P");const o=e.p+"3c486f16f8deb73e199c.jpg";var r=e("ii0bleBb"),n=e.n(r);const c=s.default.div(({theme:N})=>(0,s.css)` background-color: ${N.colors.global.contentBackground}; display: flex; justify-content: center; align-items: center; width: 33%; padding: 30px; max-width: 440px; min-width: 330px; `),v=s.default.div` width: 100%; `,d=({children:N})=>t.createElement(c,{className:"container"},t.createElement(v,null,N));d.propTypes={children:n().node.isRequired};const g=d;var p=e("fV39EiaT");const E=e.p+"048a32f39440da80050e.svg",a=s.default.img` display: block; height: 5rem; width: auto; margin: auto; margin-bottom: 1.5rem; `,u=s.default.div` position: relative; height: 100vh; width: 100%; `,f=s.default.div` z-index: -1; display: flex; flex-direction: column; position: absolute; vertical-align: middle; justify-content: center; height: 100%; width: 100%; padding: 0 30px; background-image: url(${o}); background-position: center; background-size: cover; `,y=s.default.div` position: absolute; top: 0; margin-top: 5px; width: 100%; `,T=s.default.div` display: flex; flex: 1 1 0%; flex-direction: row; min-width: 100%; min-height: 100%; `,P=s.default.div` vertical-align: middle; justify-content: center; place-self: center center; height: auto; `,O=s.default.strong(({theme:N})=>(0,s.css)` display: block; font-size: ${N.fonts.size.extraLarge}; font-weight: 800; margin-top: 1.5rem; margin-bottom: 1.5rem; `),b=s.default.h1(({theme:N})=>(0,s.css)` color: #fcfcfc; text-transform: uppercase; font-size: ${N.fonts.size.huge}; line-height: 1; font-weight: 600; `),L=s.default.span(({theme:N})=>(0,s.css)` color: ${N.colors.brand.primary}; `),W=({children:N})=>t.createElement(T,null,t.createElement(g,null,t.createElement(O,null,"Welcome to Graylog"),N),t.createElement(u,null,t.createElement(y,null,t.createElement(p.Z,{readFromConfig:!0})),t.createElement(f,null,t.createElement(P,null,t.createElement(a,{alt:"logo",src:E}),t.createElement(b,null,"Data. Insights. ",t.createElement(L,null,"Answers."))))))},"kyFu+5jg":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("QL8i6bcz");const r=()=>{const n=s.G.exports("globalNotifications").map(c=>{if(!c.component)return console.error('Missing "component" for globalNotification plugin:',c),null;const v=c.component;return c.key||console.warn('Missing "key" for globalNotification plugin:',c),t.createElement(v,{key:c.key})}).filter(c=>!!c);return t.createElement(t.Fragment,null,n)}},l4nHKZ4j:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("fV39EiaT"),n=e("kyFu+5jg");const c=({children:d})=>t.createElement(t.Fragment,null,t.createElement(n.Z,null),t.createElement(r.Z,null),d);c.propTypes={children:o().oneOfType([o().arrayOf(o().element),o().element]).isRequired};const v=c},HqzDVmZB:(M,C,e)=>{"use strict";e.d(C,{Z:()=>jo});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("PfG+ecgN"),n=e.n(r),c=e("5W3DTPWj"),v=e("Q1zRxDOP"),d=e("8fnsnG21"),g=e("/GOzvPf6"),p=e("IQSYq7+p"),E=e("PVMUg5WH"),a=e("8OvTct/Z"),u=e("v4GbOr/o"),f=e("J6y4/h8P"),y=e("UiXZqrDE"),T=e("uZqmR+ju");const P=f.default.div` display: flex; > div:first-child > div { border-top-right-radius: 0; border-bottom-right-radius: 0; } > div:last-child > div { border-top-left-radius: 0; border-bottom-left-radius: 0; } > div:not(:first-child) > div { border-left: 0; } > div:not(:first-child, :last-child) > div { border-radius: 0; } `,O=({children:Zt,className:Me})=>t.createElement(P,{className:Me},Zt);O.defaultProps={className:void 0};const b=O,L=f.default.div(({theme:Zt})=>(0,f.css)` display: inline-flex; align-items: center; justify-content: center; height: 30px; width: 30px; border-radius: 50%; background-color: ${Zt.colors.gray[80]}; `),x=Zt=>{switch(Zt){case"global":return"building";case"team":return"users";case"error":return"exclamation";case"user":default:return"user"}},N=({type:Zt,...Me})=>t.createElement(L,{...Me},t.createElement(g.JO,{name:x(Zt)})),Z=Zt=>Zt.map(Me=>({label:Me.title,value:Me.id})).toJS(),j=({capabilities:Zt,onChange:Me,title:Ye,...Ke})=>{const dt=Z(Zt),it=(0,t.useCallback)((gt,It,ot)=>{ot({target:{value:It,name:gt}}),typeof Me=="function"&&Me(It)},[Me]);return t.createElement(y.Field,{name:"capabilityId"},({field:{name:gt,value:It,onChange:ot}})=>t.createElement(g.Ph,{...Ke,clearable:!1,inputProps:{"aria-label":Ye},onChange:yt=>it(gt,yt,ot),options:dt,placeholder:Ye,value:It}))};j.defaultProps={onChange:void 0,title:"Select a capability"};const z=j,ne=f.default.div` display: flex; `,Y=f.default.div(({theme:Zt})=>(0,f.css)` width: 100%; margin-top: 3px; color: ${Zt.colors.variant.danger}; > * { margin-right: 5px; &:last-child { margin-right: 0; } } `),ae=(0,f.default)(g.Ph)` flex: 1; `,ee=f.default.div` display: flex; align-items: center; `,ue=(0,f.default)(N)` margin-right: 5px; `,H=(0,f.default)(b)` flex: 1; > div:last-child { flex: 0.5; } `,ye=(0,f.default)(T.Button)` margin-left: 15px; `,we=Zt=>Zt.map(Me=>({label:Me.title,value:Me.id,granteeType:Me.type})).toJS(),ut=Zt=>{var Me;const Ye="Viewer";return(Me=Zt.find(Ke=>Ke.title===Ye))==null?void 0:Me.id},ht=Zt=>Me=>Me?void 0:`The ${Zt} is required`,Je=({label:Zt,granteeType:Me})=>t.createElement(ee,null,t.createElement(ue,{type:Me}),Zt),Re=({availableGrantees:Zt,availableCapabilities:Me,className:Ye,onSubmit:Ke,formRef:dt})=>{const it=we(Zt),gt=ut(Me),It=(ot,yt)=>{Ke(ot).then(()=>{yt()})};return t.createElement("div",{className:Ye},t.createElement(y.Formik,{onSubmit:(ot,{resetForm:yt})=>It(ot,yt),innerRef:dt,initialValues:{granteeId:void 0,capabilityId:gt}},({isSubmitting:ot,isValid:yt,errors:Xt})=>t.createElement(y.Form,null,t.createElement(ne,null,t.createElement(H,null,t.createElement(y.Field,{name:"granteeId",validate:ht("grantee")},({field:{name:rn,value:Cn,onChange:bn}})=>t.createElement(ae,{inputProps:{"aria-label":"Search for users and teams"},onChange:hn=>bn({target:{value:hn,name:rn}}),optionRenderer:Je,options:it,placeholder:"Search for users and teams",value:Cn})),t.createElement(z,{capabilities:Me})),t.createElement(ye,{bsStyle:"success",disabled:ot||!yt,title:"Add Collaborator",type:"submit"},"Add Collaborator")),Xt&&t.createElement(Y,null,Object.entries(Xt).map(([rn,Cn])=>t.createElement("span",{key:rn},String(Cn),"."))))))};Re.defaultProps={className:void 0,formRef:void 0};const le=Re;var me=e("rVdVsuGH");const re=(Zt,Me)=>{switch(Me){case"new":return Zt.colors.variant.lighter.success;case"changed":return Zt.colors.variant.lighter.warning;default:return"transparent"}},ce=f.default.li(({theme:Zt,$currentState:Me})=>(0,f.css)` display: flex; align-items: center; width: 100%; padding: 5px; border-left: 5px solid ${re(Zt,Me)}; `),Q=f.default.div` display: flex; align-items: center; flex: 1; overflow: hidden; margin-right: 10px; `,J=f.default.div` flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; `,ie=(0,f.default)(z)` flex: 0.5; `,ge=(0,f.default)(N)` margin-right: 5px; `,fe=f.default.div` display: flex; align-items: center; justify-content: center; width: 25px; margin-left: 10px; `,Oe=({availableCapabilities:Zt,currentGranteeState:Me,grantee:{id:Ye,capabilityId:Ke,type:dt,title:it},onDelete:gt,onCapabilityChange:It})=>{const[ot,yt]=(0,t.useState)(!1),Xt=()=>{yt(!0),gt(Ye).then(()=>yt(!1))};return t.createElement(y.Formik,{initialValues:{capabilityId:Ke},onSubmit:()=>{}},t.createElement(y.Form,null,t.createElement(ce,{$currentState:Me},t.createElement(Q,{title:it},t.createElement(ge,{type:dt}),t.createElement(J,null,it)),t.createElement(ie,{onChange:rn=>It({granteeId:Ye,capabilityId:rn}),capabilities:Zt,title:`Change the capability for ${it}`}),t.createElement(fe,null,ot?t.createElement(g.$j,{text:""}):t.createElement(g.hU,{name:"trash",onClick:Xt,title:`Remove sharing for ${it}`})))))},nt=f.default.div` display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; `,et=f.default.div(({theme:Zt})=>` >:nth-child(even) { background: ${Zt.colors.table.backgroundAlt}; }; >:nth-child(odd) { background: ${Zt.colors.table.background}; }; `),Fe=f.default.ul` display: flex; justify-content: center; .pagination { margin: 10px 0; } `,Pe=(0,f.default)(g.tl)` margin-top: 10px; margin-bottom: 0; `,$e=(0,f.default)(g.IE)(({theme:Zt})=>(0,f.css)` label { font-weight: normal; font-size: ${Zt.fonts.size.body}; } `),Ot=(Zt,Me,Ye)=>{const Ke=Me*(Ye-1),dt=Ke+Me;return Zt.slice(Ke,dt)},ft=({activeShares:Zt,onDelete:Me,onCapabilityChange:Ye,entityType:Ke,entityTypeTitle:dt,availableCapabilities:it,selectedGrantees:gt,className:It,title:ot})=>{const yt=me.VZ[0],[Xt,rn]=(0,t.useState)(yt),[Cn,bn]=(0,t.useState)(1),hn=Ot(gt,Xt,Cn),ao=gt.size,Xn=Math.ceil(ao/Xt),vo=ao>yt;return t.createElement("div",{className:It},t.createElement(nt,null,t.createElement("h5",null,ot),vo&&t.createElement($e,{onChange:Kn=>rn(Kn),pageSize:Xt})),hn.size>0?t.createElement(et,null,hn.map(Kn=>{const Jn=Kn.currentState(Zt);return t.createElement(Oe,{availableCapabilities:it,currentGranteeState:Jn,grantee:Kn,key:Kn.id,onDelete:Me,onCapabilityChange:Ye})}).toArray()):t.createElement(T.Alert,null,"This ",dt||Ke," has no collaborators."),t.createElement(Fe,null,t.createElement(Pe,{totalPages:Xn,currentPage:Cn,onChange:bn})))};ft.defaultProps={className:void 0,entityTypeTitle:void 0};const Tt=ft;var Lt=e("TJOheZRu");const Be=(0,f.default)(T.Alert)` margin-top: 20px; max-height: 240px; overflow: auto; `,lt=f.default.ul` list-style: initial; padding-left: 20px; ul { list-style: circle; } `,mt=Lt.Z.capitalizeFirstLetter,zt=({missingDependencies:Zt,availableGrantees:Me})=>t.createElement(Be,{bsStyle:"danger",title:"There are missing dependencies for the current set of collaborators"},t.createElement(lt,null,Zt.entrySeq().map(([Ye,Ke])=>{const dt=Me.find(it=>it.id===Ye);return dt&&t.createElement("li",{key:dt.id},mt(dt.type)," ",t.createElement("i",null,dt.title)," needs access to",Ke.map(it=>t.createElement(lt,{key:it.id},t.createElement("li",null,mt(it.type),": ",t.createElement("i",null,it.title),t.createElement("br",null),"Owners: ",it.owners.map((gt,It)=>t.createElement("span",{key:gt.id},mt(gt.type)," ",t.createElement("i",null,gt.title),It!==it.owners.size-1&&", "))))))}).toArray()));var xt=e("13uboeDm"),nn=e.n(xt);const Vt=(0,f.default)(T.Alert)` margin-top: 20px; max-height: 240px; overflow: auto; `,jn=f.default.ul` list-style: initial; padding-left: 20px; ul { list-style: circle; } `,On=({validationResult:Zt,availableGrantees:Me})=>{const Ye=Zt.errorContext.selectedGranteeCapabilities.map(Ke=>Me.find(dt=>dt.id===Ke));return t.createElement(Vt,{bsStyle:"danger"},t.createElement(jn,null,t.createElement("li",null,"Removing the following owners will leave the entity ownerless: ",t.createElement("br",null),Ye.map((Ke,dt)=>t.createElement("span",{key:Ke==null?void 0:Ke.id},nn()(Ke==null?void 0:Ke.type)," ",t.createElement("i",null,Ke==null?void 0:Ke.title),dt!==Ye.size-1&&", ")).toArray())))};var rt=e("tz1fbBRX");const Bn=(0,f.default)(T.Alert)` display: flex; margin-top: 20px; `,de=f.default.div` height: 34px; display: flex; align-items: center; `,pt=f.default.div` margin-left: 10px; flex: 1; `,Gt=(0,f.default)(T.FormControl)(({theme:Zt})=>(0,f.css)` &[readonly] { background-color: ${Zt.colors.input.background}; } `),gn=(0,f.default)(T.InputGroup.Addon)` padding: 0; `,Jt=(0,f.default)(g.mU)` border-radius: 0; border: 0; `,xe=({entityGRN:Zt})=>{const Me=(0,t.useRef)(),Ye=(0,rt.Z)(Zt),Ke=`${window.location.origin.toString()}${Ye}`;return t.createElement(Bn,null,t.createElement(de,null,t.createElement("b",null,"Sharable URL:")),t.createElement(pt,null,t.createElement(T.FormGroup,null,t.createElement(T.InputGroup,null,t.createElement(Gt,{type:"text",value:Ke,readOnly:!0}),t.createElement(gn,null,t.createElement("span",{ref:Me},Me.current&&t.createElement(Jt,{text:Ke,container:Me.current,buttonTitle:"Copy parameter to clipboard",title:t.createElement(g.JO,{name:"copy",fixedWidth:!0})}))))),t.createElement("div",null,"You or anyone authorized to view can access this link.")))},Pn=f.default.div` margin-bottom: 25px; &:last-child { margin-bottom: 0; } `,sn=f.default.h5` margin-bottom: 10px; `,no=(Zt,Me)=>{const Ye=Me.entrySeq().map(([Ke])=>Ke);return Zt.filter(Ke=>!Ye.includes(Ke.id))},Co=({entityShareState:{activeShares:Zt,availableGrantees:Me,availableCapabilities:Ye,missingDependencies:Ke,selectedGranteeCapabilities:dt,selectedGrantees:it,validationResults:gt},description:It,entityGRN:ot,entityType:yt,entityTitle:Xt,setDisableSubmit:rn,granteesSelectFormRef:Cn,showShareableEntityURL:bn,entityTypeTitle:hn})=>{const ao=no(Me,dt);(0,t.useEffect)(()=>{rn(gt==null?void 0:gt.failed)},[gt,rn]);const Xn=({granteeId:Kn,capabilityId:Jn})=>{const Wn=dt.merge({[Kn]:Jn});rn(!0);const bo={selected_grantee_capabilities:Wn};return c.Z.prepare(yt,Xt,ot,bo)},vo=Kn=>{const Jn=dt.remove(Kn);rn(!0);const Wn={selected_grantee_capabilities:Jn};return c.Z.prepare(yt,Xt,ot,Wn)};return t.createElement(t.Fragment,null,t.createElement(Pn,null,t.createElement(sn,null,"Add collaborator"),t.createElement("p",null,It),t.createElement(le,{availableGrantees:ao,availableCapabilities:Ye,onSubmit:Xn,formRef:Cn})),t.createElement(Pn,null,t.createElement(Tt,{activeShares:Zt,availableCapabilities:Ye,entityType:yt,entityTypeTitle:hn,onDelete:vo,onCapabilityChange:Xn,selectedGrantees:it,title:"Current collaborators"})),(gt==null?void 0:gt.failed)&&t.createElement(Pn,null,t.createElement(On,{validationResult:gt,availableGrantees:Me})),(Ke==null?void 0:Ke.size)>0&&t.createElement(Pn,null,t.createElement(zt,{missingDependencies:Ke,availableGrantees:Me})),bn&&t.createElement(Pn,null,t.createElement(xe,{entityGRN:ot})))};Co.propTypes={description:o().string.isRequired,entityGRN:o().string.isRequired,entityShareState:o().object.isRequired,setDisableSubmit:o().func.isRequired,showShareableEntityURL:o().bool,entityTypeTitle:o().string},Co.defaultProps={showShareableEntityURL:!0,entityTypeTitle:void 0};const Go=Co,Mo=({description:Zt,entityId:Me,entityType:Ye,entityTitle:Ke,entityTypeTitle:dt,onClose:it,showShareableEntityURL:gt})=>{var It;const{state:ot}=(0,d.o)(p.ey),[yt,Xt]=(0,t.useState)((It=ot==null?void 0:ot.validationResults)==null?void 0:It.failed),rn=(0,v.L)(Ye,Me),Cn=(0,t.useRef)(),bn=(0,a.Z)();(0,t.useEffect)(()=>{c.Z.prepare(Ye,Ke,rn)},[Ye,Ke,rn]);const hn=()=>{var ao,Xn,vo;Xt(!0);const Kn=(Xn=(ao=Cn.current)==null?void 0:ao.values)==null?void 0:Xn.granteeId,Jn={selected_grantee_capabilities:ot.selectedGranteeCapabilities};if(Kn){const Wn=ot==null?void 0:ot.availableGrantees.find(bo=>bo.id===Kn);if(!window.confirm(`${Wn.title?`"${Wn.title}"`:"An entity (name not found)"} got selected but was never added as a collaborator. Do you want to continue anyway?`)){Xt(!1);return}}bn((vo=u.A.ENTITYSHARE)==null?void 0:vo[`ENTITY_${n()(Ye)}_SHARED`],{app_pathname:Ye}),c.Z.update(Ye,Ke,rn,Jn).then(()=>{Xt(!0),it()})};return t.createElement(E.Z,{confirmButtonDisabled:yt,confirmButtonText:"Update sharing",onConfirm:hn,onCancel:it,showModal:!0,title:t.createElement(t.Fragment,null,"Sharing ",dt!=null?dt:Ye,": ",t.createElement("i",null,Ke))},ot&&ot.entity===rn?t.createElement(Go,{description:Zt,entityGRN:rn,entityType:Ye,entityTypeTitle:dt,entityTitle:Ke,entityShareState:ot,granteesSelectFormRef:Cn,setDisableSubmit:Xt,showShareableEntityURL:gt}):t.createElement(g.$j,null))};Mo.propTypes={description:o().string.isRequired,entityId:o().string.isRequired,entityTitle:o().string.isRequired,entityType:o().string.isRequired,entityTypeTitle:o().string,onClose:o().func.isRequired,showShareableEntityURL:o().bool},Mo.defaultProps={entityTypeTitle:void 0,showShareableEntityURL:!0};const jo=Mo},Y2DdPzXi:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("J6y4/h8P");const o=s.default.h3(({theme:c})=>(0,s.css)` a { color: ${c.colors.global.textDefault}; } .label { font-size: ${c.fonts.size.tiny}; line-height: 200%; margin-left: 5px; vertical-align: bottom; } `),n=c=>t.createElement(o,{...c})},E9JT2cEW:(M,C,e)=>{"use strict";e.d(C,{Z:()=>b});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("9oVghaOd"),n=e.n(r),c=e("4E3oowBb"),v=e("uZqmR+ju"),d=e("4zkAw1kt"),g=e("/8lbhT5j"),p=e("v4GbOr/o"),E=e("8OvTct/Z"),a=e("MdYBRjRJ"),u=e("0t7Ye+61");const f=({surrounding_timerange_options:L={}})=>Object.fromEntries(Object.entries(L).map(([x,W])=>[n().duration(x).asSeconds(),W])),y=(L,x)=>{const{surrounding_filter_fields:W=[]}=x;return Object.fromEntries(W.map(N=>[N,L[N]]))},T=(L,x,W,N,Z)=>g.Z.builder().timerange({type:"absolute",from:x,to:W}).streams(Z).filterFields(N).highlightedMessage(L).build().toURL(),P=(L,x,W,N,Z,j)=>{const z=n()(x).subtract(Number(L),"seconds").toISOString(),ne=n()(x).add(Number(L),"seconds").toISOString(),Y=y(N,Z);return T(W,z,ne,Y,j)},O=({searchConfig:L,timestamp:x,id:W,messageFields:N})=>{const{streams:Z}=(0,t.useContext)(d.Z),j=f(L),z=(0,u.Z)(),ne=(0,E.Z)(),Y=ee=>{ne(p.A.SEARCH_MESSAGE_TABLE_SHOW_SURROUNDING_MESSAGE,{app_pathname:(0,a.av)(z.pathname),app_section:"search-message-table",app_action_value:"seach-message-table-show-surrounding",event_details:{range:ee}})},ae=Object.keys(j).sort((ee,ue)=>(0,c.S)(ee,ue)).map(ee=>t.createElement(v.MenuItem,{key:ee,onClick:()=>Y(ee),href:P(ee,x,W,N,L,Z),target:"_blank",rel:"noopener noreferrer"},j[ee]));return t.createElement(v.DropdownButton,{title:"Show surrounding messages",bsSize:"small",id:"surrounding-search-dropdown"},ae)};O.propTypes={id:o().string.isRequired,timestamp:o().string.isRequired,searchConfig:o().object.isRequired,messageFields:o().object.isRequired};const b=O},"1LOzeRr1":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("uZqmR+ju");const c=r.default.span(({$size:g,theme:p})=>{const{body:E,small:a,tiny:u}=p.fonts.size,f=g==="small"?a:E;return(0,r.css)` vertical-align: middle; font-size: ${g==="xsmall"?u:f}; `}),v=({color:g,size:p,text:E})=>{const a=(0,r.useTheme)(),u=a.utils.colorLevel(g,5),f=a.utils.contrastingColor(g);return t.createElement(c,{$size:p,className:"color-label-wrapper"},t.createElement(n.Label,{style:{backgroundColor:g,border:`1px solid ${u}`,color:f,overflow:"hidden",textOverflow:"ellipsis",maxWidth:"128px",marginRight:"4px",marginBottom:"4px"}},E))};v.propTypes={color:o().string.isRequired,text:o().oneOfType([o().string,o().element]),size:o().oneOf(["normal","small","xsmall"])},v.defaultProps={text:t.createElement("span",null,"\u2003"),size:"normal"};const d=v},Wh5iba66:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("ty2gyrHp"),o=e("d4kzUuQm");const n=({stream:c})=>{const v=o.ZP.stream_search(c.id);return t.createElement(s.r,{to:v},c.title)}},yzCFXWYn:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("DUKaTDO2"),s=e("jAGDuYSC"),o=e("eFxcQyPT"),r=e("MdYBRjRJ"),n=e("U1Iufsob");const c=g=>{const{url:p}=n.Z.StreamsApiController.get(g);return(0,o.ZP)("GET",(0,r.DC)(p))},d=(g,{enabled:p}={enabled:!0})=>{const{data:E,refetch:a,isFetching:u,isError:f}=(0,t.useQuery)(["streams",g],()=>c(g),{onError:y=>{s.Z.error(`Loading stream failed with status: ${y}`,"Could not load Stream")},keepPreviousData:!0,enabled:p});return{data:E,refetch:a,isFetching:u,isError:f}}},"7dh0vSOR":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("E+CaPsQD"),r=e("93yMNhQL");const n=s.default.a` display: inline-flex; align-items: center; `,c=(0,s.default)(r.Z)` margin-left: 5px; `,v=({page:g,title:p="",text:E,displayIcon:a})=>t.createElement(n,{href:o.Z.toString(g),title:p,target:"_blank"},E,a&&t.createElement(c,{name:"lightbulb",type:"regular",size:"lg"}));v.defaultProps={title:"",displayIcon:!1};const d=v},"s+Y7d/9X":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("93yMNhQL");const c=r.default.div(({small:g,theme:p})=>(0,r.css)` position: relative; min-width: 2.5em; font-size: ${g?p.fonts.size.body:p.fonts.size.large}; .fa-stack-1x { color: ${p.colors.global.textAlt}; } .fa-stack-2x { color: ${p.colors.global.textDefault}; } `),v=({small:g,children:p})=>t.createElement("table",{className:"description-tooltips",style:{marginBottom:"10px",display:"inline"}},t.createElement("tbody",null,t.createElement("tr",null,t.createElement("td",{style:{width:"40px"}},t.createElement(c,{className:`fa-stack ${g?"":"fa-lg"}`,small:g},t.createElement(n.Z,{name:"circle",className:"fa-stack-2x"}),t.createElement(n.Z,{name:"lightbulb",className:"fa-stack-1x",inverse:!0}))),t.createElement("td",null,t.createElement("strong",null,p)))));v.propTypes={small:o().bool,children:o().node.isRequired},v.defaultProps={small:!1};const d=v},"zeW/qtng":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("/GOzvPf6"),r=e("7dh0vSOR"),n=e("E+CaPsQD");const c=s.default.ul` margin: 0; padding: 0; margin-top: 5px; `,v=()=>t.createElement("div",{className:"support-sources"},t.createElement("h2",null,"Need help?"),t.createElement("p",null,"Do not hesitate to consult the Graylog community if your questions are not answered in the"," ",t.createElement(r.Z,{page:n.Z.PAGES.WELCOME,text:"documentation"}),"."),t.createElement(c,null,t.createElement("li",null,t.createElement(o.JO,{name:"users"}),"\xA0",t.createElement("a",{href:"https://www.graylog.org/community-support/",target:"_blank",rel:"noopener noreferrer"},"Community support")),t.createElement("li",null,t.createElement(o.JO,{name:"github-alt",type:"brand"}),"\xA0\xA0",t.createElement("a",{href:"https://github.com/Graylog2/graylog2-server/issues",target:"_blank",rel:"noopener noreferrer"},"Issue tracker")),t.createElement("li",null,t.createElement(o.JO,{name:"heart"}),"\xA0",t.createElement("a",{href:"https://www.graylog.org/professional-support",target:"_blank",rel:"noopener noreferrer"},"Professional support"))));v.propTypes={};const d=v},fVisTAey:(M,C,e)=>{"use strict";e.d(C,{eb:()=>c.Z});var t=e("Z7aTuO5B"),s=e("uZqmR+ju"),o=e("zeW/qtng");const r=()=>React.createElement(Row,{className:"content"},React.createElement(Col,{md:12},React.createElement(SupportSources,null))),n=null;var c=e("7dh0vSOR"),v=e("s+Y7d/9X")},fGU5yqDp:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.CurrentUserContext",()=>o)},k5v4N6a1:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.HotkeysContext",()=>o)},F5HruJCi:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.InputsContext",()=>o)},"+44s4X7G":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.NodesContext",()=>o)},gvNRgdyu:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.StreamsContext",()=>o)},nrvTDoPl:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.UserDateTimeContext",()=>o)},lN93Sbbu:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("CCNXj2ra"),o=e("IA3Ku5lS");const r={enableSmartSearch:!0,updateUnfocussed:!1,searchSidebarIsPinned:!1,dashboardSidebarIsPinned:!1,[s.eb]:s.MU},n=t.createContext(r),c=(0,o.ri)("contexts.UserPreferencesContext",()=>n)},"UeAH/0t7":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.WindowDimensionsContext",()=>o)},TkfAb49d:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("Mx+G+HdB"),o=e.n(s),r=e("UeAH/0t7");const n=()=>{const{innerWidth:g,innerHeight:p}=window;return{width:g,height:p}},c=()=>{const[g,p]=(0,t.useState)(n());return(0,t.useEffect)(()=>{const E=o()(()=>p(n()),200);return window.addEventListener("resize",E),()=>{window.removeEventListener("resize",E)}}),g},d=({children:g})=>{const p=c();return t.createElement(r.Z.Provider,{value:p},g)}},lDGobrly:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("jAGDuYSC"),s=e("9tc+dS6Z"),o=e("62FDaRYn");const r=(d,...g)=>{const{message:p,title:E}=d(...g);t.Z.success(p,E||"Success")},n=(d,g,...p)=>{var E,a;let u=String(g);((g==null?void 0:g.status)===400||(g==null?void 0:g.status)===500)&&((a=(E=g==null?void 0:g.additional)==null?void 0:E.body)!=null&&a.message)&&(u=`${g.additional.body.message} - ${g.message}`);const{message:f,title:y}=d(u,...p);t.Z.error(f,y||"Error")},v=({action:d,success:g,error:p,notFoundRedirect:E})=>(...a)=>d(...a).then(u=>(g&&r(g,...a),u)).catch(u=>{throw E&&(u==null?void 0:u.status)===404?(o.Z.report((0,s.vu)(u)),u):(n(p,u,...a),u)})},"5W3DTPWj":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("IQSYq7+p"),s=e("lDGobrly");const o=(0,s.Z)({action:t.N2.prepare,error:(v,d,g)=>({message:`Preparing shares for ${g} "${d}" failed with status: ${v}`})}),r=(0,s.Z)({action:t.N2.update,error:(v,d,g)=>({message:`Updating shares for ${g} "${d}" failed with status: ${v}`}),success:(v,d)=>({message:`Shares for ${d} "${v}" updated successfully`})}),n=(0,s.Z)({action:t.N2.loadUserSharesPaginated,error:(v,d)=>({message:`Loading entities which got shared for user with id "${d}" failed with status: ${v}`})}),c={prepare:o,update:r,loadUserSharesPaginated:n}},z6QEDyg6:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("Z7aTuO5B"),s=e("yAXMqwrl"),o=e("DUKaTDO2"),r=e("d4kzUuQm"),n=e("6dLKCZdN");const v=()=>{const{pathname:d}=(0,s.useLocation)(),{alertId:g,definitionId:p}=(0,n.Z)(),E=(0,o.useQueryClient)(),a=E.getQueryData(["event-by-id",g]),u=E.getQueryData(["event-definition-by-id",p||(a==null?void 0:a.event_definition_id)]),f=u==null?void 0:u.eventDefinition,y=u==null?void 0:u.aggregations;return(0,t.useMemo)(()=>({alertId:g,definitionId:f==null?void 0:f.id,definitionTitle:f==null?void 0:f.title,isAlert:d===r.ZP.ALERTS.replay_search(g)&&a&&(a==null?void 0:a.alert),isEvent:!!g&&d===r.ZP.ALERTS.replay_search(g)&&a&&!(a!=null&&a.alert),isEventDefinition:!!p&&d===r.ZP.ALERTS.DEFINITIONS.replay_search(p)&&!!f,eventData:a,eventDefinition:f,aggregations:y}),[g,f,d,a,p,y])}},q2j1bVbz:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("fGU5yqDp");const r=()=>{const n=(0,t.useContext)(s.Z);if(!n)throw new Error("useCurrentUser hook needs to be used inside CurrentUserContext.Provider");return n}},a5C0HdYb:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("vlOILx1C"),o=e("Mx+G+HdB"),r=e.n(o);const c=(v,d=200)=>{const[g,p]=(0,t.useState)({width:0,height:0}),E=r()(a=>p(a),d);return(0,t.useLayoutEffect)(()=>{if(v!=null&&v.current){const{width:a,height:u}=v.current.getBoundingClientRect();p({width:a,height:u})}},[v]),(0,s.Z)(v,({contentRect:{width:a,height:u}})=>{E({width:a,height:u})}),g}},zJE5UjMB:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("RCNj0OY4");const o=r=>t.Z.isFeatureEnabled(r)},"D/X+X5ed":(M,C,e)=>{"use strict";e.d(C,{Z:()=>a});var t=e("J6SvWOit"),s=e("Z7aTuO5B"),o=e("/MzrwdNa"),r=e("zJE5UjMB"),n=e("8OvTct/Z"),c=e("0t7Ye+61"),v=e("MdYBRjRJ"),d=e("v4GbOr/o");const g={preventDefault:!0,enabled:!0,enableOnFormTags:!1,enableOnContentEditable:!1,combinationKey:"+",splitKey:",",keyup:void 0,keydown:!0,description:void 0,document:void 0,ignoreModifiers:!1,displayInOverview:void 0},p=(u,f,y)=>{if(!u[y])throw Error(`Scope "${y}" does not exist in hotkeys collection.`);if(!u[y].actions[f])throw Error(`Action "${f}" does not exist in hotkeys collection of "${y}" scope.`)},a=({actionKey:u,callback:f,scope:y,options:T,dependencies:P,telemetryAppPathname:O})=>{var b,L,x;if(!(0,r.Z)("frontend_hotkeys"))return null;const N=(0,c.Z)(),Z=(0,n.Z)(),{hotKeysCollections:j,addActiveHotkey:z,removeActiveHotkey:ne}=(0,o.Z)();p(j,u,y);const Y=(0,s.useMemo)(()=>({...g,...T,scopes:y}),[T,y]),ae=(0,s.useCallback)((ee,ue)=>{var H,ye,we;Z(d.A.SHORTCUT_TYPED,{app_pathname:O!=null?O:(0,v.av)(N.pathname),event_details:{actionKey:u,scope:y,keys:(we=(ye=(H=j==null?void 0:j[y])==null?void 0:H.actions)==null?void 0:ye[u])==null?void 0:we.keys}}),f(ee,ue)},[u,f,j,N.pathname,y,Z,O]);return(0,s.useEffect)(()=>(z({scope:y,actionKey:u,options:{scope:y,enabled:Y.enabled,displayInOverview:Y.displayInOverview,combinationKey:Y.combinationKey,splitKey:Y.splitKey}}),()=>ne({scope:y,actionKey:u})),[u,z,y,ne,Y.combinationKey,Y.enabled,Y.displayInOverview,Y.splitKey]),(0,t.y1)((x=(L=(b=j==null?void 0:j[y])==null?void 0:b.actions)==null?void 0:L[u])==null?void 0:x.keys,ae,Y,P)}},"/MzrwdNa":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("k5v4N6a1");const r=()=>(0,t.useContext)(s.Z)},"2ufZf/Iw":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("F5HruJCi");const r=()=>(0,t.useContext)(s.Z)},"64CQykkG":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("+44s4X7G");const r=()=>(0,t.useContext)(s.Z)},rVdVsuGH:(M,C,e)=>{"use strict";e.d(C,{VZ:()=>v,ZP:()=>g});var t=e("oCSEoDew"),s=e.n(t),o=e("yAXMqwrl"),r=e("Z7aTuO5B"),n=e("brbjQOmY");const c=1,v=[10,20,50,100],g=(p=v,E=v[0],a=!0)=>{const{page:u,pageSize:f}=(0,n.Z)(),y=(0,o.useNavigate)(),{search:T,pathname:P}=(0,o.useLocation)(),O=P+T,b=Number(u),L=Number.isInteger(b)&&b>0?b:c,x=Number(f),N=(()=>a&&Number.isInteger(x)&&p!=null&&p.includes(x)?x:E)(),Z=(0,r.useCallback)(({page:z=L,pageSize:ne=N})=>{const Y=new(s())(O).setSearch({page:z,pageSize:a?String(ne):void 0});y(Y.toString())},[y,L,N,O,a]),j=(0,r.useCallback)(()=>{Z({page:c})},[Z]);return{page:L,resetPage:j,pageSize:N,setPagination:Z}}},"0hhBr0/b":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("QL8i6bcz");const r=n=>(0,t.useMemo)(()=>s.G.exports(n),[n])},"d4iC/0eA":(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("8fnsnG21"),o=e("PYFLluwn");const n=()=>{const{searchesClusterConfig:c}=(0,s.o)(o.s);return(0,t.useEffect)(()=>{o.q.refresh()},[]),{config:c,refresh:o.q.refresh}}},"O/XpfGnR":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("nrvTDoPl");const r=()=>{const n=(0,t.useContext)(s.Z);if(!n)throw new Error("useUserDateTime hook needs to be used inside UserDateTimeContext.Provider");return n}},ajPaUdvr:(M,C,e)=>{"use strict";var t=e("oCSEoDew"),s=e.n(t),o=e("RCNj0OY4");const r=o.Z.gl2DevMode()?"/":"/assets/";e.p=s().joinPaths(o.Z.gl2AppPathPrefix(),r).path()||r;var n=e("Z7aTuO5B"),c=e("zKLlqmvB"),v=e("JnTtTRmZ"),d=e.n(v),g=e("QL8i6bcz"),p=e("8jTixuP6"),E=e("ii0bleBb"),a=e.n(E),u=e("J6y4/h8P"),f=e("utbMO9sg"),y=e("coBi+lXG"),T=e("Fg5/d7Qn"),P=e("93yMNhQL"),O=e("qQvt58D8"),b=e("MdYBRjRJ"),L=e("UnR9x6QB");const x=(0,u.default)(P.Z)` margin-left: 6px; `,W=({server:l})=>{const[i,h]=(0,n.useState)(!1),D=()=>h(!i),I=()=>{if(!i)return null;const K=n.createElement("div",null,n.createElement("hr",null),n.createElement("p",null,"There is no information available."));if(!(l!=null&&l.error))return K;const{error:G}=l,oe=[];if(G.message&&oe.push(n.createElement("dt",{key:"error-title"},"Error message"),n.createElement("dd",{key:"error-desc"},G.message)),G.originalError){const{originalError:pe}=G;oe.push(n.createElement("dt",{key:"status-original-request-title"},"Original Request"),n.createElement("dd",{key:"status-original-request-content"},String(pe.method)," ",String(pe.url))),oe.push(n.createElement("dt",{key:"status-code-title"},"Status code"),n.createElement("dd",{key:"status-code-desc"},String(pe.status))),typeof pe.toString=="function"&&oe.push(n.createElement("dt",{key:"full-error-title"},"Full error message"),n.createElement("dd",{key:"full-error-desc"},pe.toString()))}return oe.length===0?K:n.createElement("div",null,n.createElement("hr",{style:{marginTop:10,marginBottom:10}}),n.createElement("p",null,"This is the last response we received from the server:"),n.createElement(T.Z,{bsSize:"small",style:{whiteSpace:"pre-line"}},n.createElement("dl",{style:{marginBottom:0}},oe)))},w="Server currently unavailable";return n.createElement(O.Z,{title:"Server unavailable"},n.createElement(L.Z,null,n.createElement(y.Z,{show:!0},n.createElement(y.Z.Header,null,n.createElement(y.Z.Title,null,n.createElement(P.Z,{name:"exclamation-triangle"})," ",w)),n.createElement(y.Z.Body,null,n.createElement("div",null,n.createElement("p",null,"We are experiencing problems connecting to the Graylog server running on ",n.createElement("i",null,(0,b.DC)("")),". Please verify that the server is healthy and working correctly."),n.createElement("p",null,"You will be automatically redirected to the previous page once we can connect to the server."),n.createElement("p",null,"Do you need a hand?"," ",n.createElement("a",{href:"https://www.graylog.org/community-support",rel:"noopener noreferrer",target:"_blank"},"We can help you"),"."),n.createElement("div",null,n.createElement(f.Z,{bsStyle:"primary",tabIndex:0,onClick:D,bsSize:"sm"},i?"Less details":"More details",n.createElement(x,{name:i?"chevron-up":"chevron-down"})),I()))))))};W.propTypes={server:a().object},W.defaultProps={server:void 0};const N=W;var Z=e("8fnsnG21"),j=e("OZCvPLBd"),z=e("LO+0FfLw"),ne=e("J1ga+jW6"),Y=e("rjGM+nrz"),ae=e("pc+thvZE");const ee=(0,p.Z)(()=>e.e("1255d548-7789").then(e.bind(e,"EdMu6A9M"))),ue=(0,p.Z)(()=>e.e("1255d548-7899").then(e.bind(e,"on2+SG6N"))),H=(0,p.Z)(()=>e.e("1255d548-6663").then(e.bind(e,"aQ8GUzPu"))),ye=2e4,ut=()=>{const l=(0,Z.o)(ne.D,D=>D==null?void 0:D.currentUser),i=(0,Z.o)(Y.Z,D=>D==null?void 0:D.server),h=(0,Z.o)(ae.SessionStore,D=>{var I;return(I=D==null?void 0:D.username)!=null?I:""});return(0,n.useEffect)(()=>{const D=setInterval(Y.Z.ping,ye);return()=>clearInterval(D)},[]),i.up===!1?n.createElement(N,{server:i}):h?l?n.createElement(H,null):n.createElement(ue,{text:"We are preparing Graylog for you..."}):n.createElement(ee,null)};var ht=e("oBEvVL7M"),Je=e("U1Iufsob"),Re=e("jAGDuYSC"),le=e("eFxcQyPT"),me=e("IA3Ku5lS");const ce=(0,me.ei)("customization.actions",()=>v.createActions({update:{asyncResult:!0},get:{asyncResult:!0}})),Q=Je.Z.ClusterConfigResource.config().url,ie=(0,me.dS)("customization.store",()=>d().createStore({listenables:[ce],customization:{},getInitialState(){return{customization:this.customization}},get(l){const i=(0,le.ZP)("GET",this._url(`/${l}`));i.then(h=>(this.customization={...this.customization,[l]:h},this.propagateChanges(),h)),ce.get.promise(i)},update(l,i){const h=(0,le.ZP)("PUT",this._url(`/${l}`),i);h.then(D=>(this.customization={...this.customization,[l]:D},this.propagateChanges(),D),D=>{Re.Z.error(`Update failed: ${D}`,`Could not update customization: ${l}`)}),ce.update.promise(h)},propagateChanges(){this.trigger(this.getState())},getState(){return{customization:this.customization}},_url(l){return(0,b.DC)(Q+l)}})),ge={},fe=n.createContext(ge),Ce=(0,me.ri)("contexts.CustomizationContext",()=>fe),Oe=({children:l})=>{const i=(0,Z.o)(ie,h=>h.customization);return i?n.createElement(Ce.Provider,{value:i},l):l};Oe.propTypes={children:a().node.isRequired};const nt=Oe;var et=e("/yh+QgO6"),Fe=e.n(et),Pe=e("d4kzUuQm"),$e=e("+w7neh6x"),Ot=e("PPrdvEmz"),ft=e.n(Ot),Tt=e("Q29gfrW7"),Lt=e.n(Tt),Be=e("VPaD/Np4"),lt=e.n(Be);const mt={convert(l){const i=lt().Map().withMutations(h=>{ft()(l.messages,D=>{Lt()(D.message,(I,w)=>{h.mergeWith((K,G)=>K+G,lt().Map([[w,1]]))})})});return{id:l.id,effectiveTimerange:l.effective_timerange,type:l.type,messages:l.messages,total:l.total_results,fields:i}}};var Rt=e("9oVghaOd"),zt=e.n(Rt),xt=e("3+X6e5zE");const nn=l=>zt().unix(l).format("YYYY-MM-DD HH:mm:ss"),Vt=l=>{const i=lt().OrderedMap(l);return[{type:"bar",x:i.keySeq().map(nn).toArray(),y:i.valueSeq().toArray(),name:"took_ms"}]};function jn({data:l}){return n.createElement(xt.Z,{data:Vt(l.results),style:{position:"absolute"},layout:{margin:{t:10,pad:10}},config:{displayModeBar:!1}})}jn.propTypes={data:a().shape({config:a().shape({timerange:a().object.isRequired}).isRequired,interval:a().string.isRequired,timerange:a().object.isRequired,results:a().object.isRequired}).isRequired};var Mt=e("nxMFMmDQ"),On=e("gFL+I+yc"),rt=e("/GOzvPf6"),Bn=e("0+7ljD5O"),de=e("jlRcBdjT"),pt=e("PmoDOvRy"),Gt=e("Xt0X5Kl4"),gn=e("hOf/Kwna"),Jt=e("7VrSCphN"),An=e("Wk8izdHL");const xe=(l,i)=>`Sort ${l} ${i.direction}`,Pn=(l,i,h,D,I)=>{const w=[new An.Z(An.Z.PIVOT_TYPE,h,l)];I(!0),D(w).then(()=>{I(!1)})},sn=(l,i)=>l.sort&&l.sort.length>0&&l.sort[0].field===i,no={tooltip:l=>xe(l,Jt.Z.Descending),handleSortChange:l=>l(Jt.Z.Descending)},Co={tooltip:l=>xe(l,Jt.Z.Ascending),handleSortChange:l=>l(Jt.Z.Ascending)},Go={tooltip:l=>xe(l,pt.bd),handleSortChange:l=>l(pt.bd)},Mo=(l,i)=>{switch(sn(l,i)?l.sort[0].direction.direction:null){case Jt.Z.Ascending.direction:return no;case Jt.Z.Descending.direction:return Co;default:return Go}},jo=({fieldName:l,config:i,onSortChange:h,setLoadingState:D})=>{const I=oe=>Pn(oe,i,l,h,D),w=sn(i,l)?i.sort[0].direction.direction:null,{tooltip:K,handleSortChange:G}=Mo(i,l);return n.createElement(rt.fz,{activeDirection:w,onChange:()=>G(I),title:K(l)})};jo.propTypes={config:Gt.Z.instanceOf(pt.ZP).isRequired,fieldName:a().string.isRequired,onSortChange:a().func.isRequired,setLoadingState:a().func.isRequired};const Zt=jo;var Me=e("SnOQy/BL"),Ye=e("y2LHvPyS"),Ke=e("0hhBr0/b");const it=({children:l})=>{const i=(0,Ke.Z)("views.components.widgets.messageTable.contextProviders");return!i||(i==null?void 0:i.length)===0?l:i.reduce((h,D)=>n.createElement(Ye.SV,{FallbackComponent:()=>h},n.createElement(D,null,h)),l)};var gt=e("GFJVQ2dX");const It=u.default.table(({theme:l})=>(0,u.css)` position: relative; font-size: ${l.fonts.size.small}; margin: 0; border-collapse: collapse; width: 100%; word-break: break-all; @media print { font-size: ${l.fonts.size.body}; padding-left: 0; min-width: 50%; th { font-weight: bold !important; font-size: inherit !important; white-space: break-spaces !important; word-break: break-all !important; } th, td { border: 1px ${l.colors.gray[80]} solid !important; left: 0; padding: 5px !important; position: static; } } `),ot=u.default.div(({theme:l})=>(0,u.css)` display: flex; flex-direction: column; overflow: auto; /* Fixes overflow of children with position: fixed */ clip-path: inset(0 0 0 0); @media screen and (max-width: ${l.breakpoints.max.md}) { &.table-responsive { overflow-y: auto; } } `),yt=u.default.thead(({theme:l})=>(0,u.css)` background-color: ${l.colors.gray[90]}; color: ${l.utils.readableColor(l.colors.gray[90])}; position: sticky; top: 0; z-index: 1; && > tr > th { min-width: 50px; height: ${Mt.J4}px; padding: 0 5px; vertical-align: center; border: 0; font-size: ${l.fonts.size.small}; font-weight: normal; white-space: nowrap; background-color: ${l.colors.gray[90]}; color: ${l.utils.readableColor(l.colors.gray[90])}; } `),Xt=(l,i)=>(i&&i.find(h=>h.name===l)||{type:de.ZP.Unknown}).type,rn=l=>l.map(i=>({fields:i.message,formatted_fields:Bn.Z.filterFields(i.message),id:i.message._id,index:i.index,highlight_ranges:i.highlight_ranges,decoration_stats:i.decoration_stats})),Cn=(l,i,h)=>{let D;i.contains(l)?D=i.delete(l):(D=i.add(l),On.e.disable()),h(D)},bn=({fields:l,activeQueryId:i,messages:h,config:D,onSortChange:I,setLoadingState:w,scrollContainerRef:K})=>{const[G,oe]=(0,n.useState)(Be.Set()),pe=(0,n.useMemo)(()=>rn(h),[h]),_e=(0,n.useMemo)(()=>{var he;return Be.OrderedSet((he=D==null?void 0:D.fields)!=null?he:[])},[D==null?void 0:D.fields]),ve=(0,n.useCallback)(he=>Cn(he,G,oe),[G]);return n.createElement(it,null,n.createElement(ot,{className:"table-responsive",id:"sticky-augmentations-container",ref:K},n.createElement(It,{className:"table table-condensed"},n.createElement(yt,null,n.createElement("tr",null,_e.toSeq().map(he=>n.createElement("th",{key:he},n.createElement(Me.Z,{type:Xt(he,l),name:he,queryId:i},he),n.createElement(gt.Z.Consumer,null,Ue=>Ue&&n.createElement(Zt,{fieldName:he,onSortChange:I,setLoadingState:w,config:D})))).toArray())),pe.map(he=>{const Ue=`${he.index}-${he.id}`;return n.createElement(gn.y$,{fields:l,key:Ue,message:he,config:D,showMessageRow:D==null?void 0:D.showMessageRow,selectedFields:_e,expanded:G.contains(Ue),toggleDetail:ve,expandAllRenderAsync:!1})}))))};bn.propTypes={activeQueryId:a().string.isRequired,config:Gt.Z.instanceOf(pt.ZP).isRequired,fields:Gt.Z.FieldListType.isRequired,messages:a().arrayOf(a().object).isRequired,onSortChange:a().func.isRequired,setLoadingState:a().func.isRequired};const hn=n.memo(bn);var ao=e("9FNnmA1r"),Xn=e("TkfAb49d"),vo=e("yEuO7gC5"),Kn=e("Jvb3Ez/Z"),Jn=e("zIjJeS8Y"),Wn=e("NS75yjmB"),bo=e("YcvsU7cw");const ds=(0,Jn.P1)(Wn.Ln,l=>l==null?void 0:l.searchTypes),Xo=()=>(0,bo.Z)(ds);var Do=e("orDZ6Vj2"),Jo=e("LqPK8SLb"),Zo=e("oMyijaIY"),yo=e("KAQaaMh7"),Vo=e("6/nLyfIT");const Cs=(l,i)=>(h,D)=>{const I=D(),w=(0,yo.gX)(I),K=w==null?void 0:w.query,G=(0,yo.nK)(I),oe=(0,Wn.fv)(I),pe=Object.keys(l),_e=new Jo.Z(i,K,pe,l),ve=new Zo.ZP(G,_e),he=Ue=>{const{result:He,widgetMapping:at}=Ue,Xe=He.getSearchTypesFromResponse(pe),{result:ct}=(0,yo.AS)(D());return{result:ct.updateSearchTypes(Xe),widgetMapping:at}};return h((0,Vo.Q_)(oe,[],ve,he))};var ms=e("cFn5u42x"),Yn=e("pLyxMSSz");const xo=u.default.div` display: flex; flex-direction: column; height: 100%; overflow: hidden; .pagination { margin-bottom: 0; } `,Ls=(l,i)=>{const h=(0,n.useCallback)(()=>{i!==1&&l({currentPage:1,pageErrors:[]})},[i,l]);(0,ms.Z)(h)},Vs=l=>{const i=(0,n.useRef)();return(0,n.useEffect)(()=>{i.current&&(i.current.scrollTop=0)},[l,i]),i},Bs=()=>{const l=(0,n.useContext)(Yn.Z);(0,n.useEffect)(()=>{vo.x.list().then(()=>l&&l())},[l])},Ts=({config:l,data:{id:i,messages:h,total:D},fields:I,onConfigChange:w,pageSize:K,setLoadingState:G})=>{const[{currentPage:oe,pageErrors:pe},_e]=(0,n.useState)({pageErrors:[],currentPage:1}),ve=(0,Kn.Z)(),he=Xo(),Ue=Vs(oe),He=(0,Do.Z)();Ls(_e,oe),Bs();const at=(0,n.useCallback)(ct=>{const{effectiveTimerange:Nt}=he[i],kt={[i]:{limit:K,offset:K*(ct-1)}};On.e.disable(),G(!0),He(Cs(kt,Nt)).then(Ft=>{const{result:an}=Ft.payload;G(!1),_e({pageErrors:an.errors,currentPage:ct})})},[He,K,i,he,G]),Xe=(0,n.useCallback)(ct=>{const Nt=l.toBuilder().sort(ct).build();return w(Nt)},[l,w]);return n.createElement(Xn.Z,null,n.createElement(xo,null,n.createElement(rt.l9,{onChange:at,activePage:Number(oe),showPageSizeSelect:!1,totalItems:D,pageSize:K,useQueryParameter:!1},pe!=null&&pe.length?n.createElement(ao.Z,{errors:pe}):n.createElement(hn,{activeQueryId:ve,config:l,scrollContainerRef:Ue,fields:I,onSortChange:Xe,setLoadingState:G,messages:h}))))};Ts.propTypes={onConfigChange:a().func,pageSize:a().number},Ts.defaultProps={onConfigChange:()=>Promise.resolve(),pageSize:Mt.Vm.DEFAULT_LIMIT};const Us=Ts;var ws=e("FYGzXHJc"),Lo=e("d2pcYUML"),co=e("l8tl93Rz");const ns=({field:l,contexts:{widget:i}})=>h=>{const D=[].concat(i.config.fields,[l]),I=i.config.toBuilder().fields(D).build();return h((0,co.YS)(i.id,I))},os=({contexts:{widget:l},field:i})=>Lo.Z.isMessagesWidget(l)&&l.config?!(l.config.fields||[]).includes(i):!1,Ws=({contexts:{widget:l}})=>!l;ns.isEnabled=os,ns.isHidden=Ws;const ps=ns,Ns=({field:l})=>async(i,h)=>{const I=(0,Wn.RN)(h()).map(w=>{if(w.type.toUpperCase()===Lo.Z.type.toUpperCase()){const K=[].concat(w.config.fields,[l]),G=w.config.toBuilder().fields(K).build();return w.toBuilder().config(G).build()}return w}).toList();return i((0,co.o8)(I))};var gs=e("L2qXWCIB"),Ho=e("64Qr82UM"),Yo=e("ugp+BYjv"),te=e("/QVctsfe"),Te=e("fCul1Qwh"),Le=e("7J1sc9Ol"),st=e("Jy5RbH6g"),St=e.n(st),$t=e("+KM7MH1U"),cn=e.n($t),In=e("c20giJr8"),Mn=e.n(In),Zn=e("UiXZqrDE"),qn=e("OP/RNgvV"),be=e.n(qn);const Ve=(l,i,h)=>{if(!h)return[];const D=[];return h.forEach(I=>{const{values:w}=I,K={};I.key.forEach((G,oe)=>{K[l[oe]]=G}),w.forEach(({key:G,value:oe})=>{const pe=St()(G.map((_e,ve)=>ve{if((0,Le.mf)(l)){const{type:D}=(0,dn.Z)(Le.ZP.forFunction(l),i);return D}const h=i&&i.find(D=>D.name===l);return h?h.type:de.ZP.Unknown};var zn=e("BQipOvpT"),fn=e("y5LMk7Rh");const Dn=u.default.td(({$isNumeric:l,theme:i})=>(0,u.css)` ${l?`font-family: ${i.fonts.family.monospace};`:""} ${l?"text-align: right":""} `),Hn=(l,i,h,D)=>({field:l,value:i,path:h,source:D}),_o=l=>l.flatMap(i=>Object.entries(i)).map(([i,h])=>`${i}:${h}`).join("-"),Ss=({field:l,value:i,type:h,valuePath:D,source:I})=>{const w=(0,n.useMemo)(()=>({valuePath:D}),[D]);return n.createElement(Dn,{$isNumeric:h.isNumeric(),"data-testid":`value-cell-${_o(D)}-${l}`},n.createElement(en.v.Provider,{value:w},n.createElement(zn.Z,{field:I!=null?I:l,value:i},i!=null?n.createElement(Kt.Z,{field:I!=null?I:l,type:h,value:i,render:fn.Z}):null)))},As=(l,i)=>{const h=(0,Le.mg)(l);return h&&h.field?[...i,{_exists_:h.field}]:i},Hs=(l,i=[])=>{const h=i.find(D=>D.effectiveName===l);return h?h.function:l},uo=({columnPivots:l,fields:i,series:h,columnPivotValues:D,valuePath:I,item:w,types:K})=>{const G="message-group",oe=(0,Kn.Z)(),pe=i.toArray().map(({field:he,source:Ue},He)=>Hn(he,w[he],As(he,I).slice(0,He+1),Ue)),_e=D.flatMap(he=>{const Ue=he.flatMap((at,Xe)=>[l[Xe],at]),He=[...I];for(let at=0;at{const ct=[].concat(Ue,[at]),Nt=Fe()(w,ct);return Hn(at,Nt,As(Xe,He),Xe)})}),ve=St()([pe,_e]);return n.createElement("tr",{className:`fields-row ${G}`},ve.map(({field:he,value:Ue,path:He,source:at},Xe)=>{const ct=`${oe}-${he}=${Ue}-${Xe}`;return n.createElement(Ss,{key:ct,field:he,value:Ue,type:xn(Hs(he,h),K),valuePath:He.slice(),source:at})}))};var De=e("uZqmR+ju");const ss=u.default.div` width: 100%; `,Wr=(0,u.default)(De.Table)(({theme:l,$stickyHeader:i,$borderedHeader:h})=>(0,u.css)` position: relative; font-size: ${l.fonts.size.small}; margin: 0; border-collapse: collapse; width: 100%; word-break: break-all; thead { ${i?`position: sticky; top: 0; z-index: 2`:""} } thead > tr { color: ${l.colors.global.textAlt}; } td, th { position: relative; } > thead th { border: 0; font-size: ${l.fonts.size.small}; font-weight: normal; background-color: ${l.colors.gray[90]}; color: ${l.utils.readableColor(l.colors.gray[90])}; white-space: nowrap; ${h?`border: 1px solid ${l.colors.gray[80]}`:""} } > tbody td { background-color: ${l.colors.global.contentBackground}; color: ${l.utils.contrastingColor(l.colors.global.contentBackground)}; } &.table-striped > tbody > tr:nth-of-type(odd) > td { background-color: ${l.colors.global.contentBackground}; } &.table-striped > tbody > tr:nth-of-type(even) > td { background-color: ${l.colors.table.background}; } tr { border: 0 !important; } tr.message-group { border-top: 0; } tbody.message-group-toggled { border-left: 7px solid ${l.colors.variant.light.info}; } tbody.message-highlight { border-left: 7px solid ${l.colors.variant.light.success}; } tr.fields-row { cursor: pointer; td { min-width: 50px; padding-top: 10px; } } tr.message-row td { border-top: 0; padding-top: 0; padding-bottom: 5px; font-family: ${l.fonts.family.monospace}; color: ${l.colors.variant.dark.info}; } tr.message-row { margin-bottom: 5px; cursor: pointer; } tr.message-detail-row { display: none; } tr.message-detail-row td { padding-top: 5px; border-top: 0; } tr.message-detail-row .row { margin-right: 0; } tr.message-detail-row div[class*='col-'] { padding-right: 0; } th i.sort-order-desc { position: relative; top: -1px; } th i.sort-order-item { margin-right: 2px; color: ${l.colors.gray[10]}; visibility: hidden; } th i.sort-order-active, th:hover i.sort-order-item { color: ${l.colors.global.textAlt}; } `),Sr=({children:l,condensed:i,striped:h,bordered:D,stickyHeader:I,borderedHeader:w})=>n.createElement(ss,null,n.createElement(Wr,{condensed:i,striped:h,bordered:D,$stickyHeader:I,$borderedHeader:w},l));Sr.propTypes={children:a().node.isRequired,condensed:a().bool,striped:a().bool,bordered:a().bool,stickyHeader:a().bool,borderedHeader:a().bool},Sr.defaultProps={condensed:!0,striped:!1,bordered:!1,stickyHeader:!1,borderedHeader:!1};const ir=Sr,Ps=(l,i)=>{const h={};return l.map(D=>{const I={...D},w=Object.entries(I);return w.forEach(([K,G],oe)=>{i.includes(K)&&(h[K]===G?delete I[K]:(w.slice(oe+1).forEach(pe=>delete h[pe[0]]),h[K]=G))}),I})};var Nr=e("w7+AQV2V"),cr=e.n(Nr);const Bo=(l,i)=>i?`Sort ${l} ${i.direction}`:`Remove ${l} sort`,ks=(l,i,h,D,I,w,K)=>{let G;K?G=i.set(h,new An.Z(w,h,l)):G=i.delete(h),I(!0),D(G.toList().toArray()).then(()=>{I(!1)})},ia=(l,i)=>l.get(i),Es={tooltip:l=>Bo(l,Jt.Z.Descending),handleSortChange:l=>l(Jt.Z.Descending,!0)},Ar={tooltip:l=>Bo(l,null),handleSortChange:l=>l(Jt.Z.Descending,!1)},Ie={tooltip:l=>Bo(l,Jt.Z.Ascending),handleSortChange:l=>l(Jt.Z.Ascending,!0)},Qe=l=>{switch(l){case Jt.Z.Ascending.direction:return Es;case Jt.Z.Descending.direction:return Ar;default:return Ie}},bt=({fieldName:l,type:i,sortConfigMap:h,onSortChange:D,setLoadingState:I})=>{var w,K;const G=(Ue,He)=>ks(Ue,h,l,D,I,i,He),oe=(K=(w=ia(h,l))==null?void 0:w.direction)==null?void 0:K.direction,{tooltip:pe,handleSortChange:_e}=Qe(oe),ve=(0,n.useMemo)(()=>h.size<2?void 0:h.keySeq().findIndex(He=>He===l)+1||void 0,[l,h]),he=pe(l);return n.createElement(rt.fz,{onChange:()=>_e(G),activeDirection:oe,title:he,order:ve})};bt.propTypes={sortConfigMap:Gt.Z.instanceOf(Be.OrderedMap).isRequired,fieldName:a().string.isRequired,onSortChange:a().func.isRequired,setLoadingState:a().func.isRequired};const Ut=bt;var Qt=e("dFpwyWHg"),un=e.n(Qt),Ln=e("C2ikvoS0"),Vn=e.n(Ln),vn=e("1IntWRSu"),Nn=e.n(vn),Uo=e("8nGWeFnd"),Ko=e.n(Uo),wo=e("TeAcaicX"),Oo=e.n(wo),Zs=e("eE3+5goe"),Qs=e.n(Zs),Fn=e("4Dfti3jc"),To={};To.styleTagTransform=Qs(),To.setAttributes=Ko(),To.insert=Nn().bind(null,"head"),To.domAPI=Vn(),To.insertStyleElement=Oo();var Ro=un()(Fn.Z,To);const fs=Fn.Z&&Fn.Z.locals?Fn.Z.locals:void 0,hs=u.default.th` && { height: ${Mt.J4}px; padding: 0 5px; vertical-align: middle; } `,ur=(0,u.default)(hs)(({$isNumeric:l})=>(0,u.css)` ${l?"text-align: right;":""} `),Xs=(0,u.default)(hs)` text-align: center; `,gl=u.default.button(({theme:l})=>(0,u.css)` border: 0; background: transparent; padding: 5px; cursor: pointer; position: relative; color: ${l.colors.gray[70]}; &.active { color: ${l.colors.gray[20]}; } `),Zr=({activeQuery:l,fields:i,field:h,prefix:D="",span:I=1,title:w=h,onSortChange:K,sortConfigMap:G,sortable:oe,sortType:pe,onSetColumnsWidth:_e,isPinned:ve,showPinIcon:he=!1,togglePin:Ue})=>{var He;const at=xn(h,i),Xe=(0,n.useRef)(null);(0,n.useLayoutEffect)(()=>{var Nt;_e&&((Nt=Xe==null?void 0:Xe.current)!=null&&Nt.offsetWidth)&&_e({field:`${D}${h}`,offsetWidth:Xe.current.offsetWidth})},[_e,h,D,(He=Xe==null?void 0:Xe.current)==null?void 0:He.offsetWidth]);const ct=(0,n.useCallback)(()=>{Ue(`${D}${h}`)},[Ue,D,h]);return n.createElement(ur,{ref:Xe,$isNumeric:at.isNumeric(),key:`${D}${h}`,colSpan:I,className:fs.leftAligned},n.createElement(Me.Z,{name:h,queryId:l,type:at},w),he&&n.createElement(gl,{"data-testid":`pin-${D}${h}`,type:"button",onClick:ct,className:ve?"active":""},n.createElement(rt.JO,{name:"thumbtack"})),oe&&pe&&n.createElement(Ut,{fieldName:h,onSortChange:K,setLoadingState:()=>{},sortConfigMap:G,type:pe}))};Zr.defaultProps={prefix:void 0,span:void 0,title:void 0,sortType:void 0,onSetColumnsWidth:void 0,isPinned:void 0,showPinIcon:void 0};const dr=({field:l,value:i,span:h=1,prefix:D="",type:I})=>n.createElement(Xs,{key:`${D}${l}-${i}`,colSpan:h,className:fs.leftAligned},n.createElement(Kt.Z,{field:l,value:i,type:I}));dr.defaultProps={span:1,prefix:""};const ca=({span:l})=>n.createElement("th",{"aria-label":"spacer",colSpan:l,className:fs.leftAligned}),Pr=({fields:l,pivots:i,values:h,series:D,offset:I=1})=>{const w=i.map((K,G)=>{const pe=h.map(ve=>({path:ve.slice(0,G).join("-"),key:ve[G]||"",count:1})).reduce((ve,he)=>{const Ue=Fe()(cr()(ve),"key"),He=Fe()(cr()(ve),"path");if(Ue===he.key&&cn()(He,he.path)){const at=cr()(ve),Xe=ve.slice(0,-1),ct={...at,count:at.count+1};return[].concat(Xe,[ct])}return[].concat(ve,[he])},[]),_e=xn(K,l);return n.createElement("tr",{key:`header-table-row-${K}`},I>0&&n.createElement(ca,{span:I}),pe.map(ve=>n.createElement(dr,{key:`header-field-value-${ve.path}-${ve.key}`,field:K,value:ve.key,span:ve.count*D.length,prefix:ve.path,type:_e})))});return n.createElement(n.Fragment,null,w)};Pr.defaultProps={offset:1};const Js=({columnPivots:l,fields:i,rowPivots:h,series:D,rollup:I,actualColumnPivotFields:w,onSortChange:K,sortConfigMap:G,onSetColumnsWidth:oe,pinnedColumns:pe,togglePin:_e})=>{const ve=(0,Kn.Z)(),he=h.flatMap(Ft=>Ft.fields),Ue=l.flatMap(Ft=>Ft.fields),He=(0,n.useContext)(gt.Z),at=({field:Ft,prefix:an="",span:$n=1,title:_n=Ft,sortable:ln=!1,sortType:Qn=void 0,showPinIcon:Ur=!1})=>n.createElement(Zr,{activeQuery:ve,key:`${an}${Ft}`,fields:i,field:Ft,prefix:an,span:$n,title:_n,onSortChange:K,sortConfigMap:G,sortable:ln,sortType:Qn,onSetColumnsWidth:oe,isPinned:pe.has(`${an}${Ft}`),showPinIcon:Ur,togglePin:_e}),Xe=he.map(Ft=>at({field:Ft,sortable:He,sortType:An.Z.PIVOT_TYPE,showPinIcon:He})),ct=D.map(Ft=>at({field:Ft.function,prefix:"",span:1,title:Ft.effectiveName,sortable:He,sortType:An.Z.SERIES_TYPE,showPinIcon:!1})),Nt=St()(w.map(Ft=>D.map(an=>at({field:an.function,prefix:Ft.join("-"),span:1,title:an.effectiveName,sortable:!1,showPinIcon:!1})))),kt=I?he.length+D.length:he.length;return n.createElement(n.Fragment,null,n.createElement(Pr,{fields:i,pivots:Ue,values:w,series:D,offset:kt}),n.createElement("tr",{className:"pivot-header-row"},Xe,I&&ct,Nt))};Js.defaultProps={pinnedColumns:lt().Set()};const Fr=Js;var Kr=e("TNM0kxJ5"),mo=e("ocYLQ/BD"),ua=e("W7wTd14e");const El=u.default.div` display: flex; flex-direction: column; align-items: center; justify-content: center; height: inherit; `,Ni=u.default.h2(({theme:l})=>(0,u.css)` margin-bottom: ${l.spacings.sm}; `),Zi=({toggleEdit:l,editing:i=!1})=>{const h=(0,n.useContext)(Yn.Z);(0,n.useEffect)(()=>{h&&h()},[h]);const D=(0,n.useContext)(gt.Z),I=i?n.createElement("p",null,"You are now editing the widget.",n.createElement("br",null),"To see results, add at least one metric. You can group data by adding rows/columns.",n.createElement("br",null),'You can preview widget search results by clicking on "',ua.b,'".',n.createElement("br",null),'To finish, click "',mo.i,'" to save, "Cancel" to abandon changes.'):n.createElement("p",null,"Please ",D?n.createElement(De.Button,{bsStyle:"info",onClick:l},"Edit"):"edit"," the widget to see results here.");return n.createElement(El,null,n.createElement("div",null,n.createElement(Ni,null,"Empty Aggregation"),I))};var $r=e("a5C0HdYb");const Fi=u.default.div` height: 100%; width: 100%; overflow: hidden; grid-row: 2; grid-column: 1; -ms-grid-row: 2; -ms-grid-column: 1; `,$i=({children:l})=>{const i=(0,n.useRef)(null),{width:h,height:D}=(0,$r.Z)(i);return n.createElement(Fi,{ref:i},l({height:D,width:h}))},hl="table",vs=l=>{var i;return(i=l.chart)!=null?i:l[Object.keys(l).filter(h=>h!=="events")[0]]},So=(l,i)=>Object.assign(l,{type:i}),Da=l=>{const h=g.G.exports("visualizationTypes").filter(D=>D.type===l)[0];if(!h)throw new Error(`Unable to find visualization component for type: ${l}`);return h.component},mr=l=>l.type==="events"?l.events:l.rows,Oa=({config:l,data:i,editing:h=!1,fields:D,toggleEdit:I})=>{const w=(0,n.useContext)(Kr.Z);if(!l||l.isEmpty)return n.createElement(Zi,{toggleEdit:I,editing:h});const K=Da(l.visualization||hl),{effective_timerange:G}=i.chart||Object.values(i)[0]||{},oe=Object.fromEntries(Object.entries(i).map(pe=>pe).map(([pe,_e])=>[pe,mr(_e)]));return n.createElement($i,null,({height:pe,width:_e})=>n.createElement(K,{config:l,data:oe,effectiveTimerange:G,editing:h,fields:D,height:pe,width:_e,toggleEdit:I,onChange:w}))},da=(l,i)=>i.map(({index:h,leftMargin:D})=>` ${l}:nth-child(${h+1}) { position: sticky!important; left: ${D}px; z-index: 1; } `).concat(" ; "),vl=u.default.thead(({$stickyLeftMarginsByColumnIndex:l})=>(0,u.css)` & tr.pivot-header-row { & ${da("th",l)} } `),yl=u.default.tbody(({$stickyLeftMarginsByColumnIndex:l})=>(0,u.css)` & tr { & ${da("td",l)} } `),_l=(l,i)=>{if(l===void 0)return i===void 0?0:-1;if(l.length>i.length)return 1;if(l.length(0,We.S)(D,i[I])!==0);return h===-1?0:(0,We.S)(l[h],i[h])},Cl=l=>{const i=Mn()(St()(l.filter(({source:h})=>h==="leaf"||h==="non-leaf").map(({values:h})=>h)).filter(({rollup:h})=>!h).map(({key:h})=>h.slice(0,-1)),cn());return Be.List(i).sort(_l).toArray()},Ra=({config:l,data:i,fields:h,striped:D,bordered:I,borderedHeader:w,stickyHeader:K,condensed:G,editing:oe})=>{var pe,_e,ve;const he=(0,n.useContext)(Zn.FormikContext),Ue=(0,n.useContext)(Yn.Z),He=(0,n.useContext)(vt.Z);(0,n.useEffect)(Ue,[Ue]);const[at,Xe]=(0,n.useState)({}),ct=(0,Do.Z)(),Nt=(0,n.useCallback)(({field:Gn,offsetWidth:ys})=>{Xe(wr=>{const ts={...wr};return ts[Gn]=ys,ts})},[Xe]),kt=(0,n.useCallback)(Gn=>{const ys=he==null?void 0:he.dirty,wr=()=>ct((0,co.YS)(He.id,l.toBuilder().sort(Gn).build()));return!oe||oe&&!ys||window.confirm("You have unsaved changes in configuration form. This action will rollback them")?wr():Promise.reject()},[he==null?void 0:he.dirty,oe,ct,He==null?void 0:He.id,l]),Ft=(0,n.useCallback)(Gn=>{const ys=he==null?void 0:he.dirty,wr=()=>{var ts,lr;const la=(ts=He.config.visualizationConfig)!=null?ts:At.create([]).toBuilder().build(),ky=(lr=la==null?void 0:la.pinnedColumns)!=null&&lr.has(Gn)?la.pinnedColumns.delete(Gn):la.pinnedColumns.add(Gn);return ct((0,co.YS)(He.id,He.config.toBuilder().visualizationConfig(la.toBuilder().pinnedColumns(ky.toJS()).build()).build()))};return!oe||oe&&!ys||window.confirm("You have unsaved changes in configuration form. This action will rollback them")?wr():Promise.reject()},[he==null?void 0:he.dirty,oe,He==null?void 0:He.config,He==null?void 0:He.id,ct]),{columnPivots:an,rowPivots:$n,series:_n,rollupForBackendQuery:ln}=l,Qn=(pe=vs(i))!=null?pe:[],Ur=$n.flatMap(Gn=>Gn.fields),Gm=an.flatMap(Gn=>Gn.fields),ra=ln?_n:[],aa=Be.OrderedSet(Ur.map(Gn=>({field:Gn,source:Gn}))).merge(ra.map(Gn=>({field:Gn.effectiveName,source:Gn.function}))),ml=Ve(Ur.slice(),Gm.slice(),Qn.filter(Gn=>Gn.source==="leaf")),cu=Cl(Qn),pl=(0,n.useMemo)(()=>{var Gn,ys;return((ys=(Gn=He==null?void 0:He.config)==null?void 0:Gn.visualizationConfig)==null?void 0:ys.pinnedColumns)||Be.Set()},[(ve=(_e=He==null?void 0:He.config)==null?void 0:_e.visualizationConfig)==null?void 0:ve.pinnedColumns]),uu=(0,n.useMemo)(()=>{let Gn=0;const ys=[];return $n.flatMap(ts=>{var lr;return(lr=ts.fields)!=null?lr:[]}).forEach((ts,lr)=>{if(pl.has(ts)){const la=ts;ys.push({index:lr,column:la,leftMargin:Gn}),Gn+=at[ts]}}),_n.forEach((ts,lr)=>{if(pl.has(ts.function)){const la=ts.function;ys.push({index:lr+$n.length,column:la,leftMargin:Gn}),Gn+=at[ts.function]}}),ys},[at,$n,pl,_n]),jm=Ps(ml,Ur).map((Gn,ys)=>{const wr=Ur.map(lr=>({[lr]:ml[ys][lr]})),ts=`datatableentry-${ys}`;return n.createElement(uo,{key:ts,fields:aa,item:Gn,valuePath:wr,columnPivots:Gm,columnPivotValues:cu,types:h,series:_n})}),sf=(0,n.useMemo)(()=>Be.OrderedMap(l.sort.map(Gn=>[Gn.field,Gn])),[l]);return n.createElement("div",{className:fs.container},n.createElement("div",{className:fs.scrollContainer},n.createElement(ir,{striped:D,bordered:I,borderedHeader:w,stickyHeader:K,condensed:G},n.createElement(vl,{$stickyLeftMarginsByColumnIndex:uu},n.createElement(Fr,{actualColumnPivotFields:cu,columnPivots:an,fields:h,rollup:ln,rowPivots:$n,series:_n,onSortChange:kt,sortConfigMap:sf,onSetColumnsWidth:Nt,pinnedColumns:pl,togglePin:Ft})),n.createElement(yl,{$stickyLeftMarginsByColumnIndex:uu},jm))))};Ra.defaultProps={condensed:!0,striped:!0,bordered:!1,stickyHeader:!0,borderedHeader:!0};const pr=So(Ra,"table"),br=(l,i)=>{let h=l;const{filter:D,query:I,streams:w,timerange:K}=i;return D&&(h=h.filter(D)),I&&(h=h.query(I)),w&&(h=h.streams(w)),K&&(h=h.timerange(K)),h},Sl=({field:l,type:i,contexts:{widget:h=Ho.Z.empty()}})=>D=>{const I=te.Z.builder().newId().config(Te.Z.builder().rowPivots([(0,Yo.Z)(l,i)]).series([Le.ZP.forFunction("count()"),Le.ZP.forFunction("percentage()")]).visualization(pr.type).build()),w=br(I,h).build();return D((0,co.w6)(w))},Al=({field:l,contexts:{widget:i=Ho.Z.empty()}})=>h=>{const D=(0,Le.mf)(l)?Le.ZP.forFunction(l):Le.ZP.forFunction(`avg(${l})`),I=Te.Z.builder().rowPivots([(0,Yo.Z)(Mt.rg,de.Uv.DATE())]).series([D]).visualization("line").rollup(!0).build(),w=te.Z.builder().newId().config(I),K=br(w,i).build();return h((0,co.w6)(K))};var qs=e("o+5fKqZg");const ji=a().arrayOf(a().shape({label:a().string.isRequired,value:a().string.isRequired})),Pl=Gt.Z.instanceOf(qs.ZP),Ia=a().arrayOf(Pl),Ao=Gt.Z.instanceOf(Le.ZP),bl=a().arrayOf(Ao),Dl=a().arrayOf(a().string),hu=a().string,zi=Gt.Z.instanceOf(Et.Z),er=Gt.Z.instanceOf(Te.Z),rs=a().objectOf(a().arrayOf(a().object)),tr=["linear","logarithmic"],oo="linear",as="group";class Wo extends Et.Z{constructor(i,h){super(),this._value={barmode:i,axisType:h}}get barmode(){return this._value.barmode}get axisType(){return this._value.axisType}get opacity(){return this.barmode==="overlay"?.75:1}toBuilder(){const{barmode:i,axisType:h}=this._value;return new bs({barmode:i,axisType:h})}static create(i,h=oo){return new Wo(i,h)}static empty(){return Wo.create(as)}toJSON(){const{barmode:i,axisType:h}=this._value;return{barmode:i,axis_type:h}}static fromJSON(i,h){const{barmode:D,axis_type:I}=h;return Wo.create(D,I)}}class bs{constructor(i){this.value=Object.freeze({...i})}barmode(i){return new bs({...this.value,barmode:i})}axisType(i){return new bs({...this.value,axisType:i})}build(){const{barmode:i,axisType:h}=this.value;return new Wo(i,h)}}var ma=e("cIqNHR1g"),Gr=e.n(ma),Ol=e("XA6XhKoX"),jr=e.n(Ol),$o=e("IZYxBTgT");const zr=(l,i,h)=>{if(i.length===0)return l;const D=l.slice();return i.forEach(I=>{if(D[I]){const w=D[I];D[I]=(0,$o.qb)(w)?h(D[I],"internal"):w}}),D},Fs=(l,i)=>l.map((h,D)=>({value:h,idx:D})).filter(({value:h})=>i(h)).map(({idx:h})=>h),Ma=(l,i,h)=>(D=[])=>{const I=Fs(l,K=>K.type==="time"),w=Fs(i,K=>K.type==="time");return I.length===0&&w.length===0?D:D.map(K=>{if(K.source!=="leaf")return K;const G={...K};return G.key=zr(K.key,I,h),w.length>0&&(G.values=K.values.map(oe=>{if(oe.source!=="col-leaf")return oe;const pe={...oe};return pe.key=zr(oe.key,w,h),pe})),G})},Vr="\u2E31",gr="-",Rl=l=>l.join(Vr),Hr=({type:l,name:i,labels:h,values:D,originalName:I})=>({type:l,name:i,x:h,y:D,originalName:I}),Il=(l,i=({source:h})=>h.endsWith("leaf"))=>St()(l.map(h=>h.values.filter(D=>i(D)).map(D=>[h.key,D]))),xa=({valuesBySeries:l={},xLabels:i=[]})=>Object.keys(l).map(h=>[h,i,l[h],[]]),La=l=>l.source==="leaf",Ba=l=>l.filter(La),pa=l=>l.map(({key:i})=>i),Ua=(l=Rl,i=void 0)=>h=>{const D=Ba(h),I=pa(D),w=Il(D,i),K={};return w.forEach(([G,oe])=>{const pe=l(oe.key),_e=I.findIndex(ve=>cn()(ve,G));oe.value!==null&&oe.value!==void 0&&jr()(K,[pe,_e],oe.value)}),{valuesBySeries:K,xLabels:I}},wa=(l,i=Hr,h=void 0,D=I=>I)=>{const I=h.columnPivots.flatMap(w=>w.fields);return w=>{const K=w.map(([G,oe,pe,_e])=>({type:l,name:G.split(Vr).map((ve,he)=>I[he]?D(ve,I[he]):ve).join(gr),labels:oe.map(ve=>ve.join(Vr)),values:pe,data:_e,originalName:G}));return K.map((G,oe)=>i({...G,idx:oe,total:K.length,config:h}))}},Wa=()=>l=>l.map(([i,h,D,I])=>{const w=Array.from(D).reduce((oe,pe,_e)=>pe==null?[...oe,_e]:oe,[]),K=h.filter((oe,pe)=>!w.includes(pe)),G=D.filter((oe,pe)=>!w.includes(pe));return[i,K,G,I]}),Ml=l=>l.length>1?l.slice(0,-1).join(Vr):l[0],kr=(l,{chartType:i,widgetConfig:h,generator:D=Hr,seriesFormatter:I=xa,leafValueMatcher:w,formatTime:K,mapKeys:G})=>{const{rowPivots:oe,columnPivots:pe,series:_e}=h;return Gr()([Ma(oe,pe,K),Ua(_e.length===1?Ml:void 0,w),I,Wa(),wa(i,D,h,G)])(l)};var ga=e("O/XpfGnR"),Na=e("gvNRgdyu"),Za=e("hC1XaH+L"),Qr=e("2ufZf/Iw"),Fa=e("64CQykkG");const xl=l=>`${l.short_node_id} / ${l.hostname}`,ls=()=>{const l=(0,n.useContext)(Na.Z),i=(0,n.useMemo)(()=>{var G;return Object.fromEntries((G=l==null?void 0:l.map(oe=>[oe.id,oe]))!=null?G:[])},[l]),h=(0,Fa.Z)(),D=(0,Qr.Z)(),I=(0,n.useContext)(Za.Z),w=(0,Kn.Z)(),K=(0,n.useMemo)(()=>{var G;return(G=I==null?void 0:I.queryFields)==null?void 0:G.get(w)},[w,I==null?void 0:I.queryFields]);return(0,n.useCallback)((G,oe)=>{var pe,_e,ve,he,Ue;const He=K==null?void 0:K.find(at=>at.name===oe);switch((pe=He==null?void 0:He.type)==null?void 0:pe.type){case"node":return h!=null&&h[G]?xl(h[G]):G;case"input":return(ve=(_e=D==null?void 0:D[G])==null?void 0:_e.title)!=null?ve:G;case"streams":return(Ue=(he=i==null?void 0:i[G])==null?void 0:he.title)!=null?Ue:G;default:return G}},[K,D,h,i])},Ds=(l,i)=>{const{formatTime:h}=(0,ga.Z)(),D=ls();return(0,n.useMemo)(()=>kr(l,{formatTime:h,mapKeys:D,...i}),[i,h,D,l])};var is=e("b2fGY8bZ");const Er=(l,i)=>{const{formatTime:h}=(0,ga.Z)(),D=(0,n.useCallback)(I=>h(I,"internal"),[h]);return l.eventAnnotation&&i?is.ZP.toVisualizationData(i,D):{eventChartData:void 0,shapes:void 0}};var Bl=e("VgplIV7d"),Ea=e("QfIEhzaE"),Ul=e.n(Ea),fa=e("6nsVPoEI"),fr=e("G0W2UiZR"),wl=e("e50u4lQu"),Ka=e("m/3sLmyX");const Wl=u.default.div(({color:l})=>(0,u.css)` cursor: pointer; background-color: ${l} !important; /* Needed for report generation */ -webkit-print-color-adjust: exact !important; /* Needed for report generation */ width: 12px; height: 12px; `),Or=u.default.div` display: grid; grid-template: 4fr auto / 1fr; grid-template-areas: '.' '.'; height: 100%; `,$a=u.default.div` padding: 5px; max-height: 100px; overflow: auto; `,Nl=u.default.div` display: table; width: 100%; `,ha=u.default.div` display: table-row; `,va=u.default.div` padding: 4px; display: table-cell; `,Po=u.default.div` display: flex; align-items: center; `,Zl=u.default.div` margin-left: 8px; line-height: 1; `,Vi=l=>l.map(({name:i,originalName:h})=>h!=null?h:i),Fl=(l,i)=>l.length{var i,h;return(h=(i=l==null?void 0:l.columnPivots)==null?void 0:i.flatMap(D=>D.fields))!=null?h:[]},hr=({children:l,config:i,chartData:h,labelMapper:D=Vi,labelFields:I=Kl,neverHide:w})=>{const[K,G]=(0,n.useState)(),{columnPivots:oe,series:pe}=i,_e=D(h),{colors:ve,setColor:he}=(0,n.useContext)(fr.Z),{focusedWidget:Ue}=(0,n.useContext)(Ka.Z),He=(0,n.useContext)(Za.Z),at=(0,Kn.Z)(),Xe=ls(),ct=(0,n.useCallback)(()=>G(void 0),[G]),Nt=(0,n.useCallback)((_n,ln)=>Qn=>{G({name:_n,label:ln,target:Qn.currentTarget})},[G]),kt=(0,n.useCallback)((_n,ln)=>{he(_n,ln),G(void 0)},[he]),Ft=(0,n.useMemo)(()=>I(i),[i,I]);if(!w&&(!Ue||!Ue.editing)&&pe.length<=1&&oe.length<=0)return n.createElement(n.Fragment,null,l);const an=_e.sort(Fl).map(_n=>{const ln=_n.split(Mt.qN).map((ra,aa)=>{var ml,cu,pl,uu;const jm=Ft[aa],sf=(uu=(pl=(cu=(ml=He==null?void 0:He.queryFields)==null?void 0:ml.get(at))==null?void 0:cu.find(Gn=>Gn.name===jm))==null?void 0:pl.type)!=null?uu:de.ZP.Unknown;return{label:ra,field:jm,type:sf}}),Qn=_n===is.Xo?is.Ce:void 0,Ur=ln.map(({label:ra,field:aa,type:ml})=>aa?n.createElement(Kt.Z,{key:`${aa}:${ra}`,type:ml,value:ra,field:aa}):ra),Gm=Object.values(ln).map(({label:ra,field:aa})=>Xe(ra,aa)).join(Mt.v8);return n.createElement(va,{key:_n},n.createElement(Po,null,n.createElement(Wl,{"aria-label":"Color Hint",onClick:Nt(_n,Gm),color:ve.get(_n,Qn)}),n.createElement(Zl,null,Ur)))}),$n=Ul()(an,5).map((_n,ln)=>n.createElement(ha,{key:ln},_n));return n.createElement(Or,null,l,n.createElement($a,null,n.createElement(Nl,null,$n)),K&&n.createElement(Bl.zx,{event:"mousedown",onRootClose:ct},n.createElement(Bl.aV,{show:!0,placement:"top",target:K.target},n.createElement(De.Popover,{id:"legend-config",title:`Configuration for ${K.label}`},n.createElement(fa.Z,{color:ve.get(K.name),colors:wl.O,onChange:_n=>kt(K.name,_n)})))))};hr.defaultProps={labelFields:Kl,labelMapper:Vi,neverHide:!1};const qo=hr;var $l=e("vT7mdtQI"),Ga=e("9RXNqxkm"),Os=e("UmnljV2q"),Rs=e("rNH0cW39");const Gl=(l,i,h)=>(D,I)=>{const w=(0,Wn.cE)(I()),K=(0,Wn.BY)(I()),G={type:"absolute",from:(0,$o.Od)((0,$o.U2)(l,h),"internal"),to:(0,$o.Od)((0,$o.U2)(i,h),"internal")};return K===Os.Z.Type.Dashboard?D((0,Vo.A7)(G)).then(()=>D((0,Vo.ht)())):D((0,Rs.s4)(w,G)),!1},za=l=>l<150?-.6:l<400?-.2:-.14,jl=l=>{switch(l){case"linear":return"linear";case"logarithmic":return"log";default:return(0,$l.Z)(l,"Unable to parse axis type: ")}},Va=(l,i)=>{var h;return{line:{color:i.get((h=l.originalName)!=null?h:l.name)}}},ya=({axisType:l,config:i,chartData:h,effectiveTimerange:D,getChartColor:I,setChartColor:w,height:K,plotLayout:G={},onZoom:oe})=>{const{formatTime:pe,userTimezone:_e}=(0,ga.Z)(),he={yaxis:{fixedrange:!0,rangemode:"tozero",tickformat:",~r",type:jl(l)},showlegend:!1,hovermode:"x"};K&&(he.legend={y:za(K)});const Ue={...he,...G},He=(0,Do.Z)(),at=(0,n.useCallback)(i.isTimeline?(Xe,ct)=>oe?oe(Xe,ct,_e):He(Gl(Xe,ct,_e)):()=>!0,[i.isTimeline,oe]);if(i.isTimeline&&D){const Xe=pe(D.from,"internal"),ct=pe(D.to,"internal");Ue.xaxis={range:[Xe,ct],type:"date"}}else Ue.xaxis={fixedrange:!0,type:i.sort.length>0?"category":void 0};return n.createElement(qo,{config:i,chartData:h},n.createElement(Ga.Z,{chartData:h,layout:Ue,onZoom:at,getChartColor:I,setChartColor:w}))};ya.propTypes={axisType:a().oneOf(tr),chartData:a().array.isRequired,config:Gt.Z.instanceOf(Te.Z).isRequired,effectiveTimerange:a().exact({type:a().string.isRequired,from:a().string.isRequired,to:a().string.isRequired}),plotLayout:a().object,getChartColor:a().func,setChartColor:a().func,onZoom:a().func},ya.defaultProps={axisType:oo,plotLayout:{},getChartColor:void 0,setChartColor:Va,effectiveTimerange:void 0,onZoom:void 0,height:void 0};const vr=ya,zl=(l,i)=>{var h;const D=l.find(I=>I.name===i);return(h=D==null?void 0:D.marker)==null?void 0:h.color},Ha=(l,i)=>{var h;return{marker:{color:i.get((h=l.originalName)!=null?h:l.name)}}},ka=(l,i,h,D)=>i.rowPivots.length!==1||i.rowPivots[0].type!==qs.Uv?l:l.map(K=>{var G;if(((G=K==null?void 0:K.x)==null?void 0:G.length)===1){const pe=(new Date(D)-new Date(h))*.03;return{...K,width:[Math.max(30,pe)]}}return K}),Qa=So(({config:l,data:i,effectiveTimerange:h,height:D})=>{var I,w;const K=(I=l.visualizationConfig)!=null?I:Wo.empty(),G={};K&&K.barmode&&(G.barmode=K==null?void 0:K.barmode);const oe=(w=K==null?void 0:K.opacity)!=null?w:1,pe=ls(),_e=(0,n.useMemo)(()=>{var kt,Ft;return(Ft=(kt=l==null?void 0:l.rowPivots)==null?void 0:kt.flatMap(an=>an.fields))!=null?Ft:[]},[l==null?void 0:l.rowPivots]),ve=(0,n.useCallback)(kt=>kt.map(Ft=>Ft.split(Mt.qN).map((an,$n)=>pe(an,_e[$n])).join(Mt.v8)),[pe,_e]),he=(0,n.useCallback)(({type:kt,name:Ft,labels:an,values:$n,originalName:_n})=>({type:kt,name:Ft,x:ve(an),y:$n,opacity:oe,originalName:_n}),[ve,oe]),Ue=(0,n.useMemo)(()=>vs(i),[i]),He=Ds(Ue,{widgetConfig:l,chartType:"bar",generator:he}),{eventChartData:at,shapes:Xe}=Er(l,i.events),ct=at?[...He,at]:He,Nt=Xe?{...G,shapes:Xe}:G;return n.createElement(vr,{config:l,axisType:K.axisType,chartData:ka(ct,l,h==null?void 0:h.from,h==null?void 0:h.to),effectiveTimerange:h,getChartColor:zl,setChartColor:Ha,height:D,plotLayout:Nt})},"bar");Qa.propTypes={config:er.isRequired,data:rs.isRequired,height:a().number};const k=Qa;class $ extends Et.Z{constructor(i,h=oo){super(),this._value={interpolation:i,axisType:h}}get interpolation(){return this._value.interpolation}get axisType(){return this._value.axisType}toBuilder(){return new q(Be.Map(this._value))}static create(i,h=oo){return new $(i,h)}static empty(){return new $(Mt.bj,oo)}toJSON(){const{interpolation:i,axisType:h}=this._value;return{interpolation:i,axis_type:h}}static fromJSON(i,h){var D,I;return $.create((D=h==null?void 0:h.interpolation)!=null?D:Mt.bj,(I=h==null?void 0:h.axis_type)!=null?I:oo)}}class q{constructor(i=Be.Map()){this.value=i}interpolation(i){return new q(this.value.set("interpolation",i))}axisType(i){return new q(this.value.set("axisType",i))}build(){const{interpolation:i,axisType:h}=this.value.toObject();return new $(i,h)}}const Ge=l=>{switch(l){case"step-after":return"hv";default:return l}},tt=(l,i)=>{var h;const D=l.find(I=>I.name===i);return(h=D==null?void 0:D.line)==null?void 0:h.color},wt=So(({config:l,data:i,effectiveTimerange:h,height:D})=>{var I;const w=(I=l.visualizationConfig)!=null?I:$.empty(),{interpolation:K="linear",axisType:G=oo}=w,oe=ls(),pe=(0,n.useMemo)(()=>{var Nt,kt;return(kt=(Nt=l==null?void 0:l.rowPivots)==null?void 0:Nt.flatMap(Ft=>Ft.fields))!=null?kt:[]},[l==null?void 0:l.rowPivots]),_e=(0,n.useCallback)(Nt=>Nt.map(kt=>kt.split(Mt.qN).map((Ft,an)=>oe(Ft,pe[an])).join(Mt.v8)),[oe,pe]),ve=(0,n.useCallback)(({type:Nt,name:kt,labels:Ft,values:an,originalName:$n})=>({type:Nt,name:kt,x:_e(Ft),y:an,originalName:$n,line:{shape:Ge(K)}}),[_e,K]),he=(0,n.useMemo)(()=>vs(i),[i]),Ue=Ds(he,{widgetConfig:l,chartType:"scatter",generator:ve}),{eventChartData:He,shapes:at}=Er(l,i.events),Xe=He?[...Ue,He]:Ue,ct=at?{shapes:at}:{};return n.createElement(vr,{config:l,plotLayout:ct,axisType:G,effectiveTimerange:h,getChartColor:tt,height:D,chartData:Xe})},"line");wt.propTypes={config:er.isRequired,data:rs.isRequired,height:a().number};const Un=wt;class Tn extends Et.Z{constructor(i,h){super(),this._value={trend:i,trendPreference:h}}get trend(){return this._value.trend}get trendPreference(){return this._value.trendPreference}toBuilder(){return new kn(Be.Map(this._value))}static create(i=!1,h="NEUTRAL"){return new Tn(i,h)}static empty(){return Tn.create(!1,"NEUTRAL")}toJSON(){const{trend:i,trendPreference:h}=this._value;return{trend:i,trend_preference:h}}equalsForSearch(i){return i&&"trend"in i&&i.trend===this.trend}static fromJSON(i,h){const{trend:D,trend_preference:I}=h;return Tn.create(D,I)}}class kn{constructor(i=Be.Map()){this.value=i}trend(i){return new kn(this.value.set("trend",i))}trendPreference(i){return new kn(this.value.set("trendPreference",i))}build(){const{trend:i,trendPreference:h}=this.value.toObject();return new Tn(i,h)}}var Eo=e("IdpefXWm"),eo=e("9pdI12pI"),fo=e.n(eo);const to=(l,i="neutral")=>({good:l.colors.variant.success,bad:l.colors.variant.danger,neutral:l.colors.global.contentBackground})[i],cs=u.default.div(({theme:l,trend:i})=>{const h=to(l,i);return(0,u.css)` text-align: right; ${i&&(0,u.css)` background-color: ${h} !important; /* Needed for report generation */ color: ${l.utils.contrastingColor(h)} !important /* Needed for report generation */; color-adjust: exact !important; /* Needed for report generation */ `} `}),us=u.default.div(({theme:l,trend:i})=>{const h=to(l,i);return(0,u.css)` margin: 5px; color: ${l.utils.contrastingColor(h)} !important /* Needed for report generation */; font-family: ${l.fonts.family.body}; color-adjust: exact !important; /* Needed for report generation */`}),Is=(0,u.default)(P.Z)(({theme:l,trend:i})=>{const h=to(l,i);return(0,u.css)` path { fill: ${l.utils.contrastingColor(h)}; }`}),nr=(l,i)=>{switch(i){case"LOWER":return l>0?"bad":"good";case"HIGHER":return l>0?"good":"bad";case"NEUTRAL":default:return"neutral"}},or=l=>l===0?"arrow-circle-right":l>0?"arrow-circle-up":"arrow-circle-down",po=(l,i)=>{if(typeof l=="number"&&typeof i=="number"){const h=l-i,D=h/i;return[h,D]}return[NaN,NaN]},ho=n.forwardRef(({current:l,previous:i,trendPreference:h},D)=>{const[I,w]=po(l,i),K=nr(I,h),G=or(I),oe=Number.isFinite(I)?fo()(I).format("+0,0[.]0[000]"):"--",pe=Number.isFinite(w)?fo()(w).format("+0[.]0[0]%"):"--";return n.createElement(cs,{trend:K,"data-testid":"trend-background"},n.createElement(us,{trend:K,ref:D},n.createElement(Is,{name:G,trend:K,"data-testid":"trend-icon"})," ",n.createElement("span",{"data-testid":"trend-value",title:`Previous value: ${i}`},oe," / ",pe)))}),Ms=.05,Jr=.8,Vl=u.default.div` height: 100%; width: 100%; font-size: ${l=>(0,u.css)`${l.fontSize}px`}; ${l=>l.$center?(0,u.css)` display: flex; justify-content: center; align-items: center; `:""} `,Hl=(l,i,h)=>{const D=l.offsetWidth,I=l.offsetHeight,w=i*Jr/D,K=h*Jr/I;return Math.min(w,K)},$s=l=>l!==0&&Number.isFinite(l),Gs=(l,i,h,D)=>{const[I,w]=(0,n.useState)(20);return(0,n.useEffect)(()=>{var K;const G=l?{current:{children:[l]}}:i,oe=(K=G==null?void 0:G.current)==null?void 0:K.children;if(!oe||oe.length<=0)return;const pe=oe[0],_e=Hl(pe,D,h);if(Math.abs(1-_e)<=Ms)return;const ve=Math.floor(I*_e);ve!==I&&$s(ve)&&w(ve)},[l,i,I,h,D]),I},js=({children:l,target:i,height:h,width:D,center:I})=>{const w=(0,n.useRef)(),K=Gs(i,w,h,D),G=w;return n.createElement(Vl,{$center:I,fontSize:K,ref:G},l)};js.defaultProps={target:null,center:!1};const kl=js,vu=u.default.div` display: grid; grid-template-columns: 1fr; grid-template-rows: 1fr auto; grid-gap: 0; height: 100%; width: 100%; `,Xa=u.default.div` display: grid; grid-template-columns: 1fr; grid-template-rows: 1fr; grid-gap: 0; height: 100%; width: 100%; `,yu=(0,u.default)(Eo.Z)` height: 100%; width: 100%; padding-bottom: 10px; `,Hi=(0,u.default)(Eo.Z)` height: 100%; width: 100%; `,ki=l=>{if(!l||!l[0])return{value:void 0,field:void 0};const i=l[0];if(i.source==="leaf"){const h=i.values.find(D=>D.source==="row-leaf");if(h&&h.source==="row-leaf")return{value:h.value,field:h.key[0]}}return{value:void 0,field:void 0}},_u=l=>{const{series:i=[]}=l;return i.length===0?void 0:i[0].function},_a=So(({config:l,fields:i,data:h})=>{var D;const I=(0,n.useRef)(),w=(0,n.useContext)(Yn.Z),K=(D=l.visualizationConfig)!=null?D:Tn.create(),G=_u(l);(0,n.useEffect)(w,[w]);const oe=vs(h),pe=h.trend,{value:_e}=ki(oe),{value:ve}=ki(pe||[]);if(!G||_e!==0&&!_e)return n.createElement(n.Fragment,null,"N/A");const he=K.trend?vu:Xa;return n.createElement(he,null,n.createElement(yu,{resizeDelay:20},({height:Ue,width:He})=>n.createElement(kl,{height:Ue,width:He,center:!0},n.createElement(zn.Z,{field:G,value:_e},n.createElement(Kt.Z,{field:G,type:xn(G,i),value:_e,render:fn.Z})))),K.trend&&n.createElement(Hi,null,({height:Ue,width:He})=>n.createElement(kl,{height:Ue,width:He,target:I},n.createElement(ho,{ref:I,current:_e,previous:ve,trendPreference:K.trendPreference}))))},"numeric");var Ql=e("C+aLQzYd"),Tu=e.n(Ql),Qi=e("aG6epsDL"),Xl=e.n(Qi),Xi=e("oc9db6Tt"),Rr=e.n(Xi),Ji=e("dcKvY45t"),Su=e("Kw0W+Qo6"),Yi=e("qihsatSm"),Au=e("I0Ijpclp"),Pu=e("ss9BCvNi"),qi=e("ww+BtWnX"),bu=e.n(qi),Du=e("yZFI2u4Q");class Ir{constructor(i,h){this._value={center:i,zoom:h}}get center(){return this._value.center}get zoom(){return this._value.zoom}toBuilder(){const{center:i,zoom:h}=this._value;return new Jl(Be.Map({center:i,zoom:h}))}static create(i,h){return new Ir(i,h)}toJSON(){const{center:i,zoom:h}=this._value;return{center_x:i[0],center_y:i[1],zoom:h}}static fromJSON(i){const{center_x:h,center_y:D,zoom:I}=i;return Ir.create([h,D],I)}}class Jl{constructor(i=Be.Map()){this.value=i}center(i){return new Jl(this.value.set("center",i))}zoom(i){return new Jl(this.value.set("zoom",i))}build(){const{center:i,zoom:h}=this.value.toObject();return new Ir(i,h)}}var Ja=e("H/VBAZHe"),Mr={};Mr.styleTagTransform=Qs(),Mr.setAttributes=Ko(),Mr.insert=Nn().bind(null,"head"),Mr.domAPI=Vn(),Mr.insertStyleElement=Oo();var km=un()(Ja.Z,Mr);const Yl=Ja.Z&&Ja.Z.locals?Ja.Z.locals:void 0,ec={center:[0,0],zoom:1},Ou=(l,i,h,D,I)=>{const w=(D-h)/i;return(l{const pe=l.split(",").map(he=>Number(he)).filter(he=>!isNaN(he));if(pe.length!==2)return null;const _e=Ou(i,I,h,D,w),ve=St()(Object.entries(oe).map(([he,Ue])=>[n.createElement("dt",{key:`dt-${he}-${Ue}`},he),n.createElement("dd",{key:`dd-${he}-${Ue}`},Ue)]));return n.createElement(Ji.c,{key:`${G}-${l}`,center:pe,radius:_e,color:K.hex(),fillColor:K.hex(),weight:2,opacity:.8},n.createElement(Su.G,null,n.createElement("dl",null,n.createElement("dt",null,"Name"),n.createElement("dd",null,G),ve,n.createElement("dt",null,"Coordinates:"),n.createElement("dd",null,l),i&&n.createElement(n.Fragment,null,n.createElement("dt",null,"Value:"),n.createElement("dd",null,i)))))},Ru=({onViewportChanged:l})=>{const i=(0,Yi.Sx)(),h=()=>{const{lat:D,lng:I}=i.getCenter();return l(Ir.create([D,I],i.getZoom()))};return(0,Yi.zV)({dragend:h,zoomend:h}),null};class Ya extends n.Component{constructor(){super(...arguments),this._isMapReady=!1,this._areTilesReady=!1,this._handleRenderComplete=()=>{if(this._areTilesReady&&this._isMapReady){const{onRenderComplete:i}=this.props;i()}},this._handleMapReady=()=>{this._isMapReady=!0,this._handleRenderComplete()},this._handleTilesReady=()=>{this._areTilesReady=!0,this._handleRenderComplete()}}componentDidMount(){Du.Z.use()}componentWillUnmount(){Du.Z.unuse()}render(){const{data:i,id:h,height:D,width:I,url:w,attribution:K,locked:G,viewport:oe,onChange:pe,markerRadiusSize:_e,markerRadiusIncrementSize:ve}=this.props,he=i.length,Ue=bu().scale("Spectral"),He=i.flatMap(({keys:at,name:Xe,values:ct},Nt)=>{const kt=Object.values(ct),Ft=Math.min(...kt),an=Math.max(...kt),$n=Ue(Nt*(1/he));return Object.entries(ct).map(([_n,ln],Qn)=>n.createElement(tc,{key:`${Xe}-${_n}-${ln}`,coordinates:_n,value:ln,min:Ft,max:an,radiusSize:_e,increment:ve,color:$n,name:Xe,keys:at[Qn]}))});return n.createElement(gt.Z.Consumer,null,at=>n.createElement("div",{className:G?Yl.mapLocked:"",style:{position:"relative",zIndex:0}},G&&n.createElement("div",{className:Yl.overlay,style:{height:D,width:I}}),n.createElement(Au.h,{center:oe.center,boundsOptions:{maxZoom:19,animate:at},zoom:oe.zoom,className:Yl.map,fadeAnimation:at,key:`visualization-${h}-${I}-${D}`,id:`visualization-${h}`,markerZoomAnimation:at,scrollWheelZoom:!0,style:{height:D,width:I},whenReady:this._handleMapReady,zoomAnimation:at},n.createElement(Ru,{onViewportChanged:pe}),n.createElement(Pu.I,{url:w,attribution:K,eventHandlers:{load:this._handleTilesReady}}),He)))}}Ya.propTypes={id:a().string.isRequired,data:a().arrayOf(a().object),height:a().number.isRequired,width:a().number.isRequired,url:a().string,attribution:a().string,onRenderComplete:a().func,onChange:a().func.isRequired,locked:a().bool,markerRadiusSize:a().number,markerRadiusIncrementSize:a().number,viewport:a().shape({center:a().arrayOf(a().number),zoom:a().number})},Ya.defaultProps={data:{},url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors',onRenderComplete:()=>{},locked:!1,viewport:ec,markerRadiusSize:10,markerRadiusIncrementSize:10};const Iu=Ya,Qm=([l,i,h])=>({name:l,x:i,y:h}),qa=l=>l[l.length-1],Mu=l=>{const i=Ba(l),h=pa(i);return Rr()(h)?{}:{valuesBySeries:{"No metric defined":h.map(()=>null)},xLabels:h}},xu=l=>{const i=l.flatMap(h=>h.fields);return h=>h.map(({name:D,x:I,y:w})=>{const K=I.map(pe=>Object.fromEntries(pe.slice(0,-1).map((_e,ve)=>[i[ve],_e]))),G=I.map(qa),oe=Tu()(Xl()(G,w).filter(([pe,_e])=>_e!==void 0));return{keys:K,name:D,values:oe}})},Lu=So(({config:l,data:i,editing:h,onChange:D,width:I,...w})=>{const{rowPivots:K}=l,G=(0,n.useContext)(Yn.Z),oe=!Rr()(l.series),pe=oe?void 0:1,_e=oe?Ua():Mu,{formatTime:ve}=(0,ga.Z)(),he=Gr()([Ma(l.rowPivots,l.columnPivots,ve),_e,xa,ct=>ct.map(Qm),xu(K)]),Ue=vs(i),He=he(Ue),at=Fe()(l,"visualizationConfig.viewport"),Xe=ct=>{h&&D({zoom:ct.zoom,centerX:ct.center[0],centerY:ct.center[1]})};return n.createElement(Iu,{...w,data:He,id:"world-map",viewport:at,width:I,onRenderComplete:G,markerRadiusSize:pe,onChange:Xe})},"map");Lu.propTypes={config:er.isRequired,data:rs.isRequired,onChange:a().func.isRequired,width:a().number.isRequired};const ql=Lu;var Bu=e("EAGCr4ZJ"),ei=e.n(Bu),Uu=e("wXrUUKFq"),wu=e.n(Uu),Wu=e("y9+BLtuu"),nc=e.n(Wu),Nu=e("alU4HbhK"),Xm=e.n(Nu),Ca=e("hD3VAVgz");const Jm=(l,i,h)=>{const D=l.series.map(w=>w.function),I=i.map(w=>D.length>1?D.find(K=>w.endsWith(K)):D.toString());return h.map(()=>I)},Zu=(l,i,h)=>({type:D,name:I,labels:w,values:K,data:G,config:oe})=>{const pe=oe.rowPivots.flatMap(an=>an.fields),_e=oe.columnPivots.flatMap(an=>an.fields),ve=pe.join("-"),he=_e.join("-"),Ue=Jm(oe,K,w),He=`${ve}: %{y}
${he}: %{x}
%{text}: %{customdata}`,{colorScale:at,reverseScale:Xe,zMin:ct,zMax:Nt}=l,kt=w.map(an=>i(an,pe[0])),Ft=K.map(an=>i(an,_e[0]));return{type:D,name:I,x:Ft,y:kt,z:G,text:Ue,customdata:G,hovertemplate:He,colorscale:at,reversescale:Xe,zmin:ct,zmax:Nt,originalName:I,colorbar:{tickfont:{color:h.colors.global.textDefault}}}},Ym=(l,i,h="None")=>l.map(D=>{const I=nc()(Array(i.length),h);return wu()(I,D)}),Fu=(l=[])=>l[0]?l[0].map((i,h)=>l.map(D=>D[h])):l,Ku=l=>l.reduce((i,h)=>h.reduce((D,I)=>D>I?I:D,i),(l[0]||[])[0]),qm=l=>({valuesBySeries:i,xLabels:h})=>{var D;const I=ei()(i),w=l.useSmallestAsDefault?Ku(I):(D=l.defaultValue)!=null?D:"None",K=Fu(Ym(I,h,w)),G=Object.keys(i);return[["Heatmap Chart",h,G,K]]},$u=l=>{const i={type:void 0,fixedrange:!0};return l&&(i.type="category"),i},Gu=l=>{const i=Xm()(l,D=>!Rr()(D.z)),h=$u(i);return{yaxis:h,xaxis:h,margin:{b:40}}},ep=({source:l})=>l.endsWith("leaf")&&l!=="row-leaf",oc=So(({config:l,data:i})=>{var h;const D=(0,u.useTheme)(),I=(h=l.visualizationConfig)!=null?h:Ca.ZP.empty(),w=vs(i),K=ls(),G=Ds(w,{widgetConfig:l,chartType:"heatmap",generator:Zu(I,K,D),seriesFormatter:qm(I),leafValueMatcher:ep}),oe=Gu(G);return n.createElement(Ga.Z,{chartData:G,layout:oe})},"heatmap");oc.propTypes={config:er.isRequired,data:rs.isRequired};const Ta=oc;var Yr=e("7GNmVOX8"),ju=e("mTnbNx1k"),sc=e("FfX57J1C");class zs extends Et.Z{constructor(i,h=oo){super(),this._value={interpolation:i,axisType:h}}get interpolation(){return this._value.interpolation}get axisType(){return this._value.axisType}toBuilder(){return new ti(Be.Map(this._value))}static create(i,h=oo){return new zs(i,h)}static empty(){return zs.create(Mt.bj)}toJSON(){const{interpolation:i,axisType:h}=this._value;return{interpolation:i,axis_type:h}}static fromJSON(i,h){var D,I;return zs.create((D=h==null?void 0:h.interpolation)!=null?D:Mt.bj,(I=h==null?void 0:h.axis_type)!=null?I:oo)}}class ti{constructor(i=Be.Map()){this.value=i}interpolation(i){return new ti(this.value.set("interpolation",i))}build(){const{interpolation:i,axisType:h}=this.value.toObject();return new zs(i,h)}}var ni=e("dsvqAVKU");const zu="pinned-field-charts",oi="pinned-field-charts-migrated",Vu=u.default.div` margin-top: 10px; `,Hu=l=>{switch(l){case"total":return"sum";case"mean":return"avg";case"cardinality":return"card";default:return l}},tp=(l,i)=>`${Hu(l)}(${i})`,ku=l=>{switch(l){case"scatterplot":return"scatter";case"line":case"area":case"bar":return l;default:throw new Error(`Unsupported visualization ${l}`)}},Qu=l=>{switch(l){case"quarter":return{unit:"months",value:3};default:return{unit:`${l}s`,value:1}}},np=l=>{switch(l){case"basis":case"bundle":case"cardinal":case"monotone":return"spline";case"linear":case"step-after":return l;default:throw new Error(`Unsupported interpolation ${l}`)}},Xu=(l,i)=>{const h=np(l);switch(i){case"line":return $.create(h);case"area":return zs.create(h);default:return}},Ju=(l,i)=>{const h={...l};return Object.keys(h).forEach(D=>{const I=h[D];h[D]=I.toBuilder().row(I.row+i).build()}),h},Yu=l=>async(i,h)=>{const{defaultHeight:D}=(0,ju.FZ)(te.Z.type),I=(0,Wn.Sq)(h()),w=(0,Wn.cE)(h()),K={},G=l.map((ve,he)=>{const{field:Ue}=ve,He=new Le.ZP(tp(ve.valuetype,Ue)),at={interval:{type:"timeunit",...Qu(ve.interval)}},Xe=qs.ZP.create([Mt.rg],"time",at),ct=ku(ve.renderer),Nt=Xu(ve.interpolation,ct),kt=Te.Z.builder().visualization(ct).visualizationConfig(Nt).series([He]).rowPivots([Xe]).build(),Ft=te.Z.builder().newId().timerange(void 0).config(kt).build(),an=D*he+1;return K[Ft.id]=new sc.Z(1,an,D,1/0),Ft}),oe=l.length*D,pe=Ju(I.widgetPositions,oe);return{newViewState:I.toBuilder().widgets(Be.List([...I.widgets,...G])).widgetPositions({...pe,...K}).build(),currentQueryId:w}},qu=async(l,i,h,D)=>{h(!0);const{newViewState:I,currentQueryId:w}=await l(Yu(i));await l((0,Rs.VN)(w,I)),await l((0,Vo.ht)()),Yr.Z.set(oi,"finished"),h(!1),D(!0)},rc=l=>{Yr.Z.set(oi,"discarded"),l(!0)},si=()=>{const[l,i]=(0,n.useState)(!1),[h,D]=(0,n.useState)(!!Yr.Z.get(oi)),I=ei()(Yr.Z.get(zu)),w=I.length,K=(0,Do.Z)(),G=(0,n.useCallback)(()=>qu(K,I,i,D),[K,I]);return h||Rr()(I)?null:n.createElement(De.Row,null,n.createElement(De.Col,null,n.createElement(De.Alert,{bsStyle:"warning",title:"Migrate existing search page charts"},n.createElement("br",null),"We found ",w," chart(s), created for an older version of the search. Do you want to migrate these chart(s) for the current search?",n.createElement("br",null),"When you have run the migration and want to keep the newly created charts, you will have to save the current search as a new dashboard. Otherwise the charts will get lost, when leaving the search page.",n.createElement("br",null),n.createElement(Vu,null,n.createElement(De.Button,{bsStyle:"primary",onClick:G,disabled:l,className:"save-button-margin"},"Migrate ",l&&n.createElement(ni.Z,{text:""})),n.createElement(De.Button,{onClick:()=>rc(D),disabled:l},"Discard charts")))))};var ed=e("xsbnunTq"),ri=e("iltCXley");const lc=l=>{switch(l){case"seconds":return"s";case"minutes":return"m";case"hours":return"h";case"days":return"d";case"weeks":return"w";case"months":return"M";default:throw new Error(`Invalid time unit: ${l}`)}},el=l=>{const{type:i,fields:h,config:D}=l,I={...D};switch(i){case"time":if(D.interval.type==="timeunit"){const{interval:w}=D,{unit:K,value:G}=w;I.interval={type:"timeunit",timeunit:`${G}${lc(K)}`}}break;default:}return{type:i,fields:h,...I}},ai=(l,i,{rollupForBackendQuery:h,rowPivots:D,columnPivots:I,series:w,sort:K})=>({id:l,name:i,type:"pivot",config:{id:"vals",rollup:h,row_groups:D.map(el),column_groups:I.map(el),series:w.map(G=>({id:G.effectiveName,...(0,Le.mg)(G.function)})),sort:K}}),td=({config:l})=>{const i=ai((0,ri.Z)(),"chart",l),h=li.create([i]);if(l.visualization==="numeric"&&l.visualizationConfig&&l.visualizationConfig.trend){const D={...ai((0,ri.Z)(),"trend",l),timerange:{type:"offset",source:"search_type",id:i.id}};h.add(D)}if(l.eventAnnotation){const D={id:(0,ri.Z)(),name:"events",type:"events"};h.add(D)}return h.build()};class li{constructor(i){this.value=Be.Set.of(...i)}add(i){return this.value=this.value.add(i),this}build(){return this.value.toArray()}static create(i=[]){return new li(i)}}const nd={convert(l){return l}},od=l=>l.map(i=>[i.name||i.id,i]).reduce((i,[h,D])=>({...i,[h]:D}),{});var ic=e("i0LZga0C"),sd=e("A2mY8G47");const rd=["count","sum","avg","min","max","stddev","variance","card","percentile"],sr=["count","card"],cc=({field:l,type:i,contexts:{widget:h=Ho.Z.empty()}})=>(D,I)=>{const w=(0,Wn.cE)(I()),K=(i&&i.isNumeric()?rd:sr).map(_e=>_e==="percentile"?`${_e}(${l},95)`:`${_e}(${l})`).map(Le.ZP.forFunction),G=Te.Z.builder().series(K).visualization("table").rollup(!0).build(),oe=te.Z.builder().newId().config(G),pe=br(oe,h).build();return D((0,co.w6)(pe)).then(()=>D((0,sd.T)(w,ic.Z.Widget,pe.id,`Field Statistics for ${l}`)))};var ko=e("I4XORk+Y");const ad=(l,i,h)=>{const D=h===Mt.ZW?`_exists_:${i}`:`NOT ${i}:${(0,ko.YU)(h)}`;return(0,ko.$_)(l,D)},sp=({queryId:l,field:i,value:h})=>(D,I)=>{const w=(0,Wn.M7)(l)(I()),K=ad(w,i,h);return D((0,Rs.bj)(l,K))};var ii=e("hhdCSTZj");const uc=(l,i)=>l.find(h=>h.label===i),dc=(l,i)=>l.find(h=>h.value===i),ci=(l,i)=>{var h;return l&&l.length>0&&((h=uc(i,l[0].field))==null?void 0:h.value)},mc=l=>l.sort((i,h)=>(0,We.S)(i.name,h.name)).map((i,h)=>({label:i.name,value:h})).toArray(),yr=(l,i,h)=>{const D=dc(l,h);if(!D)return;const I=new An.Z(An.Z.PIVOT_TYPE,D.label,Jt.Z.Ascending);return i([I])},pc=({fields:l,onChange:i,sort:h})=>{const D=(0,n.useMemo)(()=>mc(l),[l]);return n.createElement(ii.Z,{placeholder:"None: click to add fields",onChange:I=>yr(D,i,I),options:D,clearable:!1,"aria-label":"Select field for sorting",value:ci(h,D)})};pc.propTypes={onChange:a().func.isRequired,fields:Gt.Z.FieldListType.isRequired,sort:a().array.isRequired};const rp=pc,ui=({direction:l,disabled:i,onChange:h})=>n.createElement(ii.Z,{disabled:i,clearable:!1,options:[{label:"Ascending",value:"Ascending"},{label:"Descending",value:"Descending"}],onChange:D=>h(Jt.Z.fromString(D)),placeholder:i?"No sorting selected":"Click to select direction",value:l!=null?l:null});ui.propTypes={direction:a().string,disabled:a().bool,onChange:a().func},ui.defaultProps={direction:void 0,disabled:!1,onChange:()=>{}};const ap=ui;var ld=Object.defineProperty,id=(l,i,h)=>i in l?ld(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,tl=(l,i,h)=>(id(l,typeof i!="symbol"?i+"":i,h),h);const gc=u.default.div(({theme:l})=>(0,u.css)` background-color: ${l.colors.variant.lightest.default}; border: 1px solid ${l.colors.variant.lighter.default}; padding: 10px; margin: 5px; border-radius: 6px; .description { padding-bottom: 5px; text-transform: uppercase; } `),di=u.default.button` border: 0; background: transparent; padding: 0; `;class ea extends n.Component{constructor(i){super(i),tl(this,"onToggleConfig",()=>{const{configOpen:h}=this.state;this.setState({configOpen:!h})}),tl(this,"configPopover",()=>{const{configOpen:h}=this.state,{configurableOptions:D}=this.props;if(!h)return"";const I=n.cloneElement(D,{onClose:this.onToggleConfig});return n.createElement(rt.Uv,null,n.createElement(Bl.Ly,{placement:"bottom",target:this.target},n.createElement(De.Popover,{title:"Config options",id:"config-popover"},I)))}),tl(this,"configCaret",()=>{const{configurableOptions:h}=this.props;return h?n.createElement(di,{ref:D=>{this.target=D},type:"button",onClick:this.onToggleConfig},n.createElement(rt.JO,{name:"wrench"})):null}),this.state={configOpen:!1}}render(){const{description:i,children:h,help:D,style:I}=this.props;return n.createElement(gc,{style:I},n.createElement("div",{className:"description"},i,this.configCaret(),D&&n.createElement(rt.kF,{title:i},D)),h,this.configPopover())}}ea.propTypes={children:a().node.isRequired,configurableOptions:a().node,description:a().string.isRequired,help:a().string,style:a().object},ea.defaultProps={configurableOptions:void 0,style:void 0,help:void 0};const ta=ea;var Ec=e("pa3lbc7X"),lp=e("H1J/o4st"),fc=e("0l+/Cv54"),cd=e("B6AO2vlN"),ip=e("mSSPPdLK");class hc extends n.Component{constructor(){super(...arguments),this._formatDecorator=i=>{const{decorators:h,decoratorTypes:D,onChange:I}=this.props,w=D[i.type]||{requested_configuration:{},name:`Unknown type: ${i.type}`},K=oe=>I(h.filter(pe=>pe.id!==oe)),G=(oe,pe)=>I(h.map(_e=>_e.id===oe?pe:_e));return{id:i.id,title:n.createElement(fc.Z,{key:`decorator-${i.id}`,decorator:i,decoratorTypes:D,onDelete:K,onUpdate:G,typeDefinition:w})}},this._updateOrder=i=>{const{decorators:h,onChange:D}=this.props;i.forEach((I,w)=>{const K=h.find(G=>G.id===I.id);K.order=w}),D(h)}}componentDidMount(){Ec.D.available()}render(){const{decoratorTypes:i,onChange:h,decorators:D}=this.props;if(!i)return n.createElement(rt.$j,null);const I=D.sort((oe,pe)=>oe.order-pe.order),w=I.length>0?I[I.length-1].order+1:0,K=I.map(this._formatDecorator),G=oe=>h([...D,oe]);return n.createElement("div",null,n.createElement(lp.Z,{decoratorTypes:i,nextOrder:w,onCreate:G}),n.createElement("div",{className:ip.Z.decoratorListContainer},n.createElement(cd.Z,{decorators:K,onReorder:this._updateOrder})))}}hc.propTypes={decorators:a().array.isRequired,decoratorTypes:a().object.isRequired,onChange:a().func.isRequired};const vc=(0,Z.Z)(hc,{decoratorStore:Ec.I},({decoratorStore:{types:l={}}={}})=>({decoratorTypes:l}));var ud=e("i/Bor0y0"),yc=e("GrokUsBg");const nl=(0,u.default)(De.Row)` height: 100%; padding-bottom: 15px; flex: 1; `,mi=(0,u.default)(De.Col)` height: 100%; overflow: auto; `,pi=(0,u.default)(De.Checkbox)` label { display: flex; justify-content: space-between; } `,_c=(l,i,h)=>{const D=i.toBuilder().fields(l).build();return h(D)},cp=(l,i,h)=>{const D=i.toBuilder().sort(l).build();return h(D)},dd=(l,i,h)=>{const D=i.toBuilder().sort(i.sort.map(I=>I.toBuilder().direction(l).build())).build();return h(D)},gi=({children:l,config:i,fields:h,onChange:D,onCancel:I,onSubmit:w})=>{const{sort:K}=i,[G]=(K||[]).map(ve=>ve.direction),oe=ve=>D(i.toBuilder().decorators(ve).build()),_e=(0,Ke.Z)("views.components.widgets.messageTable.previewOptions").sort((ve,he)=>(0,We.S)(ve.sort,he.sort));return n.createElement(nl,null,n.createElement(mi,{md:3},n.createElement(ud.Z,{actions:n.createElement(mo.Z,{onCancel:I,onSubmit:w}),alignActionsAtBottom:!0},n.createElement(ta,{description:"Fields"},n.createElement(yc.Z,{onChange:ve=>_c(ve,i,D),menuPortalTarget:document.body,selectedFields:i.fields})),n.createElement(ta,{description:"Message Preview"},_e.map(ve=>n.createElement(pi,{key:ve.title,checked:ve.isChecked(i),onChange:()=>ve.onChange(i,D),disabled:ve.isDisabled(i)},ve.title,ve.help&&n.createElement(rt.kF,{title:ve.title},ve.help)))),n.createElement(ta,{description:"Sorting"},n.createElement(rp,{fields:h,sort:K,onChange:ve=>cp(ve,i,D)})),n.createElement(ta,{description:"Direction"},n.createElement(ap,{disabled:!K||K.length===0,direction:G&&G.direction,onChange:ve=>dd(ve,i,D)})),n.createElement(ta,{description:"Decorators"},n.createElement(vc,{decorators:i.decorators,onChange:oe})))),n.createElement(mi,{md:9},l))};gi.propTypes={children:Gt.Z.OneOrMoreChildren.isRequired,config:a().object.isRequired,fields:Gt.Z.FieldListType.isRequired,onChange:a().func.isRequired};const md=gi,ol=(0,p.Z)(()=>e.e("1255d548-3488").then(e.bind(e,"oUJj821/"))),Cc=(0,p.Z)(()=>e.e("1255d548-124").then(e.bind(e,"hP+nVj7o"))),pd=(0,p.Z)(()=>e.e("1255d548-517").then(e.bind(e,"21eHsCFI"))),gd=(0,p.Z)(()=>e.e("1255d548-6618").then(e.bind(e,"9/bZdhqf"))),Ei=(0,p.Z)(()=>Promise.all([e.e("1255d548-9366"),e.e("1255d548-7153")]).then(e.bind(e,"r4MY1c4i"))),Ed=(0,p.Z)(()=>Promise.all([e.e("1255d548-9366"),e.e("1255d548-7153")]).then(e.bind(e,"9lIfR+pR"))),fd=(0,p.Z)(()=>Promise.all([e.e("1255d548-9366"),e.e("1255d548-7153")]).then(e.bind(e,"cXPoJEmv")));var up=e("WyXFCd64");const Tc=()=>{const l=Le.ZP.forFunction("count()").toBuilder().config(new up.Z("Message Count")).build();return te.Z.builder().newId().config(Te.Z.builder().series([l]).visualization(_a.type).build()).build()},hd=()=>l=>l((0,co.w6)(Tc())),Sc=()=>Lo.Z.builder().newId().config(pt.ZP.builder().fields(Mt.gj).showMessageRow(!0).showSummary(!0).build()).build(),vd=()=>l=>l((0,co.w6)(Sc())),fi=({field:l,contexts:{widget:i}})=>h=>{const D=i.config.fields.filter(w=>w!==l),I=i.config.toBuilder().fields(D).build();return h((0,co.YS)(i.id,I))},yd=({contexts:{widget:l},field:i})=>Lo.Z.isMessagesWidget(l)&&l.config?(l.config.fields||[]).includes(i):!1,_d=({contexts:{widget:l}})=>!l;fi.isEnabled=yd,fi.isHidden=_d;const hi=fi,X=({field:l})=>(i,h)=>{const I=(0,Wn.RN)(h()).map(w=>{if(w.type.toUpperCase()===Lo.Z.type.toUpperCase()){const K=w.config.fields.filter(oe=>oe!==l),G=w.config.toBuilder().fields(K).build();return w.toBuilder().config(G).build()}return w}).toList();return i((0,co.o8)(I))},qe=({view:l})=>te.Z.builder().newId().timerange(l.type===Os.Z.Type.Dashboard?Mt.nn:void 0).config(Te.Z.builder().rowPivots([]).series([]).visualization(pr.type).build()).build(),Bt=()=>(l,i)=>{const h=(0,Wn.fv)(i());return l((0,co.w6)(qe({view:h})))};var Wt=e("xS8q27Jr");const Rn=({label:l})=>n.createElement("strong",null,l),go=()=>Wt.Z.EXTRACTOR_TYPES.map(l=>({label:Wt.Z.getReadableExtractorTypeName(l),value:l}));class No extends n.Component{constructor(i){super(i),this.extractorRoutes={},this._onSubmit=()=>{const{onClose:h}=this.props;h();const{selectedExtractor:D}=this.state;if(D){const I=this.extractorRoutes[D];window.open(I,"_blank").focus()}},this._onChange=h=>{this.setState({selectedExtractor:h})},this.state={selectedExtractor:void 0}}componentDidMount(){const{message:i}=this.context,{gl2_source_node:h,gl2_source_input:D}=i.fields,{field:I}=this.props;this.extractorRoutes=Wt.Z.getNewExtractorRoutes(h,D,I,i.index,i.id)}render(){const{selectedExtractor:i}=this.state;return n.createElement(De.BootstrapModalForm,{title:"Select extractor type",submitButtonDisabled:!i,show:!0,onCancel:this.props.onClose,onSubmitForm:this._onSubmit},n.createElement(ii.Z,{placeholder:"Select extractor type",optionRenderer:Rn,clearable:!0,onChange:this._onChange,options:go()}))}}No.propTypes={onClose:a().func.isRequired},No.contextType=en.f;const vi=No;class xr extends Et.Z{constructor(i){super(),this._value={viewport:i}}get viewport(){return this._value.viewport}toBuilder(){const{viewport:i}=this._value;return new Sa(Be.Map({viewport:i}))}static create(i){return new xr(i)}toJSON(){const{viewport:i}=this._value;return{viewport:i}}static fromJSON(i,h){const{viewport:D}=h;return xr.builder().viewport(Ir.fromJSON(D)).build()}static builder(){return new Sa}}class Sa{constructor(i=Be.Map()){this.value=i}viewport(i){return new Sa(this.value.set("viewport",i))}build(){const{viewport:i}=this.value.toObject();return new xr(i)}}var yi=e("CHWvwBKE");const mp=l=>l.map(i=>Object.entries(i).map(([h,D])=>h==="_exists_"?D:h)).reduce((i,h)=>[...i,...h],[]).reduce((i,h)=>i.includes(h)?i:[...i,h],[]),Cd=({contexts:{valuePath:l,widget:i}})=>(h,D)=>{const I=(0,Wn.cE)(D()),w=Object.fromEntries(l.flatMap(Object.entries)),K=i&&i.query?i.query.query_string:"",G=Object.entries(w).map(([Ue,He])=>He===Mt.ZW?`NOT _exists_:${Ue}`:`${Ue}:${(0,ko.YU)(String(He))}`).reduce((Ue,He)=>(0,ko.$_)(Ue,He),""),oe=(0,ko.$_)(K,G),pe=mp(l),_e=new Set([...Mt.gj,...pe]),ve=br(Lo.Z.builder(),i).query((0,yi.Eg)(oe)).newId().config(pt.ZP.builder().fields([..._e]).showMessageRow(!0).build()).build(),he=`Messages for ${G}`;return h((0,co.w6)(ve)).then(()=>h((0,sd.T)(I,ic.Z.Widget,ve.id,he)))};Cd.isEnabled=({contexts:{valuePath:l,widget:i}})=>l!==void 0&&i!==void 0;const Td=Cd;var pp=e("gofDlXL2"),gp=e("dogTzS57");const Sd=({field:l,value:i})=>h=>i===void 0?Promise.reject(new Error("Unable to add highlighting for missing value.")):h((0,pp.lp)(l,i)),Ep=({field:l,value:i},h)=>(0,gp.e)(h()).find(({field:I,value:w})=>l===I&&i===w)===void 0;Sd.isEnabled=Ep;const Ad=Sd,_i=l=>l.slice(0,-1),Ci=l=>!!(l&&l.type==="term"),Ti=l=>(l==null?void 0:l.type)==="string",Si=l=>(l==null?void 0:l.type)==="text",Pd=l=>(l==null?void 0:l.type)==="constant.numeric",Ac=l=>(l==null?void 0:l.type)==="keyword",bd=l=>(l==null?void 0:l.type)==="keyword.operator",Pc=l=>Ac(l)&&l.value===`${Rd.name}:`,sl=l=>!!(Ac(l)&&(l!=null&&l.value.endsWith(":"))),bc=l=>Si(l)&&(l==null?void 0:l.value)===" ",Dd=(l,i)=>{var h;if(!(l!=null&&l.length))return null;const D=l[i],I=(h=l[i-1])!=null?h:null;if((I==null?void 0:I.type)==="keyword"&&(I!=null&&I.value.endsWith(":"))&&D.type==="paren.lparen")return _i(I.value);let w=null,K=0,G=0;for(let oe=0;oe{const{name:D,type:I}=l;return{name:D,value:`${D}${h?"":":"}`,score:i,meta:I.type}},Rd={name:"_exists_",type:{type:"operator"}},fp=l=>i=>{const h=i.name.indexOf(l);return h<0?0:h===0?2:1},Id=({tokens:l,currentTokenIdx:i,prefix:h})=>{var D;const I=l[i],w=(D=l[i-1])!=null?D:null;if(sl(I)&&h)return!0;if(Ci(I)){if(sl(w)&&!Pc(w)||Dd(l,i))return!1;if(!w||bc(w)||Pc(w))return!0}return!1};class hp{constructor(i=[Rd]){this.getCompletions=({tokens:h,currentTokenIdx:D,prevToken:I,prefix:w,fieldTypes:K})=>{if(!Id({tokens:h,currentTokenIdx:D,prefix:w}))return[];const oe=fp(w),{all:pe,query:_e}=K,ve=Be.List(Object.values(_e)),he=Pc(I),Ue=Object.values(pe).filter(ct=>!_e[ct.name]),at=(he?[...ve.toArray()]:[...this.staticSuggestions,...ve.toArray()]).filter(ct=>oe(ct)>0).map(ct=>Od(ct,10+oe(ct),he)),Xe=Ue.filter(ct=>oe(ct)>0).map(ct=>Od(ct,1+oe(ct),he)).map(ct=>({...ct,meta:`${ct.meta} (not in streams)`}));return[...at,...Xe]},this.staticSuggestions=i}}const vp=hp;var Md=e("gToK60tD"),yp=e("QV1daZoe"),_p=e("PwTFiGSp");const Cp=50,Tp=l=>l.replace(/^"(.*(?="$))"$/,"$1"),Dc=(l,i)=>{const h=l==null?void 0:l.trim();switch(i){case"constant.numeric":return Number(h);case"string":return Tp(h);case"keyword.operator":return"";case"paren.lparen":return"";default:return h}},Sp=(l,i,h)=>{const D=h?l:(0,ko.YU)(l);return D.startsWith(String(i))?D:`${l} \u2B62 ${i}`},uf=({tokens:l,currentToken:i,prevToken:h,currentTokenIdx:D})=>{var I;const w=(I=l[D+1])!=null?I:null;if(sl(i)&&(!w||bc(w)))return{fieldName:_i(i.value),input:"",isQuoted:!1};if((Ci(i)||Ti(i)||bd(i)||Pd(i))&&sl(h))return{fieldName:_i(h.value),input:Dc(i.value,i.type),isQuoted:Ti(i)};const K=Dd(l,D);return K&&!(bc(i)&&(Ci(h)||Pd(h)))?{fieldName:K,input:Dc(i.value,i.type),isQuoted:!1}:{}},xd=l=>{var i;return(i=l==null?void 0:l.type.isEnumerable())!=null?i:!1},Ap=(l,i,h,D,I)=>({name:l,value:D?l:(0,ko.YU)(l),score:i,caption:Sp(l,h,D),meta:I?`${I}: ${i} hits`:`${i} hits`});class Pp{constructor(){this.shouldFetchCompletions=(i,h)=>{if(!i)return!1;const D=h==null?void 0:h.query[i];if(!D||!xd(D)){const I=h==null?void 0:h.all[i];return xd(I)}return!0},this.getCompletions=({tokens:i,currentToken:h,currentTokenIdx:D,prevToken:I,timeRange:w,streams:K,fieldTypes:G,userTimezone:oe})=>{const{fieldName:pe,input:_e,isQuoted:ve}=uf({tokens:i,currentToken:h,currentTokenIdx:D,prevToken:I});if(!pe)return[];if(!this.shouldFetchCompletions(pe,G))return[];if(this.alreadyFetchedAllSuggestions(_e,pe,K,w)){const Ue=this.filterExistingSuggestions(_e,ve);if(Ue.length>0)return Ue}const he=!w||(0,_p.j9)(w)?void 0:(0,yp.P3)(w,oe);return Md.Xj.suggestFieldValue({field:pe,input:_e,timerange:he,streams:K,size:Cp}).then(({suggestions:Ue,sum_other_docs_count:He})=>Ue?(this.previousSuggestions={furtherSuggestionsCount:He,streams:K,timeRange:w,fieldName:pe,input:_e,suggestions:Ue},Ue.map(({value:at,occurrence:Xe,title:ct})=>Ap(at,Xe,_e,ve,ct))):[])},this.identifierRegexps=[/[a-zA-Z_0-9$\\/\-\u00A2-\u2000\u2070-\uFFFF]/]}alreadyFetchedAllSuggestions(i,h,D,I){if(!this.previousSuggestions)return!1;const{fieldName:w,streams:K,timeRange:G,furtherSuggestionsCount:oe,input:pe}=this.previousSuggestions;return String(i).startsWith(String(pe))&&w===h&&cn()(K,D)&&cn()(G,I)&&!oe}filterExistingSuggestions(i,h){return this.previousSuggestions?this.previousSuggestions.suggestions.filter(({value:D})=>(h?D:(0,ko.YU)(D)).startsWith(String(i))).map(({value:D,occurrence:I,title:w})=>Ap(D,I,i,h,w)):[]}}const bp=Pp;var df=e("sWSSTOXR"),Oc=e.n(df);const mf=[{name:"AND",value:"AND ",score:10,meta:"operator"},{name:"OR",value:"OR ",score:10,meta:"operator"}],Ld=[{name:"NOT",value:"NOT ",score:10,meta:"operator"}],Bd=l=>i=>i.name.indexOf(l)>=0,Dp=(l,i)=>l.slice(0,i).reverse().find(h=>h.type!=="text"||Oc()(h.value)!=="");class Ai{constructor(){this.getCompletions=({currentToken:i,prevToken:h,prefix:D,tokens:I,currentTokenIdx:w})=>{if(Ac(i)||Ti(i)||!(I!=null&&I.length)||!D||bd(h)&&h.value==="NOT")return[];const K=Dp(I,w);if(!K||K&&K.type==="keyword.operator"){const G=Bd(D);return Ld.filter(G)}if(h&&(Ti(h)||Si(h))){const G=Bd(D);return[...mf,...Ld].filter(G)}return[]}}}const Op=Ai;var pf=e("13uboeDm"),Ud=e.n(pf),Pi=e("xTTaAS+O"),rl={};rl.styleTagTransform=Qs(),rl.setAttributes=Ko(),rl.insert=Nn().bind(null,"head"),rl.domAPI=Vn(),rl.insertStyleElement=Oo();var gf=un()(Pi.Z,rl);const Rp=Pi.Z&&Pi.Z.locals?Pi.Z.locals:void 0;var Ip=e("/7OuCFNo");const Rc=({view:l,missingRequirements:i})=>{var h;const D=(0,Ip.Z)();return n.createElement(De.Row,{className:"content"},n.createElement(De.Col,{md:6,mdOffset:3,className:Rp.bootstrapHeading},n.createElement("h1",null,Ud()(l.type),": ",n.createElement("em",null,l.title)),n.createElement("p",null,"Unfortunately executing this ",(h=l.type)==null?void 0:h.toLowerCase()," is not possible. It uses the following capabilities which are not available:"),n.createElement("ul",null,Object.entries(i).map(([I,w])=>n.createElement("li",{key:I},n.createElement("strong",null,I)," - included in",n.createElement("a",{href:w.url,target:"_blank",rel:"noopener noreferrer"},w.name))))),n.createElement(De.Col,{md:1,mdOffset:8},n.createElement(De.Button,{bsStyle:"success",onClick:()=>D.goBack()},"Back")))};Rc.propTypes={view:E.instanceOf(Os.Z).isRequired,missingRequirements:E.objectOf(E.shape({name:E.string,url:E.string})).isRequired};const Mp=Rc,wd=(l,i)=>Object.entries(l).filter(([h])=>!i.includes(h)).reduce((h,[D,I])=>({...h,[D]:I}),{}),Lp=async({view:l,executionState:i})=>{const h=g.G.exports("views.requires.provided"),D=wd(l.requires,h);if(Object.keys(D).length>0)throw()=>n.createElement(Mp,{view:l,missingRequirements:D});return[l,i]};var Bp=e("2eB4xxdN"),Wd=e("pzHcYe8v"),Ic=e("n6M7NB8F");const Up=u.default.div` padding-left: 20px; `,wp=()=>{const l=(0,Ic.Z)(),i=(0,Kn.Z)();if(!l||!i)return n.createElement(ni.Z,null);const h=(0,Wd.Z)(l,i);return n.createElement(Up,null,n.createElement("h1",null,l.title),n.createElement("h2",null,h))},Zd=({interval:l,tabs:i})=>{const h=(0,Ic.Z)(),D=(0,Kn.Z)(),I=(0,Do.Z)();return(0,n.useEffect)(()=>{const w=setInterval(()=>{if(!h||!D)return;const K=i||h.search.queries.toIndexedSeq().map((ve,he)=>he).toJS(),G=h.search.queries.toIndexedSeq().findIndex(ve=>ve.id===D),oe=K.indexOf(G),pe=K[(oe+1)%K.length],_e=h.search.queries.toIndexedSeq().get(pe).id;_e!==D&&I((0,Rs.xM)(_e))},l*1e3);return()=>clearInterval(w)},[l,h,D,i,I]),null};Zd.defaultProps={tabs:void 0};const Wp=Zd;var Np=e("HCsT5Gmk"),Zp=e("r4MY1c4i");const Fp=({tabs:l,interval:i,refresh:h})=>({tabs:l!==void 0?l.split(",").map(D=>Number.parseInt(D,10)):void 0,interval:i!==void 0?Math.max(Number.parseInt(i,10),1):30,refresh:h!==void 0?Math.max(Number.parseInt(h,10),1):10}),Ef=u.default.div` height: 100%; display: flex; flex-direction: column; padding: 10px; `,Kp=({location:l})=>{const{query:i}=l,h=Fp(i);return(0,n.useEffect)(()=>(On.e.setInterval(h.refresh*1e3),On.e.enable(),()=>{On.e.disable()}),[h.refresh]),n.createElement(gt.Z.Provider,{value:!1},n.createElement(Ef,null,n.createElement(Zp.default,null,n.createElement(Wp,{interval:h.interval,tabs:h.tabs}),n.createElement(wp,null))))},ff=(0,Np.Z)(Kp);var Fd=e("fBC5XqGO");const Kd={type:pr.type,displayName:"Data Table",component:pr,config:{createConfig:()=>({pinnedColumns:[]}),fromConfig:l=>{var i;return{pinnedColumns:(i=l==null?void 0:l.pinnedColumns.toJS())!=null?i:[]}},toConfig:l=>At.create(l.pinnedColumns),fields:[{name:"pinnedColumns",title:"Pinned Columns",type:"multi-select",options:({formValues:l})=>{var i,h;return(h=(i=l==null?void 0:l.groupBy)==null?void 0:i.groupings.filter(D=>(D==null?void 0:D.direction)==="row"&&(D==null?void 0:D.fields)).flatMap(D=>D.fields))!=null?h:[]},required:!1}]}},$p=(l,i)=>{const h=l.find(D=>D.name===i);if(h&&h.line&&h.line.color){const{line:{color:D}}=h;return D}},Mc=So(({config:l,data:i,effectiveTimerange:h,height:D})=>{const I=l.visualizationConfig||zs.empty(),{interpolation:w="linear"}=I,K=ls(),G=(0,n.useMemo)(()=>{var Xe,ct;return(ct=(Xe=l==null?void 0:l.rowPivots)==null?void 0:Xe.flatMap(Nt=>Nt.fields))!=null?ct:[]},[l==null?void 0:l.rowPivots]),oe=(0,n.useCallback)(Xe=>Xe.map(ct=>ct.split(Mt.qN).map((Nt,kt)=>K(Nt,G[kt])).join(Mt.v8)),[K,G]),pe=(0,n.useCallback)(({type:Xe,name:ct,labels:Nt,values:kt,originalName:Ft})=>({type:Xe,name:ct,x:oe(Nt),y:kt,fill:"tozeroy",line:{shape:Ge(w)},originalName:Ft}),[oe,w]),_e=(0,n.useMemo)(()=>vs(i),[i]),ve=Ds(_e,{widgetConfig:l,chartType:"scatter",generator:pe}),{eventChartData:he,shapes:Ue}=Er(l,i.events),He=he?[...ve,he]:ve,at=Ue?{shapes:Ue}:{};return n.createElement(vr,{config:l,axisType:I.axisType,plotLayout:at,effectiveTimerange:h,getChartColor:$p,height:D,chartData:He})},"area");Mc.propTypes={config:er.isRequired,data:rs.isRequired,height:a().number};const xc=Mc,$d=(l,i)=>{var h;return((h=l.metrics)==null?void 0:h.length)>=i},Gp=(l,i)=>{var h,D;return((D=(h=l.groupBy)==null?void 0:h.groupings)==null?void 0:D.length)>=i},al=l=>i=>$d(i,1)?{}:{type:`${l} requires at least one metric`},jp=al("Area chart"),Gd={type:xc.type,displayName:"Area Chart",component:xc,config:{createConfig:()=>({interpolation:Mt.bj,axisType:oo}),fromConfig:l=>({interpolation:l==null?void 0:l.interpolation,axisType:l==null?void 0:l.axisType}),toConfig:l=>zs.create(l.interpolation,l.axisType),fields:[{name:"interpolation",title:"Interpolation",type:"select",options:Mt.fH,required:!0},{name:"axisType",title:"Axis Type",type:"select",options:tr,required:!0}]},capabilities:["event-annotations"],validate:jp},zp=al("Bar chart"),Hp={type:k.type,displayName:"Bar Chart",component:k,config:{createConfig:()=>({barmode:as,axisType:oo}),fromConfig:l=>{var i,h;return{barmode:(i=l==null?void 0:l.barmode)!=null?i:as,axisType:(h=l==null?void 0:l.axisType)!=null?h:oo}},toConfig:l=>Wo.create(l.barmode,l.axisType),fields:[{name:"barmode",title:"Mode",type:"select",options:[["Group","group"],["Stack","stack"],["Relative","relative"],["Overlay","overlay"]],required:!0,helpComponent:()=>{const l={group:{label:"Group",help:"Every series is represented by its own bar in the chart."},stack:{label:"Stack",help:"All series are stacked upon each other resulting in one bar."},relative:{label:"Relative",help:"All series are stacked upon each other resulting in one chart. But negative series are placed below zero."},overlay:{label:"Overlay",help:"All series are placed as bars upon each other. To be able to see the bars the opacity is reduced to 75%. It is recommended to use this option with not more than 3 series."}};return n.createElement("ul",null,Object.values(l).map(({label:i,help:h})=>n.createElement("li",{key:i},n.createElement("h4",null,i),h)))}},{name:"axisType",title:"Axis Type",type:"select",options:tr,required:!0}]},capabilities:["event-annotations"],validate:zp},kp=l=>{const i=[];if(!Gp(l,2))i.push("Heatmap requires at least two groupings.");else{const h=l.groupBy.groupings.map(D=>D.direction);(!h.includes("row")||!h.includes("column"))&&i.push("Groupings must include row and column groupings.")}return $d(l,1)||i.push("At least one metric must be configured."),i.length>0?{type:i.join(" ")}:{}},Qp={type:Ta.type,displayName:"Heatmap",component:Ta,config:{fromConfig:({autoScale:l,colorScale:i,reverseScale:h,defaultValue:D,useSmallestAsDefault:I,zMax:w,zMin:K}=Ca.ZP.empty())=>({autoScale:l,colorScale:i,reverseScale:h,defaultValue:D,useSmallestAsDefault:I,zMax:w,zMin:K}),toConfig:({autoScale:l=!1,colorScale:i,reverseScale:h=!1,useSmallestAsDefault:D,zMax:I,zMin:w,defaultValue:K})=>{const[G,oe]=l?[void 0,void 0]:[w,I];return Ca.ZP.create(i,h,l,G,oe,D,K)},createConfig:()=>({colorScale:"Viridis",autoScale:!0}),fields:[{name:"colorScale",title:"Color Scale",required:!0,type:"select",options:[...Ca.Xm].sort(We.S)},{name:"reverseScale",type:"boolean",title:"Reverse Scale"},{name:"autoScale",type:"boolean",title:"Auto Scale"},{name:"zMin",type:"numeric",title:"Min",required:!0,isShown:l=>!(l!=null&&l.autoScale)},{name:"zMax",type:"numeric",title:"Max",required:!0,isShown:l=>!(l!=null&&l.autoScale)},{name:"useSmallestAsDefault",type:"boolean",title:"Use smallest as default"},{name:"defaultValue",type:"numeric",title:"Default Value",isShown:l=>!(l!=null&&l.useSmallestAsDefault),required:!1}]},validate:kp},Xp=al("Line chart"),Jp={type:Un.type,displayName:"Line Chart",component:Un,config:{createConfig:()=>({interpolation:Mt.bj,axisType:oo}),fromConfig:l=>{var i,h;return{interpolation:(i=l==null?void 0:l.interpolation)!=null?i:Mt.bj,axisType:(h=l==null?void 0:l.axisType)!=null?h:oo}},toConfig:l=>$.create(l.interpolation,l.axisType),fields:[{name:"interpolation",title:"Interpolation",type:"select",options:Mt.fH,required:!0},{name:"axisType",title:"Axis Type",type:"select",options:tr,required:!0}]},capabilities:["event-annotations"],validate:Xp},Yp={type:_a.type,displayName:"Single Number",component:_a,config:{fromConfig:l=>({trend:l==null?void 0:l.trend,trend_preference:l==null?void 0:l.trendPreference}),toConfig:({trend:l=!1,trend_preference:i})=>Tn.create(l,i),fields:[{name:"trend",title:"Trend",type:"boolean",description:"Show trend information for this number.",helpComponent:()=>n.createElement(n.Fragment,null,n.createElement("p",null,"If the user enables trending, a separate box is shown below the current value, indicating the direction of the change by an icon as well as the absolute and the relative differences between the current value and the previous one."),n.createElement("p",null,"The previous value is calculated by performing two searches in the background, which are completely identical besides the timerange. The timerange of the first search is identical to the one configured for this query/this widget, the second one is the same timerange, but with an offset of the timerange length shifted to the past."))},{name:"trend_preference",title:"Trend Preference",type:"select",options:[["Lower","LOWER"],["Neutral","NEUTRAL"],["Higher","HIGHER"]],required:!0,isShown:l=>(l==null?void 0:l.trend)===!0}]}},Lc=4,qp=(l,i)=>{const h=Math.ceil(i/Lc),D=Math.floor(l/Lc),I=1/h,w=I*.1;return[I*D+w,I*(D+1)-w]},eg=(l,i)=>{const h=l%Lc,D=1/Math.min(i,Lc),I=D*.1;return[D*h+I,D*(h+1)-I]},tg=l=>({type:i,name:h,labels:D,values:I,idx:w,total:K,originalName:G,config:oe})=>{var pe,_e;const ve=(_e=(pe=oe==null?void 0:oe.rowPivots)==null?void 0:pe.flatMap(he=>he.fields))!=null?_e:[];return{type:i,name:h,hole:.4,labels:D.map(he=>he.split(Mt.qN).map((Ue,He)=>l(Ue,ve[He])).join(Mt.v8)),originalLabels:D,values:I,domain:{x:eg(w,K),y:qp(w,K)},originalName:G}},ng=(l,i)=>{var h;const D=l.find(I=>I.labels.indexOf(i)>=0);if(D!=null&&D.labels&&((h=D==null?void 0:D.marker)!=null&&h.colors)){const I=D.labels.indexOf(i),{marker:{colors:w}}=D;return w[I]}},_f=(l,i)=>({marker:{colors:l.originalLabels.map(D=>i.get(D))}}),og=l=>[...new Set(l.flatMap(({labels:i,originalLabels:h})=>h!=null?h:i))],Cf=l=>{var i;return(i=l==null?void 0:l.rowPivots)==null?void 0:i.flatMap(h=>h.fields)},ll=So(({config:l,data:i})=>{const h=(0,n.useMemo)(()=>vs(i),[i]),D=ls(),I=Ds(h,{widgetConfig:l,chartType:"pie",generator:tg(D)});return n.createElement(qo,{config:l,chartData:I,labelMapper:og,labelFields:Cf,neverHide:!0},n.createElement(Ga.Z,{chartData:I,layout:{showlegend:!1},getChartColor:ng,setChartColor:_f}))},"pie");ll.propTypes={config:er.isRequired,data:rs.isRequired},ll.displayName="PieVisualization";const jd=ll,sg=al("Pie chart"),rg={type:jd.type,displayName:"Pie Chart",component:jd,validate:sg};class oa extends Et.Z{constructor(i=oo){super(),this._value={axisType:i}}get axisType(){return this._value.axisType}toBuilder(){return new Bc(Be.Map(this._value))}static create(i){return new oa(i)}static empty(){return new oa(oo)}toJSON(){const{axisType:i}=this._value;return{axis_type:i}}static fromJSON(i,h){var D;return oa.create((D=h==null?void 0:h.axis_type)!=null?D:oo)}}class Bc{constructor(i=Be.Map()){this.value=i}axisType(i){return new Bc(this.value.set("axisType",i))}build(){const{interpolation:i,axisType:h}=this.value.toObject();return new $(i,h)}}const Sf=l=>({type:i,name:h,labels:D,values:I,originalName:w})=>({type:i,name:h,x:l(D),y:I,mode:"markers",originalName:w}),zd=So(({config:l,data:i,effectiveTimerange:h,height:D})=>{var I;const w=(I=l.visualizationConfig)!=null?I:oa.empty(),K=ls(),G=(0,n.useMemo)(()=>{var at,Xe;return(Xe=(at=l==null?void 0:l.rowPivots)==null?void 0:at.flatMap(ct=>ct.fields))!=null?Xe:[]},[l==null?void 0:l.rowPivots]),oe=(0,n.useCallback)(at=>at.map(Xe=>Xe.split(Mt.qN).map((ct,Nt)=>K(ct,G[Nt])).join(Mt.v8)),[K,G]),pe=(0,n.useMemo)(()=>vs(i),[i]),_e=Ds(pe,{widgetConfig:l,chartType:"scatter",generator:Sf(oe)}),{eventChartData:ve,shapes:he}=Er(l,i.events),Ue=ve?[..._e,ve]:_e,He=he?{shapes:he}:{};return n.createElement(vr,{config:l,axisType:w.axisType,chartData:Ue,plotLayout:He,height:D,effectiveTimerange:h})},"scatter");zd.propTypes={config:er.isRequired,data:rs.isRequired,height:a().number};const Vd=zd,Hd=al("Scatter plot"),ag={type:Vd.type,displayName:"Scatter Plot",component:Vd,config:{createConfig:()=>({axisType:oo}),fromConfig:l=>{var i;return{axisType:(i=l==null?void 0:l.axisType)!=null?i:oo}},toConfig:l=>oa.create(l.axisType),fields:[{name:"axisType",title:"Axis Type",type:"select",options:tr,required:!0}]},capabilities:["event-annotations"],validate:Hd},kd={zoom:1,centerX:0,centerY:0},lg={type:ql.type,displayName:"World Map",component:ql,config:{createConfig:()=>kd,fromConfig:l=>l?{zoom:l.viewport.zoom,centerX:l.viewport.center[0],centerY:l.viewport.center[1]}:kd,toConfig:l=>xr.create(Ir.create([l.centerX,l.centerY],l.zoom)),fields:[{name:"zoom",title:"Zoom",type:"numeric",required:!0},{name:"centerX",title:"Latitude",type:"numeric",required:!0,step:"any"},{name:"centerY",title:"Longitude",type:"numeric",required:!0,step:"any"}]}},Qd=[Gd,Hp,Kd,Qp,Jp,Yp,rg,ag,lg];var ig=e("QBkrNAIi");function Xd(l,i){return l.filter(h=>!i.includes(h.type))}function bf(l,i){return o.Z.isCloud()?Xd(l,i):l}const Df=null;var Uc=e("VVS+7KXv");const wc=({value:l})=>(0,Uc.Z)(l),Rf=({field:l})=>(0,Uc.Z)(l);var Wc=e("ty2gyrHp"),Jd=e("B6TE4HBJ"),Yd=e("tt0llszK"),ug=e("uEPrrliZ"),If=e("YwMFjcSm"),Mf=e("z6QEDyg6"),qd=e("Gkq4qIYY"),dg=e("Q1zRxDOP");const Nc={[Os.Z.Type.Dashboard]:({id:l,title:i})=>[{link:Pe.ZP.DASHBOARDS,label:"Dashboards"},{label:i||l,dataTestId:"view-title"}],[Os.Z.Type.Search]:({id:l,title:i})=>[{link:Pe.ZP.SEARCH,label:"Search"},{label:i||l,dataTestId:"view-title"}],alert:({id:l})=>[{link:Pe.ZP.ALERTS.LIST,label:"Alerts & Events"},{label:l,dataTestId:"alert-id-title"}],eventDefinition:({id:l,title:i})=>[{link:Pe.ZP.ALERTS.DEFINITIONS.LIST,label:"Event definitions"},{link:Pe.ZP.ALERTS.DEFINITIONS.show(l),label:i||l,dataTestId:"event-definition-title"}]},em=u.default.div(({theme:l})=>(0,u.css)` display: flex; flex-wrap: nowrap; align-items: center; margin-bottom: ${l.spacings.xs}; gap: 4px; `),Aa=u.default.div(({theme:l})=>(0,u.css)` color: ${l.colors.gray[60]}; font-size: ${l.fonts.size.tiny}; cursor: pointer; `),Zc=u.default.span` display: flex; gap: 4px; align-items: center; & ${Aa} { display: none; } &:hover ${Aa} { display: block; } `,tm=(0,u.default)(rt.JO)` font-size: 0.5rem; `,nm=({label:l,link:i,dataTestId:h})=>i?n.createElement(Wc.r,{target:"_blank",to:i,"data-testid":h},l):n.createElement("span",{"data-testid":h},l);nm.defaultProps={dataTestId:void 0};const Fc=()=>{var l;const i=(0,Ic.Z)(),h=(0,qd.Z)(),D=(i==null?void 0:i.id)&&(i==null?void 0:i.title)&&!h,[I,w]=(0,n.useState)(!1),K=(0,n.useCallback)(()=>w(kt=>!kt),[w]),{alertId:G,definitionId:oe,definitionTitle:pe,isAlert:_e,isEventDefinition:ve,isEvent:he}=(0,Mf.Z)(),Ue=(0,Do.Z)(),He=(0,n.useCallback)(async kt=>{await Ue((0,Yd.Z)(kt)),await Ue((0,Rs.NK)(kt))},[Ue]),at=(l=i==null?void 0:i.type)==null?void 0:l.toLocaleLowerCase(),Xe=(0,ug.Z)(),ct=(0,n.useCallback)(kt=>Ue((0,Rs.NK)(i.toBuilder().favorite(kt).build())),[Ue,i]),Nt=(0,n.useMemo)(()=>_e||he?Nc.alert({id:G}):ve?Nc.eventDefinition({id:oe,title:pe}):Nc[i.type]({id:i.id,title:Xe}),[G,oe,pe,_e,he,ve,i,Xe]);return n.createElement(De.Row,null,n.createElement(em,null,Nt.map(({label:kt,link:Ft,dataTestId:an},$n)=>{const _n=$n===Nt.length-1;return n.createElement(Zc,{key:`${kt}_${Ft}`},n.createElement(nm,{link:Ft,label:kt,dataTestId:an}),!_n&&n.createElement(tm,{name:"chevron-right"}),D&&_n&&n.createElement(n.Fragment,null,n.createElement(If.Z,{isFavorite:i.favorite,grn:(0,dg.L)(i.type,i.id),onChange:ct}),n.createElement(Aa,{onClick:K,role:"button",title:`Edit ${at} ${i.title} metadata`,tabIndex:0},n.createElement(rt.JO,{name:"pen-to-square"}))))}),I&&n.createElement(Jd.Z,{show:!0,view:i,title:`Editing saved ${at}`,onClose:K,onSave:He,submitButtonText:`Save ${at}`})))};var Kc=e("iyGdd7jp"),om=e("PLPb65Bv");const sm=[{key:"view",reducer:Rs.gY},{key:"searchExecution",reducer:Vo.J8},{key:"searchMetadata",reducer:Kc.T},{key:"undoRedo",reducer:om.oh}];var rm=e("7FTHePOw"),Lr=e.n(rm),mg=e("LF8A/8I5"),bi=e.n(mg),pg=e("RjO1iR6D"),am=e.n(pg);const _r={Checked:"Checked",Empty:"Empty",Indeterminate:"Indeterminate"},lm=({groupLabel:l,checked:i,onChange:h,labels:D})=>{const I=(0,n.useMemo)(()=>Object.values(i).every(G=>G)?_r.Checked:Object.values(i).some(G=>G)?_r.Indeterminate:_r.Empty,[i]),w=(0,n.useCallback)(()=>{switch(I){case _r.Checked:return h(Lr()(i,()=>!1));case _r.Empty:return h(Lr()(i,()=>!0));case _r.Indeterminate:return h(Lr()(i,()=>!0));default:return h(Lr()(i,()=>!1))}},[i,h,I]),K=(0,n.useCallback)((G,oe)=>{h({...i,[G]:!i[G]})},[i,h]);return n.createElement(rt.oL,{header:l,expanded:!0,padded:!1,checked:I===_r.Checked,indetermined:I===_r.Indeterminate,onChange:w},n.createElement(rt.BR,null,Object.entries(i).map(([G,oe])=>n.createElement(rt.oL,{expandable:!1,header:D[G],padded:!1,key:G,checked:oe,onChange:pe=>K(G,pe)}))))},gg={rowValuePath:"Query from table row",columnValuePath:"Query from table column",columnGroupBy:"Group by column values",rowGroupBy:"Group by row values",aggCondition:"Condition",queryWithReplacedParams:"Query from search",searchFilterQuery:"Query from search filters",streams:"Streams",searchWithinMs:"Search within ms",lutParameters:"Lookup-table parameters",searchFromValue:"Query from value"},$c=["columnGroupBy","rowGroupBy","aggCondition"],Di=["rowValuePath","columnValuePath","queryWithReplacedParams","searchFilterQuery","searchFromValue"],Oi={EXACT:{label:"Exactly this value",description:"Strategy includes all search queries, filters, etc which relate to current search view"},ROW:{label:"Any in row",description:"Strategy includes row pivots"},COL:{label:"Any in column",description:"Strategy includes column pivots"},ALL:{label:"Any in widget",description:"Strategy includes all row and column pivot values, related to selected value"},CUSTOM:{label:"Custom",description:"You can select any search part"}},Eg=u.default.div` display: flex; gap: 5px; align-items: baseline; `,im=({strategy:l,onChange:i,strategyAvailabilities:h})=>{const{description:D}=Oi[l];return n.createElement(n.Fragment,null,n.createElement("b",null,"Strategy by:"),n.createElement(Eg,null,Object.entries(Oi).map(([I,{label:w}])=>h[I]?n.createElement(De.Radio,{id:I,key:I,name:"strategy",value:I,checked:I===l,onChange:i},w):null)),n.createElement("p",null,n.createElement("b",null,"Description: "),n.createElement("i",null,D)))},fg=l=>(0,ko._5)(l.filter(i=>!!i)),hg=({mappedData:l,checked:i})=>(0,n.useMemo)(()=>{const{queryWithReplacedParams:h,searchFilterQuery:D,searchFromValue:I,columnValuePath:w,rowValuePath:K,lutParameters:G,searchWithinMs:oe,streams:pe,aggValue:_e,aggFunction:ve,aggField:he,columnGroupBy:Ue,rowGroupBy:He}=l,at=Object.entries({queryWithReplacedParams:h,searchFilterQuery:D,searchFromValue:I,columnValuePath:w,rowValuePath:K}).filter(([Nt])=>i[Nt]).map(([Nt,kt])=>kt),Xe=()=>{const Nt={};return i.aggCondition&&(Nt.agg_field=he,Nt.agg_value=_e,Nt.agg_function=ve),i.columnGroupBy&&(Nt.group_by=Ue),i.rowGroupBy&&(Nt.group_by=(He||[]).concat(Nt.group_by||[])),Nt},ct=()=>{const Nt={};return i.lutParameters&&G&&G.length&&(Nt.loc_query_parameters=G),i.searchWithinMs&&oe&&(Nt.search_within_ms=oe),i.streams&&pe&&pe.length&&(Nt.streams=pe),Nt};return{type:"aggregation-v1",query:fg(at),...Xe(),...ct()}},[i,l]);var cm=e("sFVNMWbF"),vg=e.n(cm);const yg={strategy:"EXACT",checked:{},showDetails:!1},jc=(l,i)=>{const h={...l};return Object.entries(i).forEach(([D,I])=>{vg()(l,D)&&(h[D]=I)}),h},_g=(l,i)=>{const{type:h,payload:D,possibleKeys:I}=i;switch(h){case"SET_ALL_STRATEGY":return{strategy:"ALL",showDetails:l.showDetails,checked:jc(I,{searchFilterQuery:!1,queryWithReplacedParams:!1})};case"SET_EXACT_STRATEGY":return{strategy:"EXACT",showDetails:l.showDetails,checked:I};case"SET_ROW_STRATEGY":return{strategy:"ROW",showDetails:l.showDetails,checked:jc(I,{columnValuePath:!1,columnGroupBy:!1})};case"SET_COL_STRATEGY":return{strategy:"COL",showDetails:l.showDetails,checked:jc(I,{rowValuePath:!1,rowGroupBy:!1})};case"SET_CUSTOM_STRATEGY":return{strategy:"CUSTOM",showDetails:!0,checked:l.checked};case"UPDATE_CHECKED_ITEMS":return{strategy:"CUSTOM",showDetails:l.showDetails,checked:jc(l.checked,D)};case"TOGGLE_SHOW_DETAILS":return{strategy:l.strategy,showDetails:!l.showDetails,checked:l.checked};default:return l}},Cg=l=>{const[i,h]=(0,n.useReducer)(_g,yg),D=(0,n.useCallback)(({type:I,payload:w})=>{const K=Lr()(l,G=>!!G);h({type:I,payload:w,possibleKeys:K})},[l]);return(0,n.useEffect)(()=>{D({type:"SET_EXACT_STRATEGY"})},[D]),(0,n.useMemo)(()=>[i,D],[i,D])},um=u.default.div` margin-top: 10px; `,zc=({itemKey:l,value:i})=>n.createElement("span",null,n.createElement("i",null,`${gg[l]}: `),n.createElement("b",null,i)),Tg=({modalData:l,mappedData:i,show:h,onClose:D})=>{var I,w;const[{strategy:K,checked:G,showDetails:oe},pe]=Cg(l),_e=hg({mappedData:i,checked:G}),ve=(0,n.useMemo)(()=>`cedfv-${(0,ri.Z)()}`,[]),he=`${Pe.ZP.ALERTS.DEFINITIONS.CREATE}?step=condition&session-id=${ve}`,Ue=(0,n.useCallback)(ln=>{pe({type:"UPDATE_CHECKED_ITEMS",payload:ln})},[pe]),He=(0,n.useCallback)(ln=>{pe({type:`SET_${ln.target.value}_STRATEGY`})},[pe]),at=(0,n.useCallback)(()=>{pe({type:"TOGGLE_SHOW_DETAILS"})},[pe]),Xe=(0,n.useMemo)(()=>bi()(G,$c),[G]),ct=(0,n.useMemo)(()=>bi()(G,Di),[G]),Nt=(0,n.useMemo)(()=>am()(G,[...Di,...$c]),[G]),kt=(0,n.useMemo)(()=>Lr()(bi()(l,$c),(ln,Qn)=>n.createElement(zc,{itemKey:Qn,value:ln})),[l]),Ft=(0,n.useMemo)(()=>Lr()(bi()(l,Di),(ln,Qn)=>n.createElement(zc,{itemKey:Qn,value:ln})),[l]),an=(0,n.useMemo)(()=>Lr()(am()(l,[...$c,...Di]),(ln,Qn)=>n.createElement(zc,{itemKey:Qn,value:ln})),[l]),$n=(0,n.useMemo)(()=>{var ln,Qn;return{ALL:!0,ROW:!!((ln=i==null?void 0:i.rowValuePath)!=null&&ln.length),COL:!!((Qn=i==null?void 0:i.columnValuePath)!=null&&Qn.length),CUSTOM:!0,EXACT:!0}},[(I=i==null?void 0:i.columnValuePath)==null?void 0:I.length,(w=i==null?void 0:i.rowValuePath)==null?void 0:w.length]),_n=(0,n.useCallback)(()=>{Yr.Z.set(ve,_e),D()},[ve,_e,D]);return n.createElement(De.Modal,{onHide:D,show:h},n.createElement(De.Modal.Header,{closeButton:!0},n.createElement(De.Modal.Title,null,"Configure new event definition")),n.createElement(De.Modal.Body,null,n.createElement(im,{strategyAvailabilities:$n,strategy:K,onChange:He}),n.createElement(De.Button,{bsStyle:"link",className:"btn-text",bsSize:"xsmall",onClick:at},n.createElement(rt.JO,{name:`caret-${oe?"down":"right"}`}),"\xA0",oe?"Hide strategy details":"Show strategy details"),oe&&n.createElement(um,null,n.createElement(rt.BR,null,!Rr()(Xe)&&n.createElement(lm,{onChange:Ue,groupLabel:"Aggregation",checked:Xe,labels:kt}),!Rr()(ct)&&n.createElement(lm,{onChange:Ue,groupLabel:"Search query",checked:ct,labels:Ft}),Object.entries(Nt).map(([ln,Qn])=>n.createElement(rt.oL,{key:ln,checked:Qn,onChange:()=>Ue({[ln]:!Qn}),header:an[ln],padded:!1,expandable:!1}))))),n.createElement(De.Modal.Footer,null,n.createElement(rt.Qj,{bsStyle:"primary",onClick:_n,to:he,target:"_blank"},"Continue configuration")))};var Sg=e("pp5t3b0P"),Ag=e.n(Sg),Pg=e("8u9vblRK"),wf=e.n(Pg),bg=e("P5NcJT2c"),Dg=e.n(bg),Og=e("uzwJl55m");const Rg=l=>l?l.get("filters").filter(i=>i.get("type")==="stream").map(i=>i.get("id")).toArray():[],Vc=l=>(0,ko._5)(l.filter(i=>Object.keys(i)[0]!=="_exists_").map(i=>{const[h,D]=Object.entries(i)[0];return`${h}:${(0,ko.YU)(D)}`}),{withBrackets:!1}),Hc=l=>new Set(l.flatMap(({fields:i})=>i)),kc=({flattenPivots:l,valuePath:i})=>{if(!i)return[];const h=i.reduce((D,I)=>{const w=Object.keys(I)[0];return!D.has(w)&&l.has(w)&&D.set(w,I),D},new Map([]));return Array.from(h.values())},Ig=({widget:l,value:i,field:h,valuePath:D})=>{const I=l.config.series.find(at=>at.function===h),{field:w,function:K}=(0,Og.u)([I])[0],{rowPivots:G,columnPivots:oe}=l.config,pe=Hc(G),_e=Hc(oe),ve=kc({flattenPivots:pe,valuePath:D}),he=kc({flattenPivots:_e,valuePath:D}),Ue=Vc(ve),He=Vc(he);return{aggField:w,aggFunction:K,aggValue:i,rowGroupBy:Array.from(pe),columnGroupBy:Array.from(_e),rowValuePath:Ue,columnValuePath:He}},Mg=({widget:l,value:i,field:h,valuePath:D})=>{const{rowPivots:I}=l.config,w=Hc(I),K=kc({flattenPivots:w,valuePath:D}),G=Vc(K);return{searchFromValue:`${h}:${(0,ko.YU)(i)}`,rowValuePath:G}},xg=({value:l,field:i})=>({searchFromValue:`${i}:${(0,ko.YU)(l)}`}),Lg=({value:l,field:i})=>({searchFromValue:`${i}:${(0,ko.YU)(l)}`}),Wf=({widget:l,field:i})=>{if(l.type==="AGGREGATION")return!!l.config.series.find(D=>D.function===i)?Ig:Mg;if(l.type==="logs")return Lg;if(l.type==="messages")return xg;throw new Error("This widget type has incorrect type or no handler")},Bg=l=>l.reduce((i,h)=>{if(h.type==="lut-parameter-v1"){const D=h.toJSON();i.push(D)}return i},[]),Ug=({parameters:l,parameterBindings:i})=>l.reduce((h,D)=>{var I;if(D.type!=="lut-parameter-v1"){const w=D.toJSON(),{name:K}=w,G=(I=i==null?void 0:i.get(K))==null?void 0:I.value;h[K]=G!=null?G:w==null?void 0:w.default_value}return h},{}),Nf=(l=lt().List([]))=>(0,ko._5)(l.filter(i=>i.queryString&&!i.disabled).map(i=>`${i.negation?"NOT":""}(${i.queryString})`).toArray(),{withBrackets:!1}),wg=({query:l,restParameterValues:i})=>{let h=l;return Object.entries(i).forEach(([D,I])=>{h=h.replace(`$${D}$`,`${I}`)}),h},Wg=({contexts:l,field:i,queryId:h,value:D})=>(0,n.useMemo)(()=>{const I=Wf({widget:l.widget,field:i}),w=l.view.search.queries.find(Xe=>Xe.id===h),{parameters:K,parameterBindings:G}=l,oe=w.timerange.type==="relative"?w.timerange.from*1e3:void 0,pe=Bg(K),_e=Ug({parameters:K,parameterBindings:G}),ve=Nf(w.filters),he=wg({query:w.query.query_string,restParameterValues:_e}),Ue=Rg(w.filter),{...He}=I({valuePath:l.valuePath,widget:l.widget,value:D,field:i}),at={searchWithinMs:oe,lutParameters:pe,searchFilterQuery:ve,queryWithReplacedParams:he,streams:Ue,...He};return Ag()(at,Xe=>wf()(Xe)?!!Xe.length:Dg()(Xe)?!0:!!(Xe!=null&&Xe.trim()))},[l,i,h,D]);var Ng=e("Cd4wX32x");const dm=l=>{const i=(0,Z.o)(Ng.h,({streams:h})=>h.reduce((D,I)=>(D[I.id]={id:I.id,title:I.title},D),{}));return(0,n.useMemo)(()=>{const{aggField:h="",aggFunction:D="",aggValue:I="",columnGroupBy:w,rowGroupBy:K,streams:G,lutParameters:oe,...pe}=l,_e={...pe};return D&&(_e.aggCondition=`${D}(${h}): ${I}`),G!=null&&G.length&&(_e.streams=G.map(ve=>i[ve].title).join(", ")),Object.entries({columnGroupBy:w,rowGroupBy:K}).forEach(([ve,he])=>{he&&(_e[ve]=he.join(", "))}),oe&&(_e.lutParameters=oe.map(ve=>ve.name).join(", ")),_e},[l,i])},Zg=({value:l,field:i,queryId:h,onClose:D})=>{const I=(0,n.useContext)(en.f),w=Wg({contexts:I,field:i,queryId:h,value:l}),K=dm(w),[G,oe]=(0,n.useState)(!0),pe=(0,n.useCallback)(()=>{oe(!1),D()},[D]);return G?n.createElement(Tg,{modalData:K,mappedData:w,onClose:pe,show:G}):null};var Kf=e("Wh5iba66"),il=e("DUKaTDO2");const mm={fieldTypes:{}},$f=async()=>({fieldTypes:await Md.T8.getAllFieldTypes()}),Fg=()=>{const{data:l,isLoading:i}=(0,il.useQuery)(["fieldTypeOptions"],$f,{onError:h=>{Re.Z.error(`Loading field type options failed with status: ${h}`,"Could not load field type options")},keepPreviousData:!0});return{data:l!=null?l:mm,isLoading:i}},pm="field-type",Ii={pageSize:20,sort:{attributeId:"index_set_title",direction:"asc"},displayedColumns:["index_set_title","stream_titles","types"],columnsOrder:["index_set_title","stream_titles","types"]};var Kg=e("Dg3D5NJi");const $g={pagination:{total:0},list:[],attributes:[]},Gg=async({field:l,streams:i},h)=>{const{sort:{attributeId:D,direction:I},page:w,pageSize:K}=h,G={field:l,streams:i.length?i:void 0};return Md.bn.fieldTypeSummaries(G,D,w,K,I).then(({elements:oe,total:pe,attributes:_e})=>({list:oe.map(({stream_titles:ve,index_set_title:he,index_set_id:Ue,types:He})=>({streamTitles:ve,types:He,id:Ue,indexSetTitle:he})),pagination:{total:pe},attributes:_e}))},jg=({streams:l,field:i},h,{enabled:D}={enabled:!0})=>{const{data:I,refetch:w,isInitialLoading:K,isLoading:G}=(0,il.useQuery)(["fieldTypeUsages",i,h],()=>Gg({streams:l,field:i},h),{onError:oe=>{Re.Z.error(`Loading ${i} types failed with status: ${oe}`,"Could not load field types")},keepPreviousData:!0,enabled:D});return{data:I!=null?I:$g,refetch:w,isInitialLoading:K,isLoading:G}};var zg=e("qO9czYNI"),Vg=e("pwvwNHw/"),Hg=e.n(Vg);const kg=u.default.i(({theme:l})=>(0,u.css)` font-size: ${l.fonts.size.small}; display: block; margin-top: 5px; `),Pa=l=>(0,n.useMemo)(()=>({attributes:{stream_titles:{renderCell:h=>h.join(", ")},types:{renderCell:h=>{const D=l[cr()(h)]||cr()(h),I=Hg()(h,h.length-1).map(w=>l[w]||w);return D?n.createElement("div",null,n.createElement("span",null,n.createElement("b",null,D)),!!I.length&&n.createElement(kg,null,"(previous values:"," ",I.join(", "),")")):n.createElement("i",null,"type is not defined")}}}}),[l]);var zf=e("Z2BtcgLJ"),Jc=e("m7J9z16Z");const gm=()=>{var l;const{widget:i,message:h}=(0,n.useContext)(en.f),D=(0,Jc.Z)();return(0,n.useMemo)(()=>{var I,w,K,G;return(G=(K=(w=(I=h==null?void 0:h.fields)==null?void 0:I.streams)!=null?w:i==null?void 0:i.streams)!=null?K:(0,yi.Fp)(D.filter).toJS())!=null?G:[]},[(l=h==null?void 0:h.fields)==null?void 0:l.streams,D.filter,i==null?void 0:i.streams])},Hf=u.default.div` margin-top: 20px; `,Qg=(l,i)=>n.createElement(zf.Z,{selectedEntities:l,setSelectedEntities:i}),Xg=({field:l,setIndexSetSelection:i,fieldTypes:h,initialSelection:D})=>{const[I,w]=(0,n.useState)(!1),[K,G]=(0,n.useState)(1),{layoutConfig:oe,isInitialLoading:pe}=(0,Kg.Z)({entityTableId:pm,defaultPageSize:Ii.pageSize,defaultDisplayedAttributes:Ii.displayedColumns,defaultSort:Ii.sort}),_e=(0,n.useMemo)(()=>({page:K,pageSize:oe.pageSize,sort:oe.sort}),[K,oe.pageSize,oe.sort]),ve=gm(),{data:{list:he,attributes:Ue,pagination:He},isLoading:at}=jg({field:l,streams:ve},_e,{enabled:!pe&&!!ve}),{mutate:Xe}=(0,zg.Z)(pm);(0,n.useEffect)(()=>{i(D)},[D,i]);const ct=(0,n.useCallback)((ln,Qn)=>{ln&&G(ln),Qn&&Xe({perPage:Qn})},[Xe]),Nt=(0,n.useCallback)(ln=>{G(1),Xe({perPage:ln})},[Xe]),kt=(0,n.useCallback)(ln=>{G(1),Xe({sort:ln})},[Xe]),Ft=(0,n.useCallback)(ln=>{Xe({displayedAttributes:ln})},[Xe]),an=Pa(h),$n=(0,n.useCallback)(ln=>{i(ln)},[i]),_n=(0,n.useCallback)(()=>{w(ln=>!ln)},[]);return pe||at?n.createElement(rt.$j,null):n.createElement(n.Fragment,null,n.createElement(De.Button,{label:I?"Hide index sets":"Show index sets",bsStyle:"link",className:"btn-text",bsSize:"xsmall",onClick:_n},n.createElement(rt.JO,{name:`caret-${I?"down":"right"}`}),"\xA0",I?"Hide index sets":"Show index sets"),I&&n.createElement(Hf,null,n.createElement(rt.l9,{onChange:ct,totalItems:He==null?void 0:He.total,pageSize:oe.pageSize,activePage:K,showPageSizeSelect:!1,useQueryParameter:!1},!(he!=null&&he.length)&&n.createElement(rt.dX,null,"No index sets have been found."),he.length&&n.createElement(rt.$E,{activeSort:oe.sort,bulkSelection:{onChangeSelection:$n,initialSelection:D,actions:Qg},columnDefinitions:Ue,columnRenderers:an,columnsOrder:Ii.columnsOrder,data:he,onColumnsChange:Ft,onPageSizeChange:Nt,onSortChange:kt,pageSize:oe.pageSize,visibleColumns:oe.displayedAttributes}))))},Em="/system/indices/mappings",Qf=async({indexSetSelection:l,newFieldType:i,rotated:h,field:D})=>{const I=(0,b.DC)(Em),w={index_sets:l,type:i,rotate:h,field:D};return(0,le.ZP)("PUT",I,w)},Jg=()=>{const l=(0,il.useMutation)(Qf,{onError:i=>{Re.Z.error(`Changing the field type failed with status: ${i}`,"Could not change the field type")},onSuccess:()=>{Re.Z.success("The field type changed successfully","Success!")}});return{putFiledTypeMutation:l.mutateAsync,isLoading:l.isLoading}};var Yg=e("yzCFXWYn"),Jf=e("fVisTAey"),qg=e("E+CaPsQD"),eE=e("8OvTct/Z"),Yc=e("v4GbOr/o"),fm=e("0t7Ye+61");const tE=({streams:l})=>l.map(i=>({indexSet:i.index_set_id,id:i.id})),nE=()=>{const l=gm(),i=(0,Z.o)(Ng.h,tE);return(0,n.useMemo)(()=>{const h=new Set(l),D=h.size>0?({id:I})=>h.has(I):()=>!0;return i.filter(D).map(({indexSet:I})=>I)},[i,l])},qc=(0,u.default)(rt.Ph)` width: 400px; margin-bottom: 20px; `,oE=(0,u.default)(De.Badge)(({theme:l})=>(0,u.css)` background-color: ${l.colors.variant.light.danger}; `),Mi=()=>n.createElement(oE,null,"Beta Feature"),hm="000000000000000000000004",qf=()=>{const{data:l,isFetching:i,isError:h}=(0,Yg.Z)(hm);return i?n.createElement(rt.$j,null):n.createElement("span",null,n.createElement(Kf.Z,{stream:h?{id:hm,title:"Processing and Indexing Failures"}:l}),n.createElement("i",null," (",n.createElement(Wc.r,{to:Pe.ZP.SYSTEM.ENTERPRISE},"Enterprise Plugin")," required)"))},sE=({show:l,onClose:i,field:h})=>{const D=(0,eE.Z)(),[I,w]=(0,n.useState)(!1),[K,G]=(0,n.useState)(null),{data:{fieldTypes:oe},isLoading:pe}=Fg(),_e=(0,n.useMemo)(()=>Object.entries(oe).sort(([,Ft],[,an])=>(0,We.S)(Ft,an)).map(([Ft,an])=>({value:Ft,label:an})),[oe]),[ve,he]=(0,n.useState)(),{putFiledTypeMutation:Ue}=Jg(),He=nE(),{pathname:at}=(0,fm.Z)(),Xe=(0,n.useMemo)(()=>(0,b.av)(at),[at]),ct=(0,n.useCallback)(Ft=>{Ft.preventDefault(),Ue({indexSetSelection:ve,newFieldType:K,rotated:I,field:h}).then(()=>{D(Yc.A.SEARCH_FIELD_VALUE_ACTION.CHANGE_FIELD_TYPE_CHANGED,{app_pathname:Xe,app_action_value:{value:"change-field-type",rotated:I,isAllIndexesSelected:ve.length===He.length}}),i()})},[h,ve,He.length,K,i,Ue,I,D,Xe]),Nt=(0,n.useCallback)(Ft=>{G(Ft)},[]);(0,n.useEffect)(()=>{D(Yc.A.SEARCH_FIELD_VALUE_ACTION.CHANGE_FIELD_TYPE_OPENED,{app_pathname:Xe,app_action_value:"change-field-type-opened"})},[D,Xe]);const kt=(0,n.useCallback)(()=>{D(Yc.A.SEARCH_FIELD_VALUE_ACTION.CHANGE_FIELD_TYPE_CLOSED,{app_pathname:Xe,app_action_value:"change-field-type-closed"}),i()},[i,D,Xe]);return n.createElement(De.BootstrapModalForm,{title:n.createElement("span",null,"Change ",h," field type ",n.createElement(Mi,null)),submitButtonText:"Change field type",onSubmitForm:ct,onCancel:kt,show:l,bsSize:"large"},n.createElement("div",null,n.createElement(De.Alert,{bsStyle:"warning"},"Changing the type of the field can have a significant impact on the ingestion of future log messages. If you declare a field to have a type which is incompatible with the logs you are ingesting, it can lead to ingestion errors. It is recommended to enable ",n.createElement(Jf.eb,{page:qg.Z.PAGES.INDEXER_FAILURES,displayIcon:!0,text:"Failure Processing"})," and watch the ",n.createElement(qf,null)," stream closely afterwards."),n.createElement(De.Input,{label:"New Field Type:",id:"new-field-type"},n.createElement(qc,{inputId:"field_type",options:_e,value:K,onChange:Nt,placeholder:"Select field type",disabled:pe,inputProps:{"aria-label":"Select field type"},required:!0})),n.createElement(De.Alert,{bsStyle:"info"},"By default the type will be changed in all index sets of the current message/search. By expanding the next section, you can select for which index sets you would like to make the change."),n.createElement(Xg,{field:h,setIndexSetSelection:he,fieldTypes:oe,initialSelection:He}),n.createElement(De.Input,{type:"checkbox",id:"rotate",name:"rotate",label:"Rotate affected indices after change",onChange:()=>w(Ft=>!Ft),checked:I})))},vm=l=>Mt.ht.includes(l),ym=({field:l,onClose:i})=>{const[h,D]=(0,n.useState)(!0),I=(0,n.useCallback)(()=>{D(!1),i()},[i]);return h?n.createElement(sE,{field:l,onClose:I,show:h}):null},eu=l=>l.permissions.includes("typemappings:edit")||l.permissions.includes("*"),rE=({field:l,type:i,contexts:h})=>{const{currentUser:D}=h;return!(0,Le.mf)(l)&&!i.isDecorated()&&!vm(l)&&eu(D)},aE=()=>!o.Z.isFeatureEnabled("field_types_management"),_m=({contexts:l})=>{const{currentUser:i}=l;return eu(i),eu(i)?null:{title:"No permission",description:"You don't have permission to do that action"}},lE=ym;var tu=e("BcOICGB7"),Cm=e("yM9BwDic");const Tm=class du extends tu.Z{constructor(i,h,D,I,w,K,G){super(du.type,i,h,D,I,w,K,G)}static create(i,h,D,I,w,K,G){return new du(i,h,D,I,w,K,G)}toBuilder(){const{type:i,name:h,title:D,description:I,dataType:w,defaultValue:K,optional:G,binding:oe}=this._value;return new xs(Be.Map({type:i,name:h,title:D,description:I,dataType:w,defaultValue:K,optional:G,binding:oe}))}toJSON(){const{type:i,name:h,title:D,description:I,dataType:w,defaultValue:K,optional:G,binding:oe}=this._value;return{type:i,name:h,title:D,description:I,data_type:w,default_value:K,optional:G,binding:oe?oe.toJSON():void 0}}static fromJSON(i){const{name:h,title:D,description:I,data_type:w,default_value:K,optional:G,binding:oe}=i;return new du(h,D,I,w,K,G,Cm.Z.fromJSON(oe))}static builder(){return new xs().type(du.type).optional(!1).dataType("any").binding(Cm.Z.empty())}};Tm.type="value-parameter-v1";let cl=Tm;class xs{constructor(i=Be.Map()){this.value=i}type(i){return new xs(this.value.set("type",i))}name(i){return new xs(this.value.set("name",i))}title(i){return new xs(this.value.set("title",i))}description(i){return new xs(this.value.set("description",i))}dataType(i){return new xs(this.value.set("dataType",i))}defaultValue(i){return new xs(this.value.set("defaultValue",i))}optional(i){return new xs(this.value.set("optional",i))}binding(i){return new xs(this.value.set("binding",i))}build(){const{name:i,title:h,description:D,dataType:I,defaultValue:w,optional:K,binding:G}=this.value.toObject();return new cl(i,h,D,I,w,K,G)}}cl.Builder=xs;class nu{constructor(i,h){this._value={field:i,direction:h}}toJSON(){const{field:i,direction:h}=this._value;return{field:i,order:h===Jt.Z.Ascending?"ASC":"DESC"}}static fromJSON({field:i,order:h}){const D=Jt.Z.fromJSON(h==="ASC"?"Ascending":"Descending");return new nu(i,D)}}const iE=l=>{const{config:{decorators:i,sort:h}}=l;return[{type:"messages",decorators:i,sort:h.map(D=>new nu(D.field,D.direction))}]};var cE=e("SLtHYqXc");const nh=u.default.div` height: 100%; display: flex; justify-content: center; align-items: center; `,uE=u.default.div` margin: 3px 15px 0 0; `,dE=u.default.div` max-width: 700px; `,ul=u.default.div` margin-bottom: 5px; &:last-child { margin-bottom: 0; } `,Sm=u.default.ol` padding: 0; list-style: decimal inside none; `,Am=({config:l,type:i})=>n.createElement(nh,null,n.createElement(uE,null,n.createElement(rt.JO,{name:"question",size:"3x"})),n.createElement(dE,null,n.createElement(ul,null,n.createElement("strong",null,"Unknown Widget: ",i)),n.createElement(ul,null,"Unfortunately we are not able to render this widget, because we do not know how to handle widgets of type ",n.createElement("strong",null,i),". This might be caused by one of these situations:"),n.createElement(ul,null,n.createElement(Sm,null,n.createElement("li",null,"You created this widget using a plugin that is now missing."),n.createElement("li",null,"This widget was part of a legacy dashboard and created by a plugin that is not available anymore."))),n.createElement(ul,null,"What can you do about it? You can load the plugin again, contact the original plugin author for a plugin that works with Graylog 3.2+, or remove the widget if you do not need it anymore."),n.createElement(ul,null,"Either way, you can copy the widget\u2019s config to the clipboard: ",n.createElement(cE.Z,{title:n.createElement(rt.JO,{name:"copy",size:"sm"}),text:JSON.stringify(l,null,2),bsSize:"xsmall"}))));var ou=e("yAXMqwrl");const su=()=>{const l=(0,Ip.Z)(),{streamId:i}=(0,ou.useParams)();return(0,n.useEffect)(()=>{i?l.push(Pe.ZP.stream_search(i)):l.push(Pe.ZP.SEARCH)},[l,i]),null};Ho.Z.registerSubtype(te.Z.type,te.Z),Ho.Z.registerSubtype(Lo.Z.type,Lo.Z),Et.Z.registerSubtype(ql.type,xr),Et.Z.registerSubtype(k.type,Wo),Et.Z.registerSubtype(_a.type,Tn),Et.Z.registerSubtype(Un.type,$),Et.Z.registerSubtype(xc.type,zs),Et.Z.registerSubtype(Ta.type,Ca.ZP),Et.Z.registerSubtype(pr.type,At),Et.Z.registerSubtype(Vd.type,oa),tu.Z.registerSubtype(cl.type,cl),tu.Z.registerSubtype(Fd.Z.type,Fd.Z);const Pm=(l,i=[])=>i.includes(l),bm={pages:{search:{component:Cc}},routes:[{path:Mt.OV,component:gd,parentComponent:$e.Z},{path:Mt.ZB,component:ff,parentComponent:null},{path:Mt.Up,component:ol},{path:Mt.qq,component:Ei,parentComponent:$e.Z},{path:Mt.f0,component:su,parentComponent:null},{path:Mt.$4,component:Ei,parentComponent:$e.Z},{path:`${Pe.ZP.unqualified.stream_search(":streamId")}/new`,component:su,parentComponent:null},{path:Pe.ZP.unqualified.stream_search(":streamId"),component:pd,parentComponent:$e.Z},{path:Mt.XR,component:Cc,parentComponent:$e.Z},{path:Mt.Sh,component:Ei,parentComponent:$e.Z},{path:Pe.ZP.ALERTS.replay_search(":alertId"),component:Ed,parentComponent:$e.Z},{path:Pe.ZP.ALERTS.DEFINITIONS.replay_search(":definitionId"),component:fd,parentComponent:$e.Z}],enterpriseWidgets:[{type:"MESSAGES",displayName:"Message List",defaultHeight:5,reportStyle:()=>({width:800}),defaultWidth:6,visualizationComponent:Us,editComponent:md,hasEditSubmitButton:!0,needsControlledHeight:()=>!1,searchResultTransformer:l=>l[0],searchTypes:iE,titleGenerator:()=>Lo.Z.defaultTitle},{type:"AGGREGATION",displayName:"Results",defaultHeight:4,defaultWidth:4,reportStyle:()=>({width:600}),visualizationComponent:Oa,editComponent:ig.t,hasEditSubmitButton:!0,needsControlledHeight:l=>{const i=Fe()(l,"config.visualization");return![pr.type].find(D=>D===i)},searchResultTransformer:od,searchTypes:td,titleGenerator:l=>l.config.rowPivots.length>0?`Aggregating ${l.config.series.map(i=>i.effectiveName).join(", ")} by ${l.config.rowPivots.flatMap(({fields:i})=>i).join(", ")}`:l.config.series.length>0?`Aggregating ${l.config.series.map(i=>i.effectiveName).join(", ")}`:te.Z.defaultTitle},{type:"default",visualizationComponent:Am,needsControlledHeight:()=>!0,editComponent:Am,searchTypes:()=>[]}],searchTypes:[{type:"messages",handler:mt,defaults:{limit:150,offset:0}},{type:"pivot",handler:nd,defaults:{}},{type:"events",handler:is.ZP,defaults:{}}],fieldActions:[{type:"chart",title:"Chart",thunk:Al,isEnabled:({type:l})=>l.isNumeric(),resetFocus:!0},{type:"aggregate",title:"Show top values",thunk:Sl,isEnabled:({field:l,type:i,contexts:{analysisDisabledFields:h}})=>!(0,Le.mf)(l)&&i.isEnumerable()&&!i.isDecorated()&&!Pm(l,h),resetFocus:!0},{type:"statistics",title:"Statistics",isEnabled:({field:l,type:i,contexts:{analysisDisabledFields:h}})=>!(0,Le.mf)(l)&&!i.isDecorated()&&!Pm(l,h),thunk:cc,resetFocus:!1},{type:"add-to-table",title:"Add to table",thunk:ps,isEnabled:ps.isEnabled,isHidden:ps.isHidden,resetFocus:!1},{type:"remove-from-table",title:"Remove from table",thunk:hi,isEnabled:hi.isEnabled,isHidden:hi.isHidden,resetFocus:!1},{type:"add-to-all-tables",title:"Add to all tables",thunk:Ns,isEnabled:({field:l,type:i})=>!(0,Le.mf)(l)&&!i.isDecorated(),resetFocus:!1},{type:"remove-from-all-tables",title:"Remove from all tables",thunk:X,isEnabled:({field:l,type:i})=>!(0,Le.mf)(l)&&!i.isDecorated(),resetFocus:!1},{type:"copy-field-to-clipboard",title:"Copy field name to clipboard",handler:Rf,isEnabled:()=>!0,resetFocus:!1},{type:"change-field-type",title:"Change field type",isEnabled:rE,isHidden:aE,resetFocus:!1,component:lE,help:_m}],valueActions:bf([{type:"exclude",title:"Exclude from results",thunk:sp,isEnabled:({field:l,type:i})=>!(0,Le.mf)(l)&&!i.isDecorated(),resetFocus:!1},{type:"add-to-query",title:"Add to query",thunk:gs.Z,isEnabled:({field:l,type:i})=>!(0,Le.mf)(l)&&!i.isDecorated(),resetFocus:!1},{type:"show-bucket",title:"Show documents for value",thunk:Td,isEnabled:Td.isEnabled,resetFocus:!0},{type:"create-extractor",title:"Create extractor",isEnabled:({type:l,contexts:i})=>!!i.message&&!l.isDecorated()&&!!i.isLocalNode,component:vi,resetFocus:!1},{type:"highlight-value",title:"Highlight this value",thunk:Ad,isEnabled:Ad.isEnabled,resetFocus:!1},{type:"copy-value-to-clipboard",title:"Copy value to clipboard",handler:wc,isEnabled:()=>!0,resetFocus:!1},{type:"create-event-definition-from-value",title:"Create event definition",isEnabled:()=>!0,resetFocus:!1,component:Zg}],["create-extractor"]),visualizationTypes:Qd,widgetCreators:[{title:"Message Count",func:Tc,icon:()=>n.createElement(P.Z,{name:"hashtag"})},{title:"Message Table",func:Sc,icon:()=>n.createElement(P.Z,{name:"list"})},{title:"Custom Aggregation",func:qe,icon:()=>n.createElement(P.Z,{name:"chart-column"})}],creators:[{type:"preset",title:"Message Count",func:hd},{type:"preset",title:"Message Table",func:vd},{type:"generic",title:"Aggregation",func:Bt}],"views.completers":[new vp,new bp,new Op],"views.hooks.loadingView":[Lp,Bp.Z],"views.elements.header":[()=>n.createElement(ed.Z,null,n.createElement(si,null)),Fc],"views.export.formats":[{type:"csv",displayName:()=>"Comma-Separated Values (CSV)",mimeType:"text/csv",fileExtension:"csv"}],"views.components.widgets.messageTable.previewOptions":[{title:"Show message in new row",isChecked:l=>l.showMessageRow,isDisabled:()=>!1,onChange:(l,i)=>{const h=!l.showMessageRow,D=h?l.showSummary:!1,I=l.toBuilder().showMessageRow(h).showSummary(D).build();return i(I)},sort:1}],"views.reducers":sm};var mE=e("D4SbLiE/"),pE=e.n(mE),dl=e("QdZ7Yq43"),gE=e("BqxuktKK");const EE=pE()({displayName:"ThreatIntelPluginConfig",propTypes:{config:a().object,updateConfig:a().func.isRequired,sendTelemetry:a().func.isRequired},getDefaultProps(){return{config:{tor_enabled:!1,spamhaus_enabled:!1,abusech_ransom_enabled:!1}}},getInitialState(){const{config:l}=this.props;return{config:dl.Z.clone(l),threatintelConfigModal:!1}},UNSAFE_componentWillReceiveProps(l){this.setState({config:dl.Z.clone(l.config)})},_updateConfigField(l,i){const{config:h}=this.state,D=dl.Z.clone(h);D[l]=i,this.setState({config:D})},_onCheckboxClick(l,i){return()=>{this._updateConfigField(l,this[i].getChecked())}},_onSelect(l){return i=>{this._updateConfigField(l,i)}},_onUpdate(l){return i=>{this._updateConfigField(l,i.target.value)}},_openModal(){this.setState({threatintelConfigModal:!0})},_closeModal(){this.setState({threatintelConfigModal:!1})},_resetConfig(){this.setState(this.getInitialState())},_saveConfig(){const{updateConfig:l,sendTelemetry:i}=this.props;i(Yc.A.CONFIGURATIONS.THREATINTEL_CONFIGURATION_UPDATED,{app_pathname:"configurations",app_section:"threat-intel"}),l(this.state.config).then(()=>{this._closeModal()})},render(){return n.createElement("div",null,n.createElement("h3",null,"Threat Intelligence Lookup Configuration"),n.createElement("p",null,"Configuration for threat intelligence lookup plugin."),n.createElement("dl",{className:"deflist"},n.createElement("dt",null,"Tor exit nodes:"),n.createElement("dd",null,this.state.config.tor_enabled===!0?"Enabled":"Disabled"),n.createElement("dt",null,"Spamhaus:"),n.createElement("dd",null,this.state.config.spamhaus_enabled===!0?"Enabled":"Disabled")),n.createElement(rt.AE,{permissions:"clusterconfigentry:edit"},n.createElement(De.Button,{bsStyle:"info",bsSize:"xs",onClick:this._openModal},"Edit configuration")),n.createElement(De.BootstrapModalForm,{show:this.state.threatintelConfigModal,title:"Update Threat Intelligence plugin Configuration",onSubmitForm:this._saveConfig,onCancel:this._resetConfig,submitButtonText:"Update configuration"},n.createElement("fieldset",null,n.createElement(De.Input,{type:"checkbox",id:"tor-checkbox",ref:l=>{this.torEnabled=l},label:"Allow Tor exit node lookups?",help:"Enable to include Tor exit node lookup in global pipeline function, disabling also stops refreshing the data.",name:"tor_enabled",checked:this.state.config.tor_enabled,onChange:this._onCheckboxClick("tor_enabled","torEnabled")}),n.createElement(De.Input,{type:"checkbox",id:"spamhaus-checkbox",ref:l=>{this.spamhausEnabled=l},label:"Allow Spamhaus DROP/EDROP lookups?",help:"Enable to include Spamhaus lookup in global pipeline function, disabling also stops refreshing the data.",name:"tor_enabled",checked:this.state.config.spamhaus_enabled,onChange:this._onCheckboxClick("spamhaus_enabled","spamhausEnabled")}))))}}),fE=(0,gE.Z)(EE),vE=()=>n.createElement("div",null),ru=({handleFormEvent:l,validationState:i,validationMessage:h,config:D})=>n.createElement("fieldset",null);ru.propTypes={config:a().shape({}).isRequired,handleFormEvent:a().func.isRequired,validationMessage:a().func.isRequired,validationState:a().func.isRequired};const yE=ru,_E=()=>n.createElement("dl",null,n.createElement("i",null,"No configuration required.")),Dm=()=>n.createElement("div",null),Om=()=>n.createElement("fieldset",null),CE=()=>n.createElement("i",null,"No configuration necessary"),dh=()=>{const l={marginBottom:10};return n.createElement("div",null,n.createElement("p",{style:l},"The whois IP lookup data adapter can request network ownership information for an IP address."),n.createElement("h3",{style:l},"Configuration"),n.createElement("h5",{style:l},"Connect timeout"),n.createElement("p",{style:l},"The connection timeout for the socket to the whois server in milliseconds. If you set this to a high value, it can affect your processing performance."),n.createElement("h5",{style:l},"Read timeout"),n.createElement("p",{style:l},"The connection read timeout for the socket to the whois server in milliseconds. If you set this to a high value, it can affect your processing performance."))};var TE=Object.defineProperty,SE=(l,i,h)=>i in l?TE(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,Rm=(l,i,h)=>(SE(l,typeof i!="symbol"?i+"":i,h),h);class au extends n.Component{render(){const{config:i}=this.props;return n.createElement("fieldset",null,n.createElement(De.Input,{type:"number",id:"connect_timeout",name:"connect_timeout",label:"Connect timeout",required:!0,onChange:this.props.handleFormEvent,help:this.props.validationMessage("connect_timeout","WHOIS connection timeout in milliseconds."),bsStyle:this.props.validationState("connect_timeout"),value:i.connect_timeout,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}),n.createElement(De.Input,{type:"number",id:"read_timeout",name:"read_timeout",label:"Read timeout",required:!0,onChange:this.props.handleFormEvent,help:this.props.validationMessage("read_timeout","WHOIS connection read timeout in milliseconds."),bsStyle:this.props.validationState("read_timeout"),value:i.read_timeout,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}))}}Rm(au,"propTypes",{config:a().shape({connect_timeout:a().number.isRequired,read_timeout:a().number.isRequired}).isRequired,handleFormEvent:a().func.isRequired,validationMessage:a().func.isRequired,validationState:a().func.isRequired});const AE=au,Im=({dataAdapter:l})=>{const{config:i}=l;return n.createElement("dl",null,n.createElement("dt",null,"Connect timeout"),n.createElement("dd",null,i.connect_timeout," ms"),n.createElement("dt",null,"Read timeout"),n.createElement("dd",null,i.read_timeout," ms"))};Im.propTypes={dataAdapter:a().shape({config:a().shape({connect_timeout:a().number.isRequired,read_timeout:a().number.isRequired})}).isRequired};const PE=Im,bE=()=>n.createElement("div",null,n.createElement(De.Alert,{style:{marginBottom:10},bsStyle:"warning",title:"Deprecation Warning"},n.createElement("p",null,"The abuse.ch Ransomware Tracker was shut down on 2019-12-08. This Data Adapter should not be used.")));var DE=Object.defineProperty,Mm=(l,i,h)=>i in l?DE(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,xi=(l,i,h)=>(Mm(l,typeof i!="symbol"?i+"":i,h),h);class Li extends n.Component{constructor(){super(...arguments),xi(this,"_update",(i,h,D,I)=>{const w=dl.Z.clone(this.props.config);w[I]=D?i:0,w[`${I}_unit`]=h,this.props.updateConfig(w)}),xi(this,"updateRefreshInterval",(i,h,D)=>{this._update(i,h,D,"refresh_interval")}),xi(this,"_onBlocklistTypeSelect",i=>{const h=dl.Z.clone(this.props.config);h.blocklist_type=i,this.props.updateConfig(h)})}render(){const{config:i}=this.props,h=[{label:"Domain blocklist",value:"DOMAINS"},{label:"URL blocklist",value:"URLS"},{label:"IP blocklist",value:"IPS"}];return n.createElement("fieldset",null,n.createElement(De.Input,{label:"Blocklist type",id:"blocklist-type-selector",required:!0,autoFocus:!0,help:"Select the type of the abuse.ch ransomware blocklist",labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},n.createElement(rt.Ph,{placeholder:"Select the type of blocklist",clearable:!1,options:h,matchProp:"label",onChange:this._onBlocklistTypeSelect,value:i.blocklist_type})),n.createElement(rt.AX,{label:"Refresh blocklist",help:"If enabled, the abuse.ch ransomware blocklist is refreshed when it changed.",update:this.updateRefreshInterval,value:i.refresh_interval,unit:i.refresh_interval_unit||"MINUTES",defaultEnabled:i.refresh_interval>0,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}))}}xi(Li,"propTypes",{config:a().object.isRequired,updateConfig:a().func.isRequired,handleFormEvent:a().func.isRequired,validationState:a().func.isRequired,validationMessage:a().func.isRequired});const mh=Li;var OE=Object.defineProperty,RE=(l,i,h)=>i in l?OE(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,ph=(l,i,h)=>(RE(l,typeof i!="symbol"?i+"":i,h),h);class xm extends n.Component{render(){const{config:i}=this.props.dataAdapter,h={DOMAINS:"Domain blocklist",URLS:"URL blocklist",IPS:"IP blocklist"};return n.createElement("div",null,n.createElement("dl",null,n.createElement("dt",null,"Blocklist type"),n.createElement("dd",null,h[i.blocklist_type]),n.createElement("dt",null,"Update interval"),n.createElement("dd",null,n.createElement(rt.j1,{value:i.refresh_interval,unit:i.refresh_interval_unit}))),n.createElement(De.Alert,{style:{marginBottom:10},bsStyle:"warning",title:"Deprecation Warning"},n.createElement("p",null,"The abuse.ch Ransomware Tracker was shut down on 2019-12-08. This Data Adapter should not be used.")))}}ph(xm,"propTypes",{dataAdapter:a().object.isRequired});const IE=xm;class ME extends n.Component{render(){const i={marginBottom:10};return n.createElement("div",null,n.createElement("p",{style:i},"The AlienVault OTX data adapter uses the ",n.createElement(rt.dL,{href:"https://otx.alienvault.com/api"},"OTX API")," to lookup indicators for the given key."),n.createElement("h3",{style:i},"Configuration"),n.createElement("h5",{style:i},"Indicator"),n.createElement("p",{style:i},"The OTX API offers several different indicators of compromise (IOCs). You have to select which indicator should be used for this data adapter."),n.createElement("p",{style:i},"The ",n.createElement("code",null,"IP Auto-Detect")," indicator is not an official one. We added that to make it possible to auto-detect the IP address type to allow using the same data adapter for IP v4 and v6 addresses."),n.createElement("h5",{style:i},"OTX API Key"),n.createElement("p",{style:i},"The OTX API key is used to authenticate API requests. Requests also work if you don't enter an API key, but you will most probably get a smaller request limit. ",n.createElement("strong",null,"If you use this data adapter for production traffic, please register for an OTX account and get an API key.")),n.createElement("h5",{style:i},"OTX API URL"),n.createElement("p",{style:i},"HTTP URL of the OTX API server. The default setting of ",n.createElement("code",null,"https://otx.alienvault.com")," should not be changed except if you want to run some tests with a custom server."),n.createElement("h5",{style:i},"HTTP User-Agent"),n.createElement("p",{style:i},"This will set the ",n.createElement("code",null,"User-Agent")," HTTP header for OTX API requests. You can modify this to include your contact details so the OTX API operators can contact you if there are problems with your API requests."),n.createElement("h5",{style:i},"HTTP Connection Timeout"),n.createElement("p",{style:i},"The HTTP connection timeout in milliseconds for the OTX API request. If you set this to a high value and the OTX API connection is slow, processing performance can be affected."),n.createElement("h5",{style:i},"HTTP Write Timeout"),n.createElement("p",{style:i},"The HTTP write timeout in milliseconds for the OTX API request. If you set this to a high value and the OTX API connection is slow, processing performance can be affected."),n.createElement("h5",{style:i},"HTTP Read Timeout"),n.createElement("p",{style:i},"The HTTP read timeout in milliseconds for the OTX API request. If you set this to a high value and the OTX API connection is slow, processing performance can be affected."))}}const xE=ME;var Lm=e("nHcjWeCO"),LE=e.n(Lm),m=Object.defineProperty,_=(l,i,h)=>i in l?m(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,A=(l,i,h)=>(_(l,typeof i!="symbol"?i+"":i,h),h);const R=[{label:"IP Auto-Detect",value:"IPAutoDetect"},{label:"IP v4",value:"IPv4"},{label:"IP v6",value:"IPv6"},{label:"Domain",value:"domain"},{label:"Hostname",value:"hostname"},{label:"File",value:"file"},{label:"URL",value:"url"},{label:"CVE",value:"cve"},{label:"NIDS",value:"nids"},{label:"Correlation-Rule",value:"correlation-rule"}];class B extends n.Component{constructor(){super(...arguments),A(this,"handleSelect",i=>h=>{const D=LE().cloneDeep(this.props.config);D[i]=h,this.props.updateConfig(D)})}render(){const{config:i}=this.props;return n.createElement("fieldset",null,n.createElement(De.Input,{id:"indicator",label:"Indicator",required:!0,onChange:this.props.handleFormEvent,help:this.props.validationMessage("indicator","The OTX indicator type that should be used for lookups."),bsStyle:this.props.validationState("indicator"),labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},n.createElement(rt.Ph,{placeholder:"Select indicator",clearable:!1,options:R,matchProp:"label",onChange:this.handleSelect("indicator"),value:i.indicator})),n.createElement(De.Input,{type:"text",id:"api_key",name:"api_key",label:"OTX API Key",onChange:this.props.handleFormEvent,help:this.props.validationMessage("api_key","Your OTX API key."),bsStyle:this.props.validationState("api_key"),value:i.api_key,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}),n.createElement(De.Input,{type:"text",id:"api_url",name:"api_url",label:"OTX API URL",onChange:this.props.handleFormEvent,help:this.props.validationMessage("api_url","URL of the OTX API server."),bsStyle:this.props.validationState("api_url"),value:i.api_url,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}),n.createElement(De.Input,{type:"text",id:"http_user_agent",name:"http_user_agent",label:"HTTP User-Agent",required:!0,onChange:this.props.handleFormEvent,help:this.props.validationMessage("http_user_agent","The User-Agent header that should be used for the HTTP request."),bsStyle:this.props.validationState("http_user_agent"),value:i.http_user_agent,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}),n.createElement(De.Input,{type:"number",id:"http_connect_timeout",name:"http_connect_timeout",label:"HTTP Connect Timeout",required:!0,onChange:this.props.handleFormEvent,help:this.props.validationMessage("http_connect_timeout","HTTP connection timeout in milliseconds."),bsStyle:this.props.validationState("http_connect_timeout"),value:i.http_connect_timeout,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}),n.createElement(De.Input,{type:"number",id:"http_write_timeout",name:"http_write_timeout",label:"HTTP Write Timeout",required:!0,onChange:this.props.handleFormEvent,help:this.props.validationMessage("http_write_timeout","HTTP write timeout in milliseconds."),bsStyle:this.props.validationState("http_write_timeout"),value:i.http_write_timeout,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}),n.createElement(De.Input,{type:"number",id:"http_read_timeout",name:"http_read_timeout",label:"HTTP Read Timeout",required:!0,onChange:this.props.handleFormEvent,help:this.props.validationMessage("http_read_timeout","HTTP read timeout in milliseconds."),bsStyle:this.props.validationState("http_read_timeout"),value:i.http_read_timeout,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}))}}A(B,"propTypes",{config:a().shape({indicator:a().string.isRequired,api_key:a().string,api_url:a().string.isRequired,http_user_agent:a().string.isRequired,http_connect_timeout:a().number.isRequired,http_write_timeout:a().number.isRequired,http_read_timeout:a().number.isRequired}).isRequired,updateConfig:a().func.isRequired,handleFormEvent:a().func.isRequired,validationState:a().func.isRequired,validationMessage:a().func.isRequired});const U=B;var F=Object.defineProperty,V=(l,i,h)=>i in l?F(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,se=(l,i,h)=>(V(l,typeof i!="symbol"?i+"":i,h),h);class Se extends n.Component{render(){const{config:i}=this.props.dataAdapter;return n.createElement("dl",null,n.createElement("dt",null,"Indicator"),n.createElement("dd",null,i.indicator),n.createElement("dt",null,"OTX API Key"),n.createElement("dd",null,i.api_key||"n/a"),n.createElement("dt",null,"OTX API URL"),n.createElement("dd",null,i.api_url),n.createElement("dt",null,"HTTP User-Agent"),n.createElement("dd",null,i.http_user_agent),n.createElement("dt",null,"HTTP Connect Timeout"),n.createElement("dd",null,i.http_connect_timeout," ms"),n.createElement("dt",null,"HTTP Write Timeout"),n.createElement("dd",null,i.http_write_timeout," ms"),n.createElement("dt",null,"HTTP Read Timeout"),n.createElement("dd",null,i.http_read_timeout," ms"))}}se(Se,"propTypes",{dataAdapter:a().shape({config:a().shape({indicator:a().string.isRequired,api_key:a().string,api_url:a().string.isRequired,http_user_agent:a().string.isRequired,http_connect_timeout:a().number.isRequired,http_write_timeout:a().number.isRequired,http_read_timeout:a().number.isRequired})})});const Ze={systemConfigurations:[{component:fE,configType:"org.graylog.plugins.threatintel.ThreatIntelPluginConfiguration"}],lookupTableAdapters:[{type:"spamhaus-edrop",displayName:"Spamhaus (E)DROP",formComponent:yE,summaryComponent:_E,documentationComponent:vE},{type:"torexitnode",displayName:"Tor Exit Node",formComponent:Om,summaryComponent:CE,documentationComponent:Dm},{type:"whois",displayName:"Whois for IPs",formComponent:AE,summaryComponent:PE,documentationComponent:dh},{type:"abuse-ch-ransom",displayName:"[Deprecated] Ransomware blocklists from abuse.ch",formComponent:mh,summaryComponent:IE,documentationComponent:bE},{type:"otx-api",displayName:"Alienvault OTX API",formComponent:U,summaryComponent:Se,documentationComponent:xE}]};var je=e("ibdPvtmL"),ke=e("S6FuRS7B");const _t="org.graylog.aws",Dt=`${_t}.config.AWSPluginConfiguration`,jt=`/plugins/${_t}/config`,Pt=l=>am()(l,["secret_key","secret_key_salt"]),Yt=l=>{const i=b.ZP.qualifyUrl(jt);return(0,le.ZP)("PUT",i,l)},Ht=({config:l})=>{const[i,h]=(0,n.useState)(Pt(l)),[D,I]=(0,n.useState)(!1),w=(he,Ue)=>{h({...i,[he]:Ue})},K=()=>{h({...i,secret_key:""})},G=he=>Ue=>{typeof Ue=="object"?w(he,(0,ke.n6)(Ue.target)):w(he,Ue)},oe=()=>{I(!0)},pe=()=>{I(!1)},_e=()=>{h(Pt(l)),pe()},ve=()=>{Yt(i).then(()=>{je.h.list(Dt),pe()},he=>{Re.Z.error(`AWS plugin configuration failed with status: ${he}`,"Could not save AWS plugin configuration.")})};return n.createElement("div",null,n.createElement("h3",null,"AWS Plugin Configuration"),n.createElement("p",null,"Base configuration for all plugins the AWS module is providing. Note that some parameters will be stored in MongoDB without encryption. Graylog users with required permissions will be able to read them in the configuration dialog on this page."),n.createElement("dl",{className:"deflist"},n.createElement("dt",null,"Instance detail lookups:"),n.createElement("dd",null,l.lookups_enabled===!0?"Enabled":"Disabled"),n.createElement("dt",null,"Connect through proxy:"),n.createElement("dd",null,l.proxy_enabled===!0?"Enabled":"Disabled"),n.createElement("dt",null,"Lookup regions:"),n.createElement("dd",null,l.lookup_regions?l.lookup_regions:"[not set]"),n.createElement("dt",null,"Access Key:"),n.createElement("dd",null,l.access_key?l.access_key:"[not set]"),n.createElement("dt",null,"Secret Key:"),n.createElement("dd",null,l.secret_key?"***********":"[not set]")),n.createElement(rt.AE,{permissions:"clusterconfigentry:edit"},n.createElement(De.Button,{bsStyle:"info",bsSize:"xs",onClick:oe},"Edit configuration")),n.createElement(De.BootstrapModalForm,{show:D,title:"Update AWS Plugin Configuration",onSubmitForm:ve,onCancel:_e,submitButtonText:"Update configuration"},n.createElement("fieldset",null,n.createElement(De.Input,{id:"aws-lookups-enabled",type:"checkbox",label:"Run AWS instance detail lookups for IP addresses?",help:n.createElement("span",null,"When enabled, a message processor will try to identify IP addresses of your AWS entities (like EC2, ELB, RDS, ...) and add additional information abut the service or instance behind it. It can take up to a minute for a change of this to take effect."),name:"lookups_enabled",checked:i.lookups_enabled,onChange:G("lookups_enabled")}),n.createElement(De.Input,{id:"aws-access-key",type:"text",label:"AWS Access Key",help:n.createElement("span",null,"Note that this will only be used in encrypted connections but stored in plaintext. Please consult the documentation for suggested rights to assign to the underlying IAM user."),name:"access_key",value:i.access_key,onChange:G("access_key")}),n.createElement(De.Input,{id:"aws-secret-key",type:"password",label:"AWS Secret Key",help:n.createElement("span",null,"Note that this will only be used in encrypted connections and will be stored encrypted (using the system secret). Please consult the documentation for suggested rights to assign to the underlying IAM user."),name:"secret_key",value:i.secret_key!==void 0?i.secret_key:l.secret_key,onFocus:K,onChange:G("secret_key")}),n.createElement(De.Input,{id:"aws-lookup-regions",type:"text",label:"Lookup regions",help:n.createElement("span",null,"The AWS instance lookup message processor keeps a table of instances for fast address translation. Define the AWS regions you want to include in the tables. This should be all regions you run AWS services in. Remember that your IAM user needs permission for these regions or you will see warnings in your graylog-server log files."),name:"lookup_regions",value:i.lookup_regions,onChange:G("lookup_regions")}),n.createElement(De.Input,{id:"aws-proxy-enabled",type:"checkbox",label:"Use HTTP proxy?",help:n.createElement("span",null,"When enabled, we'll access the AWS APIs through the HTTP proxy configured (",n.createElement("code",null,"http_proxy_uri"),") in your Graylog configuration file.",n.createElement("br",null),n.createElement("em",null,"Important:")," You have to restart all AWS inputs for this configuration to take effect."),name:"proxy_enabled",checked:i.proxy_enabled,onChange:G("proxy_enabled")}))))};Ht.propTypes={config:a().shape({lookups_enabled:a().bool,lookup_regions:a().string,access_key:a().string,secret_key:a().string,proxy_enabled:a().bool})},Ht.defaultProps={config:{lookups_enabled:!1,lookup_regions:"us-east-1,us-west-1,us-west-2,eu-west-1,eu-central-1",access_key:"",secret_key:"",proxy_enabled:!1}};const qt=Ht,tn=o.Z.isCloud()?{}:{systemConfigurations:[{component:qt,configType:Dt}]},wn={INTEGRATIONS:{AWS:{CLOUDWATCH:{index:"/integrations/aws/cloudwatch"}}}},on={INTEGRATIONS:{AWS:{PERMISSIONS:"/plugins/org.graylog.integrations/aws/permissions",REGIONS:"/plugins/org.graylog.integrations/aws/regions",CLOUDWATCH:{GROUPS:"/plugins/org.graylog.integrations/aws/cloudwatch/log_groups"},KINESIS:{HEALTH_CHECK:"/plugins/org.graylog.integrations/aws/kinesis/health_check",STREAMS:"/plugins/org.graylog.integrations/aws/kinesis/streams",SAVE:"/plugins/org.graylog.integrations/aws/inputs"},KINESIS_AUTO_SETUP:{CREATE_STREAM:"/plugins/org.graylog.integrations/aws/kinesis/auto_setup/create_stream",CREATE_SUBSCRIPTION_POLICY:"/plugins/org.graylog.integrations/aws/kinesis/auto_setup/create_subscription_policy",CREATE_SUBSCRIPTION:"/plugins/org.graylog.integrations/aws/kinesis/auto_setup/create_subscription"}}}},so={INTEGRATIONS:{AWS:{AWS_KINESIS_CLOUDWATCH_INPUTS:"aws-kinesiscloudwatch-input"}}},yn=wn,lo=({url:l})=>{const i=(0,ou.useNavigate)();return(0,n.useEffect)(()=>{i(l)},[l,i]),null};lo.propTypes={url:a().string},lo.defaultProps={url:yn.INTEGRATIONS.AWS.CLOUDWATCH.index};const Sn=lo;var ro=e("/W/x1zfW");const Io=(0,n.createContext)(),rr=({children:l})=>{const[i,h]=(0,n.useState)(n.createElement(n.Fragment,null)),D=()=>{h(n.createElement(n.Fragment,null))};return n.createElement(Io.Provider,{value:{sidebar:i,clearSidebar:D,setSidebar:h}},l)};rr.propTypes={children:a().any.isRequired};const Qo=(0,n.createContext)(),ba=({initialFormData:l,children:i})=>{const[h,D]=(0,n.useState)(l),I=(K,G)=>{D({...h,[K]:{...h[K],...G,dirty:!0}})},w=K=>{Object.keys(h).find(G=>G===K)&&(delete h[K],D(h))};return n.createElement(Qo.Provider,{value:{formData:h,setFormData:I,clearField:w}},i)};ba.propTypes={children:a().any.isRequired,initialFormData:a().object},ba.defaultProps={initialFormData:{}};const BE=null,lu=(0,n.createContext)(),Bi=({children:l})=>{const[i,h]=(0,n.useState)("authorize"),[D,I]=(0,n.useState)(["authorize"]),[w,K]=(0,n.useState)([]),G=pe=>!D||D.length===0?!0:!D.includes(pe),oe=pe=>{I([...D,pe])};return n.createElement(lu.Provider,{value:{availableSteps:w,currentStep:i,enabledSteps:D,isDisabledStep:G,setAvailableStep:K,setCurrentStep:h,setEnabledStep:oe}},l)};Bi.propTypes={children:a().any.isRequired};const sa=(0,n.createContext)(),Bm=({children:l})=>{const[i,h]=(0,n.useState)([]),[D,I]=(0,n.useState)([]),[w,K]=(0,n.useState)([]),[G,oe]=(0,n.useState)(null),pe=He=>h(He.regions),_e=He=>{const at=He.log_groups.map(Xe=>({value:Xe,label:Xe}));K(at)},ve=He=>{const at=He.streams.map(Xe=>({value:Xe,label:Xe}));I(at)},he=He=>{oe({message:JSON.stringify(He.message_fields,null,2),type:He.input_type,additional:He.explanation})},Ue=()=>{oe(null)};return n.createElement(sa.Provider,{value:{availableStreams:D,setStreams:ve,availableRegions:i,setRegions:pe,logData:G,setLogData:he,clearLogData:Ue,availableGroups:w,setGroups:_e}},l)};Bm.propTypes={children:a().any.isRequired};const iu=(0,n.createContext)(),io=({children:l})=>{const[i,h]=(0,n.useState)(!1),[D,I]=(0,n.useState)(!1);return n.createElement(iu.Provider,{value:{isAdvancedOptionsVisible:i,isAWSCustomEndpointsVisible:D,setAdvancedOptionsVisibility:h,setAWSCustomEndpointsVisibility:I}},l)};io.propTypes={children:a().any.isRequired};const Cr=[{value:"KINESIS_CLOUDWATCH_FLOW_LOGS",label:"Kinesis CloudWatch Flow Logs"},{value:"KINESIS_CLOUDWATCH_RAW",label:"Kinesis CloudWatch Raw"},{value:"KINESIS_RAW",label:"Kinesis Raw"}],Ui="KINESIS_CLOUDWATCH_FLOW_LOGS",es={automatic:"Automatic",keysecret:"Key & Secret"},av=(l,i)=>{const{awsAuthenticationType:h,awsCloudWatchAssumeARN:D,awsCloudWatchAwsKey:I,awsCloudWatchAwsSecret:w,awsEndpointCloudWatch:K,awsEndpointIAM:G,awsEndpointDynamoDB:oe,awsEndpointKinesis:pe,key:_e,secret:ve}=l;return{...(h==null?void 0:h.value)===es.keysecret?{aws_access_key_id:I==null?void 0:I.value,aws_secret_access_key:w==null?void 0:w.value}:{aws_access_key_id:_e,aws_secret_access_key:ve},assume_role_arn:D==null?void 0:D.value,cloudwatch_endpoint:K==null?void 0:K.value,dynamodb_endpoint:oe==null?void 0:oe.value,iam_endpoint:G==null?void 0:G.value,kinesis_endpoint:pe==null?void 0:pe.value,...i}},lv=({awsAuthenticationType:l,awsCloudWatchAddFlowLogPrefix:i={value:void 0},awsCloudWatchAssumeARN:h={value:void 0},awsCloudWatchAwsKey:D={value:void 0},awsCloudWatchAwsRegion:I,awsCloudWatchBatchSize:w,awsEndpointCloudWatch:K={value:void 0},awsCloudWatchKinesisInputType:G={value:Ui},awsCloudWatchKinesisStream:oe,awsCloudWatchName:pe,awsCloudWatchThrottleEnabled:_e={value:void 0},awsEndpointDynamoDB:ve={value:void 0},awsEndpointIAM:he={value:void 0},awsEndpointKinesis:Ue={value:void 0},awsCloudWatchAwsSecret:He,key:at,secret:Xe})=>({type:"org.graylog.integrations.aws.inputs.AWSInput",title:pe.value,configuration:{...(l==null?void 0:l.value)===es.keysecret?{aws_access_key:D==null?void 0:D.value,aws_secret_key:He==null?void 0:He.value}:{aws_access_key:at,aws_secret_key:Xe},aws_message_type:G.value,throttling_allowed:!!_e.value,aws_flow_log_prefix:!!i.value,aws_region:I.value,aws_assume_role_arn:h==null?void 0:h.value,cloudwatch_endpoint:K==null?void 0:K.value,dynamodb_endpoint:ve==null?void 0:ve.value,iam_endpoint:he==null?void 0:he.value,kinesis_endpoint:Ue==null?void 0:Ue.value,kinesis_stream_name:oe.value,kinesis_record_batch_size:Number(w.value||w.defaultValue)}});var iv=e("t7jeigEY"),cv=e("1e+nFvZs");const Um={checkInputValidity:(l,i)=>{const{validity:h}=l,D=h.valid,I=l.getAttribute("title");if(D)return;const w=h.valueMissing,K=h.typeMismatch,G=h.patternMismatch,oe=h.tooLong||h.rangeOverflow,pe=h.rangeUnderflow,_e=h.stepMismatch,he=[{invalid:w,message:I||"A value is required."},{invalid:K,message:I||"Please verify that your input is the expected type (ie: email address)."},{invalid:G,message:I||"This input does not match the expected value."},{invalid:oe,message:I||"Your input is too long."},{invalid:pe,message:I||"Your input is too short."},{invalid:_e,message:I||"Unexpected value."}].find(Ue=>Ue.invalid);return i||he.message},isFormValid:(l,i)=>!!l.find(h=>!i[h]||!i[h].value||i[h].error)},uv=({label:l,error:i})=>i?n.createElement(mv,null,l,n.createElement(dv,null,n.createElement("i",{className:"fa fa-exclamation-triangle"})," ",i)):l,UE=({className:l,help:i,onChange:h,id:D,label:I,fieldData:w,type:K,...G})=>{const{dirty:oe,error:pe,value:_e}=w,ve=he=>{if(oe){const Ue=Um.checkInputValidity(he.target);h(he,{error:Ue})}};return n.createElement(De.Input,{...G,id:D,type:K,onChange:h,onBlur:ve,className:l,bsStyle:pe&&oe&&"error"||void 0,defaultValue:K!=="select"&&_e||void 0,value:K==="select"&&_e||void 0,label:n.createElement(uv,{label:I,error:pe}),help:i})};UE.propTypes={className:a().string,fieldData:a().shape({error:a().string,dirty:a().bool,value:a().string}),help:a().string,label:a().oneOfType([a().string,a().node]).isRequired,id:a().string.isRequired,onChange:a().func,required:a().bool,type:a().string.isRequired},UE.defaultProps={className:void 0,onChange:()=>{},required:!1,help:"",fieldData:{dirty:!1,error:void 0,value:void 0}};const dv=u.default.span` display: block; font-weight: normal; padding-left: 15px; font-size: 0.85em; `,mv=u.default.span` display: flex; align-items: center; `,ar=UE,wE=({fullMessage:l,niceMessage:i})=>{const[h,D]=(0,n.useState)(!1),I=n.createElement(n.Fragment,null,n.createElement(pv,null),n.createElement(gv,null,i||l),i&&n.createElement(Ev,{onClick:()=>D(!h),expanded:h},"More Info ",n.createElement("i",{className:"fa fa-chevron-right"})));return i?n.createElement(De.Panel,{header:I,bsStyle:"danger",collapsible:!0,expanded:h},n.createElement("strong",null,"Additional Information: "),l):n.createElement(De.Panel,{header:I,bsStyle:"danger"})};wE.propTypes={fullMessage:a().string.isRequired,niceMessage:a().oneOfType([a().string,a().node])},wE.defaultProps={niceMessage:null};const WE=({buttonContent:l,children:i,className:h,disabled:D,description:I,error:w,loading:K,onSubmit:G,title:oe})=>{const pe=(0,n.useRef)(),[_e,ve]=(0,n.useState)(D),he=Ue=>(Ue.preventDefault(),!1);return(0,n.useEffect)(()=>{ve(K||D)},[K,D]),n.createElement("form",{onSubmit:he,autoComplete:"off",noValidate:!0,className:h,ref:pe},oe&&(typeof oe=="string"?n.createElement("h2",null,oe):oe),I&&(typeof I=="string"?n.createElement("p",null,I):I),w&&w.full_message&&n.createElement(wE,{fullMessage:w.full_message,niceMessage:w.nice_message}),i,n.createElement(De.Button,{type:"button",onClick:_e?null:G,bsStyle:"primary",disabled:_e},K?"Loading...":l))};WE.propTypes={buttonContent:a().oneOfType([a().string,a().node]),children:a().any.isRequired,disabled:a().bool,error:a().shape({full_message:a().string.isRequired,nice_message:a().oneOfType([a().string,a().node])}),description:a().oneOfType([a().string,a().node]),loading:a().bool,onSubmit:a().func,title:a().oneOfType([a().string,a().node]),className:a().string},WE.defaultProps={buttonContent:"Submit",disabled:!1,error:null,description:null,loading:!1,onSubmit:()=>{},title:null,className:void 0};const pv=(0,u.createGlobalStyle)` /* NOTE: This is to remove Bootstrap styles from the anchor element I can't override in Panel.Header */ form { .panel.panel-danger { .panel-heading > a { font-size: 14px; text-decoration: none; color: #ad0707; &:hover { text-decoration: none; } } } } `,gv=u.default.span` display: block; `,Ev=u.default.button` border: 0; background: none; color: #1f1f1f; font-size: 11px; text-transform: uppercase; margin: 12px 0 0; padding: 0; .fa { transform: rotate(${l=>l.expanded?"90deg":"0deg"}); transition: 150ms transform ease-in-out; } `,wi=WE;function NE({value:l,label:i}){return n.createElement("option",{value:l,key:l},i)}const wm=(l=[],i="Choose One",h=!1)=>h?NE({value:"",label:"Loading..."}):n.createElement(n.Fragment,null,n.createElement("option",{value:""},i),l.map(D=>NE({value:D.value,label:D.label})));NE.propTypes={value:a().string.isRequired,label:a().string.isRequired};const Xy=null,fv=l=>l.additional&&l.additional.body&&l.additional.body.message||l.message,Br=(l,i=()=>{},h="GET",D={})=>{const{formData:I}=(0,n.useContext)(Qo),[w,K]=(0,n.useState)(l),[G,oe]=(0,n.useState)(!1),[pe,_e]=(0,n.useState)(null),[ve,he]=(0,n.useState)(null),Ue=w?(0,b.DC)(w):null;return(0,n.useEffect)(()=>{let He=!!Ue;return(async()=>{let Xe=Promise.resolve();return He&&!ve&&(oe(!0),h==="GET"?Xe=(0,le.ZP)(h,Ue):Xe=(0,le.ZP)(h,Ue,av(I,D)),Xe.then(ct=>{_e(null),he(ct),i(ct)}).catch(ct=>{he(null),_e(fv(ct))}).finally(()=>{oe(!1)})),Xe})(),()=>{He=!1}},[Ue]),[{loading:G,error:pe,data:ve},K]},ZE=({className:l,label:i,...h})=>{const[D,I]=(0,n.useState)(!0),w=n.createElement(hv,null,i,n.createElement(vv,{onClick:()=>I(!D),ariaDescription:`Toggle ${i} field input`},n.createElement(rt.JO,{name:D?"eye-slash":"eye"})));return n.createElement(ar,{...h,type:D?"password":"text",label:w,formGroupClassName:l})};ZE.propTypes={label:a().oneOfType([a().string,a().node]).isRequired,className:a().string},ZE.defaultProps={className:void 0};const hv=u.default.span` display: flex; align-items: center; `,vv=u.default.button` border: 0; background: none; padding: 0; margin: 0 0 0 12px; `,yv=ZE,FE=({onChange:l,awsKey:i,awsSecret:h})=>n.createElement(n.Fragment,null,n.createElement(ar,{id:"awsCloudWatchAwsKey",type:"text",label:"AWS Access Key",placeholder:"AK****************",onChange:l,fieldData:i,autoComplete:"off",maxLength:"512",help:'Your AWS Key should be a 20-character long, alphanumeric string that starts with the letters "AK".',required:!0}),n.createElement(_v,{id:"awsCloudWatchAwsSecret",label:"AWS Secret Key",placeholder:"***********",onChange:l,fieldData:h,autoComplete:"off",maxLength:"512",help:"Your AWS Secret is usually a 40-character long, base-64 encoded string.",required:!0})),_v=(0,u.default)(yv)` margin-bottom: 0; `;FE.propTypes={onChange:a().func.isRequired,awsKey:a().object,awsSecret:a().object},FE.defaultProps={awsKey:void 0,awsSecret:void 0};const gh=FE,Eh=u.default.p` font-weight: bold; font-size: 1.2em; margin: 0 0 12px; `,fh=u.default.p` font-style: italic; margin: 3px 0 0; `,Cv=(0,u.default)(De.Table)` margin: 0; `,Tv=()=>n.createElement(Cv,{condensed:!0},n.createElement("thead",null,n.createElement("tr",null,n.createElement("td",{colSpan:"2"},n.createElement(Eh,null,"Automatic authentication will attempt each of the following in the listed order.")))),n.createElement("tbody",null,n.createElement("tr",null,n.createElement("th",null,"Environment variables"),n.createElement("td",null,n.createElement("code",null,"AWS_ACCESS_KEY_ID")," and ",n.createElement("code",null,"AWS_SECRET_ACCESS_KEY"))),n.createElement("tr",null,n.createElement("th",null,"Java system properties"),n.createElement("td",null,n.createElement("code",null,"aws.accessKeyId")," and ",n.createElement("code",null,"aws.secretKey"))),n.createElement("tr",null,n.createElement("th",null,"Default credential profiles file"),n.createElement("td",null,"Typically located at ",n.createElement("code",null,"~/.aws/credentials"))),n.createElement("tr",null,n.createElement("th",null,"Amazon ECS container credentials"),n.createElement("td",null,"Loaded from the Amazon ECS if the environment variable ",n.createElement("code",null,"AWS_CONTAINER_CREDENTIALS_RELATIVE_URI")," is set")),n.createElement("tr",null,n.createElement("th",null,"Instance profile credentials"),n.createElement("td",null,"Used on EC2 instances, and delivered through the Amazon EC2 metadata service"))),n.createElement("tfoot",null,n.createElement("tr",null,n.createElement("td",{colSpan:"2"},n.createElement(fh,null,"For more information, check out the ",n.createElement("a",{href:"https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html",target:"_blank",rel:"noopener noreferrer"},"AWS Credential Configuration Documentation ",n.createElement(rt.JO,{name:"external-link-alt"}))))))),KE=({awsARN:l,onChange:i})=>n.createElement(De.Input,{id:"awsCloudWatchAssumeARN",type:"text",value:l.value,onChange:i,label:"AWS Assume Role (ARN)",help:"Amazon Resource Name with required cross account permission",placeholder:"arn:aws:sts::123456789012:assumed-role/some-role",maxLength:"2048"});KE.propTypes={awsARN:a().shape({value:a().string}),onChange:a().func.isRequired},KE.defaultProps={awsARN:{value:""}};const Sv=KE,Av=u.default.div(({theme:l})=>(0,u.css)` margin: 0 0 21px 9px; padding: 3px 0 3px 21px; border-left: 3px solid ${l.colors.gray[80]}; `),hh=({onChange:l})=>{const{clearField:i,formData:h}=(0,n.useContext)(Qo),{awsAuthenticationType:D,awsCloudWatchAwsSecret:I,awsCloudWatchAwsKey:w,awsCloudWatchAssumeARN:K}=h;let G;o.Z.isCloud()?G=es.keysecret:G=D?D.value:es.automatic;const[oe,pe]=(0,n.useState)(G);(0,n.useEffect)(()=>{l({target:{name:"awsAuthenticationType",value:G}})},[]);const _e=he=>oe===he,ve=he=>{pe(he.target.value),l({target:{name:"awsAuthenticationType",value:he.target.value}}),_e(es.automatic)&&(i("awsCloudWatchAwsKey"),i("awsCloudWatchAwsSecret"))};return n.createElement(n.Fragment,null,o.Z.isCloud()?n.createElement(gh,{awsKey:w,awsSecret:I,onChange:l}):n.createElement(n.Fragment,null,n.createElement(De.Input,{type:"select",name:"awsAuthType",id:"awsAuthType",onChange:ve,label:"AWS Authentication Type",defaultValue:oe},Object.keys(es).map(he=>n.createElement("option",{value:es[he],key:`option-${he}`},es[he]))),n.createElement(Av,null,_e(es.automatic)&&n.createElement(Tv,null),_e(es.keysecret)&&n.createElement(gh,{awsKey:w,awsSecret:I,onChange:l}))),n.createElement(Sv,{awsARN:K,onChange:l}))};hh.propTypes={onChange:a().func.isRequired};const Pv=hh,$E=({children:l,className:i,onToggle:h,title:D,visible:I})=>{const[w,K]=(0,n.useState)(I),G=()=>{K(!w),h(!w)};return n.createElement("div",{className:i},n.createElement(Dv,{bsStyle:"link",bsSize:"xsmall",onClick:G,type:"button"},D," ",n.createElement(rt.JO,{name:w?"angle-down":"angle-right",fixedWidth:!0})),n.createElement(bv,{visible:w},l))};$E.propTypes={children:a().any.isRequired,title:a().string.isRequired,onToggle:a().func,visible:a().bool,className:a().string},$E.defaultProps={onToggle:()=>{},visible:!1,className:void 0};const bv=u.default.div` display: ${l=>l.visible?"block":"none"}; padding: 0 100px 0 25px; `,Dv=(0,u.default)(De.Button)` border: 0; display: block; font-size: 14px; &:hover { text-decoration: underline; } `,GE=$E,Wm="https://(.*)",Nm="Domain should begin with 'https://'",Zm="https://vpce-1234.service.region.vpce.amazonaws.com",Ov=(0,u.default)(GE)` margin: 0 0 35px; `,Rv=(0,u.default)(Eh)` margin: 12px 0 0; `,Iv=(0,u.default)(fh)` margin: 0 0 12px; `,vh=({onChange:l})=>{const{formData:i}=(0,n.useContext)(Qo),{isAWSCustomEndpointsVisible:h,setAWSCustomEndpointsVisibility:D}=(0,n.useContext)(iu),{awsEndpointCloudWatch:I,awsEndpointDynamoDB:w,awsEndpointIAM:K,awsEndpointKinesis:G}=i,oe=pe=>{D(pe)};return n.createElement(Ov,{title:"Optional AWS VPC Endpoints",visible:h,onToggle:oe},n.createElement(Rv,null,"Overrides the default AWS API endpoint URL that Graylog communicates with."),n.createElement(Iv,null,"Only specify these if you are using ",n.createElement(rt.dL,{href:"https://docs.aws.amazon.com/vpc/latest/userguide/vpc-endpoints.html"},"VPC Endpoints")," for AWS services."),n.createElement(ar,{id:"awsEndpointCloudWatch",type:"text",fieldData:I,onChange:l,label:"CloudWatch API Endpoint Override",placeholder:Zm,pattern:Wm,title:Nm}),n.createElement(ar,{id:"awsEndpointIAM",type:"text",fieldData:K,onChange:l,label:"IAM API Endpoint Override",placeholder:Zm,pattern:Wm,title:Nm}),n.createElement(ar,{id:"awsEndpointDynamoDB",type:"text",fieldData:w,onChange:l,label:"DynamoDB API Endpoint Override",placeholder:Zm,pattern:Wm,title:Nm}),n.createElement(ar,{id:"awsEndpointKinesis",type:"text",fieldData:G,onChange:l,label:"Kinesis API Endpoint Override",placeholder:Zm,pattern:Wm,title:Nm}))};vh.propTypes={onChange:a().func.isRequired};const Mv=vh,jE=({onChange:l,onSubmit:i,sidebarComponent:h})=>{const{formData:D}=(0,n.useContext)(Qo),{clearSidebar:I,setSidebar:w}=(0,n.useContext)(Io),{availableRegions:K,setRegions:G,setStreams:oe}=(0,n.useContext)(sa),[pe,_e]=(0,n.useState)(null),[ve]=Br(on.INTEGRATIONS.AWS.REGIONS,G,"GET"),[he,Ue]=Br(null,ct=>{oe(ct),i()},"POST",{region:D.awsCloudWatchAwsRegion?D.awsCloudWatchAwsRegion.value:""});(0,n.useEffect)(()=>{if(Ue(null),ve.error)_e({full_message:ve.error});else if(he.error){const ct=/security token/g,Nt=/signing method/g,kt=/No Kinesis streams/g;he.error.match(ct)?_e({full_message:he.error,nice_message:'Invalid AWS Key, check out your AWS account for the 20-character long, alphanumeric string that usually starts with the letters "AK"'}):he.error.match(Nt)?_e({full_message:he.error,nice_message:"Invalid AWS Secret, it is usually a 40-character long, base-64 encoded string, but you only get to view it once when you create the Key"}):he.error.match(kt)?(oe({streams:[]}),i()):_e({full_message:he.error})}return()=>{_e(null)}},[ve.error,he.error]);const He=()=>{Ue(on.INTEGRATIONS.AWS.KINESIS.STREAMS)};(0,n.useEffect)(()=>(h&&w(h),()=>{I()}),[]);const at=D.awsAuthenticationType&&D.awsAuthenticationType.value,Xe=Um.isFormValid(["awsCloudWatchName","awsCloudWatchAwsRegion",...at!==es.automatic?["awsCloudWatchAwsKey","awsCloudWatchAwsSecret"]:[]],D);return n.createElement(wi,{onSubmit:He,buttonContent:"Authorize & Choose Stream",loading:ve.loading||he.loading,disabled:Xe,error:pe,title:"Create Input & Authorize AWS",description:"This integration allows Graylog to read messages directly from a Kinesis stream. CloudWatch messages can optionally be forwarded to Kinesis via CloudWatch subscriptions and then read by Graylog."},n.createElement(yh,{id:"name",type:"text"}),n.createElement(yh,{id:"password",type:"password"}),n.createElement(ar,{id:"awsCloudWatchName",type:"text",fieldData:D.awsCloudWatchName,onChange:l,placeholder:"Graylog Input Name",label:"Graylog Input Name",autoComplete:"off",required:!0}),n.createElement(Pv,{onChange:l}),n.createElement(ar,{id:"awsCloudWatchAwsRegion",type:"select",fieldData:D.awsCloudWatchAwsRegion,onChange:l,label:"AWS Region",help:"The AWS Region your service is running in.",disabled:ve.loading,required:!0},wm(K,"Choose AWS Region",ve.loading)),n.createElement(Mv,{onChange:l}))};jE.propTypes={onSubmit:a().func.isRequired,onChange:a().func.isRequired,sidebarComponent:a().node},jE.defaultProps={sidebarComponent:null};const yh=u.default.input` position: fixed; top: -500vh; left: -500vw; `,xv=jE;var _h=e("7dh0vSOR");const Ch=({onChange:l})=>{const{formData:i}=(0,n.useContext)(Qo),{isAdvancedOptionsVisible:h,setAdvancedOptionsVisibility:D}=(0,n.useContext)(iu),{awsCloudWatchBatchSize:I,awsCloudWatchThrottleEnabled:w,awsCloudWatchAddFlowLogPrefix:K}=i,G=oe=>{D(oe)};return n.createElement(Lv,{title:"Advanced Options",visible:h,onToggle:G},n.createElement(De.Input,{id:"awsCloudWatchThrottleEnabled",type:"checkbox",value:"enable-throttling",defaultChecked:w&&w.value,onChange:l,label:"Enable Throttling",help:"If enabled, no new messages will be read from this input until Graylog catches up with its message load. This is typically useful for inputs reading from files or message queue systems like AMQP or Kafka. If you regularly poll an external system, e.g. via HTTP, you normally want to leave this disabled."}),n.createElement(De.Input,{id:"awsCloudWatchAddFlowLogPrefix",type:"checkbox",value:"enable-logprefix",defaultChecked:K&&K.value,onChange:l,label:"Add Flow Log field name prefix",help:'Add field with the Flow Log prefix e. g. "src_addr" -> "flow_log_src_addr".'}),n.createElement(De.Input,{id:"awsCloudWatchBatchSize",type:"number",value:I.value||I.defaultValue,onChange:l,label:"Kinesis Record batch size",help:"The number of Kinesis records to fetch at a time. Each record may be up to 1MB in size. The AWS default is 10,000. Enter a smaller value to process smaller chunks at a time."}))};Ch.propTypes={onChange:a().func.isRequired};const Lv=(0,u.default)(GE)` margin: 0 0 35px; `,Bv=Ch,zE=({onChange:l,onSubmit:i,toggleSetup:h})=>{const{formData:D}=(0,n.useContext)(Qo),[I,w]=(0,n.useState)(null),{availableStreams:K,setLogData:G}=(0,n.useContext)(sa),{clearSidebar:oe,setSidebar:pe}=(0,n.useContext)(Io),[_e,ve]=Br(null,Ue=>{G(Ue),i()},"POST",{region:D.awsCloudWatchAwsRegion.value,stream_name:D.awsCloudWatchKinesisStream?D.awsCloudWatchKinesisStream.value:""});(0,n.useEffect)(()=>{pe(n.createElement(De.Panel,{bsStyle:"info",header:n.createElement("span",null,"Don't see the stream you need?")},n.createElement(Uv,null,n.createElement("p",null,"At least one Kinesis stream must exist in the specified region in order to continue with the setup. The log stream must contain at least a few log messages."),n.createElement("p",null,"Graylog also supports the ability to create a Kinesis stream for you and subscribe it to a CloudWatch log group of your choice. Please be aware that this option will create additional resources in your AWS environment that will incur billing charges.")),n.createElement(De.Button,{onClick:()=>{oe(),h()},type:"button"},"Setup Kinesis Automatically")))},[]),(0,n.useEffect)(()=>{_e.error&&(ve(null),w({full_message:_e.error,nice_message:n.createElement("span",null,"We were unable to find any logs in this Kinesis stream. Please select a different Kinesis stream.")}))},[_e.error]);const he=()=>{ve(on.INTEGRATIONS.AWS.KINESIS.HEALTH_CHECK)};return n.createElement(n.Fragment,null,n.createElement(wv,{show:_e.loading,backdrop:"static",keyboard:!1,bsSize:"small"},n.createElement(Wv,null,n.createElement("i",{className:"fa fa-spin fa-spinner"}),n.createElement(Nv,null,"This request may take a few moments."))),n.createElement(wi,{onSubmit:he,buttonContent:"Verify Stream & Format",loading:_e.loading,error:I,disabled:Um.isFormValid(["awsCloudWatchKinesisStream"],D),title:"Select Kinesis Stream",description:n.createElement(n.Fragment,null,n.createElement("p",null,"Below is a list of all Kinesis streams found within the specified AWS account."),n.createElement("p",null,"Please select the stream you would like to read messages from, or follow the\xA0",n.createElement(_h.Z,{page:so.INTEGRATIONS.AWS.AWS_KINESIS_CLOUDWATCH_INPUTS,text:"AWS Kinesis/CloudWatch Input "}),"documentation for more details on this set up."))},n.createElement(ar,{id:"awsCloudWatchKinesisStream",type:"select",fieldData:D.awsCloudWatchKinesisStream,onChange:l,label:"Select Stream",required:!0},wm(K,"Select Kinesis Stream")),n.createElement(Bv,{onChange:l})))};zE.propTypes={onSubmit:a().func.isRequired,onChange:a().func.isRequired,toggleSetup:a().func},zE.defaultProps={toggleSetup:()=>{}};const Uv=u.default.div` margin-bottom: 9px; `,wv=(0,u.default)(De.Modal)` > .modal-dialog { width: 400px; margin-left: auto; margin-right: auto; } `,Wv=(0,u.default)(De.Modal.Body)` text-align: center; i.fa { font-size: 48px; color: #702785; } `,Nv=u.default.p` font-size: 16px; font-weight: bold; padding-top: 15px; color: #a6afbd; `,Zv=zE,Th=({groupName:l,streamName:i})=>n.createElement(n.Fragment,null,n.createElement("p",null,"This auto setup will create the following AWS resources. Click below to acknowledge that you understand that these resources will be created and that you are solely responsible for any associated AWS fees incurred from them. Note that all resources must be manually deleted by you if they are not needed."),n.createElement("ol",null,n.createElement("li",null,"Create a Kinesis stream with ",n.createElement("strong",null,"1")," shard."),n.createElement("li",null,"Create an IAM Role and Policy to allow the specified CloudWatch group ",n.createElement("strong",null,l)," to publish log messages to the Kinesis stream ",n.createElement("strong",null,i)),n.createElement("li",null,"Create a CloudWatch Subscription, which publishes log messages to the Kinesis stream.")));Th.propTypes={groupName:a().string.isRequired,streamName:a().string.isRequired};const Fv=Th,Sh=({label:l,progress:i})=>{const{data:h,error:D,loading:I}=i,K=I?`Creating ${l}`:!h&&!I&&!D&&"Waiting...",G=h?h.result:K,oe=D||G;return n.createElement(Kv,null,n.createElement($v,null,!h&&!I&&!D&&n.createElement("i",{className:"fa fa-hourglass-start fa-2x",style:{color:"#dce1e5"}}),I&&n.createElement("i",{className:"fa fa-spinner fa-2x fa-spin",style:{color:"#0063be"}}),h&&n.createElement("i",{className:"fa fa-check fa-2x",style:{color:"#00ae42"}}),D&&n.createElement("i",{className:"fa fa-times fa-2x",style:{color:"#ad0707"}})),n.createElement(Gv,null,n.createElement(jv,null,"Create ",l),n.createElement(zv,null,oe)))};Sh.propTypes={progress:a().shape({data:a().object,error:a().object,loading:a().bool}).isRequired,label:a().string.isRequired};const Kv=u.default.li` display: flex; margin: 0 0 12px; `,$v=u.default.div` min-width: 36px; `,Gv=u.default.div` flex-grow: 1; `,jv=u.default.span` font-size: 18px; `,zv=u.default.p` margin: 3px 0 0; `,VE=Sh,Ah=({onSuccess:l,onError:i})=>{const{formData:h}=(0,n.useContext)(Qo),[D,I]=(0,n.useState)(null),[w,K]=(0,n.useState)(null),[G,oe]=Br(null,()=>{l()},"POST",{region:h.awsCloudWatchAwsRegion.value,log_group_name:h.awsCloudWatchAwsGroupName.value,filter_name:"filter-name",filter_pattern:"",destination_stream_arn:D,role_arn:w}),[pe,_e]=Br(null,Ue=>{K(Ue.role_arn),oe(on.INTEGRATIONS.AWS.KINESIS_AUTO_SETUP.CREATE_SUBSCRIPTION)},"POST",{region:h.awsCloudWatchAwsRegion.value,stream_name:h.awsCloudWatchKinesisStream.value,stream_arn:D}),[ve,he]=Br(null,Ue=>{I(Ue.stream_arn),_e(on.INTEGRATIONS.AWS.KINESIS_AUTO_SETUP.CREATE_SUBSCRIPTION_POLICY)},"POST",{region:h.awsCloudWatchAwsRegion.value,stream_name:h.awsCloudWatchKinesisStream.value});return(0,n.useEffect)(()=>{he(on.INTEGRATIONS.AWS.KINESIS_AUTO_SETUP.CREATE_STREAM)},[]),(0,n.useEffect)(()=>{(ve.error||pe.error||G.error)&&i()},[ve.error,pe.error,G.error]),n.createElement(Vv,null,n.createElement(VE,{label:"Kinesis Stream",progress:ve}),n.createElement(VE,{label:"Subscription Policy",progress:pe}),n.createElement(VE,{label:"Subscription",progress:G}))};Ah.propTypes={onSuccess:a().func.isRequired,onError:a().func.isRequired};const Vv=u.default.ul` list-style: none; margin: 0; padding: 0; `,Hv=Ah,Ph=({onSubmit:l,onCancel:i,groupName:h,streamName:D})=>{const[I,w]=(0,n.useState)(!1),[K,G]=(0,n.useState)(!1),[oe,pe]=(0,n.useState)(!1),ve=K?"Continue Setup":!oe&&!K?"Creating...":"Close",he=()=>{G(!0),pe(!1)},Ue=()=>{G(!1),pe(!0)};return n.createElement(De.Modal,{show:!0},n.createElement(De.Modal.Header,null,n.createElement(De.Modal.Title,null,I?"Executing Auto-Setup":"Kinesis Auto Setup Agreement")),n.createElement(De.Modal.Body,null,I?n.createElement(Hv,{onSuccess:he,onError:Ue}):n.createElement(Fv,{groupName:h,streamName:D}),I&&K&&n.createElement(De.Alert,{key:"delayedLogs",variant:"warning"},"It may take up to ten minutes for the first messages to arrive in the Kinesis stream. The Kinesis Health Check in the following step will not complete successfully until messages are present in the stream. Please see the official ",n.createElement("a",{href:"https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/Subscriptions.html",target:"_blank",rel:"noopener noreferrer"},"CloudWatch Subscriptions")," documentation for more information.")),n.createElement(De.Modal.Footer,null,I?n.createElement(De.Button,{bsStyle:"success",onClick:K?l:i,type:"button",disabled:!oe&&!K},ve):n.createElement(n.Fragment,null,n.createElement(De.Button,{onClick:i,type:"button"},"Cancel"),n.createElement(De.Button,{onClick:()=>w(!0),type:"button",bsStyle:"success"},"I Agree! Create these AWS resources now."))))};Ph.propTypes={onSubmit:a().func.isRequired,onCancel:a().func.isRequired,groupName:a().string.isRequired,streamName:a().string.isRequired};const kv=Ph,HE=({onChange:l,onSubmit:i,toggleSetup:h})=>{const{availableGroups:D,setGroups:I,clearLogData:w}=(0,n.useContext)(sa),{formData:K}=(0,n.useContext)(Qo),[G,oe]=(0,n.useState)(null),[pe,_e]=(0,n.useState)(!1),[ve,he]=(0,n.useState)(!1),[Ue,He]=(0,n.useState)(!1),[at,Xe]=Br(on.INTEGRATIONS.AWS.CLOUDWATCH.GROUPS,Ft=>{I(Ft)},"POST",{region:K.awsCloudWatchAwsRegion.value});(0,n.useEffect)(()=>{if(at.error){Xe(null);const Ft=/No CloudWatch log groups/g;at.error.match(Ft)?(oe({full_message:at.error,nice_message:n.createElement("span",null,"We're unable to find any groups in your chosen region. Please try selecting a different region.")}),he(!0)):oe({full_message:at.error})}return()=>{I({log_groups:[]})}},[at.error]);const ct=()=>{w(),i()},Nt=()=>{_e(!0),He(!0)},kt=()=>{_e(!1),He(!1)};return n.createElement(wi,{onSubmit:Nt,buttonContent:"Begin Automated Setup",disabled:Um.isFormValid(["awsCloudWatchKinesisStream","awsCloudWatchAwsGroupName"],K)||pe,loading:at.loading,error:G,title:"Set Up Kinesis Automatically",description:""},n.createElement("p",null,"Complete the fields below and Graylog will perform the automated Kinesis setup, which performs the following operations within your AWS account. See ",n.createElement("a",{target:"_blank",rel:"noopener noreferrer",href:"https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/SubscriptionFilters.html"},"Using CloudWatch Logs Subscription Filters")," in the AWS documentation for more information."),n.createElement("ol",null,n.createElement("li",null,"Create a new Kinesis stream with the specified name."),n.createElement("li",null,"Create the IAM role/policy needed to subscribe the Kinesis stream to the CloudWatch Log Group."),n.createElement("li",null,"Subscribe the new Kinesis stream to the Log Group.")),n.createElement(ar,{id:"awsCloudWatchKinesisStream",type:"text",label:"Kinesis Stream Name",placeholder:"Stream Name",onChange:l,fieldData:K.awsCloudWatchKinesisStream,disabled:pe,pattern:"[a-zA-Z0-9_.-]{1,128}$",help:"1-128 alphanumeric characters and special characters underscore (_), period (.), and hyphen (-).",required:!0}),n.createElement(ar,{id:"awsCloudWatchAwsGroupName",type:"select",fieldData:K.awsCloudWatchAwsGroupName,onChange:l,label:"CloudWatch Group Name",required:!0,disabled:at.loading||ve||pe},wm(D,"Choose CloudWatch Group",at.loading)),h&&n.createElement(Qv,{onClick:h,type:"button",disabled:pe},"Back to stream Selection"),Ue&&n.createElement(kv,{onSubmit:ct,onCancel:kt,groupName:K.awsCloudWatchAwsGroupName.value,streamName:K.awsCloudWatchKinesisStream.value}))};HE.propTypes={onSubmit:a().func.isRequired,onChange:a().func.isRequired,toggleSetup:a().func},HE.defaultProps={toggleSetup:null};const Qv=(0,u.default)(De.Button)` margin-right: 9px; `,Xv=HE,kE=({hasStreams:l,...i})=>{const[h,D]=(0,n.useState)(l);return n.createElement(n.Fragment,null,h?n.createElement(Zv,{...i,toggleSetup:()=>D(!1)}):n.createElement(Xv,{...i,toggleSetup:l?()=>D(!0):null}))};kE.propTypes={hasStreams:a().bool,onChange:a().func.isRequired,onSubmit:a().func.isRequired},kE.defaultProps={hasStreams:!1};const Jv=kE,bh=({onChange:l,onSubmit:i})=>{const{formData:h}=(0,n.useContext)(Qo);return n.createElement(GE,{title:"Skip Health Check"},n.createElement(Yv,{onSubmit:i,buttonContent:"Confirm",title:"Choose Log Type & Skip Health Check",disabled:!(h.awsCloudWatchKinesisInputType&&h.awsCloudWatchKinesisInputType.value),description:n.createElement("p",null,"If you're sure of the data contained within your new ",n.createElement("strong",null,h.awsCloudWatchKinesisStream.value)," stream, then choose your option below to skip our automated check.")},n.createElement(ar,{id:"awsCloudWatchKinesisInputType",type:"select",fieldData:h.awsCloudWatchKinesisInputType,onChange:l,label:"Choose AWS Input Type",required:!0},wm(Cr,"Choose Log Type"))))};bh.propTypes={onSubmit:a().func.isRequired,onChange:a().func.isRequired};const Yv=(0,u.default)(wi)` padding-top: 25px; `,qv=bh;function QE({callback:l,className:i,timeInSeconds:h,paused:D}){let I=h,w;const K=(0,Rt.duration)(h,"seconds").format("mm:ss"),[G,oe]=(0,n.useState)(K),pe=()=>{w=setInterval(()=>{I-=1;const _e=(0,Rt.duration)(I,"seconds").format("mm:ss",{trim:!1});I<0?(I=h,oe(K),clearInterval(w),l()):oe(_e)},1e3)};return(0,n.useEffect)(()=>(D?clearInterval(w):pe(),()=>{clearInterval(w)}),[D]),n.createElement("span",{className:i},G)}QE.propTypes={timeInSeconds:a().number.isRequired,callback:a().func,className:a().string,paused:a().bool},QE.defaultProps={callback:()=>{},className:"",paused:!1};const ey=QE,Dh=({onChange:l,onSubmit:i})=>{const{logData:h,setLogData:D}=(0,n.useContext)(sa),{formData:I}=(0,n.useContext)(Qo),[w,K]=(0,n.useState)(!1),[G,oe]=Br(null,ct=>{D(ct),l({target:{name:"awsCloudWatchKinesisInputType",value:ct.type}})},"POST",{region:I.awsCloudWatchAwsRegion.value,stream_name:I.awsCloudWatchKinesisStream.value}),pe=()=>{K(!0),oe(on.INTEGRATIONS.AWS.KINESIS.HEALTH_CHECK)};if((0,n.useEffect)(()=>{h||pe()},[]),(0,n.useEffect)(()=>{!G.loading&&!G.data&&(K(!1),oe(null))},[G.loading]),!h)return n.createElement(De.Panel,{bsStyle:"warning",header:n.createElement(Oh,null,n.createElement("i",{className:"fa fa-exclamation-triangle fa-2x"}),n.createElement("span",null,"We haven't received a response back from Amazon yet."))},n.createElement("p",null,"Hang out for a few moments while we keep checking your AWS stream for logs. Amazon's servers parse logs every 10 minutes, so grab a cup of coffee because this may take some time!"),n.createElement(ty,null,n.createElement("strong",null,"Checking again in: ",n.createElement(ey,{timeInSeconds:120,callback:pe,paused:w})),n.createElement(De.Button,{type:"button",bsStyle:"success",bsSize:"sm",onClick:pe,disabled:G.loading},G.loading?"Checking...":"Check Now")),n.createElement("p",null,n.createElement("em",null,"Do not refresh your browser, we are continually checking for your logs and this page will automatically refresh when your logs are available.")),n.createElement("div",null,n.createElement(qv,{onSubmit:i,onChange:l})));const _e=h.type===Ui,ve=_e?"check":"exclamation-triangle",he=_e?"Awesome!":"Drats!",Ue=_e?"success":"warning",He=Cr.find(ct=>ct.value===h.type).label,at=_e?`a ${He}`:"an unknown",Xe=()=>{i(),l({target:{name:"awsCloudWatchKinesisInputType",value:h.type}})};return n.createElement(wi,{onSubmit:Xe,buttonContent:"Review & Finalize",disabled:!1,title:"Create Kinesis Stream",description:n.createElement("p",null,"We are going to attempt to parse a single log to help you out! If we are unable to, or you would like it parsed differently, head on over to ",n.createElement("a",{href:"/system/pipelines"},"Pipeline Rules")," to set up your own parser!")},n.createElement(De.Panel,{bsStyle:Ue,header:n.createElement(Oh,null,n.createElement("i",{className:`fa fa-${ve} fa-2x`}),n.createElement("span",null,he," looks like ",n.createElement("em",null,at)," message type."))},_e?"Take a look at what we have parsed so far and you can create Pipeline Rules to handle even more!":"Not to worry, Graylog can still read in these log messages. We have parsed what we could and you can build Pipeline Rules to do the rest!"),n.createElement(De.Input,{id:"awsCloudWatchLog",type:"textarea",label:"Formatted Log Message",value:h.message,rows:10,disabled:!0}))};Dh.propTypes={onSubmit:a().func.isRequired,onChange:a().func.isRequired};const Oh=u.default.span` display: flex; align-items: center; > span { margin-left: 6px; } `,ty=u.default.p` display: flex; align-items: center; > strong { margin-right: 9px; } `,ny=Dh,Rh=({value:l})=>n.createElement(n.Fragment,null,l," ",n.createElement("small",null,"(default)"));Rh.propTypes={value:a().string.isRequired};const XE=({onSubmit:l,onEditClick:i,externalInputSubmit:h})=>{const[D,I]=(0,n.useState)(null),{formData:w}=(0,n.useContext)(Qo),{logData:K}=(0,n.useContext)(sa),{awsAuthenticationType:G,awsCloudWatchAddFlowLogPrefix:oe={value:void 0},awsCloudWatchAssumeARN:pe={value:void 0},awsCloudWatchAwsKey:_e={value:void 0},awsCloudWatchAwsRegion:ve,awsCloudWatchBatchSize:he,awsEndpointCloudWatch:Ue={value:void 0},awsCloudWatchKinesisInputType:He={value:Ui},awsCloudWatchKinesisStream:at,awsCloudWatchName:Xe,awsCloudWatchThrottleEnabled:ct={value:void 0},awsEndpointDynamoDB:Nt={value:void 0},awsEndpointIAM:kt={value:void 0},awsEndpointKinesis:Ft={value:void 0}}=w,an=!!ct.value,$n=!!oe.value,[_n,ln]=Br(null,()=>{l()},"POST",{name:Xe.value,region:ve.value,aws_input_type:He.value,stream_name:at.value,batch_size:Number(he.value||he.defaultValue),enable_throttling:an,add_flow_log_prefix:$n});(0,n.useEffect)(()=>{_n.error&&I({full_message:_n.error,nice_message:n.createElement("span",null,"We were unable to save your Input, please try again in a few moments.")})},[_n.error]);const Qn=()=>{if(h){l(w);return}ln(on.INTEGRATIONS.AWS.KINESIS.SAVE)};return n.createElement(wi,{onSubmit:Qn,buttonContent:"Complete CloudWatch Setup",loading:_n.loading,error:D,title:"Final Review",description:"Check out everything below to make sure it's correct, then click the button below to complete your CloudWatch setup!"},n.createElement(oy,null,n.createElement(JE,null,"Setting up CloudWatch ",n.createElement("small",null,n.createElement(Ih,{onClick:i("authorize")},"Edit"))),n.createElement(YE,null,n.createElement("li",null,n.createElement("strong",null,"Name"),n.createElement("span",null,Xe.value)),n.createElement("li",null,n.createElement("strong",null,"Authorization Type"),n.createElement("span",null,G.value)),_e.value&&n.createElement("li",null,n.createElement("strong",null,"AWS Key"),n.createElement("span",null,_e.value)),pe.value&&n.createElement("li",null,n.createElement("strong",null,"AWS Assumed ARN Role"),n.createElement("span",null,pe.value)),Ue.value&&n.createElement("li",null,n.createElement("strong",null,"CloudWatch VPC Endpoint"),n.createElement("span",null,Ue.value)),Nt.value&&n.createElement("li",null,n.createElement("strong",null,"DynamoDB VPC Endpoint"),n.createElement("span",null,Nt.value)),kt.value&&n.createElement("li",null,n.createElement("strong",null,"IAM VPC Endpoint"),n.createElement("span",null,kt.value)),Ft.value&&n.createElement("li",null,n.createElement("strong",null,"Kinesis VPC Endpoint"),n.createElement("span",null,Ft.value)),n.createElement("li",null,n.createElement("strong",null,"AWS Region"),n.createElement("span",null,ve.value))),n.createElement(JE,null,"Setting up Kinesis ",n.createElement("small",null,n.createElement(Ih,{onClick:i("kinesis-setup")},"Edit"))),n.createElement(YE,null,n.createElement("li",null,n.createElement("strong",null,"Stream"),n.createElement("span",null,at.value)),n.createElement("li",null,n.createElement("strong",null,"Global Input"),n.createElement("span",null,n.createElement(rt.JO,{name:"check"}))),n.createElement("li",null,n.createElement("strong",null,"Record Batch Size"),n.createElement("span",null,he.value?he.value:n.createElement(Rh,{value:he.defaultValue}))),n.createElement("li",null,n.createElement("strong",null,"Enable Throttling"),n.createElement("span",null,n.createElement(rt.JO,{name:an?"check":"times"}))),n.createElement("li",null,n.createElement("strong",null,"Add Flow Log prefix to field names"),n.createElement("span",null,n.createElement(rt.JO,{name:$n?"check":"times"})))),n.createElement(JE,null,"Formatting"),n.createElement(YE,null,n.createElement("li",null,n.createElement("strong",null,"Log Type"),n.createElement("span",null,Cr.find(Ur=>Ur.value===He.value).label))),n.createElement("p",null,"If you need your logs parsed differently check out our ",n.createElement(Wc.r,{to:Pe.ZP.SYSTEM.PIPELINES.RULES},"Pipeline Rule")," for additional details and instructions."),n.createElement(De.Input,{id:"awsCloudWatchLog",type:"textarea",label:"",value:K&&K.message||"We haven't received a response back from Amazon yet.",rows:10,disabled:!0})))};XE.propTypes={onSubmit:a().func.isRequired,onEditClick:a().func.isRequired,externalInputSubmit:a().bool},XE.defaultProps={externalInputSubmit:!1};const oy=u.default.div` border: 1px solid #a6afbd; margin: 25px 0; padding: 15px; border-radius: 4px; `,JE=u.default.h3` margin: 0 0 10px; `,YE=u.default.ul` list-style: none; margin: 0 0 25px 10px; padding: 0; li { padding: 5px; &:nth-of-type(odd) { background-color: rgb(220 225 229 / 40%); } } strong::after { content: ':'; margin-right: 5px; } `,Ih=u.default.a` font-size: 12px; margin-left: 5px; font-style: italic; cursor: pointer; &::before { content: '('; } &::after { content: ')'; } `,sy=XE;function qE({title:l,note:i,policy:h}){const[D,I]=(0,n.useState)(!1),w=()=>{I(!D)};return n.createElement("div",null,n.createElement(ay,{onClick:w},n.createElement(ly,null,n.createElement(uy,null,D?"Hide":"Show"," ",l),n.createElement(dy,null,i)),n.createElement(iy,{opened:D},n.createElement("i",{className:"fa fa-chevron-right fa-2x"}))),n.createElement(cy,{opened:D},JSON.stringify(h,null,2)))}qE.propTypes={title:a().string.isRequired,note:a().string.isRequired,policy:a().object.isRequired};function ry(){const[l]=Br(on.INTEGRATIONS.AWS.PERMISSIONS);return n.createElement(De.Panel,{bsStyle:"info",header:n.createElement("span",null,"AWS Policy Permissions")},n.createElement("p",null,"Please verify that you have granted your AWS IAM user sufficient permissions. You can use the following policies for reference."),!l.loading&&l.data&&n.createElement(n.Fragment,null,n.createElement(qE,{title:"Recommended Policy",note:"To be able to use all available functionality for Kinesis setup.",policy:JSON.parse(l.data.setup_policy)}),n.createElement(qE,{title:"Least Privilege Policy",note:"Doesn't include Kinesis auto-subscription controls.",policy:JSON.parse(l.data.auto_setup_policy)})))}const ay=u.default.header` display: flex; align-items: center; cursor: pointer; `,ly=u.default.div` flex-grow: 1; `,iy=u.default.span` transform: rotate(${l=>l.opened?"90deg":"0deg"}); transition: transform 150ms ease-in-out; `,cy=u.default.pre` overflow: hidden; max-height: ${l=>l.opened?"1000px":"0"}; opacity: ${l=>l.opened?"1":"0"}; transition: max-height 150ms ease-in-out, opacity 150ms ease-in-out, margin 150ms ease-in-out, padding 150ms ease-in-out; margin-bottom: ${l=>l.opened?"12px":"0"}; padding: ${l=>l.opened?"9.5px":"0"}; `,uy=u.default.h4` font-weight: bold; `,dy=u.default.p` font-style: italic; `,ef=({externalInputSubmit:l,onSubmit:i})=>{const{availableSteps:h,currentStep:D,isDisabledStep:I,setAvailableStep:w,setCurrentStep:K,setEnabledStep:G}=(0,n.useContext)(lu),{setFormData:oe}=(0,n.useContext)(Qo),{availableStreams:pe}=(0,n.useContext)(sa),{sidebar:_e,clearSidebar:ve}=(0,n.useContext)(Io),[he,Ue]=(0,n.useState)(!1),[He,at]=(0,n.useState)(!1),Xe=(0,ou.useNavigate)(),ct=kt=>{K(kt)},Nt=(0,n.useMemo)(()=>{const kt=$n=>()=>{K($n)},Ft=({target:$n},_n)=>{const ln=$n.name||$n.id;let Qn=(0,ke.n6)($n);typeof Qn=="string"&&(Qn=Qn.trim()),he||Ue(!0),oe(ln,{..._n,value:Qn})},an=$n=>{ve();const _n=h.indexOf(D)+1;if(h[_n]){const ln=h[_n];K(ln),G(ln)}else at(!0),l?i($n):Xe(Pe.ZP.SYSTEM.INPUTS)};return[{key:"authorize",title:"AWS Kinesis Authorize",component:n.createElement(xv,{onSubmit:an,onChange:Ft,sidebarComponent:n.createElement(ry,null)}),disabled:I("authorize")},{key:"kinesis-setup",title:"AWS Kinesis Setup",component:n.createElement(Jv,{onSubmit:an,onChange:Ft,hasStreams:pe.length>0}),disabled:I("kinesis-setup")},{key:"health-check",title:"AWS CloudWatch Health Check",component:n.createElement(ny,{onSubmit:an,onChange:Ft}),disabled:I("health-check")},{key:"review",title:"AWS Kinesis Review",component:n.createElement(sy,{onSubmit:an,onEditClick:kt,externalInputSubmit:l}),disabled:I("review")}]},[I,pe.length,l,K,he,oe,ve,h,D,G,i,Xe]);return(0,n.useEffect)(()=>{h.length===0&&w(Nt.map(kt=>kt.key))},[h,w,Nt]),n.createElement(n.Fragment,null,he&&!He&&n.createElement(iv.Z,{question:"Are you sure? Your new Input will not be created."}),n.createElement(cv.Z,{steps:Nt,activeStep:D,onStepChange:ct,horizontal:!0,justified:!0,hidePreviousNextButtons:!0},_e))};ef.propTypes={externalInputSubmit:a().bool,onSubmit:a().func},ef.defaultProps={externalInputSubmit:!1,onSubmit:void 0};const my=ef,py={awsCloudWatchBatchSize:{defaultValue:"10000"},awsCloudWatchThrottleEnabled:{value:!0},awsCloudWatchAddFlowLogPrefix:{value:!0}},tf=({onSubmit:l})=>{const i=h=>{l&&l(lv(h))};return n.createElement(Bm,null,n.createElement(Bi,null,n.createElement(ba,{initialFormData:py},n.createElement(rr,null,n.createElement(io,null,n.createElement(my,{onSubmit:i,externalInputSubmit:typeof l=="function"}))))))};tf.propTypes={onSubmit:a().func},tf.defaultProps={onSubmit:void 0};const Mh=tf,xh=()=>n.createElement(n.Fragment,null,n.createElement(ro.Z,{title:"AWS Integrations"},n.createElement("span",null,"This feature retrieves log messages from various AWS sources.")),n.createElement(Mh,null));xh.propTypes={};const gy=xh,Lh=({notification:l})=>{var i,h,D,I,w;return n.createElement(n.Fragment,null,n.createElement(rt.mv,{label:"Routing Key",value:(i=l.config)==null?void 0:i.routing_key}),n.createElement(rt.mv,{label:"Custom Incident",value:(h=l.config)==null?void 0:h.custom_incident}),n.createElement(rt.mv,{label:"Key Prefix",value:(D=l.config)==null?void 0:D.key_prefix}),n.createElement(rt.mv,{label:"Client Name",value:(I=l.config)==null?void 0:I.client_name}),n.createElement(rt.mv,{label:"Client URL",value:(w=l.config)==null?void 0:w.client_url}))};Lh.propTypes={notification:a().shape({config:a().shape({routing_key:a().string,custom_incident:a().bool,key_prefix:a().string,client_name:a().string,client_url:a().string}).isRequired}).isRequired};const Ey=Lh;var fy=e("IW7priiX"),Fm=e.n(fy),hy=Object.defineProperty,vy=(l,i,h)=>i in l?hy(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,Km=(l,i,h)=>(vy(l,typeof i!="symbol"?i+"":i,h),h);class nf extends n.Component{constructor(){super(...arguments),Km(this,"propagateChange",(i,h)=>{const{config:D,onChange:I}=this.props,w=Fm()(D);w[i]=h,I(w)}),Km(this,"handleChange",i=>{const{name:h}=i.target;this.propagateChange(h,(0,ke.n6)(i.target))})}render(){const{config:i,validation:h}=this.props;return n.createElement(n.Fragment,null,n.createElement(De.Input,{id:"pagerduty-notification-v2-routing_key",name:"routing_key",label:"Routing Key",type:"text",bsStyle:h.errors.routing_key?"error":null,help:Fe()(h,"errors.routing_key[0]","The Pager Duty integration Routing Key."),value:i.routing_key,onChange:this.handleChange,required:!0}),n.createElement(De.Input,{id:"pagerduty-notification-v2-custom_incident",name:"custom_incident",label:"Use Custom Incident Key",type:"checkbox",bsStyle:h.errors.custom_incident?"error":null,help:Fe()(h,"errors.custom_incident[0]","Generate a custom incident key based on the Stream and the Alert Condition."),value:i.custom_incident,checked:i.custom_incident,onChange:this.handleChange}),n.createElement(De.Input,{id:"pagerduty-notification-v2-key_prefix",name:"key_prefix",label:"Incident Key Prefix",type:"text",bsStyle:h.errors.key_prefix?"error":null,help:Fe()(h,"errors.key_prefix[0]","Incident key prefix that identifies the incident."),value:i.key_prefix,onChange:this.handleChange,required:!0}),n.createElement(De.Input,{id:"pagerduty-notification-v2-client_name",name:"client_name",label:"Client Name",type:"text",bsStyle:h.errors.client_name?"error":null,help:Fe()(h,"errors.client_name[0]","The name of the Graylog system that is triggering the PagerDuty event."),value:i.client_name,onChange:this.handleChange,required:!0}),n.createElement(De.Input,{id:"pagerduty-notification-v2-client_url",name:"client_url",label:"Client URL",type:"text",bsStyle:h.errors.client_url?"error":null,help:Fe()(h,"errors.client_url[0]","The URL of the Graylog system that is triggering the PagerDuty event."),value:i.client_url,onChange:this.handleChange,required:!0}))}}Km(nf,"propTypes",{config:a().shape({client_name:a().string,client_url:a().string,custom_incident:a().bool,key_prefix:a().string,routing_key:a().string}).isRequired,validation:a().shape({failed:a().bool.isRequired,errors:a().shape({client_name:a().arrayOf(a().string),client_url:a().arrayOf(a().string),custom_incident:a().arrayOf(a().string),key_prefix:a().arrayOf(a().string),routing_key:a().arrayOf(a().string)}),error_context:a().object}).isRequired,onChange:a().func.isRequired}),Km(nf,"defaultConfig",{client_name:"Graylog",client_url:"",custom_incident:!0,key_prefix:"Graylog",routing_key:""});const Bh=nf;var $m=e("KNFOZ/rv");function Uh({notification:l,...i}){var h,D,I,w,K;return n.createElement($m.Z,{...i,notification:l},n.createElement("tr",null,n.createElement("td",null,"Routing Key"),n.createElement("td",null,n.createElement("code",null,(h=l==null?void 0:l.config)==null?void 0:h.routing_key))),n.createElement("tr",null,n.createElement("td",null,"Use Custom Incident Key"),n.createElement("td",null,n.createElement("code",null,(D=l==null?void 0:l.config)!=null&&D.custom_incident?"Yes":"No"))),n.createElement("tr",null,n.createElement("td",null,"Incident Key Prefix"),n.createElement("td",null,n.createElement("code",null,(I=l==null?void 0:l.config)==null?void 0:I.key_prefix))),n.createElement("tr",null,n.createElement("td",null,"Client Name"),n.createElement("td",null,n.createElement("code",null,(w=l==null?void 0:l.config)==null?void 0:w.client_name))),n.createElement("tr",null,n.createElement("td",null,"Client URL"),n.createElement("td",null,n.createElement("code",null,(K=l==null?void 0:l.config)==null?void 0:K.client_url))))}Uh.propTypes={type:a().string.isRequired,notification:a().shape({config:a().shape({routing_key:a().string,custom_incident:a().bool,key_prefix:a().string,client_name:a().string,client_url:a().string}).isRequired}).isRequired,definitionNotification:a().shape.isRequired};const yy=Uh,_y=(0,u.default)(De.Well)(({theme:l})=>(0,u.css)` margin-bottom: 5px; font-family: ${l.fonts.family.monospace}; font-size: ${l.fonts.size.body}; white-space: pre-wrap; word-wrap: break-word; `),Cy=({notification:l})=>n.createElement(n.Fragment,null,n.createElement(rt.mv,{label:"Webhook URL",value:l.config.webhook_url}),n.createElement(rt.mv,{label:"Channel",value:l.config.channel}),n.createElement(rt.mv,{label:"Custom Message Template ",value:n.createElement(_y,{bsSize:"small"},l.config.custom_message||n.createElement("em",null,"Empty body"))}),n.createElement(rt.mv,{label:"Message Backlog Limit",value:l.config.backlog_size}),n.createElement(rt.mv,{label:"User Name",value:l.config.user_name}),n.createElement(rt.mv,{label:"Include Title",value:l.config.include_title}),n.createElement(rt.mv,{label:"Notify Channel",value:l.config.notify_channel}),n.createElement(rt.mv,{label:"Link Names",value:l.config.link_names}),n.createElement(rt.mv,{label:"Icon URL",value:l.config.icon_url}),n.createElement(rt.mv,{label:"Icon Emoji",value:l.config.icon_emoji}),n.createElement(rt.mv,{label:"Time Zone",value:l.config.time_zone}));var Ty=e("WoBpjwwo"),of=e.n(Ty),wh=e("1LOzeRr1");class Wh extends n.Component{constructor(i){super(i),this.handleBacklogSizeChange=D=>{const{name:I}=D.target,w=(0,ke.n6)(D.target);this.setState({[of()(I)]:w}),this.propagateChange(I,(0,ke.n6)(D.target))},this.toggleBacklogSize=()=>{const{isBacklogSizeEnabled:D,backlogSize:I}=this.state;this.setState({isBacklogSizeEnabled:!D}),this.propagateChange("backlog_size",D?0:I)},this.propagateChange=(D,I)=>{const{config:w,onChange:K}=this.props,G=Fm()(w);G[D]=I,K(G)},this.handleColorChange=(D,I,w)=>{w(),this.propagateChange("color",D)},this.handleChange=D=>{const{name:I}=D.target;this.propagateChange(I,(0,ke.n6)(D.target))},this.handleTimeZoneChange=D=>{this.propagateChange("time_zone",D)};const h=i.config.backlog_size;this.state={isBacklogSizeEnabled:h>0,backlogSize:h}}render(){const{config:i,validation:h}=this.props,{isBacklogSizeEnabled:D,backlogSize:I}=this.state,w=n.createElement("p",null,"Custom message to be appended below the alert title. See ",n.createElement(_h.Z,{text:"docs",page:"alerts#notifications"})," for more details.");return n.createElement(n.Fragment,null,n.createElement(De.FormGroup,{controlId:"color"},n.createElement(De.ControlLabel,null,"Configuration color"),n.createElement("div",null,n.createElement(wh.Z,{color:i.color}),n.createElement("div",{style:{display:"inline-block",marginLeft:15}},n.createElement(rt.h4,{id:"color",color:i.color||"#f06292",placement:"right",triggerNode:n.createElement(De.Button,{bsSize:"xsmall"},"Change color"),onChange:this.handleColorChange}))),n.createElement(De.HelpBlock,null,"Choose a color to use for this configuration.")),n.createElement(De.Input,{id:"notification-webhookUrl",name:"webhook_url",label:"Webhook URL",type:"text",bsStyle:h.errors.webhook_url?"error":null,help:Fe()(h,"errors.webhook_url[0]",'Slack "Incoming Webhook" URL'),value:i.webhook_url||"",onChange:this.handleChange,required:!0}),n.createElement(De.Input,{id:"notification-channel",name:"channel",label:"Channel",type:"text",bsStyle:h.errors.channel?"error":null,help:Fe()(h,"errors.channel[0]","Name of Slack #channel or @user for a direct message"),value:i.channel||"",onChange:this.handleChange,required:!0}),n.createElement(De.Input,{id:"notification-customMessage",name:"custom_message",label:"Custom Message (optional)",type:"textarea",bsStyle:h.errors.custom_message?"error":null,help:Fe()(h,"errors.custom_message[0]",w),value:i.custom_message||"",onChange:this.handleChange}),n.createElement(De.Input,{id:"notification-time-zone",help:"Time zone used for timestamps in the notification body.",label:"Time zone for date/time values"},n.createElement(rt.Cc,{className:"timezone-select",name:"time_zone",value:i.time_zone,onChange:this.handleTimeZoneChange,clearable:!1})),n.createElement(De.FormGroup,null,n.createElement(De.ControlLabel,null,"Message Backlog Limit (optional)"),n.createElement(De.InputGroup,null,n.createElement(De.InputGroup.Addon,null,n.createElement("input",{id:"toggle_backlog_size",type:"checkbox",checked:D,onChange:this.toggleBacklogSize})),n.createElement(De.FormControl,{type:"number",id:"backlog_size",name:"backlog_size",onChange:this.handleBacklogSizeChange,value:I,min:"0",disabled:!D})),n.createElement(De.HelpBlock,null,"Limit the number of backlog messages sent as part of the Slack notification. If set to 0, no limit will be enforced.")),n.createElement(De.Input,{id:"notification-userName",name:"user_name",label:"User Name (optional)",type:"text",bsStyle:h.errors.user_name?"error":null,help:Fe()(h,"errors.user_name[0]","User name of the sender in Slack"),value:i.user_name||"",onChange:this.handleChange}),n.createElement(De.Row,null,n.createElement(De.Col,{md:4},n.createElement(De.Input,{id:"include_title",name:"include_title",label:"Include Title",bsStyle:h.errors.include_title?"error":null,help:Fe()(h,"errors.include_title[0]","Include the event definition title and description in the notification"),type:"checkbox",checked:i.include_title,onChange:this.handleChange})),n.createElement(De.Col,{md:4},n.createElement(De.Input,{id:"notification-notifyChannel",name:"notify_channel",label:"Notify Channel",type:"checkbox",bsStyle:h.errors.notify_channel?"error":null,help:Fe()(h,"errors.notify_channel[0]","Notify all users in channel by adding @channel to the message"),checked:i.notify_channel||"",onChange:this.handleChange})),n.createElement(De.Col,{md:4},n.createElement(De.Input,{id:"notification-notifyHere",name:"notify_here",label:"Notify Here",type:"checkbox",bsStyle:h.errors.notify_here?"error":null,help:Fe()(h,"errors.notify_here[0]","Notify active users in channel by adding @here to the message"),checked:i.notify_here||"",onChange:this.handleChange}))),n.createElement(De.Input,{id:"notification-linkNames",name:"link_names",label:"Link Names",type:"checkbox",bsStyle:h.errors.link_names?"error":null,help:Fe()(h,"errors.link_names[0]","Find and link channel names and user names"),checked:i.link_names||"",onChange:this.handleChange}),n.createElement(De.Input,{id:"notification-iconUrl",name:"icon_url",label:"Icon URL (optional)",type:"text",bsStyle:h.errors.icon_url?"error":null,help:Fe()(h,"errors.icon_url[0]","Image to use as the icon for this message"),value:i.icon_url||"",onChange:this.handleChange}),n.createElement(De.Input,{id:"notification-iconEmoji",name:"icon_emoji",label:"Icon Emoji (optional)",type:"text",bsStyle:h.errors.icon_emoji?"error":null,help:Fe()(h,"errors.icon_emoji[0]","Emoji to use as the icon for this message (overrides Icon URL)"),value:i.icon_emoji||"",onChange:this.handleChange}))}}Wh.defaultConfig={color:"#FF0000",webhook_url:"",channel:"#channel",custom_message:"--- [Event Definition] ---------------------------\nTitle: ${event_definition_title}\nType: ${event_definition_type}\n--- [Event] --------------------------------------\nAlert Replay: ${http_external_uri}alerts/${event.id}/replay-search\nTimestamp: ${event.timestamp}\nMessage: ${event.message}\nSource: ${event.source}\nKey: ${event.key}\nPriority: ${event.priority}\nAlert: ${event.alert}\nTimestamp Processing: ${event.timestamp}\nTimerange Start: ${event.timerange_start}\nTimerange End: ${event.timerange_end}\nEvent Fields:\n${foreach event.fields field}\n${field.key}: ${field.value}\n${end}\n${if backlog}\n--- [Backlog] ------------------------------------\nLast messages accounting for this alert:\n${foreach backlog message}\n${message.timestamp} :: ${message.source} :: ${message.message}\n${message.message}\n${end}${end}\n",user_name:"Graylog",notify_channel:!1,link_names:!1,icon_url:"",icon_emoji:"",backlog_size:0,time_zone:"UTC"};const Nh=Wh;function Zh({notification:l,...i}){var h;return n.createElement($m.Z,{...i,notification:l},n.createElement("tr",null,n.createElement("td",null,"Color"),n.createElement("td",null,(h=l==null?void 0:l.config)==null?void 0:h.color)),n.createElement("tr",null,n.createElement("td",null,"Webhook URL"),n.createElement("td",null,l.config.webhook_url)),n.createElement("tr",null,n.createElement("td",null,"Channel"),n.createElement("td",null,l.config.channel)),n.createElement("tr",null,n.createElement("td",null,"Include Title"),n.createElement("td",null,l.config.include_title)),n.createElement("tr",null,n.createElement("td",null,"Custom Message"),n.createElement("td",null,l.config.custom_message)),n.createElement("tr",null,n.createElement("td",null,"Time Zone"),n.createElement("td",null,l.config.time_zone)),n.createElement("tr",null,n.createElement("td",null,"Message Backlog Limit"),n.createElement("td",null,l.config.backlog_size)),n.createElement("tr",null,n.createElement("td",null,"User Name"),n.createElement("td",null,l.config.user_name)),n.createElement("tr",null,n.createElement("td",null,"Notify Channel"),n.createElement("td",null,l.config.notify_channel?"Yes":"No")),n.createElement("tr",null,n.createElement("td",null,"Link Names"),n.createElement("td",null,l.config.link_names?"Yes":"No")),n.createElement("tr",null,n.createElement("td",null,"Icon URL"),n.createElement("td",null,l.config.icon_url)),n.createElement("tr",null,n.createElement("td",null,"Icon Emoji"),n.createElement("td",null,l.config.icon_emoji)))}Zh.defaultProps={notification:{}};const Sy=Zh,Ay=(0,u.default)(De.Well)(({theme:l})=>(0,u.css)` margin-bottom: 5px; font-family: ${l.fonts.family.monospace}; font-size: ${l.fonts.size.body}; white-space: pre-wrap; word-wrap: break-word; `),Py=({notification:l})=>n.createElement(n.Fragment,null,n.createElement(rt.mv,{label:"Webhook URL",value:l.config.webhook_url}),n.createElement(rt.mv,{label:"Custom Message Template ",value:n.createElement(Ay,{bsSize:"small"},l.config.custom_message||n.createElement("em",null,"Empty body"))}),n.createElement(rt.mv,{label:"Message Backlog Limit",value:l.config.backlog_size}),n.createElement(rt.mv,{label:"Icon URL",value:l.config.icon_url}),n.createElement(rt.mv,{label:"Time Zone",value:l.config.time_zone}));class Fh extends n.Component{constructor(i){super(i),this.handleBacklogSizeChange=D=>{const{name:I}=D.target,w=(0,ke.n6)(D.target);this.setState({[of()(I)]:w}),this.propagateChange(I,(0,ke.n6)(D.target))},this.toggleBacklogSize=()=>{const{isBacklogSizeEnabled:D,backlogSize:I}=this.state;this.setState({isBacklogSizeEnabled:!D}),this.propagateChange("backlog_size",D?0:I)},this.propagateChange=(D,I)=>{const{config:w,onChange:K}=this.props,G=Fm()(w);G[D]=I,K(G)},this.handleColorChange=(D,I,w)=>{w(),this.propagateChange("color",D)},this.handleTimeZoneChange=D=>{this.propagateChange("time_zone",D)},this.handleChange=D=>{const{name:I}=D.target;this.propagateChange(I,(0,ke.n6)(D.target))};const h=i.config.backlog_size;this.state={isBacklogSizeEnabled:h>0,backlogSize:h}}render(){const{config:i,validation:h}=this.props,{isBacklogSizeEnabled:D,backlogSize:I}=this.state,w="https://docs.graylog.org/docs/alerts#notifications",K=n.createElement("p",null,"Custom message to be appended below the alert title. See ",n.createElement("a",{href:w,rel:"noopener noreferrer",target:"_blank"},"docs "),"for more details.");return n.createElement(n.Fragment,null,n.createElement(De.FormGroup,{controlId:"color"},n.createElement(De.ControlLabel,null,"Configuration color"),n.createElement("div",null,n.createElement(wh.Z,{color:i.color}),n.createElement("div",{style:{display:"inline-block",marginLeft:15}},n.createElement(rt.h4,{id:"color",color:i.color||"#f06292",placement:"right",triggerNode:n.createElement(De.Button,{bsSize:"xsmall"},"Change color"),onChange:this.handleColorChange}))),n.createElement(De.HelpBlock,null,"Choose a color to use for this configuration.")),n.createElement(De.Input,{id:"notification-webhookUrl",name:"webhook_url",label:"Webhook URL",type:"text",bsStyle:h.errors.webhook_url?"error":null,help:Fe()(h,"errors.webhook_url[0]",'Teams "Incoming Webhook" URL'),value:i.webhook_url||"",onChange:this.handleChange,required:!0}),n.createElement(De.Input,{id:"notification-customMessage",name:"custom_message",label:"Custom Message (optional)",type:"textarea",bsStyle:h.errors.custom_message?"error":null,help:Fe()(h,"errors.custom_message[0]",K),value:i.custom_message||"",onChange:this.handleChange}),n.createElement(De.FormGroup,null,n.createElement(De.Input,{id:"notification-time-zone",help:"Time zone used for timestamps in the notification body.",label:"Time zone for date/time values"},n.createElement(rt.Cc,{className:"timezone-select",name:"time_zone",value:i.time_zone,onChange:this.handleTimeZoneChange,clearable:!1})),n.createElement(De.ControlLabel,null,"Message Backlog Limit (optional)"),n.createElement(De.InputGroup,null,n.createElement(De.InputGroup.Addon,null,n.createElement("input",{id:"toggle_backlog_size",type:"checkbox",checked:D,onChange:this.toggleBacklogSize})),n.createElement(De.FormControl,{type:"number",id:"backlog_size",name:"backlog_size",onChange:this.handleBacklogSizeChange,value:I,min:"0",disabled:!D})),n.createElement(De.HelpBlock,null,"Limit the number of backlog messages sent as part of the Microsoft Teams notification. If set to 0, no limit will be enforced.")),n.createElement(De.Input,{id:"notification-iconUrl",name:"icon_url",label:"Icon URL (optional)",type:"text",bsStyle:h.errors.icon_url?"error":null,help:Fe()(h,"errors.icon_url[0]","Image to use as the icon for this message"),value:i.icon_url||"",onChange:this.handleChange}))}}Fh.defaultConfig={color:"#FF0000",webhook_url:"",custom_message:`--- [Event Definition] ---
Title:\${event_definition_title}
Type:\${event_definition_type}
--- [Event] ---
Alert Replay:\${http_external_uri}alerts/\${event.id}/replay-search
Timestamp:\${event.timestamp}
Message:\${event.message}
Source:\${event.source}
Key:\${event.key}
Priority:\${event.priority}
Alert:\${event.alert}
Timestamp Processing:\${event.timestamp}
Timerange Start:\${event.timerange_start}
Timerange End:\${event.timerange_end}
Event Fields:
\${foreach event.fields field} \${end}
\${field.key}:\${field.value}
\${if backlog} --- [Backlog] --- \${foreach backlog message}

\${message.timestamp} :: \${message.source} :: \${message.message}

\${end}\${end}`,icon_url:"",backlog_size:0,time_zone:"UTC"};const Kh=Fh;function $h({notification:l,...i}){var h;return n.createElement($m.Z,{...i,notification:l},n.createElement("tr",null,n.createElement("td",null,"Color"),n.createElement("td",null,(h=l==null?void 0:l.config)==null?void 0:h.color)),n.createElement("tr",null,n.createElement("td",null,"Webhook URL"),n.createElement("td",null,l.config.webhook_url)),n.createElement("tr",null,n.createElement("td",null,"Custom Message"),n.createElement("td",null,l.config.custom_message)),n.createElement("tr",null,n.createElement("td",null,"Time Zone"),n.createElement("td",null,l.config.time_zone)),n.createElement("tr",null,n.createElement("td",null,"Message Backlog Limit"),n.createElement("td",null,l.config.backlog_size)),n.createElement("tr",null,n.createElement("td",null,"Icon URL"),n.createElement("td",null,l.config.icon_url)))}$h.defaultProps={notification:{}};const by=$h,Gh=({config:l,updateConfig:i,validationMessage:h,validationState:D})=>{var I,w,K;const G=(0,n.useRef)(!((I=l.api_token)!=null&&I.is_set)),[oe,pe]=(0,n.useState)(((w=l.api_token)==null?void 0:w.is_set)===!0),_e=(0,n.useCallback)(Ue=>{i({...l,api_token:Ue})},[i,l]);(0,n.useEffect)(()=>{var Ue;((Ue=l.api_token)==null?void 0:Ue.is_set)!==void 0&&_e({keep_value:!0})},[_e,l.api_token]);const ve=({target:Ue})=>{const He=Ue.value;let at={set_value:He};He===""&&(at={delete_value:!0}),_e(at)},he=()=>{if(oe){_e({delete_value:!0}),pe(!1);return}_e({keep_value:!0}),pe(!0)};return n.createElement("fieldset",null,oe?n.createElement(De.Input,{id:"api_token",label:"User Password",labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},n.createElement(De.Button,{onClick:he},"Reset token")):n.createElement(De.Input,{type:"password",id:"api_token",name:"api_token",label:"API Token",buttonAfter:G.current?void 0:n.createElement(De.Button,{type:"button",onClick:he},"Undo Reset"),onChange:ve,help:h("api_token","The API Token."),bsStyle:D("api_token"),value:((K=l.api_token)==null?void 0:K.set_value)||"",labelClassName:"col-sm-3",wrapperClassName:"col-sm-9",required:!0}))};Gh.propTypes={config:a().shape({api_token:a().object.isRequired}).isRequired,updateConfig:a().func.isRequired,handleFormEvent:a().func.isRequired,validationState:a().func.isRequired,validationMessage:a().func.isRequired};const jh=Gh;var Dy=Object.defineProperty,Oy=(l,i,h)=>i in l?Dy(l,i,{enumerable:!0,configurable:!0,writable:!0,value:h}):l[i]=h,Ry=(l,i,h)=>(Oy(l,typeof i!="symbol"?i+"":i,h),h);class zh extends n.Component{render(){return n.createElement("div",null,n.createElement("dl",null,n.createElement("dt",null,"API Token"),n.createElement("dd",null,"******")),n.createElement(De.Alert,{style:{marginBottom:10},bsStyle:"danger",title:"Deprecation Warning"},n.createElement("p",null,"The GreyNoise Community IP Lookup Data Adapter is no longer supported. This Data Adapter should not be used.")))}}Ry(zh,"propTypes",{dataAdapter:a().shape({config:a().shape({}).isRequired,updateConfig:a().func.isRequired,handleFormEvent:a().func.isRequired,validationState:a().func.isRequired,validationMessage:a().func.isRequired})});const Vh=zh;class Iy extends n.Component{render(){const i={marginBottom:10};return n.createElement("div",null,n.createElement("p",{style:i},"The GreyNoise Quick IP Lookup data adapter uses the ",n.createElement(rt.dL,{href:"https://developer.greynoise.io/"},"Greynoise API")," to lookup indicators for the given key and returns the values for the IP Quick Context endpoint. See ",n.createElement(rt.dL,{href:"https://developer.greynoise.io/reference/ip-lookup-1#quickcheck-1"},"IP Quick Context")))}}const My=Iy;class xy extends n.Component{render(){return n.createElement("div",null,n.createElement(De.Alert,{style:{marginBottom:10},bsStyle:"warning",title:"Deprecation Warning"},n.createElement("p",null,"The GreyNoise Community IP Lookup Data Adapter is no longer supported. This Data Adapter should not be used.")))}}const Ly=xy;class Hh extends n.Component{constructor(i){super(i),this.handleBacklogSizeChange=D=>{const{name:I}=D.target,w=(0,ke.n6)(D.target);this.setState({[of()(I)]:w}),this.propagateChange(I,(0,ke.n6)(D.target))},this.toggleBacklogSize=()=>{const{isBacklogSizeEnabled:D,backlogSize:I}=this.state;this.setState({isBacklogSizeEnabled:!D}),this.propagateChange("backlog_size",D?0:I)},this.propagateChange=(D,I)=>{const{config:w,onChange:K}=this.props,G=Fm()(w);G[D]=I,K(G)},this.handleTimeZoneChange=D=>{this.propagateChange("time_zone",D)},this.handleWebhookUrlChange=D=>{this.propagateChange("webhook_url",(0,ke.n6)(D.target))},this.handleAdaptiveCardChange=D=>{this.propagateChange("adaptive_card",D)};const h=i.config.backlog_size;this.state={isBacklogSizeEnabled:h>0,backlogSize:h}}render(){const{config:i,validation:h}=this.props,{isBacklogSizeEnabled:D,backlogSize:I}=this.state,w="https://docs.graylog.org/docs/alerts#notifications",K=n.createElement("p",null,"Adaptive Card to post to Teams. See ",n.createElement("a",{href:w,rel:"noopener noreferrer",target:"_blank"},"docs "),"for more details.");return n.createElement(n.Fragment,null,n.createElement(rt.zX,{label:"Webhook URL",onChange:this.handleWebhookUrlChange,validationState:h.errors.webhook_url?"error":null,validationMessage:Fe()(h,"errors.webhook_url[0]",'Teams "Incoming Webhook" URL'),url:i.webhook_url||"",autofocus:!1}),n.createElement(De.FormGroup,null,n.createElement(De.ControlLabel,null,"Adaptive Card Template"),n.createElement(rt.KB,{id:"notification-adaptiveCard",mode:"text",theme:"light",value:i.adaptive_card||"",wrapEnabled:!0,onChange:this.handleAdaptiveCardChange}),n.createElement(De.HelpBlock,null,Fe()(h,"errors.adaptive_card[0]",K))),n.createElement(De.FormGroup,null,n.createElement(De.Input,{id:"notification-time-zone",help:"Time zone used for timestamps in the notification body.",label:"Time zone for date/time values"},n.createElement(rt.Cc,{className:"timezone-select",name:"time_zone",value:i.time_zone,onChange:this.handleTimeZoneChange,clearable:!1})),n.createElement(De.ControlLabel,null,"Message Backlog Limit (optional)"),n.createElement(De.InputGroup,null,n.createElement(De.InputGroup.Addon,null,n.createElement("input",{id:"toggle_backlog_size",type:"checkbox",checked:D,onChange:this.toggleBacklogSize})),n.createElement(De.FormControl,{type:"number",id:"backlog_size",name:"backlog_size",onChange:this.handleBacklogSizeChange,value:I,min:"0",disabled:!D})),n.createElement(De.HelpBlock,null,"Limit the number of backlog messages sent as part of the Microsoft Teams notification. If set to 0, no limit will be enforced.")))}}Hh.defaultConfig={webhook_url:"",adaptive_card:`{ "type": "message", "attachments": [ { "contentType": "application/vnd.microsoft.card.adaptive", "content": { "type": "AdaptiveCard", "version": "1.6", "msTeams": { "width": "full" }, "body": [ { "type": "TextBlock", "size": "Large", "weight": "Bolder", "text": "\${event_definition_title} triggered", "style": "heading", "fontType": "Default" }, { "type": "TextBlock", "text": "\${event_definition_description}", "wrap": true }, { "type": "TextBlock", "text": "Event Details", "wrap": true }, { "type": "FactSet", "facts": [ { "title": "Type", "value": "\${event_definition_type}" }, { "title": "Timestamp", "value": "\${event.timestamp_processing}" }, { "title": "Message", "value": "\${event.message}" }, { "title": "Source", "value": "\${event.source}" }, { "title": "Key", "value": "\${event.key}" }, { "title": "Priority", "value": "\${event.priority}" }, { "title": "Alert", "value": "\${event.alert}" }, { "title": "Timerange Start", "value": "\${event.timerange_start}" }, { "title": "Timerange End", "value": "\${event.timerange_end}" } ] }\${if event.fields}, { "type": "TextBlock", "text": "Event Fields", "weight": "bolder", "size": "medium" }, { "type": "FactSet", "facts": [\${foreach event.fields field} { "title": "\${field.key}", "value": "\${field.value}" }\${if last_field}\${else},\${end}\${end} ] }\${end}\${if backlog}, { "type": "TextBlock", "text": "Backlog", "weight": "bolder", "size": "medium" }, { "type": "FactSet", "facts": [\${foreach backlog message} { "title": "Message", "value": "\${message.message}" }\${if last_message}\${else},\${end}\${end} ] }\${end} ], "actions": [{ "type": "Action.OpenUrl", "title": "Replay Search", "url": "\${http_external_uri}alerts/\${event.id}/replay-search" }], "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "rtl": false } } ] }`,backlog_size:0,time_zone:"UTC"};const kh=Hh;function Qh({notification:l,...i}){return n.createElement($m.Z,{...i,notification:l},n.createElement("tr",null,n.createElement("td",null,"Webhook URL"),n.createElement("td",null,l.config.webhook_url)),n.createElement("tr",null,n.createElement("td",null,"Adaptive Card Template"),n.createElement("td",null,l.config.adaptive_card)),n.createElement("tr",null,n.createElement("td",null,"Time Zone"),n.createElement("td",null,l.config.time_zone)),n.createElement("tr",null,n.createElement("td",null,"Message Backlog Limit"),n.createElement("td",null,l.config.backlog_size)))}Qh.defaultProps={notification:{}};const By=Qh,Uy=(0,u.default)(De.Well)(({theme:l})=>(0,u.css)` margin-bottom: 5px; font-family: ${l.fonts.family.monospace}; font-size: ${l.fonts.size.body}; white-space: pre-wrap; word-wrap: break-word; `),wy=({notification:l})=>n.createElement(n.Fragment,null,n.createElement(rt.mv,{label:"Webhook URL",value:l.config.webhook_url}),n.createElement(rt.mv,{label:"Adaptive Card Template",value:n.createElement(Uy,{bsSize:"small"},l.config.adaptive_card)}),n.createElement(rt.mv,{label:"Message Backlog Limit",value:l.config.backlog_size}),n.createElement(rt.mv,{label:"Time Zone",value:l.config.time_zone})),Wy={routes:[{path:yn.INTEGRATIONS.AWS.CLOUDWATCH.index,component:gy}],inputConfiguration:[{type:"org.graylog.integrations.aws.inputs.AWSInput",component:Sn,embeddedComponent:Mh}],eventNotificationTypes:[{type:"pagerduty-notification-v2",displayName:"PagerDuty Notification [Official]",formComponent:Bh,summaryComponent:yy,detailsComponent:Ey,defaultConfig:Bh.defaultConfig},{type:"slack-notification-v1",displayName:"Slack Notification",formComponent:Nh,summaryComponent:Sy,detailsComponent:Cy,defaultConfig:Nh.defaultConfig},{type:"teams-notification-v1",displayName:"Microsoft Teams Notification (Deprecated - use V2)",formComponent:Kh,summaryComponent:by,detailsComponent:Py,defaultConfig:Kh.defaultConfig},{type:"teams-notification-v2",displayName:"Microsoft Teams Notification V2",formComponent:kh,summaryComponent:By,detailsComponent:wy,defaultConfig:kh.defaultConfig}],lookupTableAdapters:[{type:"GreyNoise",displayName:"GreyNoise Quick IP Lookup",formComponent:jh,summaryComponent:Vh,documentationComponent:My},{type:"GreyNoise Community IP Lookup",displayName:"[Deprecated] GreyNoise Community IP Lookup",formComponent:jh,summaryComponent:Vh,documentationComponent:Ly}]};var Ny=e("Ds5vWZ1u"),Zy=e("pcmOAiUc"),Xh=e("+jOfIC1E"),Fy=e("2dBXfbRP"),Jh=e("2aaiYHqX");const Ky=()=>{const{host:l,api_key:i}=o.Z.telemetry()||{};return{host:l,key:i}},$y=(l,i)=>(Xh.ZP.init(l,{autocapture:!1,api_host:i,capture_pageview:!1,capture_pageleave:!1}),Xh.ZP),Gy=({children:l})=>{const i=(0,Z.o)(Jh.o,w=>w.telemetrySetting),{host:h,key:D}=Ky(),{currentUser:I}=(0,Z.o)(ne.D);return(0,n.useEffect)(()=>{I&&Jh.W.get()},[I]),!(i!=null&&i.telemetry_enabled)||!h||!D?l:n.createElement(Fy.zf,{client:$y(D,h)},l)},jy={defaultOptions:{queries:{refetchOnWindowFocus:!1,networkMode:"always"}}},zy=({children:l})=>{const i=(0,n.useMemo)(()=>new il.QueryClient(jy),[]);return n.createElement(il.QueryClientProvider,{client:i},l)};d().setPromiseFactory(l=>Zy.Z.of(new Promise(l))),g.G.register(new g.h({},bm)),g.G.register(new g.h({},Ze)),g.G.register(new g.h({},tn)),g.G.register(new g.h({},Wy));function Vy(l){c.render(n.createElement(nt,null,n.createElement(Gy,null,n.createElement(zy,null,n.createElement(ht.Z,null,n.createElement(Ny.Z,null),n.createElement(ut,null))))),l)}const Hy=document.querySelector("div#app-root");Vy(Hy)},"4E3oowBb":(M,C,e)=>{"use strict";e.d(C,{S:()=>s});const s=((o={})=>new Intl.Collator(void 0,o).compare)()},vT7mdtQI:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});const t=r=>JSON.stringify(r,null,2),o=(r,n)=>{throw new Error(`${n}: ${t(r)}`)}},"9tc+dS6Z":(M,C,e)=>{"use strict";e.d(C,{Ax:()=>t,W6:()=>g,ZT:()=>s,fQ:()=>o,hy:()=>n,vE:()=>r,vu:()=>c});const t="ReactError",s="NotFoundError",o="UnauthorizedError",r="StreamPermissionError",n=(p,E)=>({error:p,info:E,type:t}),c=p=>({error:p,type:s}),v=p=>({error:p,type:o}),d=p=>({error:p,type:r}),g=p=>{var E,a;switch(p.status){case 403:return((a=(E=p==null?void 0:p.additional)==null?void 0:E.body)==null?void 0:a.type)==="MissingStreamPermission"?d(p):v(p);case 404:return c(p);default:throw Error(`Provided FetchError is not a valid ReportedError because status code ${p.status} is not supported`)}}},iltCXley:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("i3pQAyXy");const o=()=>(0,t.Z)()},"7GNmVOX8":(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const t={set(o,r,n=window.localStorage){n.setItem(o,JSON.stringify(r))},get(o,r=window.localStorage){const n=r.getItem(o);if(n!=null)try{return JSON.parse(n)}catch{return n}},delete(o,r=window.localStorage){r.removeItem(o)},sessionSet(o,r){return t.set(o,r,window.sessionStorage)},sessionGet(o){return t.get(o,window.sessionStorage)},sessionDelete(o){return t.delete(o,window.sessionStorage)}},s=t},"0+7ljD5O":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("InkdxEOv");const o={filterFields(r){const n={};return Object.keys(r).forEach(c=>{(0,t.Z)(c)||(n[c]=r[c])}),n}}},Q1zRxDOP:(M,C,e)=>{"use strict";e.d(C,{C:()=>o,L:()=>s});const t=r=>r===""?void 0:r,s=(r,n)=>`grn::::${r}:${n}`,o=r=>{const n=r.split(":"),[c,v,d,g,p,E]=n.map(t);return{resourceNameType:c,cluster:v,tenant:d,scope:g,type:p,id:E}}},CIb2ALfk:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("VPaD/Np4"),s=e.n(t);class o{constructor(c,v,d){this._value={id:c,title:v,type:d}}get id(){return this._value.id}get title(){return this._value.title}get type(){return this._value.type}toBuilder(){const{id:c,title:v,type:d}=this._value;return new r(t.Map({id:c,title:v,type:d}))}toJSON(){const{id:c,title:v,type:d}=this._value;return{id:c,title:v,type:d}}static fromJSON(c){const{id:v,title:d,type:g}=c;return o.builder().id(v).title(d).type(g).build()}static builder(){return new r}}class r{constructor(c=t.Map()){this.value=c}id(c){return new r(this.value.set("id",c))}title(c){return new r(this.value.set("title",c))}type(c){return new r(this.value.set("type",c))}build(){const{id:c,title:v,type:d}=this.value.toObject();return new o(c,v,d)}}},EregcbZy:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("VPaD/Np4"),s=e.n(t),o=e("CIb2ALfk");class r{constructor(v,d,g,p){this._value={id:v,owners:d,title:g,type:p}}get id(){return this._value.id}get owners(){return this._value.owners}get title(){return this._value.title}get type(){return this._value.type}toBuilder(){const{id:v,owners:d,title:g}=this._value;return new n(t.Map({id:v,owners:d,title:g}))}toJSON(){const{id:v,owners:d,title:g,type:p}=this._value;return{id:v,owners:d,title:g,type:p}}static fromJSON(v){const{id:d,owners:g,title:p,type:E}=v,a=t.fromJS(g.map(u=>o.Z.fromJSON(u)));return r.builder().id(d).owners(a).title(p).type(E).build()}static builder(){return new n}}class n{constructor(v=t.Map()){this.value=v}id(v){return new n(this.value.set("id",v))}owners(v){return new n(this.value.set("owners",v))}title(v){return new n(this.value.set("title",v))}type(v){return new n(this.value.set("type",v))}build(){const{id:v,owners:d,title:g,type:p}=this.value.toObject();return new r(v,d,g,p)}}},pcmOAiUc:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});const o=class mu{constructor(n,c=!1){this._promise=n,this._isCanceled=c}then(n,c){return new mu(this._promise.then(n,c),this._isCanceled)}catch(n){return new mu(this._promise.catch(n),this._isCanceled)}finally(n){return new mu(this._promise.finally(n),this._isCanceled)}static of(n){return new mu(n)}cancel(){return this._isCanceled=!0,this}isCancelled(){return this._isCanceled}}},eFxcQyPT:(M,C,e)=>{"use strict";e.d(C,{Ib:()=>O,ZP:()=>L,dc:()=>j,vl:()=>Z,sD:()=>W,wR:()=>N});var t=e("euujeYld"),s=e.n(t),o=e("X6P4SH4J"),r=e.n(o);class n extends Error{constructor(ne,Y,ae){var ee,ue;super(ne),this.name="FetchError";const H=r()(ae)?ae:(ee=ae==null?void 0:ae.message)!=null?ee:"Not available";this.message=`There was an error fetching a resource: ${ne}. Additional information: ${H}`,this.responseMessage=(ue=ae==null?void 0:ae.message)!=null?ue:void 0,this.additional={body:ae,status:Y,res:{text:r()(ae)&&ae}},this.status=Y}}var c=e("62FDaRYn"),v=e("9tc+dS6Z"),d=e("pcmOAiUc"),g=e("rjGM+nrz");const p=s()(()=>e("pc+thvZE")),E=()=>{g.w.reportSuccess()},a=z=>c.Z.report((0,v.W6)(z)),u=z=>z&&z!==""?z:void 0,f=async(z,ne=a)=>{var Y,ae;const ee=(Y=z.headers)==null?void 0:Y.get("Content-Type"),ue=await(ee!=null&&ee.startsWith("application/json")?z.json().then(ut=>ut):(ae=z==null?void 0:z.text)==null?void 0:ae.call(z)),{SessionStore:H,SessionActions:ye}=p(),we=new n(z.statusText,z.status,u(ue));throw H.isLoggedIn()&&z.status===401&&ye.logout(),H.isLoggedIn()&&z.status===403&&ne(we),z&&!z.status&&g.w.reportError(we),we},y=z=>z&&typeof z!="string"?JSON.stringify(z):z,T=z=>{if(z.ok){const{status:ne}=z,Y=Number.parseInt(z.headers.get("Content-Length"),10),ae=ne===204||Y===0;return E(),ae?null:z.json()}throw z},P=z=>{if(z.ok)return E(),z.text();throw z};class O{constructor(ne,Y){this.options={},this.method=ne,this.url=Y.replace(/([^:])\/\//,"$1/"),this.options={"X-Requested-With":"XMLHttpRequest","X-Requested-By":"XMLHttpRequest"},this.responseHandler=ae=>ae,this.errorHandler=void 0}setHeader(ne,Y){return this.options={...this.options,[ne]:Y},this}json(ne){return this.body={body:y(ne),mimeType:"application/json"},this.accept="application/json",this.responseHandler=T,this.errorHandler=Y=>f(Y),this}formData(ne,Y="application/json"){return this.body={body:ne},this.accept=Y,this.responseHandler=T,this.errorHandler=ae=>f(ae),this}file(ne,Y){return this.body={body:y(ne),mimeType:"application/json"},this.accept=Y,this.responseHandler=ae=>{if(ae.ok)return E(),ae.text();throw ae},this.errorHandler=ae=>f(ae),this}plaintext(ne){return this.body={body:ne,mimeType:"text/plain"},this.accept="application/json",this.responseHandler=T,this.errorHandler=Y=>f(Y),this}streamingplaintext(ne){return this.body={body:ne,mimeType:"text/plain"},this.accept="text/plain",this.responseHandler=P,this.errorHandler=Y=>f(Y),this}ignoreUnauthorized(){return this.errorHandler=ne=>f(ne,()=>{}),this}noSessionExtension(){return this.options={...this.options,"X-Graylog-No-Session-Extension":"true"},this}build(){const ne=this.body&&this.body.mimeType?{...this.options,"Content-Type":this.body.mimeType}:this.options;return this.accept&&(ne.Accept=this.accept),d.Z.of(window.fetch(this.url,{method:this.method,headers:ne,body:this.body?this.body.body:void 0})).then(this.responseHandler,this.errorHandler).catch(this.errorHandler)}}function b(z){const{SessionStore:ne,SessionActions:Y}=p();return ne.isLoggedIn()?z:()=>d.Z.of(new Promise((ae,ee)=>{Y.login.completed.listen(()=>{z().then(ae,ee)})}))}function L(z,ne,Y,ae=!0){const ee=()=>new O(z,ne).json(Y).build();return ae?b(ee)():ee()}function x(z,ne,Y=!0){const ae=()=>new O("POST",z).formData(ne).build();return Y?b(ae)():ae()}function W(z,ne,Y){return b(()=>new O(z,ne).plaintext(Y).build())()}function N(z,ne,Y){return b(()=>new O(z,ne).streamingplaintext(Y).build())()}function Z(z,ne,Y){return b(()=>new O(z,ne).noSessionExtension().json(Y).build())()}function j(z,ne,Y,ae="text/csv"){return b(()=>new O(z,ne).file(Y,ae).build())()}},"jsQWU+f2":(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("kqAR+wt5"),s=e.n(t);let o=!1;const n={init(){o||(s()("#scroll-to-search-hint, #scroll-to-search-hint i").on("click",()=>{s()("html, body").animate({scrollTop:0},"fast")}),o=!0)},escape(c){return c.replace(/(&&|\|\||[:\\\/\+\-!\(\)\{\}\[\]\^"~*\?])/g,"\\$&")},_query(){return s()("#universalsearch-query")},setQuery(c){const v=this._query();v.val(c),v.effect("bounce"),this.scrollToSearchbarHint()},getQuery(){return this._query().val()},submit(){s()("#universalsearch form").submit()},createSourceQuery(c){return`source:${this.escape(c)}`},queryContainsSegment(c){return this.getQuery().split(" ").some(g=>g===c)},addSegment(c,v){let d=this.getQuery();if(this.queryContainsSegment(c))return;d==="*"&&(d="");let g="";typeof v<"u"&&d!==""&&(g=`${d} ${v} `),g+=c,this.setQuery(g)},andOperator(){return"AND"},orOperator(){return"OR"},notOperator(){return"NOT"},scrollToSearchbarHint(){s()(document).scrollTop()>50&&s()("#scroll-to-search-hint").fadeIn("fast").delay(1500).fadeOut("fast")},substringMatcher(c,v,d){return function(p,E){const a=[];c.forEach(u=>{if(a.length{if(a.length{"use strict";e.d(C,{dS:()=>o,ei:()=>s,ri:()=>t});const t=(r,n)=>(window.singletons[r]||(window.singletons[r]=n()),window.singletons[r]),s=(r,n)=>t(`${r}Actions`,n),o=(r,n)=>t(`${r}Store`,n);typeof window.singletons>"u"&&(window.singletons={})},"v4GbOr/o":(M,C,e)=>{"use strict";e.d(C,{A:()=>t});const t={SEARCH_TIMERANGE_PRESET_SELECTED:"Search TimeRange Preset Selected",SEARCH_TIMERANGE_PICKER_TOGGLED:"Search TimeRange Picker Toggled",SEARCH_TIMERANGE_PICKER_UPDATED:"Search TimeRange Picker Updated",SEARCH_TIMERANGE_PICKER_CANCELED:"Search TimeRange Picker Canceled",SEARCH_TIMERANGE_PICKER_TAB_SELECTED:"Search TimeRange Picker Tab Selected",SEARCH_STREAM_INPUT_CHANGED:"Search Stream Input Changed",SEARCH_REFRESH_CONTROL_PRESET_SELECTED:"Search Refresh Control Preset Selected",SEARCH_REFRESH_CONTROL_TOGGLED:"Search Refresh Control Toggled",SEARCH_BUTTON_CLICKED:"Search Button Clicked",SEARCH_FILTER_CREATE_CLICKED:"Search Filter Create Clicked",SEARCH_FILTER_CREATED:"Search Filter Created",SEARCH_FILTER_UPDATED:"Search Filter Updated",SEARCH_FILTER_DELETED:"Search Filter Deleted",SEARCH_FILTER_LOAD_CLICKED:"Search Filter Load Clicked",SEARCH_FILTER_LOADED:"Search Filter Loaded",SEARCH_FILTER_ITEM_MENU_TOGGLED:"Search Filter Item Menu Toggled",SEARCH_FILTER_ITEM_DISABLED_TOGGLED:"Search Filter Item Disabled Toggled",SEARCH_FILTER_ITEM_SHARE_CLICKED:"Search Filter Item Share Clicked",SEARCH_FILTER_ITEM_EDIT_CLICKED:"Search Filter Item Edit Clicked",SEARCH_FILTER_ITEM_COPIED:"Search Filter Item Copied",SEARCH_FILTER_ITEM_REMOVED:"Search Filter Item Removed",SEARCH_FILTER_ITEM_REFERENCE_REPLACED:"Search Filter Item Reference Replaced",SEARCH_FILTER_ITEM_NEGATION_TOGGLED:"Search Filter Item Negation Toggled",SEARCH_WIDGET_EXPORT_DOWNLOADED:"Search Widget Export Downloaded",SEARCH_TIMERANGE_PRESET_ADD_QUICK_ACCESS:"Search TimeRange Preset Add Quick Access",SEARCH_WIDGET_ACTION:{FOCUSED:"Search Widget Focused",DELETED:"Search Widget Deleted",MOVE:"Search Widget Moved",DUPLICATE:"Search Widget Duplicate",COPY_TO_DASHBOARD:"Search Widget Copy To Dashboard Clicked",SEARCH_WIDGET_HORIZONTAL_STRETCH:"Search Widget Horizontal Width Toggled",SEARCH_WIDGET_EXTRA_ACTION:"Search Widget Extra Action Clicked",WIDGET_EDIT_TOGGLED:"Search Widget Edit Toggled",WIDGET_EDIT_CANCEL_CLICKED:"Search Widget Edit Cancel Clicked",WIDGET_CONFIG_UPDATED:"Search Widget Config Updated"},SEARCH_WIDGET_CREATE:{AGGREGATION:"Search Widget Aggregation Created",MESSAGE_COUNT:"Search Widget Message Count Created",MESSAGE_TABLE:"Search Widget Message Table Created",LOG_VIEW:"Search Widget Log View Created"},SEARCH_FIELD_VALUE_ACTION:{CHART:"Search Field Action Chart Clicked",STATISTICS:"Search Field Action Statistics Clicked",SHOW_TOP_VALUES:"Search Field Action Show Top Values Clicked",ADD_TO_TABLE:"Search Field Action Add To Table Clicked",REMOVE_FROM_TABLE:"Search Field Action Remove From Table Clicked",ADD_TO_ALL_TABLES:"Search Field Action Add To All Tables Clicked",COPY_FIELD_NAME_TO_CLIPBOARD:"Search Field Action Copy Field Name To Clipboard Clicked",REMOVE_FROM_ALL_TABLES:"Search Field Action Remove From All Tables Clicked",EXCLUDE_FROM_RESULTS:"Search Value Action Exclude From Results Clicked",ADD_TO_QUERY:"Search Value Action Add To Query Clicked",SHOW_DOCUMENT_FOR_VALUE:"Search Value Action Show Document For Value Clicked",CREATE_EXTRACTOR:"Search Value Action Create Extractor Clicked",HIGHLIGHT_THIS_VALUE:"Search Value Action Highlight This Value Clicked",COPY_VALUE_TO_CLIPBOARD:"Search Value Action Copy Value To Clipboard Clicked",CREATE_EVENT_DEFINITION:"Search Value Action Create Event Definition Clicked",INSERT_INTO_DASHBOARD_SEARCH:"Search Value Action Insert Into Dashboard/Search Clicked",CHANGE_FIELD_TYPE_OPENED:"Search Field Action Change Field Type Opened",CHANGE_FIELD_TYPE_CLOSED:"Search Field Action Change Field Type Closed",CHANGE_FIELD_TYPE_CHANGED:"Search Field Action Change Field Type Changed"},DASHBOARD_FULL_SCREEN_MODE_STARTED:"Dashboard Fullscreen Mode Started",SEARCH_MESSAGE_TABLE_SHOW_SURROUNDING_MESSAGE:"Search Message Table Show Surrounding Message Clicked ",SEARCH_MESSAGE_TABLE_TEST_AGAINST_STREAM:"Search Message Table Test Against Stream Clicked ",SEARCH_MESSAGE_TABLE_DETAILS_TOGGLED:"Widget Message Table Details Toggled",SEARCH_SIDEBAR_TOGGLE:"Search Sidebar Toggled",SEARCH_SIDEBAR_HIGHLIGHT_CREATED:"Search Sidebar Highlight Created",SEARCH_SIDEBAR_HIGHLIGHT_UPDATED:"Search Sidebar Highlight Updated",SEARCH_SIDEBAR_HIGHLIGHT_DELETED:"Search Sidebar Highlight Deleted",SEARCH_SIDEBAR_REDO:"Search Sidebar Redo",SEARCH_SIDEBAR_UNDO:"Search Sidebar Undo",DASHBOARD_ACTION:{DASHBOARD_NEW_SAVED:"Dashboard New Saved",DASHBOARD_SAVED:"Dashboard Saved",DASHBOARD_UPDATED:"Dashboard Updated",DASHBOARD_CREATE_CLICKED:"Dashboard Create Clicked",DASHBOARD_CREATE_PAGE:"Dashboard Create Page Clicked",DASHBOARD_PAGE_CONFIGURATION:"Dashboard Page Configuration Clicked",DASHBOARD_PAGE_CONFIGURATION_UPDATED:"Dashboard Page Configuration Updated",DASHBOARD_PAGE_CONFIGURATION_CANCELED:"Dashboard Page Configuration Update Cancel",DASHBOARD_PAGE_CONFIGURATION_SORTING_UPDATED:"Dashboard Page Configuration Sorting Updated",DASHBOARD_PAGE_CONFIGURATION_PAGE_REMOVED:"Dashboard Page Configuration Page Remove"},EVENTDEFINITION_LIST:{COLUMNS_CHANGED:"EventDefinition List Columns Changed",SORT_CHANGED:"EventDefinition List Sort Changed",PAGE_SIZE_CHANGED:"EventDefinition List Page Size Changed",BULK_ACTION_DELETE_CLICKED:"EventDefinition List Bulk Delete Clicked",BULK_ACTION_ENABLE_CLICKED:"EventDefinition List Bulk Enable Clicked",BULK_ACTION_DISABLE_CLICKED:"EventDefinition List Bulk Disable Clicked",ROW_ACTION_DELETE_CLICKED:"EventDefinition List Row Delete Clicked",ROW_ACTION_ENABLE_CLICKED:"EventDefinition List Row Enable Clicked",ROW_ACTION_DISABLE_CLICKED:"EventDefinition List Row Disable Clicked",ROW_ACTION_COPY_CLICKED:"EventDefinition List Row Copy Clicked",ROW_ACTION_SHARE_CLICKED:"EventDefinition List Row Share Clicked"},EVENTDEFINITION_CREATE_BUTTON_CLICKED:"EventDefinition Create Button Clicked",EVENTDEFINITION_DUPLICATED:"EventDefinition Duplicated",EVENTDEFINITION_NEXT_CLICKED:"EventDefinition Next Clicked",EVENTDEFINITION_PREVIOUS_CLICKED:"EventDefinition Previous Clicked",EVENTDEFINITION_DETAILS:{STEP_CLICKED:"EventDefinition Details Step Clicked",PRIORITY_CHANGED:"EventDefinition Details Priority Changed"},EVENTDEFINITION_CONDITION:{STEP_CLICKED:"EventDefinition Condition Step Clicked",TYPE_SELECTED:"EventDefinition Condition Type Selected",FILTER_STREAM_SELECTED:"EventDefinition Condition Filter Stream Selected",FILTER_SEARCH_WITHIN_THE_LAST_UNIT_CHANGED:"EventDefinition Condition Filter Search Within The Last Unit Changed",FILTER_EXECUTE_SEARCH_EVERY_UNIT_CHANGED:"EventDefinition Condition Filter Execute Search Every Unit Changed",FILTER_EXECUTED_AUTOMATICALLY_TOGGLED:"EventDefinition Condition Filter Executed Automatically Toggled",FILTER_EVENT_LIMIT_CHANGED:"EventDefinition Condition Filter Event Limit Changed",AGGREGATION_TOGGLED:"EventDefinition Aggregation Toggled",AGGREGATION_GROUP_BY_FIELD_SELECTED:"EventDefinition Aggregation Group By Field Selected",CORRELATION_WITHIN_THE_LAST_UNIT_CHANGED:"EventDefinition Condition Correlation Within The Last Unit Changed",CORRELATION_EXECUTE_EVERY_UNIT_CHANGED:"EventDefinition Condition Correlation Execute Every Unit Changed",CORRELATION_EXECUTED_AUTOMATICALLY_TOGGLED:"EventDefinition Condition Correlation Executed Automatically Toggled",CORRELATION_EVENT_SELECTED:"EventDefinition Condition Correlation Event Selected",CORRELATION_ADD_EVENT_CLICKED:"EventDefinition Condition Correlation Add Event Clicked",CORRELATION_REMOVE_EVENT_CLICKED:"EventDefinition Condition Correlation Remove Event Clicked",CORRELATION_OCCURRENCE_TIME_CHANGED:"EventDefinition Condition Correlation Occurrence Time Changed",CORRELATION_NO_OCCURRENCE_FOLLOWED_BY_EVENT_SELECTED:"EventDefinition Condition Correlation No Occurrence Followed By Event Selected",CORRELATION_NO_OCCURRENCE_IN_THE_NEXT_SELECTED:"EventDefinition Condition Correlation No Occurrence In The Next Selected",CORRELATION_NO_OCCURRENCE_IN_THE_NEXT_UNIT_CHANGED:"EventDefinition Condition Correlation No Occurrence In The Next Unit Changed"},EVENTDEFINITION_FIELDS:{STEP_CLICKED:"EventDefinition Fields Step Clicked",ADD_CUSTOM_FIELD_CLICKED:"EventDefinition Fields Add Custom Field Clicked",AS_EVENT_KEY_TOGGLED:"EventDefinition Fields As Event Key Toggled",SET_VALUE_FROM_TEMPLATE_SELECTED:"EventDefinition Fields Set Value From Template Selected",SET_VALUE_FROM_LOOKUP_TABLE_SELECTED:"EventDefinition Fields Set Value From Lookup Table Selected",DONE_CLICKED:"EventDefinition Fields Done Clicked",CANCEL_CLICKED:"EventDefinition Fields Cancel Clicked"},EVENTDEFINITION_NOTIFICATIONS:{STEP_CLICKED:"EventDefinition Notifications Step Clicked",ADD_CLICKED:"EventDefinition Notifications Add Clicked",MANAGE_LINK_CLICKED:"EventDefinition Notifications Manage Link Clicked",NOTIFICATION_SELECTED:"EventDefinition Notifications Notification Selected",CREATE_NEW_CLICKED:"EventDefinition Notifications Create New Clicked",NOTIFICATION_TYPE_SELECTED:"EventDefinition Notifications Notification Type Selected",DONE_CLICKED:"EventDefinition Notifications Done Clicked",CANCEL_CLICKED:"EventDefinition Notifications Cancel Clicked"},EVENTDEFINITION_SUMMARY:{STEP_CLICKED:"EventDefinition Summary Step Clicked",CANCEL_CLICKED:"EventDefinition Summary Cancel Clicked",CREATE_CLICKED:"EventDefinition Summary Create Clicked",UPDATE_CLICKED:"EventDefinition Summary Update Clicked"},NOTIFICATIONS:{CREATE_CLICKED:"Notifications Create Clicked",EDIT_CLICKED:"Notifications Edit Clicked",EXECUTE_TEST_CLICKED:"Notifications Execute Test Clicked",BULK_ACTION_DELETE_CLICKED:"Notifications Bulk Delete Clicked",ROW_ACTION_DELETE_CLICKED:"Notifications Row Delete Clicked",ROW_ACTION_TEST_CLICKED:"Notifications Row Test Clicked"},CONTENTSTREAM:{PREV_ARROW_CLICKED:"Content Stream Left Arrow Clicked",NEXT_ARROW_CLICKED:"Content Stream Right Arrow Clicked",READ_MORE_CLICKED:"Content Stream Read More Clicked",ARTICLE_CLICKED:"Content Stream Article Clicked",RELESE_ARTICLE_CLICKED:"Content Stream Release Article Clicked",NEWS_OPT_IN_TOGGLED:"Content Stream News Opt-In Clicked",RELEASE_OPT_IN_TOGGLED:"Content Stream Release Opt-In Clicked"},STREAMS:{CREATE_FORM_MODAL_OPENED:"Stream Create Form Modal Opened",NEW_STREAM_CREATED:"Stream New Stream Created",STREAM_ITEM_UPDATED:"Stream Item Updated",STREAM_ITEM_STATUS_TOGGLED:"Stream Item Status Toggled",STREAM_ITEM_SHARE_MODAL_OPENED:"Stream Item Share Modal Opened",STREAM_ITEM_UPDATE_MODAL_OPENED:"Stream Item Update Modal Opened",STREAM_ITEM_CLONED:"Stream Item Cloned",STREAM_ITEM_RULE_SAVED:"Stream Item Rule SAVED",STREAM_ITEM_DELETED:"Stream Item Deleted"},ENTITYSHARE:{ENTITY_STREAM_SHARED:"Entity Share: Entity Stream Shared",ENTITY_SEARCH_SHARED:"Entity Share: Entity Search Shared",ENTITY_SEARCH_FILTER_SHARED:"Entity Share: Entity Filter Shared",ENTITY_EVENT_DEFINITION_SHARED:"Entity Share: Event Definition Shared",ENTITY_NOTIFICATION_SHARED:"Entity Share: Notification Shared",ENTITY_DASHBOARD_SHARED:"Entity Share: Dashboard Shared"},PIPELINE_RULE_BUILDER:{CREATE_RULE_CLICKED:"Pipeline Create Rule Clicked",RUN_RULE_SIMULATION_CLICKED:"Pipeline Run Rule Simulation Clicked",RESET_RULE_SIMULATION_CLICKED:"Pipeline Reset Rule Simulation Clicked",USE_SOURCE_CODE_EDITOR_CLICKED:"Pipeline RuleBuilder Use Source Code Editor Clicked",SWITCH_TO_SOURCE_CODE_EDITOR_CONFIRM_CLICKED:"Pipeline RuleBuilder Switch to Source Code Editor Confirm Clicked",SWITCH_TO_SOURCE_CODE_EDITOR_CANCEL_CLICKED:"Pipeline RuleBuilder Switch to Source Code Editor Cancel Clicked",CREATE_NEW_RULE_FROM_CODE_CLICKED:"Pipeline RuleBuilder Create New Rule From Code Clicked",COPY_CODE_AND_CLOSE_CLICKED:"Pipeline RuleBuilder Code Copy & Close Clicked",NEW_CONDITION_SELECTED:"Pipeline RuleBuilder New Condition Selected",NEW_ACTION_SELECTED:"Pipeline RuleBuilder New Action Selected",ADD_CONDITION_CLICKED:"Pipeline RuleBuilder Add Condition Clicked",ADD_ACTION_CLICKED:"Pipeline RuleBuilder Add Action Clicked",UPDATE_CONDITION_CLICKED:"Pipeline RuleBuilder Update Condition Clicked",UPDATE_ACTION_CLICKED:"Pipeline RuleBuilder Update Action Clicked",CANCEL_CLICKED:"Pipeline RuleBuilder Cancel Clicked",ADD_RULE_CLICKED:"Pipeline RuleBuilder Add Rule Clicked",CONVERT_TO_SOURCE_CODE_CLICKED:"Pipeline RuleBuilder Convert to Source Code Clicked",OPERATOR_AND_CLICKED:"Pipeline RuleBuilder Operator AND Clicked",OPERATOR_OR_CLICKED:"Pipeline RuleBuilder Operator OR Clicked",UPDATE_RULE_CLICKED:"Pipeline RuleBuilder Update Rule Clicked",UPDATE_RULE_AND_CLOSE_CLICKED:"Pipeline RuleBuilder Update Rule And Close Clicked",NEGATE_CONDITION_CLICKED:"Pipeline RuleBuilder Negate Condition Clicked",DUPLICATE_ACTION_CLICKED:"Pipeline RuleBuilder Duplicate Action Clicked",INSERT_ABOVE_ACTION_CLICKED:"Pipeline RuleBuilder Insert Above Action Clicked",INSERT_BELOW_ACTION_CLICKED:"Pipeline RuleBuilder Insert Below Action Clicked",DELETE_CONDITION_CLICKED:"Pipeline RuleBuilder Delete Condition Clicked",DELETE_ACTION_CLICKED:"Pipeline RuleBuilder Delete Action Clicked",EDIT_CONDITION_CLICKED:"Pipeline RuleBuilder Edit Condition Clicked",EDIT_ACTION_CLICKED:"Pipeline RuleBuilder Edit Action Clicked"},ILLUMINATE:{BUNDLE_UPLOADED:"Illuminate Bundle Uploaded",BUNDLE_DOWNLOADED_AND_INSTALLED:"Illuminate Bundle Downloaded and Installed",PACK_ENABLE_MODAL_TOGGLED:"Illuminate Pack Enable Modal Toggled",PACK_DISABLE_MODAL_TOGGLED:"Illuminate Pack Modal Toggled",PACKS_BULK_UPDATED:"Illuminate Packs Bulk Updated",PACKS_OVERRIDE_FORM_OPENED:"Illuminate Packs Override Form Opened",PACKS_OVERRIDE_SAVED:"Illuminate Packs Override Saved"},SECURITY_APP:{ASSET_DELETED:"Security Asset Deleted",ASSET_SOURCE_DELETED:"Security Asset Source Deleted",ASSET_CONFIG_REPRIORITIZED:"Security Asset Config Reprioritized",ASSET_CONFIG_CATEGORY_ADDED:"Security Asset Config Category Added",ASSET_CONFIG_CATEGORY_UPDATED:"Security Asset Config Category Updated",ASSET_CONFIG_CATEGORY_DELETED:"Security Asset Config Category Deleted",ASSET_CONFIG_PRIORITY_ADDED:"Security Asset Config Priority Added",ASSET_CONFIG_PRIORITY_UPDATED:"Security Asset Config Priority Updated",ASSET_CONFIG_PRIORITY_DELETED:"Security Asset Config Priority Deleted",INVESTIGATION_UPDATED:"Security Investigation Update",INVESTIGATION_ARCHIVED:"Security Investigation Archived",INVESTIGATION_EDITED:"Security Investigation Updated",INVESTIGATION_RESTORED:"Security Investigation Restored",INVESTIGATION_DELETED:"Security Investigation Deleted",INVESTIGATION_PRIORITY_ADDED:"Security Investigation Priority Added",INVESTIGATION_PRIORITY_UPDATED:"Security Investigation Priority Updated",INVESTIGATION_PRIORITY_DELETED:"Security Investigation Priority Deleted",INVESTIGATION_PRIORITY_REPRIORITIZED:"Security Investigation Priority Reprioritized",INVESTIGATION_PRIORITY_DEFAULT_SET:"Security Investigation Priority Default Set",INVESTIGATION_PRIORITY_DEFAULT_REMOVED:"Security Investigation Priority Default Removed",INVESTIGATION_STATUS_ADDED:"Security Investigation Status Added",INVESTIGATION_STATUS_UPDATED:"Security Investigation Status Updated",INVESTIGATION_STATUS_DELETED:"Security Investigation Status Deleted",INVESTIGATION_STATUS_REPRIORITIZED:"Security Investigation Status Reprioritized",INVESTIGATION_STATUS_DEFAULT_SET:"Security Investigation Status Default Set",INVESTIGATION_STATUS_DEFAULT_REMOVED:"Security Investigation Status Default Removed",INVESTIGATION_DETAILS_UPDATED:"Security Investigation Details Updated",INVESTIGATION_DRAWER_OPENED:"Security Investigation Drawer Opened",INVESTIGATION_DRAWER_CLOSED:"Security Investigation Drawer Closed",INVESTIGATION_DRAWER_COLLAPSE_TOGGLED:"Security Investigation Drawer Collapse Toggled",INVESTIGATION_NOTE_ADDED:"Security Investigation Note Added",INVESTIGATION_NOTE_SAVED:"Security Investigation Note Saved",INVESTIGATION_NOTE_EDIT:"Security Investigation Note Updated",INVESTIGATION_NOTE_DELETED:"Security Investigation Note Deleted",SIGMA_IMPORT_RULES_OPENED:"Security Sigma Rules Import Opened",SIGMA_IMPORT_RULES_IMPORTED:"Security Sigma Rules Imported",SIGMA_RULE_UPDATED:"Security Sigma Rules Update",SIGMA_RULE_CREATED:"Security Sigma Rules Created",ANOMALY_DETECTION_SAVED:"Security Anomaly Detection Saved",ANOMALY_DETECTION_DELETED:"Security Anomaly Detection Deleted"},FORWARDER:{INPUTPROFILE_FORWARDER_ASSIGNED:"Forwarder Input Profile Forwarder Assigned",FORWARDER_WIZARD_WELCOME_STEP_OPENED:"Forwarder Wizard Welcome Step Opened",FORWARDER_WIZARD_SELECT_FORWARDER_STEP_OPENED:"Forwarder Wizard Select Forwarder Step Opened",FORWARDER_WIZARD_CONFIGURE_FORWARDER_STEP_OPENED:"Forwarder Wizard Configure Forwarder Step Opened",FORWARDER_WIZARD_INPUTS_STEP_OPENED:"Forwarder Wizard Forwarder Inputs Step Opened",FORWARDER_WIZARD_SUMMARY_STEP_OPENED:"Forwarder Wizard Forwarder Summary Step Opened",FORWARDER_WIZARD_CONFIGURE_FORWARDER_SELECTED:"Forwarder Wizard Configure Forwarder Selected",FORWARDER_WIZARD_CONFIGURE_FORWARDER_SAVED:"Forwarder Wizard Configure Forwarder Saved",FORWARDER_WIZARD_INPUT_PROFILE_SELECTED:"Forwarder Wizard Input Profile Selected",FORWARDER_WIZARD_INPUT_PROFILE_SAVED:"Forwarder Wizard Input Profile Saved",FORWARDER_INPUT_PROFILE_CREATED:"Forwarder Input Profile Created",FORWARDER_CREATED:"Forwarder Created",FORWARDER_UPDATED:"Forwarder Updated",FORWARDER_DELETED:"Forwarder Created",FORWARDER_CONFIGURATION_REMOVED:"Forwarder Configuration Removed",FORWARDER_INPUT_PROFILE_UPDATED:"Forwarder Input Profile Updated",FORWARDER_INPUT_PROFILE_FORWARDER_ASSIGNED:"Forwarder Input Profile Forwarder Assigned",FORWARDER_INPUT_PROFILE_CREATE_CANCELED:"Forwarder Input Profile Create Canceled",FORWARDER_INPUT_PROFILE_INPUT_CREATED:"Forwarder Input Profile Input Created",FORWARDER_INPUT_PROFILE_INPUT_UPDATED:"Forwarder Input Profile Input Updated",FORWARDER_INPUT_PROFILE_INPUT_DELETED:"Forwarder Input Profile Input Deleted",FORWARDER_WIZARD_SETUP_CANCELED:"Forwarder Wizard Setup Canceled"},ARCHIVE:{DELETED:"Archive Deleted",RESTORED:"Archive Restored",CREATED:"Archive Created",ITEM_DETAILS_TOGGLED:"Archive Item Details Opened",BACKEND_CONFIGURATION_UPDATED:"Archive Backend Configuration Updated",BACKEND_CONFIGURATION_CREATED:"Archive Backend Configuration Created",BACKEND_CONFIGURATION_DELETED:"Archive Backend Configuration Deleted",CONFIGURATION_UPDATED:"Archive Configuration Update"},LICENSE:{VALIDATED:"License Validated",SAVED:"License Saved",DELETED:"License Deleted"},REPORT:{CONFIGURED:"Report Configured",DELETED:"Report Deleted",SENT:"Report Sent",CREATED:"Report Created",UPDATED:"Report Updated"},CUSTOMIZATION:{NOTIFICATION_CREATED:"Customization Notification Created",NOTIFICATION_DELETED:"Customization Notification Deleted",NOTIFICATION_BULK_DELETED:"Customization Notification Bulk Deleted",THEME_REVERTED:"Customization Theme Reverted",THEME_RESETED:"Customization Theme Reseted",HEADER_BADGE_UPDATED:"Customization Header Badge Updated"},TRAFFIC_VIOLATION_CONFIGURATION_SAVED:"Traffic Violation Configuration Saved",FAILURE_PROCESSING_CONFIGURATION_SAVED:"Failure Processing Configuration Saved",SHORTCUT_TYPED:"Shortcut Typed",CONFIGURATIONS:{INDEX_SETS_UPDATED:"Configurations Index Sets Defaults Updated",THREATINTEL_CONFIGURATION_UPDATED:"Configurations Threat Intel Configuration Updated",PERMISSIONS_UPDATED:"Configurations Permissions Updated",SEARCHES_UPDATED:"Configurations Searches Updated",URL_WHITE_LIST_UPDATED:"Configurations Url White List Updated",USER_UPDATED:"Configurations User Updated",CERTIFICATE_RENEWAL_UPDATED:"Configurations Certificate Renewal Updated",CERTIFICATE_RENEWAL_POLICY_UPDATED:"Configurations Certificate Renewal Policy Updated",DECORATORS_UPDATED:"Configurations Decorators Updated",GEOLOCATION_CONFIGURATION_UPDATED:"Configurations Geolocation Configuration Updated"},INPUTS:{INPUT_SELECTED:"Inputs Input Selected",INPUT_CREATED:"Inputs Input Created",FIND_MORE_CLICKED:"Inputs Find More Inputs Clicked",INPUT_DELETED:"Inputs Input Deleted",INPUT_EDIT_CLICKED:"Inputs Input Edit Clicked",INPUT_UPDATED:"Inputs Input Updated",SHOW_RECEIVED_MESSAGES_CLICKED:"Inputs Show Received Messages Clicked",MANAGE_EXTRACTORS_CLICKED:"Inputs Manage Extractors Clicked",SHOW_METRICS_CLICKED:"Inputs Show Metrics Clicked",INPUT_START_CLICKED:"Inputs Input Start Clicked",INPUT_STOP_CLICKED:"Inputs Input Stop Clicked"},OUTPUTS:{OUTPUT_CREATED:"Outputs Output Created",OUTPUT_ASSIGNED:"Outputs Output Assigned",OUTPUT_GLOBALLY_REMOVED:"Outputs Output Globally Removed",OUTPUT_FROM_STREAM_REMOVED:"Outputs Output From Stream Removed",OUTPUT_UPDATED:"Outputs Output Updated"},INDICES:{INDEX_SET_DEFAULT_SET:"Indices Index Set Default Set",INDEX_SET_DELETED:"Indices Index Set Deleted",INDEX_SET_CREATED:"Indices Index Set Created",INDEX_SET_UPDATED:"Indices Index Set Updated"},LOGGING:{LOG_LEVEL_EDITED:"Logging Log Level Edited",SHOW_LOG_LEVEL_METRICS_TOGGLED:"Logging Show Log Level Metrics Toggled"},LUT:{DELETED:"LUT Deleted",CREATED:"LUT Created",UPDATED:"LUT Updated",CACHE_TYPE_CHANGED:"LUT Cache Type Changed",CACHE_DELETED:"LUT Cache Deleted",CACHE_CREATED:"LUT Cache Created",CACHE_UPDATED:"LUT Cache Updated",DATA_ADAPTER_DELETED:"LUT Data Adapter Deleted",DATA_ADAPTER_CREATED:"LUT Data Adapter Created",DATA_ADAPTER_UPDATED:"LUT Data Adapter Updated"},USERS:{USER_CREATED:"Users User Created",USER_DISABLED:"Users User Disabled",USER_ENABLED:"Users User Enabled",USER_DELETED:"Users User Deleted"},GROK_PATTERN:{CREATED:"Grok Pattern Created",UPDATED:"Grok Pattern Updated",DELETED:"Grok Pattern Deleted",TESTED:"Grok Pattern Tested",IMPORTED:"Grok Pattern Imported"},ROLES:{USER_ASSIGNED:"Roles User Assigned",USER_UNASSIGNED:"Roles User Unassigned"},AUTHENTICATION:{CONFIG_UPDATED:"Authentication Config Updated",SERVICE_CREATED:"Authentication Service Created",SERVICE_SELECTED:"Authentication Service Selected",DIRECTORY_SERVER_CONFIG_SAVE_CLICKED:"Authentication Directory Server Config Save Clicked",DIRECTORY_USER_SYNC_SAVE_CLICKED:"Authentication Directory User Sync Save Clicked",DIRECTORY_GROUP_SYNC_SAVE_CLICKED:"Authentication Directory Group Sync Save Clicked",DIRECTORY_NEXT_USER_SYNC_CLICKED:"Authentication Directory Next User Sync Clicked",DIRECTORY_NEXT_GROUP_SYNC_CLICKED:"Authentication Directory Next Group Sync Clicked",OIDC_SERVER_CONFIG_SAVE_CLICKED:"Authentication OIDC Server Config Save Clicked",OIDC_NEXT_GROUP_SYNC_CLICKED:"Authentication OIDC Next Group Sync Clicked",OIDC_PREVIOUS_SERVER_CONFIG_CLICKED:"Authentication OIDC Previous Server Config Clicked",OIDC_GROUP_SYNC_SAVE_CLICKED:"Authentication OIDC Group Sync Save Clicked"},SIDECARS:{CONFIGURATION_CREATED:"Sidecar Configuration Created",CONFIGURATION_UPDATED:"Sidecar Configuration Updated",CONFIGURATION_CLONED:"Sidecar Configuration Cloned",CONFIGURATION_DELETED:"Sidecar Configuration Deleted",CONFIGURATION_ASSIGNED:"Sidecar Configuration Assigned",PROCESS_ACTION_SET:"Sidecar Process Action Set",LOG_COLLECTOR_CLONED:"Sidecar Log Collector Cloned",LOG_COLLECTOR_CREATED:"Sidecar Log Collector Created",LOG_COLLECTOR_SERVICE_TYPE_CHANGED:"Sidecar Log Collector Service Type Changed",LOG_COLLECTOR_NODE_OPERATING_SYSTEM_CHANGED:"Sidecar Log Collector Node Operating System Changed",LOG_COLLECTOR_UPDATED:"Sidecar Log Collector Updated",LOG_COLLECTOR_DELETED:"Sidecar Log Collector Deleted"},SYSTEM_OVERVIEW_OUTGOING_TRAFFIC_DAYS_CHANGED:"System Overview Outgoing Traffic Days Changed",URLWHITELIST_CONFIGURATION_UPDATED:"Urlwhitelist Configuration Updated",CONTENT_PACK:{INSTALLED:"Content Pack Installed",DOWNLOADED:"Content Pack Downloaded",ALL_VERSIONS_DELETED:"Content Pack All Versions Deleted"},TEAM:{CREATED:"Team Created",ASSIGNED:"Team Assigned",UNASSIGNED:"Team Unassigned",DELETED:"Team Deleted"}}},"Crt2wUQ/":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext({sendTelemetry:()=>{}}),r=(0,s.ri)("contexts.TelemetryContext",()=>o)},"8OvTct/Z":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("Z7aTuO5B"),s=e("Crt2wUQ/"),o=e("yAXMqwrl"),r=e("IA3Ku5lS");const n=()=>{const g=(0,o.useLocation)(),p=(0,t.useContext)(o.UNSAFE_DataRouterContext);return(0,t.useMemo)(()=>{var E;if((E=p==null?void 0:p.router)!=null&&E.routes){const{router:{routes:a}}=p,u=(0,o.matchRoutes)(a,g.pathname),{route:f}=u.at(-1);return f.path}},[g.pathname,p])},c=(0,r.ri)("hooks.useRoutePattern",()=>n),d=()=>{const{sendTelemetry:g}=(0,t.useContext)(s.Z),p=c();return(0,t.useCallback)((E,a)=>g(E,{app_path_pattern:p,...a}),[g,p])}},BqxuktKK:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("8OvTct/Z");const r=n=>function(v){const d=(0,s.Z)();return t.createElement(n,{...v,sendTelemetry:d})}},sIZ0mQDD:(M,C,e)=>{"use strict";e.r(C),e.d(C,{default:()=>c});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("m5sCWlWB");const n=({displayPageLayout:v})=>{const d=t.createElement(t.Fragment,null,t.createElement("p",null,"The party gorilla was just here, but had another party to rock."),t.createElement("p",null,"Oh, party gorilla! How we miss you! Will we ever see you again?"));return t.createElement(r.Z,{title:"Page not found",description:d,displayPageLayout:v})};n.propTypes={displayPageLayout:o().bool},n.defaultProps={displayPageLayout:!0};const c=n},"6vcCRWgg":(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("RCNj0OY4"),c=e("/GOzvPf6"),v=e("uZqmR+ju"),d=e("m5sCWlWB"),g=e("zeW/qtng"),p=e("SLtHYqXc");const E=r.default.div` font-weight: normal; `,a=t.createElement(t.Fragment,null,t.createElement("p",null,"It seems like the page you navigated to contained an error."),t.createElement("p",null,"You can use the navigation to reach other parts of the product, refresh the page or submit an error report.")),u=({error:y,componentStack:T})=>{const[P,O]=(0,t.useState)(n.Z.gl2DevMode()),b=` Stack Trace: ${y.stack} Component Stack: ${T}`,L=(0,t.useCallback)(x=>{x.preventDefault(),O(W=>!W)},[]);return t.createElement(d.Z,{title:"Something went wrong.",description:a},t.createElement("div",{className:"content",style:{padding:"2em"}},t.createElement(g.Z,null)),t.createElement("dl",null,t.createElement("dt",null,"Error:",t.createElement(E,{className:"pull-right"},t.createElement(v.Button,{bsStyle:"link",tabIndex:0,onClick:L},P?"Show less":"Show more"))),t.createElement("dt",null,t.createElement("pre",{className:"content",id:"render-error"},t.createElement("div",{className:"pull-right"},t.createElement(p.Z,{title:t.createElement(c.JO,{name:"copy",fixedWidth:!0}),bsSize:"sm",text:`${y.message} ${b}`,buttonTitle:"Copy error details to clipboard"})),y.message,P&&b))))};u.propTypes={error:o().shape({message:o().string.isRequired,stack:o().string}).isRequired,componentStack:o().string.isRequired};const f=u},CYFwYmkW:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("knkDHhNA");const n=({error:v,missingStreamIds:d=[]})=>{var g,p;const E=t.createElement(t.Fragment,null,t.createElement("p",null,"This resource includes streams you do not have permissions for."),t.createElement("p",null,"Please contact your administrator and provide the error details which include a list of streams you need access to.")),a=d.length>0?d:(p=(g=v==null?void 0:v.additional)==null?void 0:g.body)==null?void 0:p.streams,u=(a==null?void 0:a.length)>0?`You need permissions for streams with the id: ${a.join(", ")}.`:void 0;return t.createElement(r.Z,{error:v,description:E,title:"Missing Stream Permissions",errorDetails:u})};n.propTypes={error:o().shape({message:o().string.isRequired,additional:o().shape({body:o().shape({streams:o().arrayOf(o().string)})})}).isRequired,missingStreamIds:o().arrayOf(o().string)},n.defaultProps={missingStreamIds:[]};const c=n},knkDHhNA:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("/GOzvPf6"),n=e("m5sCWlWB"),c=e("HCsT5Gmk");const v=(p,E,a)=>{const u=`${E} ${a}`;return p?`${p} ${u}`:u},d=({error:p,errorDetails:E,title:a,description:u,location:{pathname:f}})=>{const y=(p==null?void 0:p.message)||JSON.stringify(p),T=`The permissions check for the following request failed, while trying to access ${f}.`,P=t.createElement(t.Fragment,null,t.createElement("p",null,"You do not have the required permissions to view this resource."),t.createElement("p",null,"Please contact your administrator and provide the error details.")),O=v(E,T,y);return t.createElement(n.Z,{title:a,description:u!=null?u:P},t.createElement("dl",null,t.createElement("dd",null,t.createElement("pre",{className:"content"},t.createElement("div",{className:"pull-right"},t.createElement(r.mU,{title:t.createElement(r.JO,{name:"copy",fixedWidth:!0}),bsSize:"sm",text:O,buttonTitle:"Copy error details to clipboard"})),E&&t.createElement("p",null,E),t.createElement("p",null,T),t.createElement("p",null,y)))))};d.propTypes={description:o().element,errorDetails:o().string,title:o().string},d.defaultProps={description:void 0,errorDetails:void 0,title:"Missing Permissions"};const g=(0,c.Z)(d)},U1Iufsob:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("pjsNBHWI"),s=e.n(t);const r={AlarmCallbacksApiController:{available:()=>({url:"/alerts/callbacks/types"}),create:n=>({url:`/streams/${n}/alarmcallbacks`}),delete:(n,c)=>({url:`/streams/${n}/alarmcallbacks/${c}`}),listAll:()=>({url:"/alerts/callbacks"}),list:n=>({url:`/streams/${n}/alarmcallbacks`}),testAlert:n=>({url:`/alerts/callbacks/${n}/test`}),update:(n,c)=>({url:`/streams/${n}/alarmcallbacks/${c}`})},AlarmCallbackHistoryApiController:{list:(n,c)=>({url:`/streams/${n}/alerts/${c}/history`})},AuthenticationController:{create:()=>({url:"/system/authentication/services/backends"}),delete:n=>({url:`/system/authentication/services/backends/${n}`}),disableUser:n=>({url:`/system/authentication/users/${n}/disable`}),enableUser:n=>({url:`/system/authentication/users/${n}/enable`}),load:n=>({url:`/system/authentication/services/backends/${n}`}),loadActive:()=>({url:"/system/authentication/services/active-backend"}),loadUsersPaginated:n=>({url:`/system/authentication/services/backends/${n}/users`}),loadActiveBackendType:()=>({url:"/system/authentication/services/backends/active-backend/type"}),servicesPaginated:()=>({url:"/system/authentication/services/backends"}),testConnection:()=>({url:"/system/authentication/services/test/backend/connection"}),testLogin:()=>({url:"/system/authentication/services/test/backend/login"}),update:n=>({url:`/system/authentication/services/backends/${n}`}),updateConfiguration:()=>({url:"/system/authentication/services/configuration"})},AuthzRolesController:{load:n=>({url:`/authz/roles/${n}`}),delete:n=>({url:`/authz/roles/${n}`}),list:()=>({url:"/authz/roles"}),removeMember:(n,c)=>({url:`/authz/roles/${n}/assignee/${c}`}),addMembers:n=>({url:`/authz/roles/${n}/assignees`}),loadRolesForUser:n=>({url:`/authz/roles/user/${n}`}),loadUsersForRole:n=>({url:`/authz/roles/${n}/assignees`})},CatalogsController:{showEntityIndex:()=>({url:"/system/catalog"}),queryEntities:()=>({url:"/system/catalog"})},CodecTypesController:{list:()=>({url:"/system/codecs/types/all"})},ContentPacksController:{list:()=>({url:"/system/content_packs/latest"}),get:n=>({url:`/system/content_packs/${n}`}),getRev:(n,c)=>({url:`/system/content_packs/${n}/${c}`}),downloadRev:(n,c)=>({url:`/system/content_packs/${n}/${c}/download`}),create:()=>({url:"/system/content_packs"}),delete:n=>({url:`/system/content_packs/${n}`}),deleteRev:(n,c)=>({url:`/system/content_packs/${n}/${c}`}),install:(n,c)=>({url:`/system/content_packs/${n}/${c}/installations`}),installList:n=>({url:`/system/content_packs/${n}/installations`}),uninstall:(n,c)=>({url:`/system/content_packs/${n}/installations/${c}`}),uninstallDetails:(n,c)=>({url:`/system/content_packs/${n}/installations/${c}/uninstall_details`})},CountsApiController:{total:()=>({url:"/count/total"}),indexSetTotal:n=>({url:`/count/${n}/total`})},ClusterApiResource:{list:()=>({url:"/system/cluster/nodes"}),node:()=>({url:"/system/cluster/node"}),elasticsearchStats:()=>({url:"/system/cluster/stats/elasticsearch"})},ClusterConfigResource:{config:()=>({url:"/system/cluster_config"})},GrokPatternsController:{test:()=>({url:"/system/grok/test"}),paginated:()=>({url:"/system/grok/paginated"})},DashboardsApiController:{create:()=>({url:"/dashboards"}),index:()=>({url:"/dashboards"}),get:n=>({url:`/dashboards/${n}`}),delete:n=>({url:`/dashboards/${n}`}),update:n=>({url:`/dashboards/${n}`}),addWidget:n=>({url:`/dashboards/${n}/widgets`}),removeWidget:(n,c)=>({url:`/dashboards/${n}/widgets/${c}`}),widget:(n,c)=>({url:`/dashboards/${n}/widgets/${c}`}),updateWidget:(n,c)=>({url:`/dashboards/${n}/widgets/${c}`}),widgetValue:(n,c)=>({url:`/dashboards/${n}/widgets/${c}/value`}),updatePositions:n=>({url:`/dashboards/${n}/positions`})},DecoratorsResource:{available:()=>({url:"/search/decorators/available"}),create:()=>({url:"/search/decorators"}),get:()=>({url:"/search/decorators"}),remove:n=>({url:`/search/decorators/${n}`}),update:n=>({url:`/search/decorators/${n}`})},DeflectorApiController:{cycle:n=>({url:`/cluster/deflector/${n}/cycle`}),list:n=>({url:`/system/deflector/${n}`})},EntityScopeController:{getScope:()=>({url:"/entity_scopes"})},EntityShareController:{prepare:n=>({url:`/authz/shares/entities/${n}/prepare`}),update:n=>({url:`/authz/shares/entities/${n}`}),userSharesPaginated:n=>({url:`/authz/shares/user/${n}`}),entityScopes:()=>({url:"/entity_scopes"})},EventDefinitionsApiController:{list:()=>({url:"/events/definitions"}),paginated:()=>({url:"/events/definitions/paginated"}),get:n=>({url:`/events/definitions/${n}`}),create:()=>({url:"/events/definitions"}),bulkDelete:()=>({url:"/events/definitions/bulk_delete"}),bulkSchedule:()=>({url:"/events/definitions/bulk_schedule"}),bulkUnschedule:()=>({url:"/events/definitions/bulk_unschedule"}),update:n=>({url:`/events/definitions/${n}`}),delete:n=>({url:`/events/definitions/${n}`})},EventNotificationsApiController:{list:()=>({url:"/events/notifications"}),paginated:()=>({url:"/events/notifications/paginated"}),get:n=>({url:`/events/notifications/${n}`}),create:()=>({url:"/events/notifications"}),bulkDelete:()=>({url:"/events/notifications/bulk_delete"}),bulkSchedule:()=>({url:"/events/notifications/bulk_schedule"}),bulkUnschedule:()=>({url:"/events/notifications/bulk_unschedule"}),update:n=>({url:`/events/notifications/${n}`}),delete:n=>({url:`/events/notifications/${n}`})},HTTPHeaderAuthConfigController:{load:()=>({url:"/system/authentication/http-header-auth-config"}),update:()=>({url:"/system/authentication/http-header-auth-config"})},IndexerClusterApiController:{health:()=>({url:"/system/indexer/cluster/health"}),name:()=>({url:"/system/indexer/cluster/name"})},IndexerFailuresApiController:{count:n=>({url:`/system/indexer/failures/count?since=${n}`}),list:(n,c)=>({url:`/system/indexer/failures?limit=${n}&offset=${c}`})},IndexerOverviewApiResource:{list:n=>({url:`/system/indexer/overview/${n}`})},IndexRangesApiController:{list:()=>({url:"/system/indices/ranges"}),rebuild:n=>({url:`/system/indices/ranges/index_set/${n}/rebuild`}),rebuildSingle:n=>({url:`/system/indices/ranges/${n}/rebuild`})},IndexSetsApiController:{list:n=>({url:`/system/indices/index_sets?stats=${n}`}),listPaginated:(n,c,v)=>({url:`/system/indices/index_sets?skip=${n}&limit=${c}&stats=${v}`}),get:n=>({url:`/system/indices/index_sets/${n}`}),create:()=>({url:"/system/indices/index_sets"}),delete:(n,c)=>({url:`/system/indices/index_sets/${n}?delete_indices=${c}`}),searchPaginated:(n,c,v,d)=>({url:`/system/indices/index_sets/search?searchTitle=${n}&skip=${c}&limit=${v}&stats=${d}`}),setDefault:n=>({url:`/system/indices/index_sets/${n}/default`}),stats:()=>({url:"/system/indices/index_sets/stats"})},IndicesApiController:{close:n=>({url:`/system/indexer/indices/${n}/close`}),delete:n=>({url:`/system/indexer/indices/${n}`}),list:n=>({url:`/system/indexer/indices/${n}/list`}),listAll:()=>({url:"/system/indexer/indices"}),listClosed:n=>({url:`/system/indexer/indices/${n}/closed`}),multiple:()=>({url:"/system/indexer/indices/multiple"}),reopen:n=>({url:`/system/indexer/indices/${n}/reopen`})},InputsApiController:{list:()=>({url:"/system/inputs"}),get:n=>({url:`/system/inputs/${n}`}),globalRecentMessage:n=>({url:`/${n}`})},InputStatesController:{start:n=>({url:`/system/inputstates/${n}`}),stop:n=>({url:`/system/inputstates/${n}`})},ClusterInputStatesController:{list:()=>({url:"/cluster/inputstates"}),start:n=>({url:`/cluster/inputstates/${n}`}),stop:n=>({url:`/cluster/inputstates/${n}`})},ClusterLoggersResource:{loggers:()=>({url:"/cluster/system/loggers"}),subsystems:()=>({url:"/cluster/system/loggers/subsystems"}),setSubsystemLoggerLevel:(n,c,v)=>({url:`/cluster/system/loggers/${n}/subsystems/${c}/level/${v}`})},ClusterSupportBundleController:{delete:n=>({url:`/cluster/debug/support/bundle/${n}`}),download:n=>({url:`/cluster/debug/support/bundle/download/${n}`}),list:()=>({url:"/cluster/debug/support/bundle/list"}),create:()=>({url:"/cluster/debug/support/bundle/build"})},MessageFieldsApiController:{list:()=>({url:"/system/fields"}),types:()=>({url:"views/fields"})},MetricsApiController:{multiple:()=>({url:"/system/metrics/multiple"}),byNamespace:n=>({url:`/system/metrics/namespace/${n}`})},ClusterMetricsApiController:{multiple:n=>({url:`/cluster/${n}/metrics/multiple`}),multipleAllNodes:()=>({url:"/cluster/metrics/multiple"}),byNamespace:(n,c)=>({url:`/cluster/${n}/metrics/namespace/${c}`})},NotificationsApiController:{delete:n=>({url:`/system/notifications/${n}`}),deleteWithKey:(n,c)=>({url:`/system/notifications/${n}/${c}`}),list:()=>({url:"/system/notifications"}),getHtmlMessage:n=>({url:`/system/notification/message/html/${n.toLocaleUpperCase()}`}),getHtmlMessageWithKey:(n,c)=>({url:`/system/notification/message/html/${n.toLocaleUpperCase()}/${c}`})},OutputsApiController:{index:()=>({url:"/system/outputs"}),create:()=>({url:"/system/outputs"}),delete:n=>({url:`/system/outputs/${n}`}),update:n=>({url:`/system/outputs/${n}`}),availableType:n=>({url:`/system/outputs/available/${n}`}),availableTypes:()=>({url:"/system/outputs/available"})},RolesApiController:{listRoles:()=>({url:"/roles"}),createRole:()=>({url:"/roles"}),updateRole:n=>({url:`/roles/${n}`}),deleteRole:n=>({url:`/roles/${n}`}),loadMembers:n=>({url:`/roles/${n}/members`})},SavedSearchesApiController:{create:()=>({url:"/search/saved"}),delete:n=>({url:`/search/saved/${n}`}),update:n=>({url:`/search/saved/${n}`})},SessionsApiController:{validate:()=>({url:"/system/sessions"})},StreamsApiController:{index:()=>({url:"/streams"}),paginated:()=>({url:"/streams/paginated"}),get:n=>({url:`/streams/${n}`}),bulk_delete:()=>({url:"/streams/bulk_delete"}),bulk_resume:()=>({url:"/streams/bulk_resume"}),bulk_pause:()=>({url:"/streams/bulk_pause"}),create:()=>({url:"/streams"}),update:n=>({url:`/streams/${n}`}),cloneStream:n=>({url:`/streams/${n}/clone`}),delete:n=>({url:`/streams/${n}`}),pause:n=>({url:`/streams/${n}/pause`}),resume:n=>({url:`/streams/${n}/resume`}),testMatch:n=>({url:`/streams/${n}/testMatch`})},StreamOutputsApiController:{add:n=>({url:`/streams/${n}/outputs`}),index:n=>({url:`/streams/${n}/outputs`}),delete:(n,c)=>({url:`/streams/${n}/outputs/${c}`})},StreamRulesApiController:{delete:(n,c)=>({url:`/streams/${n}/rules/${c}`}),update:(n,c)=>({url:`/streams/${n}/rules/${c}`}),create:n=>({url:`/streams/${n}/rules`})},SystemApiController:{info:()=>({url:"/system"}),jvm:()=>({url:"/system/jvm"}),fields:()=>({url:"/system/fields"}),locales:()=>({url:"/system/locales"})},SystemJobsApiController:{list:()=>({url:"/cluster/jobs"}),getJob:n=>({url:`/cluster/jobs/${n}`}),acknowledgeJob:n=>({url:`/system/jobs/acknowledge/${n}`}),cancelJob:n=>({url:`/cluster/jobs/${n}`})},SystemMessagesApiController:{all:n=>({url:`/system/messages?page=${n}`})},SystemSearchVersionApiController:{satisfiesVersion:(n,c)=>({url:`/system/searchVersion/satisfiesVersion/${n}${c?`?version=${c}`:""}`})},ToolsApiController:{grokTest:()=>({url:"/tools/grok_tester"}),jsonTest:()=>({url:"/tools/json_tester"}),naturalDateTest:(n,c)=>({url:`/tools/natural_date_tester?string=${n}&timezone=${c}`}),regexTest:()=>({url:"/tools/regex_tester"}),regexValidate:n=>({url:`/tools/regex_tester/validate?regex=${n}`}),regexReplaceTest:()=>({url:"/tools/regex_replace_tester"}),splitAndIndexTest:()=>({url:"/tools/split_and_index_tester"}),substringTest:()=>({url:"/tools/substring_tester"}),containsStringTest:()=>({url:"/tools/contains_string_tester"}),lookupTableTest:()=>({url:"/tools/lookup_table_tester"}),urlWhitelistCheck:()=>({url:"/system/urlwhitelist/check"}),urlWhitelistGenerateRegex:()=>({url:"/system/urlwhitelist/generate_regex"})},TelemetryApiController:{info:()=>({url:"/telemetry"}),setting:()=>({url:"/telemetry/user/settings"})},UniversalSearchApiController:{_streamFilter(n){return n?{filter:`streams:${n}`}:{}},_buildBaseQueryString(n,c,v){const d={},g=this._streamFilter(v);return d.query=n,Object.keys(c).forEach(p=>{d[p]=c[p]}),Object.keys(g).forEach(p=>{d[p]=g[p]}),d},_buildUrl(n,c){return`${n}?${s().stringify(c)}`},search(n,c,v,d,g,p,E,a,u){const f=`/search/universal/${n}`,y=this._buildBaseQueryString(c,v,d);return g&&(y.limit=g),p&&(y.offset=p),E&&a&&(y.sort=`${E}:${a}`),u!==void 0&&(y.decorate=u),{url:this._buildUrl(f,y)}},export(n,c,v,d,g,p,E){const a=`/search/universal/${n}/export`,u=this._buildBaseQueryString(c,v,d);return g&&(u.limit=g),p&&(u.offset=p),E&&(u.fields=E.join(",")),{url:this._buildUrl(a,u)}}},UsersApiController:{changePassword:n=>({url:`/users/${n}/password`}),create:()=>({url:"/users"}),list:()=>({url:"/users"}),paginated:()=>({url:"/users/paginated"}),load:n=>({url:`/users/id/${n}`}),loadByUsername:n=>({url:`/users/${n}`}),delete:n=>({url:`/users/id/${n}`}),update:n=>({url:`/users/${n}`}),create_token:(n,c)=>({url:`/users/${n}/tokens/${c}`}),delete_token:(n,c)=>({url:`/users/${n}/tokens/${c}`}),list_tokens:n=>({url:`/users/${n}/tokens`}),setStatus:(n,c)=>({url:`/users/${n}/status/${c}`})},DashboardsController:{show:n=>({url:`/dashboards/${n}`})},ExtractorsController:{create:n=>({url:`/system/inputs/${n}/extractors`}),delete:(n,c)=>({url:`/system/inputs/${n}/extractors/${c}`}),order:n=>({url:`/system/inputs/${n}/extractors/order`}),update:(n,c)=>({url:`/system/inputs/${n}/extractors/${c}`})},MessagesController:{analyze:(n,c)=>({url:`/messages/${n}/analyze?string=${c}`}),parse:()=>({url:"/messages/parse"}),single:(n,c)=>({url:`/messages/${n}/${c}`}),exportSearch:n=>({url:`/views/search/messages/${n}`}),exportSearchType:(n,c)=>({url:`/views/search/messages/${n}/${c}`}),jobResults:(n,c)=>({url:`/views/search/messages/job/${n}/${c}`})},ExportJobsController:{exportSearch:n=>({url:`/views/export/${n}`}),exportSearchType:(n,c)=>({url:`/views/export/${n}/${c}`})},MapDataController:{search:()=>({url:"/search/mapdata"})},PipelinesController:{list:()=>({url:"/system/pipelines/pipeline"}),paginatedList:()=>({url:"/system/pipelines/pipeline/paginated"}),create:()=>({url:"/system/pipelines/pipeline"}),get:n=>({url:`/system/pipelines/pipeline/${n}`}),update:n=>({url:`/system/pipelines/pipeline/${n}`}),delete:n=>({url:`/system/pipelines/pipeline/${n}`}),parse:()=>({url:"/system/pipelines/pipeline/parse"})},RulesController:{list:()=>({url:"/system/pipelines/rule"}),paginatedList:()=>({url:"/system/pipelines/rule/paginated"}),create:()=>({url:"/system/pipelines/rule"}),get:n=>({url:`/system/pipelines/rule/${n}`}),update:n=>({url:`/system/pipelines/rule/${n}`}),delete:n=>({url:`/system/pipelines/rule/${n}`}),multiple:()=>({url:"/system/pipelines/rule/multiple"}),functions:()=>({url:"/system/pipelines/rule/functions"}),parse:()=>({url:"/system/pipelines/rule/parse"}),simulate:()=>({url:"/system/pipelines/rule/simulate"}),metricsConfig:()=>({url:"/system/pipelines/rule/config/metrics"})},RuleBuilderController:{create:()=>({url:"/system/pipelines/rulebuilder"}),update:n=>({url:`/system/pipelines/rulebuilder/${n}`}),validate:()=>({url:"/system/pipelines/rulebuilder/validate"}),simulate:()=>({url:"/system/pipelines/rulebuilder/simulate"}),listConditionsDict:()=>({url:"/system/pipelines/rulebuilder/conditions"}),listActionsDict:()=>({url:"/system/pipelines/rulebuilder/actions"})},ConnectionsController:{list:()=>({url:"/system/pipelines/connections"}),to_stream:()=>({url:"/system/pipelines/connections/to_stream"}),to_pipeline:()=>({url:"/system/pipelines/connections/to_pipeline"})},SimulatorController:{simulate:()=>({url:"/system/pipelines/simulate"})},ping:()=>({url:"/"})}},"+w7neh6x":(M,C,e)=>{"use strict";e.d(C,{Z:()=>Ar});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("ww+BtWnX"),r=e.n(o),n=e("yAXMqwrl"),c=e("QvoWw71B"),v=e("ZaccISJq"),d=e("ii0bleBb"),g=e.n(d),p=e("7GNmVOX8"),E=e("D/X+X5ed");const a=(0,t.createContext)(void 0),u=({children:Ie,loginName:Qe})=>{const bt=`gl-scratchpad-${Qe}`,Ut=p.Z.get(bt)||{},[Qt,un]=(0,t.useState)(Ut.opened||!1),Ln=(0,t.useMemo)(()=>({isScratchpadVisible:Qt,localStorageItem:bt,setScratchpadVisibility:Nn=>{const Uo=p.Z.get(bt);p.Z.set(bt,{...Uo,opened:Nn}),un(Nn)},toggleScratchpadVisibility:()=>{const Nn=p.Z.get(bt);p.Z.set(bt,{...Nn,opened:!Qt}),un(!Qt)}}),[Qt,bt]);return(0,E.Z)({actionKey:"show-scratchpad-modal",callback:()=>{un(!0)},scope:"general"}),t.createElement(a.Provider,{value:Ln},Ie)};u.propTypes={children:g().node.isRequired,loginName:g().string.isRequired};var f=e("/GOzvPf6"),y=e("V5KdrmCp"),T=e.n(y),P=e("Mx+G+HdB"),O=e.n(P),b=e("uZqmR+ju"),L=e("hHVzGgmW"),x=e("93yMNhQL"),W=e("VVS+7KXv");const N="",Z="scratchpad-text-content",j="Cleared.",z="Copied!",ne="Auto saved.",Y="",ae=s.default.div` display: flex; flex-direction: column; height: 100%; `,ee=s.default.textarea(({$copied:Ie,theme:Qe})=>(0,s.css)` width: 100%; padding: 3px; resize: none; flex: 1; margin: 15px 0 7px; border: 1px solid ${Ie?Qe.colors.variant.success:Qe.colors.variant.lighter.default}; box-shadow: inset 1px 1px 1px rgb(0 0 0 / 7.5%)${Ie&&`, 0 0 8px ${r()(Qe.colors.variant.success).alpha(.4).css()}`}; transition: border 150ms ease-in-out, box-shadow 150ms ease-in-out; font-family: ${Qe.fonts.family.monospace}; font-size: ${Qe.fonts.size.body}; &:focus { border-color: ${Qe.colors.variant.light.info}; outline: none; } `),ue=(0,s.default)(b.Alert)` && { padding: 6px 12px; margin: 6px 0 0; display: flex; align-items: center; } `,H=s.default.em` margin-left: 6px; flex: 1; `,ye=s.default.footer(({theme:Ie})=>(0,s.css)` display: flex; align-items: center; padding: 7px 0 9px; border-top: 1px solid ${Ie.colors.gray[80]}; `),we=s.default.span(({theme:Ie,$visible:Qe})=>(0,s.css)` flex: 1; color: ${Ie.colors.variant.success}; font-style: italic; opacity: ${Qe?"1":"0"}; transition: opacity 150ms ease-in-out; `),ht=()=>{const Ie=(0,t.useRef)(),Qe=(0,t.useRef)(),bt=(0,t.useRef)(),{setScratchpadVisibility:Ut,localStorageItem:Qt}=(0,t.useContext)(a),un=p.Z.get(Qt)||{},[Ln,Vn]=(0,t.useState)(un.securityConfirmed||!1),[vn,Nn]=(0,t.useState)(un.value||N),[Uo,Ko]=(0,t.useState)(un.size||void 0),[wo,Oo]=(0,t.useState)(un.position||void 0),[Zs,Qs]=(0,t.useState)(Y),[Fn,To]=(0,t.useState)(!1),[Ro,fs]=(0,t.useState)(!1),hs=mo=>{const ua=p.Z.get(Qt);p.Z.set(Qt,{...ua,...mo})},ur=()=>{bt.current&&clearTimeout(bt.current),bt.current=setTimeout(()=>{To(!1)},1e3)},Xs=mo=>{Qs(mo),To(!0),ur()},gl=O()(()=>{const{value:mo}=Qe.current;Nn(mo),Xs(ne),hs({value:mo})},500),Zr=mo=>{Oo(mo),hs({position:mo})},dr=mo=>{Ko(mo),hs({size:mo})},ca=()=>{Vn(!0),hs({securityConfirmed:!0})},Pr=()=>{fs(!0)},Js=()=>{fs(!1)},Fr=()=>{Nn(N),hs({value:N}),Js(),Xs(j)};(0,t.useEffect)(()=>(Ie.current=new(T())("[data-clipboard-button]",{}),Ie.current.on("success",()=>{Xs(z)}),()=>{Ie.current.destroy(),bt.current&&clearTimeout(bt.current)})),(0,t.useEffect)(()=>{Qe.current&&(Qe.current.focus(),Qe.current.value=vn)},[vn]),(0,E.Z)({actionKey:"clear",scope:"scratchpad",callback:Pr,options:{enableOnFormTags:!0,preventDefault:!0}});const Kr=()=>{(0,W.Z)(vn).then(()=>Xs(z))};return(0,E.Z)({actionKey:"copy",scope:"scratchpad",callback:Kr,options:{enableOnFormTags:!0}}),t.createElement(L.Z,{title:"Scratchpad",onClose:()=>Ut(!1),onDrag:Zr,onResize:dr,size:Uo,position:wo},t.createElement(ae,null,!Ln&&t.createElement(ue,{bsStyle:"warning",bsSize:"sm"},t.createElement(H,null,"We recommend you do ",t.createElement("strong",null,"not")," store any sensitive information, such as passwords, in this area."),t.createElement(b.Button,{bsStyle:"link",bsSize:"sm",onClick:ca},"Got It!")),t.createElement(ee,{ref:Qe,onChange:gl,id:Z,$copied:Zs===z,spellCheck:!1}),t.createElement(ye,null,t.createElement(f.Ox,{placement:"right",trigger:["hover","focus"],overlay:t.createElement(b.Tooltip,{id:"scratchpad-help",show:!0},"You can use this space to store personal notes and other information while interacting with Graylog, without leaving your browser window. For example, store timestamps, user IDs, or IP addresses you need in various investigations.")},t.createElement(b.Button,{bsStyle:"link"},t.createElement(x.Z,{name:"question-circle"}))),t.createElement(we,{$visible:Fn},t.createElement(x.Z,{name:Zs===z?"copy":"hdd",type:"regular"})," ",Zs),t.createElement(b.ButtonGroup,null,t.createElement(b.Button,{"data-clipboard-button":!0,"data-clipboard-target":`#${Z}`,id:"scratchpad-actions",title:"Copy"},t.createElement(x.Z,{name:"copy"})),t.createElement(b.Button,{onClick:Pr,title:"Clear"},t.createElement(x.Z,{name:"trash-alt"}))))),t.createElement(b.BootstrapModalConfirm,{showModal:Ro,title:"Are you sure?",onConfirm:Fr,onCancel:Js},"This will clear out your Scratchpad content, do you wish to proceed?"))},Re=()=>{const{isScratchpadVisible:Ie}=(0,t.useContext)(a);return Ie?t.createElement(ht,null):null};var le=e("fGU5yqDp"),me=e("QL8i6bcz"),re=e("4E3oowBb"),ce=e("ty2gyrHp"),Q=e("MdYBRjRJ"),J=e("RCNj0OY4"),ie=e("0TVxnHwi"),ge=e("q2j1bVbz"),fe=e("8fnsnG21"),Ce=e("zkmy/ViL"),Oe=e("JnTtTRmZ"),nt=e.n(Oe),et=e("IA3Ku5lS"),Fe=e("woUyHGxd");const Pe=(0,et.dS)("core.GlobalThroughput",()=>nt().createStore({listenables:[],throughput:{input:0,output:0,loading:!1},metrics:{input:"org.graylog2.throughput.input.1-sec-rate",output:"org.graylog2.throughput.output.1-sec-rate",loading:!0},init(){Fe.K.addGlobal(this.metrics.input),Fe.K.addGlobal(this.metrics.output),this.listenTo(Fe.q,this.updateMetrics),setInterval(Fe.K.list,this.INTERVAL)},getInitialState(){return{throughput:this.throughput}},INTERVAL:2e3,updateMetrics(Ie){if(!Ie.metrics)return;const Qe=Object.keys(Ie.metrics).map(Ut=>{var Qt,un,Ln;return(Ln=(un=(Qt=Ie.metrics[Ut][this.metrics.input])==null?void 0:Qt.metric)==null?void 0:un.value)!=null?Ln:0}).reduce((Ut,Qt)=>Ut+Qt,0),bt=Object.keys(Ie.metrics).map(Ut=>{var Qt,un,Ln;return(Ln=(un=(Qt=Ie.metrics[Ut][this.metrics.output])==null?void 0:Qt.metric)==null?void 0:un.value)!=null?Ln:0}).reduce((Ut,Qt)=>Ut+Qt,0);this.throughput={input:Qe,output:bt,loading:!1},this.trigger({throughput:this.throughput})}})),$e=(0,s.default)(b.NavItem)` > a { padding-top: 10px !important; padding-bottom: 10px !important; display: flex !important; align-items: center; height: 50px; @media (width <= 991px) { height: auto; display: block; } } `,Ot=s.default.strong` display: grid; grid-template-columns: 1fr; grid-template-rows: 1fr 1fr; grid-gap: 0; height: 30px; @media (width <= 991px) { height: auto; display: block; &::before { content: attr(aria-label); font-weight: normal; } span, &::after { display: none; } } `,ft=s.default.span(({$dataIn:Ie,theme:Qe})=>(0,s.css)` font-size: ${Qe.fonts.size.small}; line-height: 1; grid-area: ${Ie?"1 / 1 / 2 / 2":"2 / 1 / 3 / 2"}; display: grid; grid-template-columns: 1fr 1.75em; grid-template-rows: 1fr 1px; grid-gap: 0 3px; color: ${Qe.colors.global.textDefault}; > span { grid-area: 1 / 1 / 2 / 2; text-align: right; padding-left: 3px; } > i { font-weight: normal; grid-area: 1 / 2 / 2 / 3; } &::after { ${Ie&&` content: ' '; min-height: 1px; background-color: ${Qe.colors.variant.light.default}; display: block; grid-area: 2 / 1 / 3 / 3; `} } `),Lt=Ie=>{const{throughput:Qe}=(0,fe.o)(Pe);let bt=t.createElement(f.$j,{text:""});if(!Qe.loading){const Ut=Ce.Z.formatNumber(Qe.input),Qt=Ce.Z.formatNumber(Qe.output);bt=t.createElement(Ot,{"aria-label":`In ${Ut} / Out ${Qt} msg/s`},t.createElement(ft,{$dataIn:!0},t.createElement("span",null,Ut)," ",t.createElement("i",null,"in")),t.createElement(ft,null,t.createElement("span",null,Qt)," ",t.createElement("i",null,"out")))}return t.createElement($e,{...Ie},bt)};var Be=e("d4kzUuQm"),lt=e("pc+thvZE"),mt=e("/7OuCFNo"),Rt=e("D+lRrw/6"),zt=e.n(Rt),xt=e("CCNXj2ra");const nn=s.default.div` display: flex; align-items: center; `,Vt=(0,s.default)(f.JO)(({theme:Ie,$currentMode:Qe})=>(0,s.css)` opacity: ${Qe?"1":"0.5"}; color: ${Qe?Ie.colors.brand.primary:Ie.colors.variant.darkest.default}; `),Mt=()=>{const Ie=(0,s.useTheme)(),Qe=Ie.mode,[bt,Ut]=(0,t.useState)(!1);(0,t.useEffect)(()=>{bt&&Ut(!1)},[bt,Ie]);const Qt=Vn=>{const{checked:vn}=Vn.target;Vn.persist(),Ut(!0);const Nn=vn?xt.cC:xt.TN;zt()(()=>Ie.changeMode(Nn))},un=Qe===xt.cC&&bt,Ln=Qe===xt.TN&&bt;return t.createElement(nn,null,t.createElement(Vt,{name:un?"spinner":"sun",spin:un,$currentMode:Qe===xt.TN}),t.createElement(f.ZD,null,t.createElement("input",{value:xt.cC,type:"checkbox",onChange:Qt,checked:Qe===xt.cC,disabled:un||Ln}),t.createElement("span",{className:"slider"})),t.createElement(Vt,{name:Ln?"spinner":"moon",spin:Ln,$currentMode:Qe===xt.cC}))},On=({fullName:Ie,readOnly:Qe=!0,userId:bt})=>{const Ut=(0,mt.Z)(),Qt=Qe?Be.ZP.SYSTEM.USERS.show(bt):Be.ZP.SYSTEM.USERS.edit(bt),un=Qe?"Show profile":"Edit profile",Ln=()=>{lt.SessionActions.logout().then(()=>{lt.SessionActions.validate(),Ut.push(Be.ZP.STARTPAGE)})};return t.createElement(b.NavDropdown,{title:t.createElement(f.JO,{name:"user",size:"lg"}),"aria-label":`User Menu for ${Ie}`,id:"user-menu-dropdown",noCaret:!0},t.createElement(b.MenuItem,{header:!0},Ie),t.createElement(b.MenuItem,{divider:!0}),t.createElement(b.MenuItem,{header:!0},t.createElement(Mt,null)),t.createElement(b.MenuItem,{divider:!0}),t.createElement(ce.J,{to:Qt},t.createElement(b.MenuItem,null,un)),t.createElement(b.MenuItem,{onSelect:Ln,icon:"sign-out-alt"},"Log out"))};On.propTypes={userId:g().string.isRequired,fullName:g().string.isRequired};const rt=On;var Bn=e("E+CaPsQD");const de=({active:Ie})=>t.createElement(b.NavDropdown,{active:Ie,id:"help-menu-dropdown",title:t.createElement(f.JO,{name:"question-circle",size:"lg"}),"aria-label":"Help",noCaret:!0},t.createElement(b.MenuItem,{href:Bn.Z.versionedDocsHomePage(),target:"_blank"},t.createElement(f.dL,null,"Documentation")),J.Z.isCloud()&&t.createElement(b.MenuItem,{href:Be.ZP.global_api_browser(),target:"_blank"},t.createElement(f.dL,null,"Cluster Global API browser")));de.propTypes={active:g().bool.isRequired};const pt=de,Gt=s.default.a(({theme:Ie})=>` display: flex; color: ${Ie.colors.variant.default}; align-items: center; justify-content: center; padding: 0 15px; min-height: ${xt.xR}; &:hover, &:focus { color: ${Ie.colors.variant.dark.default}; background-color: transparent; } `),gn=({active:Ie,...Qe})=>{const bt=(0,s.useTheme)();return t.createElement(Gt,{...Qe,className:"navbar-brand"},t.createElement("svg",{height:"26",width:"90",viewBox:"0 0 287 92",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"logoTitleId"},t.createElement("title",{id:"logoTitleId"},"Graylog Logo"),t.createElement("path",{d:"M0.479675 45.8302C0.479675 58.7145 8.75571 68.7774 21.8281 68.7774C29.0696 68.7774 35.0885 65.5799 38.098 60.2192V69.4357C38.098 78.182 32.4552 83.8247 23.803 83.8247C16.0913 83.8247 11.0128 79.8748 9.88426 73.1035H1.04395C2.73677 84.7652 11.2949 91.8186 23.803 91.8186C37.9099 91.8186 46.8443 82.6021 46.8443 68.1191V24.0116H38.9444L38.2861 31.8174C35.3707 26.0806 29.6339 22.695 22.2043 22.695C8.84975 22.695 0.479675 32.8519 0.479675 45.8302ZM9.31998 45.6421C9.31998 37.178 14.5865 30.4067 23.4269 30.4067C32.4552 30.4067 37.7218 36.8018 37.7218 45.6421C37.7218 54.6705 32.2672 61.0656 23.3328 61.0656C14.6806 61.0656 9.31998 54.2944 9.31998 45.6421Z",fill:bt.colors.brand.logo}),t.createElement("path",{d:"M81.2327 23.6354C79.4458 23.2592 78.1292 23.0711 76.5304 23.0711C70.2293 23.0711 65.6211 26.2687 63.7402 31.065L63.1759 24.1056H54.8999V70H63.7402V45.6421C63.7402 36.8018 68.9127 31.7234 77.2828 31.7234H81.2327V23.6354Z",fill:bt.colors.brand.logo}),t.createElement("path",{d:"M98.2704 71.1285C105.7 71.1285 112.001 67.8369 114.352 62.5704L115.293 70H122.816V41.1279C122.816 28.7139 115.105 22.695 103.725 22.695C91.8753 22.695 83.9754 28.996 83.9754 38.5887H91.6872C91.6872 33.04 95.9193 29.7484 103.349 29.7484C109.556 29.7484 114.164 32.4757 114.164 40.1875V41.5041L99.6811 42.6327C88.8658 43.4791 82.5648 48.7456 82.5648 57.2098C82.5648 65.5798 88.3956 71.1285 98.2704 71.1285ZM100.81 64.2632C95.0728 64.2632 91.4991 61.818 91.4991 56.9276C91.4991 52.4134 94.6967 49.404 102.502 48.6516L114.258 47.7111V50.1563C114.258 58.8085 109.18 64.2632 100.81 64.2632Z",fill:bt.colors.brand.logo}),t.createElement("path",{d:"M124.996 90.596C127.347 91.1603 129.793 91.5365 132.708 91.5365C139.762 91.5365 144.37 88.2449 147.473 80.345L169.198 24.0116H160.075L146.439 61.0656L133.084 24.0116H123.774L142.301 72.4452L140.702 76.8653C138.539 82.6962 135.153 83.3545 130.921 83.3545H124.996V90.596Z",fill:bt.colors.brand.logo}),t.createElement("path",{d:"M183.423 70V0.782288H174.583V70H183.423Z",fill:"#F44040"}),t.createElement("path",{d:"M239.31 45.8302C239.31 58.7145 247.586 68.7774 260.659 68.7774C267.9 68.7774 273.919 65.5798 276.929 60.2192V69.4357C276.929 78.182 271.286 83.8247 262.634 83.8247C254.922 83.8247 249.843 79.8748 248.715 73.1035H239.874C241.567 84.7652 250.125 91.8186 262.634 91.8186C276.74 91.8186 285.675 82.6021 285.675 68.1191V24.0116H277.775L277.117 31.8174C274.201 26.0806 268.464 22.695 261.035 22.695C247.68 22.695 239.31 32.8519 239.31 45.8302ZM248.151 45.6421C248.151 37.178 253.417 30.4067 262.257 30.4067C271.286 30.4067 276.552 36.8018 276.552 45.6421C276.552 54.6705 271.098 61.0657 262.163 61.0657C253.511 61.0657 248.151 54.2944 248.151 45.6421Z",fill:"#F44040"}),t.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M212.5 62C221.06 62 228 55.0604 228 46.5C228 37.9396 221.06 31 212.5 31C203.94 31 197 37.9396 197 46.5C197 55.0604 203.94 62 212.5 62ZM212.5 70C225.479 70 236 59.4787 236 46.5C236 33.5213 225.479 23 212.5 23C199.521 23 189 33.5213 189 46.5C189 59.4787 199.521 70 212.5 70Z",fill:"#F44040"}),t.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M213.772 36.0561C213.892 35.6114 214.499 35.5522 214.703 35.9652L219.03 44.7215C219.114 44.892 219.288 45 219.478 45H223C223.828 45 224.5 45.6716 224.5 46.5C224.5 47.3284 223.828 48 223 48H217.614C217.424 48 217.25 47.892 217.166 47.7215L214.941 43.22L211.228 56.9439C211.108 57.3886 210.501 57.4478 210.297 57.0348L205.97 48.2785C205.886 48.108 205.712 48 205.522 48H202C201.172 48 200.5 47.3284 200.5 46.5C200.5 45.6716 201.172 45 202 45H207.386C207.576 45 207.75 45.108 207.834 45.2785L210.059 49.78L213.772 36.0561Z",fill:bt.colors.variant.darker.default})))};gn.propTypes={active:g().bool,className:g().string},gn.defaultProps={active:!1,className:void 0};const Jt=gn;var An=e("bpbGjAaT");const xe=(0,s.default)(b.NavItem)` .navbar-default .navbar-nav > & > a { &:hover, &:focus { background: transparent; } } `,Pn=({active:Ie,className:Qe,children:bt,...Ut})=>t.createElement(xe,{className:Qe,...Ut},bt);Pn.propTypes={active:g().any,children:g().oneOfType([g().array,g().element,g().string]).isRequired,className:g().string},Pn.defaultProps={active:void 0,className:void 0};const sn=Pn,no=(0,s.default)(b.Nav)` > li > a { min-height: ${xt.xR}; display: inline-flex; align-items: center; justify-content: center; padding: 12px; } `,Co=(0,s.default)(sn)` a:hover { border: 0; text-decoration: none; } `,Go=3e3,jo=()=>{const Ie=(0,fe.o)(An.p,Qe=>Qe==null?void 0:Qe.total);return(0,t.useEffect)(()=>{const Qe=setInterval(An.x.list,Go);return()=>{clearInterval(Qe)}},[]),Ie?t.createElement(no,{navbar:!0},t.createElement(ce.J,{to:Be.ZP.SYSTEM.OVERVIEW},t.createElement(Co,null,t.createElement(b.Badge,{bsStyle:"danger","data-testid":"notification-badge"},Ie)))):null},Zt=({description:Ie,path:Qe,topLevel:bt,...Ut})=>t.createElement(ce.J,{key:Qe,to:Qe,...Ut},bt?t.createElement(b.NavItem,null,Ie):t.createElement(b.MenuItem,null,Ie));Zt.propTypes={description:g().oneOfType([g().string,g().object]).isRequired,path:g().string.isRequired,topLevel:g().bool},Zt.defaultProps={topLevel:!1};const Me=Zt,Ye=({smallScreen:Ie})=>{const Qe=Ie?"small-scrn-badge":"";return J.Z.gl2DevMode()?t.createElement(b.Badge,{className:`${Qe} dev-badge`,bsStyle:"danger"},J.Z.isCloud()?String.fromCharCode(9928):""," DEV"):null};Ye.propTypes={smallScreen:g().bool},Ye.defaultProps={smallScreen:!1};const Ke=Ye;var dt=e("8wYeYPUw"),it=e("rzOX6PZw");const gt="System",It="/system",ot=(Ie,Qe)=>Ie.indexOf((0,Q.s6)(Qe))===0,yt={"/overview":"Overview","/nodes":"Nodes","/inputs":"Inputs","/outputs":"Outputs","/indices":"Indices","/logging":"Logging","/authentication":"Authentication","/contentpacks":"Content Packs","/grokpatterns":"Grok Patterns","/lookuptables":"Lookup Tables","/configurations":"Configurations","/pipelines":"Pipelines","/sidecars":"Sidecars","/users":"Users","/teams":"Teams","/roles":"Roles"},Xt=Ie=>{var Qe;const bt=(Qe=Object.entries(yt).find(([Qt])=>ot(Ie,`${It}${Qt}`)))==null?void 0:Qe[1];if(bt)return`${gt} / ${bt}`;const Ut=me.G.exports("systemnavigation").filter(Qt=>ot(Ie,Qt.path))[0];return Ut?`${gt} / ${Ut.description}`:gt},Cn=()=>{const Ie=(0,n.useLocation)();let Qe=!0;J.Z.isCloud()&&(Qe=J.Z.isFeatureEnabled("cloud_inputs"));const bt=me.G.exports("systemnavigation").sort((Ut,Qt)=>(0,re.S)(Ut.description.toLowerCase(),Qt.description.toLowerCase())).map(({description:Ut,path:Qt,permissions:un})=>{const Ln=(0,Q.s6)(Qt),Vn=t.createElement(Me,{description:Ut,path:Ln});return un?t.createElement(it.Z,{key:Ut,permissions:un},Vn):t.createElement(Me,{key:Ut,path:Ln,description:Ut})});return t.createElement(b.NavDropdown,{title:Xt(Ie.pathname),id:"system-menu-dropdown",inactiveTitle:gt},t.createElement(Me,{path:Be.ZP.SYSTEM.OVERVIEW,description:"Overview"}),t.createElement(it.Z,{permissions:["clusterconfigentry:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.CONFIGURATIONS,description:"Configurations"})),t.createElement(dt.Z,null,t.createElement(Me,{path:Be.ZP.SYSTEM.NODES.LIST,description:"Nodes"})),t.createElement(it.Z,{permissions:["inputs:read"]},Qe?t.createElement(Me,{path:Be.ZP.SYSTEM.INPUTS,description:"Inputs"}):null),t.createElement(dt.Z,null,t.createElement(it.Z,{permissions:["outputs:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.OUTPUTS,description:"Outputs"}))),t.createElement(it.Z,{permissions:["indices:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.INDICES.LIST,description:"Indices"})),t.createElement(dt.Z,null,t.createElement(it.Z,{permissions:["loggers:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.LOGGING,description:"Logging"}))),t.createElement(it.Z,{permissions:["users:list"],anyPermissions:!0},t.createElement(Me,{path:Be.ZP.SYSTEM.USERS.OVERVIEW,description:"Users and Teams"})),t.createElement(it.Z,{permissions:["roles:read"],anyPermissions:!0},t.createElement(Me,{path:Be.ZP.SYSTEM.AUTHZROLES.OVERVIEW,description:"Roles"})),t.createElement(dt.Z,null,t.createElement(it.Z,{permissions:["authentication:edit"],anyPermissions:!0},t.createElement(Me,{path:Be.ZP.SYSTEM.AUTHENTICATION.BACKENDS.ACTIVE,description:"Authentication"}))),t.createElement(it.Z,{permissions:["contentpack:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.CONTENTPACKS.LIST,description:"Content Packs"})),t.createElement(it.Z,{permissions:["grok_pattern:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.GROKPATTERNS,description:"Grok Patterns"})),t.createElement(it.Z,{permissions:["lookuptables:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.LOOKUPTABLES.OVERVIEW,description:"Lookup Tables"})),t.createElement(it.Z,{permissions:["pipeline:read","pipeline_connection:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.PIPELINES.OVERVIEW,description:"Pipelines"})),t.createElement(it.Z,{permissions:["sidecars:read"]},t.createElement(Me,{path:Be.ZP.SYSTEM.SIDECARS.OVERVIEW,description:"Sidecars"})),bt)},bn=(0,s.default)(b.Button)` padding-left: 6px; padding-right: 6px; background: none; border: 0; `,ao=()=>{const{toggleScratchpadVisibility:Ie}=(0,t.useContext)(a);return t.createElement("li",{role:"presentation"},t.createElement(bn,{bsStyle:"link",type:"button","aria-label":"Scratchpad",id:"scratchpad-toggle",onClick:Ie},t.createElement(f.JO,{name:"edit",size:"lg",fixedWidth:!0,title:"Scratchpad"})))};var Xn=e("NV1/EHMi");const Kn=(0,s.default)(b.Navbar)(({theme:Ie})=>(0,s.css)` .dev-badge-wrap > a { padding: 0 !important; cursor: default; } .dev-badge-wrap .dev-badge { margin: 0 10px; } &.navbar-default .navbar-main > li { > a { font-family: ${Ie.fonts.family.navigation}; font-size: ${Ie.fonts.size.navigation}; } &:hover { ${(0,Xn.RF)(Ie)} } &.active { ${(0,Xn.A7)(Ie)} &:hover, :focus { ${(0,Xn.A7)(Ie)} } } } .dropdown-menu li { &:not(.dropdown-header) { font-family: ${Ie.fonts.family.navigation}; font-size: ${Ie.fonts.size.navigation}; } a { padding: 6px 20px; } } @media (width <= 991px) { .small-scrn-badge { float: right; margin: 15px 15px 0; } .header-meta-nav { border-top: 1px solid ${Ie.colors.gray[50]}; padding-top: 7.5px; #scratchpad-toggle { padding: 10px 15px; display: block; width: 100%; text-align: left; &:hover { text-decoration: none; } } #scratchpad-toggle, .dropdown-toggle, #welcome-nav-link { font-size: ${Ie.fonts.size.body}; font-family: ${Ie.fonts.family.body}; &::before { content: attr(aria-label); } [class*='fa-'] { display: none; } } } .dev-badge-wrap { display: none !important; } } @media (width >= 768px) { .navbar-toggle { display: block; } .navbar-collapse { width: auto; border-top: 1px solid transparent; box-shadow: inset 0 1px 0 rgb(255 255 255 / 10%); &.collapse { height: auto !important; padding-bottom: 0; } &.in { overflow-y: auto; } } .navbar-fixed-top .navbar-collapse, .navbar-static-top .navbar-collapse, .navbar-fixed-bottom .navbar-collapse { padding-right: 15px; padding-left: 15px; } .navbar-header { float: none; } .container > .navbar-header, .container-fluid > .navbar-header, .container > .navbar-collapse, .container-fluid > .navbar-collapse { margin-right: -15px; } } @media (width >= 991px) { .header-meta-nav { display: flex; align-items: center; #scratchpad-toggle, .dropdown-toggle { padding: 12px !important; min-height: ${xt.xR}; display: inline-flex; align-items: center; justify-content: center; } } .navbar-toggle { display: none; } .navbar-collapse { width: auto; border-top: 0; box-shadow: none; &.collapse { display: block !important; height: auto !important; padding-bottom: 0; overflow: visible !important; } &.in { overflow-y: visible; } } .navbar-fixed-top .navbar-collapse, .navbar-static-top .navbar-collapse, .navbar-fixed-bottom .navbar-collapse { padding-right: 0; padding-left: 0; } .navbar-header { float: left; } .small-scrn-badge { display: none; } .container > .navbar-header, .container-fluid > .navbar-header, .container > .navbar-collapse, .container-fluid > .navbar-collapse { margin-right: 0; margin-left: 0; } } `),Jn=(Ie,Qe,bt=void 0)=>bt?Ie===(0,Q.s6)(Qe):Ie.indexOf((0,Q.s6)(Qe))===0;function Wn(Ie){const Qe=me.G.exports("navigation");return Qe?!!Qe.find(bt=>{var Ut;return((Ut=bt.description)==null?void 0:Ut.toLowerCase())===Ie.toLowerCase()}):!1}const bo=({description:Ie,path:Qe,permissions:bt,requiredFeatureFlag:Ut,BadgeComponent:Qt},un,Ln=!1)=>bt&&!(0,ie.rq)(un,bt)||Ut&&!J.Z.isFeatureEnabled(Ut)?null:t.createElement(Me,{key:Ie,description:Qt?t.createElement(Qt,{text:Ie}):Ie,path:(0,Q.s6)(Qe),topLevel:Ln}),ds=(Ie,Qe,bt)=>{if(Ie.requiredFeatureFlag&&!J.Z.isFeatureEnabled(Ie.requiredFeatureFlag))return null;if(Ie.children){const Ut=Ie.children.filter(({path:vn,end:Nn})=>vn&&Jn(bt,vn,Nn)),Qt=Ut.length>0?`${Ie.description} / ${Ut[0].description}`:Ie.description;if(!Ie.children.some(vn=>(0,ie.rq)(Qe,vn.permissions)&&(vn.requiredFeatureFlag?J.Z.isFeatureEnabled(vn.requiredFeatureFlag):!0)))return null;const{BadgeComponent:Ln}=Ie,Vn=Ie.children.some(vn=>(0,ie.rq)(Qe,vn.permissions)&&(vn==null?void 0:vn.BadgeComponent));return t.createElement(b.NavDropdown,{key:Qt,title:Qt,badge:Vn?Ln:null,id:"enterprise-dropdown",inactiveTitle:Ie.description},Ie.children.map(vn=>bo(vn,Qe,!1)))}return bo(Ie,Qe,!0)},zo=t.memo(({pathname:Ie})=>{const Qe=(0,ge.Z)(),{permissions:bt,fullName:Ut,readOnly:Qt,id:un}=Qe||{},Ln=me.G.exports("navigation"),Vn=!Wn(Be.Kl),vn=!Wn(Be.T7),Nn=(0,ie.rq)(bt,["licenseinfos:read"]);Vn&&Nn&&Ln.push({path:Be.ZP.SYSTEM.ENTERPRISE,description:Be.Kl}),vn&&Nn&&Ln.push({path:Be.ZP.SECURITY,description:Be.T7});const Uo=Ln.sort((wo,Oo)=>(0,re.S)(wo.description.toLowerCase(),Oo.description.toLowerCase())).map(wo=>ds(wo,Qe.permissions,Ie)),Ko=me.G.exports("navigationItems");return t.createElement(Kn,{fluid:!0,fixedTop:!0,collapseOnSelect:!0},t.createElement(b.Navbar.Header,null,t.createElement(b.Navbar.Brand,null,t.createElement(ce.J,{relativeActive:!0,to:Be.ZP.STARTPAGE},t.createElement(Jt,null))),t.createElement(b.Navbar.Toggle,null),t.createElement(Ke,{smallScreen:!0}),Ko.map(({key:wo,component:Oo})=>t.createElement(Oo,{key:wo,smallScreen:!0}))),t.createElement(b.Navbar.Collapse,null,t.createElement(b.Nav,{className:"navbar-main"},t.createElement(ce.J,{relativeActive:!0,to:Be.ZP.SEARCH},t.createElement(b.NavItem,{to:"search"},"Search")),t.createElement(ce.J,{relativeActive:!0,to:Be.ZP.STREAMS},t.createElement(b.NavItem,null,"Streams")),t.createElement(ce.J,{relativeActive:!0,to:Be.ZP.ALERTS.LIST},t.createElement(b.NavItem,null,"Alerts")),t.createElement(ce.J,{relativeActive:!0,to:Be.ZP.DASHBOARDS},t.createElement(b.NavItem,null,"Dashboards")),Uo,t.createElement(Cn,null)),t.createElement(jo,null),t.createElement(b.Nav,{pullRight:!0,className:"header-meta-nav"},J.Z.isCloud()?t.createElement(Lt,{disabled:!0}):t.createElement(ce.J,{to:Be.ZP.SYSTEM.NODES.LIST},t.createElement(Lt,null)),t.createElement(sn,{className:"dev-badge-wrap"},t.createElement(Ke,null),Ko.map(({key:wo,component:Oo})=>t.createElement(Oo,{key:wo}))),t.createElement(ao,null),t.createElement(pt,{active:Jn(Ie,Be.ZP.WELCOME)}),t.createElement(ce.J,{relativeActive:!0,to:Be.ZP.WELCOME},t.createElement(b.NavItem,{id:"welcome-nav-link","aria-label":"Welcome"},t.createElement(f.JO,{size:"lg",fixedWidth:!0,title:"Welcome",name:"home"}))),t.createElement(rt,{fullName:Ut,readOnly:Qt,userId:un}))))}),Do=()=>{const{pathname:Ie}=(0,n.useLocation)();return t.createElement(zo,{pathname:Ie})};var Jo=e("m5sCWlWB"),Zo=e("62FDaRYn"),yo=e("9tc+dS6Z"),Vo=e("6vcCRWgg"),_s=e("sIZ0mQDD"),Cs=e("knkDHhNA"),ms=e("CYFwYmkW");const Yn=({reportedError:Ie})=>t.createElement(Jo.Z,{title:"Something went wrong",description:t.createElement("p",null,"An unknown error has occurred. Please have a look at the following message and the graylog server log for more information.")},t.createElement("pre",null,JSON.stringify(Ie))),xo=({reportedError:Ie})=>{switch(Ie.type){case yo.Ax:return t.createElement(Vo.Z,{error:Ie.error,componentStack:Ie.info.componentStack});case yo.ZT:return t.createElement(_s.default,null);case yo.fQ:return t.createElement(Cs.Z,{error:Ie.error});case yo.vE:return t.createElement(ms.Z,{error:Ie.error});default:return t.createElement(Yn,{reportedError:Ie})}},Vs=({children:Ie})=>{const[Qe,bt]=(0,t.useState)(),Ut=un=>bt(un);(0,t.useEffect)(()=>{const un=Zo.Z.report.listen(Ut);return()=>{un()}},[]);const Qt=(0,n.useLocation)();return(0,t.useEffect)(()=>{Qe&&bt(null)},[Qt]),Qe?t.createElement(xo,{reportedError:Qe}):t.createElement(t.Fragment,null,Ie)};class Bs extends t.Component{componentDidCatch(Qe,bt){Zo.Z.report((0,yo.hy)(Qe,bt))}render(){const{children:Qe}=this.props;return Qe}}Bs.propTypes={children:g().node},Bs.defaultProps={children:null};const Ts=Bs;var Us=e("dFpwyWHg"),ws=e.n(Us),Lo=e("C2ikvoS0"),co=e.n(Lo),ns=e("1IntWRSu"),os=e.n(ns),Ws=e("8nGWeFnd"),ps=e.n(Ws),Tr=e("TeAcaicX"),Ns=e.n(Tr),gs=e("eE3+5goe"),Ho=e.n(gs),Yo=e("xVpy+aBO"),te={};te.styleTagTransform=Ho(),te.setAttributes=ps(),te.insert=os().bind(null,"head"),te.domAPI=co(),te.insertStyleElement=Ns();var Te=ws()(Yo.Z,te);const Le=Yo.Z&&Yo.Z.locals?Yo.Z.locals:void 0;var st=e("0t7Ye+61"),St=e("8OvTct/Z");const cn=()=>{const Ie=(0,st.Z)(),Qe=(0,St.Z)();return(0,t.useEffect)(()=>{Ie.pathname&&Qe("$pageview",{app_pathname:(0,Q.av)(Ie.pathname)})},[Ie.pathname,Qe]),null};var In=e("J6SvWOit"),Mn=e("VPaD/Np4"),Zn=e.n(Mn),qn=e("k5v4N6a1"),be=e("zJE5UjMB");const ze={undo:{keys:"mod+shift+z",description:"Undo last action"},redo:{keys:"mod+shift+y",description:"Redo last action"}},Ve={general:{title:"General",description:"General keyboard shortcuts",actions:{"show-hotkeys-modal":{keys:"shift+?",displayKeys:"?",description:"Show available keyboard shorts"},"submit-form":{keys:"enter",description:"Submit form"},"close-modal":{keys:"esc",description:"Close modal"},"show-scratchpad-modal":{keys:"mod+/",description:"Show scratchpad"}}},search:{title:"Search",description:"Keyboard shortcuts for search page",actions:{...ze,save:{keys:"mod+s",description:"Save search"},"save-as":{keys:"mod+shift+s",description:"Save search as"}}},dashboard:{title:"Dashboard",description:"Keyboard shortcuts for dashboard page",actions:{...ze,save:{keys:"mod+s",description:"Save dashboard"},"save-as":{keys:"mod+shift+s",description:"Save dashboard as"}}},scratchpad:{title:"Scratchpad",description:"Scratchpad shortcuts",actions:{clear:{keys:["mod+backspace","mod+del"],description:"Clear scratchpad"},copy:{keys:"shift+mod+c",description:"Copy scratchpad"}}}},We=({children:Ie})=>{const[Qe,bt]=(0,t.useState)(Zn().Map()),{enabledScopes:Ut}=(0,In.QU)(),Qt=(0,t.useCallback)(({scope:Vn,actionKey:vn,options:Nn})=>{bt(Uo=>Uo.set(`${Vn}.${vn}`,{options:Nn}))},[]),un=(0,t.useCallback)(({scope:Vn,actionKey:vn})=>{bt(Nn=>Nn.delete(`${Vn}.${vn}`))},[]),Ln=(0,t.useMemo)(()=>({enabledScopes:Ut,hotKeysCollections:Ve,activeHotkeys:Qe,addActiveHotkey:Qt,removeActiveHotkey:un}),[Qe,Qt,Ut,un]);return t.createElement(qn.Z.Provider,{value:Ln},Ie)},Et=({children:Ie})=>(0,be.Z)("frontend_hotkeys")?t.createElement(In.NL,null,t.createElement(We,null,Ie)):Ie;var At=e("LF8A/8I5"),Ct=e.n(At),Kt=e("8u9vblRK"),en=e.n(Kt),dn=e("dLGFg9GJ"),En=e.n(dn),xn=e("/MzrwdNa"),zn=e("QBkUz07U"),fn=e("3yfJIRSb");const Dn=()=>navigator.userAgent.indexOf("Mac OS X")!==-1,Hn=s.default.div` padding: 20px; `,_o=s.default.div` display: flex; justify-content: right; align-items: center; `,Ss=s.default.div` display: flex; flex-direction: column; `,As=s.default.div` display: flex; gap: 5px; justify-content: space-between; &:not(:last-child) { margin-bottom: 3px; } `,Hs=s.default.div` display: inline-flex; gap: 5px; justify-content: right; flex-wrap: wrap; `,Fo=s.default.div` display: flex; align-items: center; `,uo=(Ie,Qe)=>({mod:Qe?"\u2318":"Ctrl"})[Ie]||Ie,De=({keys:Ie,splitKey:Qe,combinationKey:bt,isEnabled:Ut,isMacOS:Qt})=>{const un=en()(Ie)?Ie:[Ie],Ln=En()(un.map(Vn=>Vn.split(Qe)));return t.createElement(t.Fragment,null,Ln.map((Vn,vn)=>{const Nn=Vn.split(bt),Uo=vn===Ln.length-1;return t.createElement(t.Fragment,{key:Vn},Nn.map((Ko,wo)=>{const Oo=wo===Nn.length-1;return t.createElement(t.Fragment,{key:Ko},t.createElement(b.KeyboardKey,{bsStyle:Ut?"info":"default"},uo(Ko,Qt)),!Oo&&t.createElement(Fo,null,bt))}),!Uo&&t.createElement(Fo,null,"or"))}))},ss=({description:Ie,keys:Qe,combinationKey:bt,splitKey:Ut,isEnabled:Qt,isMacOS:un})=>t.createElement(As,null,Ie,t.createElement(Hs,null,t.createElement(De,{keys:Qe,combinationKey:bt,splitKey:Ut,isEnabled:Qt,isMacOS:un}))),Wr=({collection:Ie,scope:Qe,isMacOS:bt})=>{const{activeHotkeys:Ut}=(0,xn.Z)(),{title:Qt,description:un,actions:Ln}=Ie,Vn=Object.entries(Ln).filter(([vn])=>{const Nn=`${Qe}.${vn}`;return Ut.has(Nn)&&Ut.get(Nn).options.displayInOverview!==!1});return Vn.length?t.createElement(zn.Z,{title:Qt},t.createElement("p",{className:"description"},un),t.createElement(Ss,null,Vn.map(([vn,{description:Nn,keys:Uo,displayKeys:Ko}])=>{var wo,Oo,Zs,Qs,Fn,To;const Ro=!!((Oo=(wo=Ut.get(`${Qe}.${vn}`))==null?void 0:wo.options)!=null&&Oo.enabled),fs=(Qs=(Zs=Ut.get(`${Qe}.${vn}`))==null?void 0:Zs.options)==null?void 0:Qs.splitKey,hs=(To=(Fn=Ut.get(`${Qe}.${vn}`))==null?void 0:Fn.options)==null?void 0:To.combinationKey,ur=en()(Uo)?Uo.join(","):Uo;return t.createElement(ss,{description:Nn,keys:Ko!=null?Ko:Uo,combinationKey:hs,splitKey:fs,isEnabled:Ro,isMacOS:bt,key:ur})}))):null},Sr=()=>{const{hotKeysCollections:Ie,enabledScopes:Qe}=(0,xn.Z)(),Ut=Qe.length===1&&Qe[0]==="*"?Ie:Ct()(Ie,Qe);return Object.entries(Ut)},Ps=({onToggle:Ie})=>{const Qe=Dn(),bt=Sr();return t.createElement(b.Modal,{onHide:Ie,show:!0,title:"Keyboard shortcuts",bsSize:"large"},t.createElement(b.Modal.Header,{closeButton:!0},t.createElement(b.Modal.Title,null,"Keyboard shortcuts")),t.createElement(b.Modal.Body,null,t.createElement(Hn,null,t.createElement(fn.Z,null,bt.map(([Ut,Qt])=>t.createElement(Wr,{scope:Ut,collection:Qt,isMacOS:Qe,key:Ut}))))),t.createElement(b.Modal.Footer,null,t.createElement(_o,null,t.createElement(b.Button,{onClick:()=>Ie()},"Close"))))},cr=()=>{const[Ie,Qe]=(0,t.useState)(!1),bt=(0,t.useCallback)(()=>Qe(Ut=>!Ut),[]);return(0,E.Z)({actionKey:"show-hotkeys-modal",callback:()=>Qe(!0),scope:"general"}),Ie?t.createElement(Ps,{onToggle:()=>bt()}):null},Bo=s.default.div` display: flex; flex-direction: column; height: 100%; `,ks=s.default.div` height: 100%; overflow: auto; flex: 1; `,ia=s.default.div(({theme:Ie})=>(0,s.css)` position: fixed; left: 50%; margin-left: -125px; top: 50px; /* stylelint-disable function-no-unknown */ color: ${Ie.utils.readableColor(r()(Ie.colors.brand.tertiary).alpha(.8).css())}; font-size: 80px; padding: 25px; z-index: 2000; width: 200px; text-align: center; cursor: pointer; border-radius: 10px; display: none; background: ${r()(Ie.colors.brand.tertiary).alpha(.8).css()}; `),Ar=()=>t.createElement(v.QueryParamProvider,{adapter:c.Q},t.createElement(le.Z.Consumer,null,Ie=>Ie?t.createElement(Et,null,t.createElement(u,{loginName:Ie.username},t.createElement(cn,null),t.createElement(t.Fragment,null,t.createElement(Bo,null,t.createElement(Do,null),t.createElement(ia,{id:"scroll-to-hint"},t.createElement(f.JO,{name:"arrow-up"})),t.createElement(Re,null),t.createElement(Vs,null,t.createElement(Ts,null,t.createElement(ks,null,t.createElement(n.Outlet,null))))),t.createElement(cr,null)))):t.createElement(f.$j,null)))},d4kzUuQm:(M,C,e)=>{"use strict";e.d(C,{Kl:()=>y,T7:()=>T,ZP:()=>O});var t=e("QL8i6bcz"),s=e("oCSEoDew"),o=e.n(s),r=e("RCNj0OY4"),n=e("nxMFMmDQ");const c={STARTPAGE:"/",NOTFOUND:"/notfound",SEARCH:"/search",STREAMS:"/streams",ALERTS:{LIST:"/alerts",replay_search:b=>`/alerts/${b}/replay-search`,DEFINITIONS:{LIST:"/alerts/definitions",CREATE:"/alerts/definitions/new",edit:b=>`/alerts/definitions/${b}/edit`,show:b=>`/alerts/definitions/${b}`,replay_search:b=>`/alerts/definitions/${b}/replay-search`},NOTIFICATIONS:{LIST:"/alerts/notifications",CREATE:"/alerts/notifications/new",edit:b=>`/alerts/notifications/${b}/edit`,show:b=>`/alerts/notifications/${b}`}},SECURITY:"/security",SOURCES:"/sources",DASHBOARDS:"/dashboards",WELCOME:"/welcome",GLOBAL_API_BROWSER_URL:"/api/api-browser/global/index.html",SYSTEM:{CONFIGURATIONS:"/system/configurations",configurationsSection:(b,L)=>`/system/configurations/${b}${L?`/${L}`:""}`,CONTENTPACKS:{LIST:"/system/contentpacks",EXPORT:"/system/contentpacks/export",CREATE:"/system/contentpacks/create",edit:(b,L)=>`/system/contentpacks/${b}/${L}/edit`,show:b=>`/system/contentpacks/${b}`},GROKPATTERNS:"/system/grokpatterns",INDICES:{LIST:"/system/indices",FAILURES:"/system/indices/failures"},INDEX_SETS:{CONFIGURATION:(b,L)=>L?`/system/index_sets/${b}/configuration?from=${L}`:`/system/index_sets/${b}/configuration`,SHOW:b=>`/system/index_sets/${b}`,CREATE:"/system/index_sets/create"},INPUTS:"/system/inputs",LOGGING:"/system/logging",METRICS:b=>`/system/metrics/node/${b}`,NODES:{LIST:"/system/nodes",SHOW:b=>`/system/nodes/${b}`},THREADDUMP:b=>`/system/threaddump/${b}`,OUTPUTS:"/system/outputs",OVERVIEW:"/system/overview",PROCESSBUFFERDUMP:b=>`/system/processbufferdump/${b}`,SYSTEMLOGS:b=>`/system/logs/recent/${b}`,AUTHENTICATION:{BACKENDS:{OVERVIEW:"/system/authentication/services",ACTIVE:"/system/authentication/services/active",CREATE:"/system/authentication/services/create",createBackend:b=>`/system/authentication/services/create/${b}`,show:b=>`/system/authentication/services/${b}`,edit:(b,L)=>{const x=`/system/authentication/services/edit/${b}`;return L?`${x}?initialStepKey=${L}`:x}},AUTHENTICATORS:{SHOW:"/system/authentication/authenticator",EDIT:"/system/authentication/authenticator/edit"}},USERS:{CREATE:"/system/users/new",edit:b=>`/system/users/edit/${b}`,TOKENS:{edit:b=>`/system/users/tokens/${b}`},OVERVIEW:"/system/users",show:b=>`/system/users/${b}`},AUTHZROLES:{OVERVIEW:"/system/roles",show:b=>`/system/roles/${b}`,edit:b=>`/system/roles/edit/${b}`},LOOKUPTABLES:{OVERVIEW:"/system/lookuptables",CREATE:"/system/lookuptables/create",show:b=>`/system/lookuptables/table/${b}`,edit:b=>`/system/lookuptables/table/${b}/edit`,CACHES:{OVERVIEW:"/system/lookuptables/caches",CREATE:"/system/lookuptables/caches/create",show:b=>`/system/lookuptables/caches/${b}`,edit:b=>`/system/lookuptables/caches/${b}/edit`},DATA_ADAPTERS:{OVERVIEW:"/system/lookuptables/data_adapters",CREATE:"/system/lookuptables/data_adapters/create",show:b=>`/system/lookuptables/data_adapter/${b}`,edit:b=>`/system/lookuptables/data_adapter/${b}/edit`}},PIPELINES:{OVERVIEW:"/system/pipelines",PIPELINE:b=>`/system/pipelines/${b}`,RULES:"/system/pipelines/rules",RULE:b=>`/system/pipelines/rules/${b}`,SIMULATOR:"/system/pipelines/simulate"},ENTERPRISE:"/system/enterprise",SIDECARS:{OVERVIEW:"/system/sidecars",STATUS:b=>`/system/sidecars/${b}/status`,ADMINISTRATION:"/system/sidecars/administration",CONFIGURATION:"/system/sidecars/configuration",FAILURE_TRACKING:"/system/sidecars/failuretracking",NEW_CONFIGURATION:"/system/sidecars/configuration/new",EDIT_CONFIGURATION:b=>`/system/sidecars/configuration/edit/${b}`,NEW_COLLECTOR:"/system/sidecars/collector/new",EDIT_COLLECTOR:b=>`/system/sidecars/collector/edit/${b}`}},VIEWS:{LIST:n.N3,VIEWID:b=>`${n.N3}/${b}`},EXTENDEDSEARCH:n.XR,search_with_query:(b,L,x,W)=>{const N=new(o())(c.SEARCH),Z={q:b};if(L&&x)switch(Z.rangetype=L,L){case"relative":Z.relative=x.relative;break;case"absolute":Z.from=x.from,Z.to=x.to;break;case"keyword":Z.keyword=x.keyword;break;default:throw new Error(`Invalid range type: ${L}.`)}return W&&(Z.streams=W.join(",")),N.query(Z),N.resource()},_common_search_url:(b,L,x,W)=>{const N=new(o())(b),Z={q:L,interval:W};return x&&Object.keys(x).forEach(j=>{Z[j]=x[j]}),N.setQuery(Z),N.resource()},search:(b,L,x)=>c._common_search_url(c.SEARCH,b,L,x),message_show:(b,L)=>`/messages/${b}/${L}`,stream_edit:b=>`/streams/${b}/edit`,stream_edit_example:(b,L,x)=>`${c.stream_edit(b)}?index=${L}&message_id=${x}`,stream_outputs:b=>`/streams/${b}/outputs`,stream_search:(b,L,x,W)=>c._common_search_url(`${c.STREAMS}/${b}/search`,L,x,W),stream_alerts:b=>`/alerts/?stream_id=${b}`,legacy_stream_search:b=>`/streams/${b}/messages`,dashboard_show:b=>`/dashboards/${b}`,show_saved_search:b=>`/search/${b}`,node:b=>`/system/nodes/${b}`,node_inputs:b=>`${c.SYSTEM.INPUTS}/${b}`,global_input_extractors:b=>`/system/inputs/${b}/extractors`,local_input_extractors:(b,L)=>`/system/inputs/${b}/${L}/extractors`,export_extractors:(b,L)=>`${c.local_input_extractors(b,L)}/export`,import_extractors:(b,L)=>`${c.local_input_extractors(b,L)}/import`,new_extractor:(b,L,x,W,N,Z)=>{const j=new(o())(`/system/inputs/${b}/${L}/extractors/new`),z={extractor_type:x,field:W,example_index:N,example_id:Z};return j.search(z),j.resource()},edit_extractor:(b,L,x)=>`/system/inputs/${b}/${L}/extractors/${x}/edit`,edit_input_extractor:(b,L,x)=>`/system/inputs/${b}/${L}/extractors/${x}/edit`,filtered_metrics:(b,L)=>`${c.SYSTEM.METRICS(b)}?filter=${L}`,global_api_browser:()=>c.GLOBAL_API_BROWSER_URL},v=(b,L)=>{const x=new(o())(b);return x.directory(`${L}/${x.directory()}`).normalizePath().resource()},d=b=>typeof b=="string",g=b=>typeof b=="function",p=(b,L)=>L==="/"?b:Object.fromEntries(Object.entries(b).map(([x,W])=>d(W)?[x,v(W,L)]:g(W)?[x,(...N)=>{const Z=W(...N);return v(Z,L)}]:[x,p(W,L)])),E=r.Z.gl2AppPathPrefix()?p(c,r.Z.gl2AppPathPrefix()):c,a=c,u=(b,L=!0)=>{const x={};t.G.exports("routes").forEach(N=>{const Z=new(o())(N.path),j=Z.segment(),z=j.map(Y=>Y.replace(":","")).join("_").toUpperCase(),ne=j.filter(Y=>Y.startsWith(":"));if(ne.length>0){x[z]=(...Y)=>(ne.forEach((ae,ee)=>{const ue=String(Y[ee]);Z.segment(j.indexOf(ae),ue)}),Z.pathname());return}x[z]=N.path});const W=(r.Z.gl2AppPathPrefix()?p(x,r.Z.gl2AppPathPrefix()):x)[b];if(!W&&L)throw new Error(`Could not find plugin route '${b}'.`);return W},f=b=>u(b,!1),y="Enterprise",T="Security",O=Object.assign(E,{pluginRoute:u,getPluginRoute:f,unqualified:a})},tz1fbBRX:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p});var t=e("Q1zRxDOP"),s=e("d4kzUuQm"),o=e("vT7mdtQI"),r=e("0hhBr0/b");const n=(E,a,u)=>{for(let f=0;f{const u=(0,r.Z)("entityRoutes");return u!=null&&u.length?n(u,E,a):null},d=(E,a)=>{const u=c(E,a);if(u)return u;switch(a==null?void 0:a.toLowerCase()){case"user":return s.ZP.SYSTEM.USERS.show(E);case"team":return s.ZP.getPluginRoute("SYSTEM_TEAMS_TEAMID")(E);case"dashboard":return s.ZP.dashboard_show(E);case"event_definition":return s.ZP.ALERTS.DEFINITIONS.show(E);case"notification":return s.ZP.ALERTS.NOTIFICATIONS.show(E);case"search":return s.ZP.getPluginRoute("SEARCH_VIEWID")(E);case"stream":return s.ZP.stream_search(E);case"search_filter":return s.ZP.getPluginRoute("MY-FILTERS_DETAILS_FILTERID")(E);case"report":return s.ZP.getPluginRoute("REPORTS_REPORTID_CONFIGURATION")(E);case"role":return s.ZP.SYSTEM.AUTHZROLES.show(E);case"output":return s.ZP.SYSTEM.OUTPUTS;default:return(0,o.Z)(a!=null?a:"(undefined)","Can't find route for type")}},p=E=>{const{id:a,type:u}=(0,t.C)(E);return d(a,u)}},"8jTixuP6":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("y2LHvPyS");const o=({error:v})=>((0,t.useEffect)(()=>{console.error(v)},[v]),t.createElement("div",null,"Loading component failed: ",v.message)),r=t.createElement(t.Fragment,null),c=v=>{const d=t.lazy(v);return g=>t.createElement(s.SV,{FallbackComponent:o},t.createElement(t.Suspense,{fallback:r},t.createElement(d,{...g})))}},"/7OuCFNo":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("yAXMqwrl");const r=()=>{const n=(0,s.useNavigate)();return(0,t.useMemo)(()=>({goBack:()=>n(-1),push:c=>n(c),pushWithState:(c,v)=>n(c,{state:v}),replace:c=>n(c,{replace:!0})}),[n])}},"0t7Ye+61":(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});var t=e("yAXMqwrl");const s=t.useLocation},"6dLKCZdN":(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});var t=e("yAXMqwrl");const s=t.useParams},brbjQOmY:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("yAXMqwrl"),o=e("pjsNBHWI"),r=e.n(o);const c=()=>{const{search:v}=(0,s.useLocation)();return(0,t.useMemo)(()=>r().parse(v,{ignoreQueryPrefix:!0}),[v])}},HCsT5Gmk:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("yAXMqwrl"),o=e("brbjQOmY");const n=c=>v=>{const d=(0,s.useLocation)(),g=(0,o.Z)(),p=(0,t.useMemo)(()=>({...d,query:g}),[d,g]);return t.createElement(c,{...v,location:p})}},ibdPvtmL:(M,C,e)=>{"use strict";e.d(C,{h:()=>d,i:()=>p});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("eFxcQyPT"),n=e("U1Iufsob"),c=e("jAGDuYSC"),v=e("IA3Ku5lS");const d=(0,v.ei)("core.Configuration",()=>s().createActions({list:{asyncResult:!0},listSearchesClusterConfig:{asyncResult:!0},listMessageProcessorsConfig:{asyncResult:!0},listEventsClusterConfig:{asyncResult:!0},listIndexSetsDefaultsClusterConfig:{asyncResult:!0},listWhiteListConfig:{asyncResult:!0},listPermissionsConfig:{asyncResult:!0},listUserConfig:{asyncResult:!0},update:{asyncResult:!0},updateWhitelist:{asyncResult:!0},updateIndexSetDefaults:{asyncResult:!0},updateMessageProcessorsConfig:{asyncResult:!0}})),g=n.Z.ClusterConfigResource.config().url,p=(0,v.dS)("core.Configuration",()=>s().createStore({listenables:[d],configuration:{},searchesClusterConfig:{},eventsClusterConfig:{},indexSetsDefaultConfig:{},getInitialState(){return this.getState()},getState(){return{configuration:this.configuration,searchesClusterConfig:this.searchesClusterConfig,eventsClusterConfig:this.eventsClusterConfig,indexSetsDefaultConfig:this.indexSetsDefaultConfig}},propagateChanges(){this.trigger(this.getState())},_url(E){return(0,o.DC)(g+E)},list(E){const a=(0,r.ZP)("GET",this._url(`/${E}`));a.then(u=>(this.configuration={...this.configuration,[E]:u},this.propagateChanges(),u)),d.list.promise(a)},listSearchesClusterConfig(){const E=(0,r.ZP)("GET",this._url("/org.graylog2.indexer.searches.SearchesClusterConfig")).then(a=>(this.searchesClusterConfig=a,this.propagateChanges(),a));d.listSearchesClusterConfig.promise(E)},listMessageProcessorsConfig(E){const a=(0,r.ZP)("GET",(0,o.DC)("/system/messageprocessors/config")).then(u=>(this.configuration={...this.configuration,[E]:u},this.propagateChanges(),u));d.listMessageProcessorsConfig.promise(a)},listWhiteListConfig(E){const a=(0,r.ZP)("GET",(0,o.DC)("/system/urlwhitelist")).then(u=>(this.configuration={...this.configuration,[E]:u},this.propagateChanges(),u));d.listWhiteListConfig.promise(a)},listPermissionsConfig(E){const a=(0,r.ZP)("GET",this._url(`/${E}`)).then(u=>(this.configuration={...this.configuration,[E]:u||{allow_sharing_with_everyone:!0,allow_sharing_with_users:!0}},this.propagateChanges(),u));d.listPermissionsConfig.promise(a)},listUserConfig(E){const a=(0,r.ZP)("GET",this._url(`/${E}`)).then(u=>(this.configuration={...this.configuration,[E]:u||{enable_global_session_timeout:!1,global_session_timeout_interval:"PT1H"}},this.propagateChanges(),u));d.listUserConfig.promise(a)},listEventsClusterConfig(){const E=(0,r.ZP)("GET",this._url("/org.graylog.events.configuration.EventsConfiguration")).then(a=>(this.eventsClusterConfig=a,this.propagateChanges(),a));d.listEventsClusterConfig.promise(E)},listIndexSetsDefaultsClusterConfig(){const E=(0,r.ZP)("GET",this._url("/org.graylog2.configuration.IndexSetsDefaultConfiguration")).then(a=>(this.indexSetsDefaultConfig=a,this.propagateChanges(),a));d.listIndexSetsDefaultsClusterConfig.promise(E)},updateIndexSetDefaults(E,a){const u=(0,r.ZP)("PUT",(0,o.DC)("/system/indices/index_set_defaults"),a);u.then(()=>(this.configuration={...this.configuration,[E]:a},this.propagateChanges(),c.Z.success("Index defaults configuration updated successfully"),a),f=>{c.Z.error(f.additional.body.message,"Index defaults configuration update failed")}),d.updateIndexSetDefaults.promise(u)},update(E,a){const u=(0,r.ZP)("PUT",this._url(`/${E}`),a);u.then(f=>(this.configuration={...this.configuration,[E]:f},this.propagateChanges(),c.Z.success("Configuration updated successfully"),f),f=>{c.Z.error(`Search config update failed: ${f}`,`Could not update search config: ${E}`)}),d.update.promise(u)},updateWhitelist(E,a){const u=(0,r.ZP)("PUT",(0,o.DC)("/system/urlwhitelist"),a);u.then(()=>(this.configuration={...this.configuration,[E]:a},this.propagateChanges(),c.Z.success("Url Whitelist Configuration updated successfully"),a),f=>{c.Z.error(`Url Whitelist config update failed: ${f}`,`Could not update Url Whitelist: ${E}`)}),d.updateWhitelist.promise(u)},updateMessageProcessorsConfig(E,a){const u=(0,r.ZP)("PUT",(0,o.DC)("/system/messageprocessors/config"),a);u.then(f=>(this.configuration={...this.configuration,[E]:f},this.propagateChanges(),c.Z.success("Configuration updated successfully"),f),f=>{c.Z.error(`Message processors config update failed: ${f}`,`Could not update config: ${E}`)}),d.updateMessageProcessorsConfig.promise(u)}}))},"8fnsnG21":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d,o:()=>c});var t=e("Z7aTuO5B"),s=e("87D/Fijl"),o=e.n(s),r=e("SwOo9/Yp");const n=g=>g;function c(g,p=n){const[E,a]=(0,t.useState)(()=>g.getInitialState()),u=(0,t.useRef)(E),f=(0,t.useMemo)(()=>p(E),[p,E]);return(0,t.useEffect)(()=>{const y=g.listen(T=>{(0,r.Z)(T,u.current)||(a(T),u.current=T)});return a(g.getInitialState()),y},[g]),f}function v(g,p,E=a=>a){const a=g.displayName||g.name||"Unknown/Anonymous";class u extends t.Component{constructor(y){super(y),this._genProps=P=>{const O={};return Object.keys(p).forEach(b=>{O[b]=P[b]}),E(O)};const T=Object.keys(p).map(P=>{const O=p[P];if(O===void 0||!o()(O.getInitialState))return console.error(`Error: The store passed for the \`${P}\` property is not defined or invalid. Check the connect()-call wrapping your \`${a}\` component.`),[P,void 0];const b=O.getInitialState();return[P,b]}).reduce((P,[O,b])=>({...P,[O]:b}),{});this.state={...this.state,...T}}componentDidMount(){this.unsubscribes=Object.keys(p).map(y=>{const T=p[y];return T===void 0||!o()(T.listen)?(console.error(`Error: The store passed for the \`${y}\` property is not defined or invalid. Check the connect()-call wrapping your \`${a}\` component.`),()=>{}):T.listen(P=>this.setState(O=>({...O,[y]:P})))})}shouldComponentUpdate(y,T){const P=this._genProps(this.state),O=this._genProps(T);return!((0,r.Z)(P,O)&&(0,r.Z)(this.props,y))}componentWillUnmount(){this.unsubscribes.forEach(y=>y())}render(){const y=this._genProps(this.state),{ref:T,...P}=this.props;return t.createElement(g,{...y,...P})}}return u.displayName=`ConnectStoresWrapper[${a}] stores=${Object.keys(p).join(",")}`,u}const d=v},pa3lbc7X:(M,C,e)=>{"use strict";e.d(C,{D:()=>v,I:()=>d});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("U1Iufsob"),n=e("eFxcQyPT"),c=e("IA3Ku5lS");const v=(0,c.ei)("core.Decorators",()=>s().createActions({available:{asyncResult:!0},create:{asyncResult:!0},list:{asyncResult:!0},remove:{asyncResult:!0},update:{asyncResult:!0}})),d=(0,c.dS)("core.Decorators",()=>s().createStore({listenables:[v],state:{},getInitialState(){return this.state},init(){v.available(),v.list()},list(){const g=o.DC(r.Z.DecoratorsResource.get().url),p=(0,n.ZP)("GET",g);return p.then(E=>{this.trigger({decorators:E}),this.state.decorators=E}),v.list.promise(p),p},available(){const g=o.DC(r.Z.DecoratorsResource.available().url),p=(0,n.ZP)("GET",g);return p.then(E=>{this.trigger({types:E}),this.state.types=E}),v.available.promise(p),p},create(g){const p=o.DC(r.Z.DecoratorsResource.create().url),E=(0,n.ZP)("POST",p,g);return v.create.promise(E),E},createCompleted(){v.list()},remove(g){const p=o.DC(r.Z.DecoratorsResource.remove(g).url),E=(0,n.ZP)("DELETE",p);return v.remove.promise(E),E},removeCompleted(){v.list()},update(g,p){const E=o.DC(r.Z.DecoratorsResource.update(g).url),a=(0,n.ZP)("PUT",E,p);return v.update.promise(a),a},updateCompleted(){v.list()}}))},"0j5jZleo":(M,C,e)=>{"use strict";e.d(C,{Q:()=>v});var t=e("JnTtTRmZ"),s=e.n(t),o=e("jAGDuYSC"),r=e("MdYBRjRJ"),n=e("eFxcQyPT"),c=e("IA3Ku5lS");const v=(0,c.dS)("core.InputStaticFields",()=>s().createStore({listenables:[],sourceUrl:d=>`/system/inputs/${d}/staticfields`,create(d,g,p){const E=r.DC(this.sourceUrl(d.id)),a=(0,n.ZP)("POST",E,{key:g,value:p});return a.then(u=>(this.trigger({}),o.Z.success(`Static field '${g}' added to '${d.title}' successfully`),u),u=>{o.Z.error(`Adding static field to input failed with: ${u}`,`Could not add static field to input '${d.title}'`)}),a},destroy(d,g){const p=r.DC(`${this.sourceUrl(d.id)}/${g}`),E=(0,n.ZP)("DELETE",p);return E.then(a=>(this.trigger({}),o.Z.success(`Static field '${g}' removed from '${d.title}' successfully`),a),a=>{o.Z.error(`Removing static field from input failed with: ${a}`,`Could not remove static field '${g} from input '${d.title}'`)}),E}}))},yEuO7gC5:(M,C,e)=>{"use strict";e.d(C,{Q:()=>g,x:()=>d});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("eFxcQyPT"),n=e("jAGDuYSC"),c=e("IA3Ku5lS"),v=e("0j5jZleo");const d=(0,c.ei)("core.Inputs",()=>s().createActions({list:{asyncResult:!0},get:{asyncResult:!0},getOptional:{asyncResult:!0},create:{asyncResult:!0},delete:{asyncResult:!0},update:{asyncResult:!0}})),g=(0,c.dS)("core.Inputs",()=>s().createStore({listenables:[d],sourceUrl:"/system/inputs",inputs:void 0,input:void 0,init(){this.trigger(this._state()),this.listenTo(v.Q,this.list)},getInitialState(){return this._state()},_state(){return{inputs:this.inputs,input:this.input}},list(){const p=(0,r.ZP)("GET",o.DC(this.sourceUrl));p.then(E=>(this.inputs=E.inputs,this.trigger(this._state()),this.inputs),E=>{n.Z.error(`Fetching Inputs failed with status: ${E}`,"Could not retrieve Inputs")}),d.list.promise(p)},get(p){return this.getOptional(p,!0)},getOptional(p,E){const a=(0,r.ZP)("GET",o.DC(`${this.sourceUrl}/${p}`));a.then(u=>(this.input=u,this.trigger(this._state()),this.input),u=>{E?n.Z.error(`Fetching input ${p} failed with status: ${u}`,"Could not retrieve input"):this.trigger(this._state())}),d.get.promise(a)},create(p){const E=(0,r.ZP)("POST",o.DC(this.sourceUrl),p);E.then(()=>{n.Z.success(`Input '${p.title}' launched successfully`),d.list()},a=>{n.Z.error(`Launching input '${p.title}' failed with status: ${a}`,"Could not launch input")}),d.create.promise(E)},delete(p){const E=p.id,a=p.title,u=(0,r.ZP)("DELETE",o.DC(`${this.sourceUrl}/${E}`));u.then(()=>{n.Z.success(`Input '${a}' deleted successfully`),d.list()},f=>{n.Z.error(`Deleting input '${a}' failed with status: ${f}`,"Could not delete input")}),d.delete.promise(u)},update(p,E){const a=(0,r.ZP)("PUT",o.DC(`${this.sourceUrl}/${p}`),E);a.then(()=>{n.Z.success(`Input '${E.title}' updated successfully`),d.list()},u=>{n.Z.error(`Updating input '${E.title}' failed with status: ${u}`,"Could not update input")}),d.update.promise(a)}}));g.inputsAsMap=p=>{const E={};return p.forEach(a=>{E[a.id]=a}),E}},"SwOo9/Yp":(M,C,e)=>{"use strict";e.d(C,{Z:()=>u});var t=e("1twFHSbl"),s=e.n(t),o=e("87D/Fijl"),r=e.n(o),n=e("Z7aTuO5B"),c=e("7KtBiBAd"),v=e.n(c);const d=(f,y)=>f&&f[y]&&r()(f[y]),g=f=>d(f,"equals"),p=f=>d(f,"toJS"),E=(f,y)=>{if(p(f)&&p(y))return s()(f.toJS(),y.toJS(),E);if(g(f))return f.equals(y);if((0,n.isValidElement)(f)||(0,n.isValidElement)(y))return v()(f,y)},u=(f,y)=>s()(f,y,E)},woUyHGxd:(M,C,e)=>{"use strict";e.d(C,{K:()=>p,q:()=>E});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("U1Iufsob"),n=e("eFxcQyPT"),c=e("5NVsf39r"),v=e("IA3Ku5lS"),d=e("Vg8s2y9S"),g=e("pc+thvZE");const p=(0,v.ei)("core.Metrics",()=>s().createActions({add:{asyncResult:!0},addGlobal:{asyncResult:!0},clear:{asyncResult:!0},filter:{asyncResult:!0},list:{asyncResult:!0},names:{asyncResult:!0},remove:{asyncResult:!0},removeGlobal:{asyncResult:!0}})),E=(0,v.dS)("core.Metrics",()=>s().createStore({listenables:[p,g.SessionActions],namespace:"org",registrations:{},globalRegistrations:{},promises:{},init(){this.listenTo(d.S,this.updateNodes)},getInitialState(){return{metricsNames:this.metricsNames,metrics:this.metrics}},updateNodes(a){this.nodes=a.nodes},_allResults(a){const u=[];let f=Promise.resolve(null);return a.forEach(y=>{f=f.then(()=>y).then(T=>u.push(T),T=>u.push(T))}),f.then(()=>u)},_metricsToFetch(a,u){const f={};return Object.keys(a).filter(y=>Object.keys(a[y]).length>0).forEach(y=>{Object.keys(a[y]).filter(T=>a[y][T]>0).forEach(T=>{f[T]=1})}),Object.keys(u).filter(y=>u[y]>0).forEach(y=>{f[y]=1}),f},_buildMetricsFromResponse(a){const u={};return Object.keys(a).forEach(f=>{const y={};a[f]&&(a[f].metrics.forEach(T=>{y[T.full_name]=T}),u[f]=y)}),u},list(){if(!g.SessionStore.isLoggedIn())return null;const a=this._metricsToFetch(this.registrations,this.globalRegistrations),u=o.DC(r.Z.ClusterMetricsApiController.multipleAllNodes().url);if(!this.promises.list){const f=(0,n.vl)("POST",u,{metrics:Object.keys(a)}).finally(()=>delete this.promises.list);f.then(y=>(this.metrics=this._buildMetricsFromResponse(y),this.trigger({metrics:this.metrics,metricsUpdatedAt:c.Z.nowInSeconds()}),this.metrics)),this.promises.list=f}return p.list.promise(this.promises.list),this.promises.list},names(){if(!this.nodes){console.warn("Node list not yet available, not fetching metrics.");return}const a=this._allResults(Object.keys(this.nodes).map(u=>{const f=o.DC(r.Z.ClusterMetricsApiController.byNamespace(u,this.namespace).url);return(0,n.ZP)("GET",f).then(y=>({nodeId:u,names:y.metrics}),y=>({nodeId:u,names:this.metricsNames[u],error:y}))})).then(u=>{const f={},y={};return u.forEach(T=>{T.nodeId&&(f[T.nodeId]=T.names,y[T.nodeId]=T.error)}),this.trigger({metricsNames:f,metricsErrors:y}),this.metricsNames=f,f});p.names.promise(a)},add(a,u){this.registrations[a]||(this.registrations[a]={}),this.registrations[a][u]=this.registrations[a][u]?this.registrations[a][u]+1:1},addGlobal(a){this.globalRegistrations[a]?this.globalRegistrations[a]+=1:this.globalRegistrations[a]=1},remove(a,u){this.registrations[a]&&(this.registrations[a][u]=this.registrations[a][u]>0?this.registrations[a][u]-1:0,this.registrations[a][u]===0&&delete this.registrations[a][u])},removeGlobal(a){this.globalRegistrations[a]&&(this.globalRegistrations[a]=this.globalRegistrations[a]>0?this.globalRegistrations[a]-1:0,this.globalRegistrations[a]===0&&delete this.globalRegistrations[a])}}))},Vg8s2y9S:(M,C,e)=>{"use strict";e.d(C,{S:()=>g,h:()=>d});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("eFxcQyPT"),n=e("U1Iufsob"),c=e("IA3Ku5lS"),v=e("pc+thvZE");const d=(0,c.ei)("core.Nodes",()=>s().createActions({list:{asyncResult:!0}})),g=(0,c.dS)("core.Nodes",()=>s().createStore({listenables:[d],nodes:void 0,clusterId:void 0,nodeCount:0,INTERVAL:5e3,promises:{},init(){this.nodes===void 0&&(this._triggerList(),setInterval(this._triggerList,this.INTERVAL))},_triggerList(){v.SessionStore.isLoggedIn()&&d.list()},getInitialState(){return this.getNodesInfo()},getNodesInfo(){return{nodes:this.nodes,clusterId:this.clusterId,nodeCount:this.nodeCount}},list(){const p=this.promises.list||(0,r.vl)("GET",(0,o.DC)(n.Z.ClusterApiResource.list().url)).then(E=>(this.nodes={},E.nodes&&(this.nodes=E.nodes.map(a=>[a.node_id,a]).reduce((a,[u,f])=>({...a,[u]:f}),{}),this.clusterId=this._clusterId(),this.nodeCount=this._nodeCount(),this._propagateState()),E)).finally(()=>delete this.promises.list);this.promises.list=p,d.list.promise(p)},getNode(p){var E;return(E=this.nodes)==null?void 0:E[p]},_clusterId(){const p=Object.keys(this.nodes).map(E=>this.nodes[E]).find(E=>E.cluster_id);return p?p.cluster_id.toUpperCase():void 0},_nodeCount(){return Object.keys(this.nodes).length},_propagateState(){this.trigger(this.getNodesInfo())}}))},bpbGjAaT:(M,C,e)=>{"use strict";e.d(C,{p:()=>d,x:()=>v});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("U1Iufsob"),n=e("eFxcQyPT"),c=e("IA3Ku5lS");const v=(0,c.ei)("core.Notifications",()=>s().createActions({delete:{asyncResult:!0},list:{asyncResult:!0},getHtmlMessage:{asyncResult:!0}})),d=(0,c.dS)("core.Notifications",()=>s().createStore({listenables:[v],notifications:void 0,total:void 0,message:{},promises:{},init(){this.list()},getInitialState(){return{notifications:this.notifications,total:this.total,messages:this.messages}},propagateChanges(){this.trigger({notifications:this.notifications,total:this.total,messages:this.messages})},list(){const g=o.DC(r.Z.NotificationsApiController.list().url),p=this.promises.list||(0,n.vl)("GET",g).finally(()=>delete this.promises.list);this.promises.list=p,v.list.promise(p)},listCompleted(g){this.notifications=g.notifications,this.total=g.total,this.propagateChanges()},delete(g,p){let E;p?E=o.DC(r.Z.NotificationsApiController.deleteWithKey(g,p).url):E=o.DC(r.Z.NotificationsApiController.delete(g).url);const a=(0,n.ZP)("DELETE",E);v.delete.promise(a)},deleteCompleted(){this.list(),this.propagateChanges()},getHtmlMessage(g,p,E={values:{}}){let a;p?a=o.DC(r.Z.NotificationsApiController.getHtmlMessageWithKey(g,p).url):a=o.DC(r.Z.NotificationsApiController.getHtmlMessage(g).url);const u=(0,n.ZP)("POST",a,E);u.then(f=>{this.messages={...this.messages,[`${g}-${p}`]:f},this.propagateChanges()}),v.getHtmlMessage.promise(u)}}))},"IQSYq7+p":(M,C,e)=>{"use strict";e.d(C,{N2:()=>W,ey:()=>ne});var t=e("JnTtTRmZ"),s=e.n(t),o=e("VPaD/Np4"),r=e("EregcbZy"),n=e("U1Iufsob"),c=e("eFxcQyPT"),v=e("4E3oowBb");class d{constructor(ee,ue){this._value={id:ee,title:ue}}get id(){return this._value.id}get title(){return this._value.title}toBuilder(){const{id:ee,title:ue}=this._value;return new g(o.Map({id:ee,title:ue}))}toJSON(){const{id:ee,title:ue}=this._value;return{id:ee,title:ue}}static fromJSON(ee){const{id:ue,title:H}=ee;return d.builder().id(ue).title(H).build()}static builder(){return new g}}class g{constructor(ee=o.Map()){this.value=ee}id(ee){return new g(this.value.set("id",ee))}title(ee){return new g(this.value.set("title",ee))}build(){const{id:ee,title:ue}=this.value.toObject();return new d(ee,ue)}}var p=e("CIb2ALfk");class E{constructor(ee,ue,H){this._value={grant:ee,grantee:ue,capability:H}}get grant(){return this._value.grant}get grantee(){return this._value.grantee}get capability(){return this._value.capability}toBuilder(){const{grant:ee,grantee:ue,capability:H}=this._value;return new a(o.Map({grant:ee,grantee:ue,capability:H}))}toJSON(){const{grant:ee,grantee:ue,capability:H}=this._value;return{grant:ee,grantee:ue,capability:H}}static fromJSON(ee){const{grant:ue,grantee:H,capability:ye}=ee;return E.builder().grant(ue).grantee(H).capability(ye).build()}static builder(){return new a}}class a{constructor(ee=o.Map()){this.value=ee}grant(ee){return new a(this.value.set("grant",ee))}grantee(ee){return new a(this.value.set("grantee",ee))}capability(ee){return new a(this.value.set("capability",ee))}build(){const{grant:ee,grantee:ue,capability:H}=this.value.toObject();return new E(ee,ue,H)}}class u{constructor(ee,ue,H,ye){this._value={id:ee,title:ue,type:H,capabilityId:ye}}get id(){return this._value.id}get title(){return this._value.title}get type(){return this._value.type}get capabilityId(){return this._value.capabilityId}currentState(ee){const{capabilityId:ue,id:H}=this._value,ye=ee.find(we=>we.grantee===H);return ye?ye.capability!==ue?"changed":"unchanged":"new"}static create(ee,ue,H,ye){return new u(ee,ue,H,ye)}}class f{constructor(ee,ue,H){this._value={errors:ee,errorContext:ue,failed:H}}get errors(){return this._value.errors}get errorContext(){return this._value.errorContext}get failed(){return this._value.failed}toBuilder(){const{errors:ee,errorContext:ue,failed:H}=this._value;return new y(o.Map({errors:ee,errorContext:ue,failed:H}))}static create(ee,ue,H){return new f(ee,ue,H)}static createSuccess(){return f.create({selectedGranteeCapabilities:o.List()},{selectedGranteeCapabilities:o.List()},!1)}toJSON(){const{errors:ee,errorContext:ue,failed:H}=this._value;return{errors:{selected_grantee_capabilities:ee.selectedGranteeCapabilities},error_context:{selected_grantee_capabilities:ue.selectedGranteeCapabilities},failed:H}}static fromJSON(ee){if(!ee)return f.createSuccess();const{errors:ue,error_context:H,failed:ye}=ee,we={selectedGranteeCapabilities:o.List(ue.selected_grantee_capabilities)},ut={selectedGranteeCapabilities:o.List(H.selected_grantee_capabilities)};return f.create(we,ut,ye)}static builder(){return new y}}class y{constructor(ee=o.Map()){this.value=ee}errors(ee){return new y(this.value.set("errors",ee))}errorContext(ee){return new y(this.value.set("errorContext",ee))}failed(ee){return new y(this.value.set("failed",ee))}build(){const{errors:ee,errorContext:ue,failed:H}=this.value.toObject();return new f(ee,ue,H)}}const T=ae=>{let ee=o.Map();return Object.keys(ae).forEach(ue=>{const H=ae[ue];ee=ee.set(ue,H.map(ye=>r.Z.fromJSON(ye)))}),ee},P=(ae,ee)=>{const ue=ae.filter(ye=>!ee||ee.findIndex(we=>we.grantee===ye.id)>=0).sort((ye,we)=>(0,v.S)(ye.title,we.title)).groupBy(ye=>ye.type),H=ae.filter(ye=>ee&&ee.findIndex(we=>we.grantee===ye.id)===-1).reverse();return o.List().concat(H,ue.get("error"),ue.get("global"),ue.get("team"),ue.get("user")).filter(ye=>!!ye).toList()};class O{constructor(ee,ue,H,ye,we,ut,ht){this._value={entity:ee,availableGrantees:P(ue),availableCapabilities:H,activeShares:ye,selectedGranteeCapabilities:we,missingDependencies:ut,validationResults:ht}}get entity(){return this._value.entity}get availableGrantees(){return this._value.availableGrantees}get availableCapabilities(){return this._value.availableCapabilities}get activeShares(){return this._value.activeShares}get selectedGranteeCapabilities(){return this._value.selectedGranteeCapabilities}get missingDependencies(){return this._value.missingDependencies}get validationResults(){return this._value.validationResults}get selectedGrantees(){const ee=H=>this._value.availableGrantees.find(ye=>ye.id===H),ue=this._value.selectedGranteeCapabilities.entrySeq().map(([H,ye])=>{const we=ee(H);return we?u.create(we.id,we.title,we.type,ye):u.create(H,`not found ${H} (error)`,"error",ye)}).toList();return P(ue,this._value.activeShares)}toBuilder(){const{entity:ee,availableGrantees:ue,availableCapabilities:H,activeShares:ye,selectedGranteeCapabilities:we,missingDependencies:ut,validationResults:ht}=this._value;return new b(o.Map({entity:ee,availableGrantees:ue,availableCapabilities:H,activeShares:ye,selectedGranteeCapabilities:we,missingDependencies:ut,validationResults:ht}))}toJSON(){const{entity:ee,availableGrantees:ue=o.List(),availableCapabilities:H=o.List(),activeShares:ye=o.List(),selectedGranteeCapabilities:we=o.Map(),missingDependencies:ut=o.Map(),validationResults:ht}=this._value;return{entity:ee,available_grantees:ue.toJS(),available_capabilities:H.toJS(),active_shares:ye.toJS(),selected_grantee_capabilities:we.toJS(),missing_permissions_on_dependencies:ut.toJS(),validation_result:ht}}static fromJSON(ee){const{entity:ue,available_grantees:H,available_capabilities:ye,active_shares:we,selected_grantee_capabilities:ut,missing_permissions_on_dependencies:ht,validation_result:Je}=ee,Re=o.fromJS(H.map(J=>p.Z.fromJSON(J))),le=o.fromJS(ye.map(J=>d.fromJSON(J))),me=o.fromJS(we.map(J=>E.fromJSON(J))),re=o.fromJS(ut),ce=T(ht),Q=f.fromJSON(Je);return new O(ue,Re,le,me,re,ce,Q)}static builder(){return new b}}class b{constructor(ee=o.Map()){this.value=ee}entity(ee){return new b(this.value.set("entity",ee))}availableGrantees(ee){return new b(this.value.set("availableGrantees",ee))}availableCapabilities(ee){return new b(this.value.set("availableCapabilities",ee))}activeShares(ee){return new b(this.value.set("activeShares",ee))}selectedGranteeCapabilities(ee){return new b(this.value.set("selectedGranteeCapabilities",ee))}missingDependencies(ee){return new b(this.value.set("missingDependencies",ee))}validationResults(ee){return new b(this.value.set("validationResults",ee))}build(){const{entity:ee,availableGrantees:ue,availableCapabilities:H,activeShares:ye,selectedGranteeCapabilities:we,missingDependencies:ut,validationResults:ht}=this.value.toObject();return new O(ee,ue,H,ye,we,ut,ht)}}var L=e("IA3Ku5lS");const W=(0,L.ei)("permissions.EntityShare",()=>s().createActions({prepare:{asyncResult:!0},update:{asyncResult:!0},loadUserSharesPaginated:{asyncResult:!0}}));var N=e("MdYBRjRJ"),Z=e("gyRmhZSW");const j={},z=({additional_queries:ae,context:ee,count:ue,entities:H,page:ye,per_page:we,query:ut,total:ht})=>({list:o.List(H.map(Je=>r.Z.fromJSON(Je))),context:{granteeCapabilities:ee.grantee_capabilities},pagination:{additionalQueries:ae,page:ye,perPage:we,query:ut,count:ue,total:ht}}),ne=(0,L.dS)("permissions.EntityShare",()=>s().createStore({listenables:[W],state:void 0,getInitialState(){return this._state()},prepare(ae,ee,ue,H=j){const ye=(0,N.DC)(n.Z.EntityShareController.prepare(ue).url),we=(0,c.ZP)("POST",ye,JSON.stringify(H)).then(this._handleResponse);return W.prepare.promise(we),we},update(ae,ee,ue,H){const ye=(0,N.DC)(n.Z.EntityShareController.update(ue).url),we=(0,c.ZP)("POST",ye,JSON.stringify(H)).then(this._handleResponse);return W.update.promise(we),we},loadUserSharesPaginated(ae,{page:ee,perPage:ue,query:H,additionalQueries:ye}){const we=(0,Z.Z)(n.Z.EntityShareController.userSharesPaginated(ae).url,ee,ue,H,ye),ut=(0,c.ZP)("GET",(0,N.DC)(we)).then(z);return W.loadUserSharesPaginated.promise(ut),ut},_handleResponse(ae){const ee=O.fromJSON(ae);return this.state=ee,this._trigger(),this.state},_state(){return{state:this.state}},_trigger(){this.trigger(this._state())}})),Y=null},"rjGM+nrz":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d,w:()=>c});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("U1Iufsob"),n=e("IA3Ku5lS");const c=(0,n.ei)("core.ServerAvailability",()=>s().createActions(["reportError","reportSuccess"])),v=g=>window.fetch(g,{method:"GET",headers:{Accept:"application/json","X-Graylog-No-Session-Extension":"true"}}),d=(0,n.dS)("core.ServerAvailability",()=>s().createStore({listenables:[c],server:{up:!0},init(){this.ping()},getInitialState(){return{server:this.server}},ping(){return v(o.DC(r.Z.ping().url)).then(()=>c.reportSuccess(),g=>c.reportError(g))},reportError(g){this.server.up&&(this.server={up:!1,error:g},this.trigger({server:this.server}))},reportSuccess(){this.server.up||(this.server={up:!0},this.trigger({server:this.server}))}}))},"pc+thvZE":(M,C,e)=>{"use strict";e.r(C),e.d(C,{SessionActions:()=>d,SessionStore:()=>g});var t=e("JnTtTRmZ"),s=e.n(t),o=e("7GNmVOX8"),r=e("MdYBRjRJ"),n=e("U1Iufsob"),c=e("eFxcQyPT"),v=e("IA3Ku5lS");const d=(0,v.ei)("core.Session",()=>s().createActions({login:{asyncResult:!0},logout:{asyncResult:!0},validate:{asyncResult:!0}})),g=(0,v.dS)("core.Session",()=>s().createStore({listenables:[d],sourceUrl:"/system/sessions",username:void 0,validatingSession:!1,init(){this.validate()},getInitialState(){return this.getSessionInfo()},login(p,E,a){const f=new c.Ib("POST",(0,r.DC)(this.sourceUrl)).json({username:p,password:E,host:a}).build().then(y=>({username:y==null?void 0:y.username}));d.login.promise(f)},logout(){const p=new c.Ib("DELETE",(0,r.DC)(`${this.sourceUrl}/`)).build().then(E=>{(E.ok||E.status===401)&&this._removeSession()},this._removeSession);d.logout.promise(p)},validate(){const p=o.Z.get("username");this.validatingSession=!0,this._propagateState();const E=this._validateSession().then(a=>{var u;return a.is_valid?d.login.completed({username:(u=a.username)!=null?u:p}):(p&&this._removeSession(),a)}).finally(()=>{this.validatingSession=!1,this._propagateState()});d.validate.promise(E)},_validateSession(){return new c.Ib("GET",(0,r.DC)(n.Z.SessionsApiController.validate().url)).json().build()},_removeSession(){o.Z.delete("username"),this.username=void 0,this._propagateState()},_propagateState(){this.trigger(this.getSessionInfo())},loginCompleted(p){const{username:E}=p;o.Z.set("username",E),this.username=E,this._propagateState()},isLoggedIn(){return!!this.username},getSessionInfo(){return{username:this.username,validatingSession:this.validatingSession}}}))},"pUKP3+Pg":(M,C,e)=>{"use strict";e.d(C,{s3:()=>a,sH:()=>f,ZP:()=>y});var t=e("JnTtTRmZ"),s=e.n(t),o=e("XYSsaeV4"),r=e.n(o),n=e("eFxcQyPT"),c=e("U1Iufsob"),v=e("MdYBRjRJ"),d=e("jAGDuYSC"),g=e("gyRmhZSW"),p=e("IA3Ku5lS");const a=(0,p.ei)("Streams",()=>s().createActions({searchPaginated:{asyncResult:!0},listStreams:{asyncResult:!0},load:{asyncResult:!0},get:{asyncResult:!0},remove:{asyncResult:!0},pause:{asyncResult:!0},resume:{asyncResult:!0},cloneStream:{asyncResult:!0},update:{asyncResult:!0},save:{asyncResult:!0},removeOutput:{asyncResult:!0},addOutput:{asyncResult:!0},testMatch:{asyncResult:!0}}));var u=e("J1ga+jW6");const f=(0,p.dS)("Streams",()=>s().createStore({listenables:[a],callbacks:[],searchPaginated(T,P,O,b){const L=(0,g.Z)(c.Z.StreamsApiController.paginated().url,T,P,O,b),x=(0,n.ZP)("GET",(0,v.DC)(L)).then(W=>{const{elements:N,query:Z,attributes:j,pagination:{count:z,total:ne,page:Y,per_page:ae}}=W;return{elements:N,attributes:j,pagination:{count:z,total:ne,page:Y,perPage:ae,query:Z}}});return a.searchPaginated.promise(x),x},listStreams(){const T="/streams",P=(0,n.ZP)("GET",(0,v.DC)(T)).then(O=>O.streams).catch(O=>{d.Z.error(`Loading streams failed with status: ${O}`,"Could not load streams")});return a.listStreams.promise(P),P},load(T){this.listStreams().then(P=>{T(P)})},remove(T){const P=(0,v.DC)(c.Z.StreamsApiController.delete(T).url),O=(0,n.ZP)("DELETE",P).then(()=>u.D.reload().then(this._emitChange.bind(this)));return a.remove.promise(O),O},pause(T,P){const O=x=>{d.Z.error(`Pausing Stream failed with status: ${x}`,"Could not pause Stream")},b=(0,v.DC)(c.Z.StreamsApiController.pause(T).url),L=(0,n.ZP)("POST",b).then(P,O).then(x=>(this._emitChange(),x));return a.pause.promise(L),L},resume(T,P){const O=x=>{d.Z.error(`Resuming Stream failed with status: ${x}`,"Could not resume Stream")},b=(0,v.DC)(c.Z.StreamsApiController.resume(T).url),L=(0,n.ZP)("POST",b).then(P,O).then(x=>(this._emitChange(),x));return a.resume.promise(L),L},save(T,P){const O=x=>{d.Z.error(`Saving Stream failed with status: ${x}`,"Could not save Stream")},b=(0,v.DC)(c.Z.StreamsApiController.create().url),L=(0,n.ZP)("POST",b,T).then(P,O).then(()=>u.D.reload().then(this._emitChange.bind(this)));return a.save.promise(L),L},update(T,P,O){const b=W=>{d.Z.error(`Updating Stream failed with status: ${W}`,"Could not update Stream")},L=(0,v.DC)(c.Z.StreamsApiController.update(T).url),x=(0,n.ZP)("PUT",L,P).then(O,b).then(this._emitChange.bind(this));return a.update.promise(x),x},cloneStream(T,P,O){const b=W=>{d.Z.error(`Cloning Stream failed with status: ${W}`,"Could not clone Stream")},L=(0,v.DC)(c.Z.StreamsApiController.cloneStream(T).url),x=(0,n.ZP)("POST",L,P).then(O,b).then(()=>u.D.reload().then(this._emitChange.bind(this)));return a.cloneStream.promise(x),x},removeOutput(T,P,O){const b=(0,v.DC)(c.Z.StreamOutputsApiController.delete(T,P).url),L=(0,n.ZP)("DELETE",b).then(O,x=>{d.Z.error(`Removing output from stream failed with status: ${x}`,"Could not remove output from stream")}).then(this._emitChange.bind(this));return a.removeOutput.promise(L),L},addOutput(T,P,O){const b=(0,v.DC)(c.Z.StreamOutputsApiController.add(T).url),L=(0,n.ZP)("POST",b,{outputs:[P]}).then(O,x=>{d.Z.error(`Adding output to stream failed with status: ${x}`,"Could not add output to stream")}).then(this._emitChange.bind(this));return a.addOutput.promise(L),L},testMatch(T,P,O){const b=(0,v.DC)(c.Z.StreamsApiController.testMatch(T).url),L=(0,n.ZP)("POST",b,P).then(O,x=>{d.Z.error(`Testing stream rules of stream failed with status: ${x.message}`,"Could not test stream rules of stream")});return a.testMatch.promise(L),L},onChange(T){this.callbacks.push(T)},_emitChange(){this.callbacks.forEach(T=>T())},unregister(T){r()(this.callbacks,T)}})),y=f},"9xj2LQzD":(M,C,e)=>{"use strict";e.d(C,{B:()=>v});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("U1Iufsob"),n=e("eFxcQyPT"),c=e("IA3Ku5lS");const v=(0,c.dS)("core.System",()=>s().createStore({system:void 0,locales:void 0,init(){this.info().then(d=>{this.trigger({system:d}),this.system=d}),this.systemLocales().then(d=>{this.trigger({locales:d}),this.locales=d.locales})},getInitialState(){return{system:this.system,locales:this.locales}},info(){const d=o.DC(r.Z.SystemApiController.info().url);return(0,n.ZP)("GET",d)},jvm(){const d=o.DC(r.Z.SystemApiController.jvm().url);return(0,n.ZP)("GET",d)},systemLocales(){const d=o.DC(r.Z.SystemApiController.locales().url);return(0,n.ZP)("GET",d)},elasticsearchVersion(){const d=o.DC(r.Z.ClusterApiResource.elasticsearchStats().url);return new Promise((p,E)=>{(0,n.ZP)("GET",d).then(a=>{const u=a.cluster_version.split(".");p({major:u[0],minor:u[1],patch:u[2]})}).catch(E)})}}))},"2aaiYHqX":(M,C,e)=>{"use strict";e.d(C,{W:()=>g,o:()=>p});var t=e("JnTtTRmZ"),s=e.n(t),o=e("IA3Ku5lS"),r=e("MdYBRjRJ"),n=e("U1Iufsob"),c=e("eFxcQyPT"),v=e("jAGDuYSC");const d=n.Z.TelemetryApiController.setting().url,g=(0,o.ei)("telemetry.settings.actions",()=>s().createActions({update:{asyncResult:!0},get:{asyncResult:!0}})),p=(0,o.dS)("telemetry.settings.store",()=>s().createStore({listenables:[g],telemetrySetting:void 0,getInitialState(){return{telemetrySetting:this.telemetrySetting}},init(){this.get()},get(){const E=(0,c.ZP)("GET",this._url());E.then(a=>(this.telemetrySetting=a,this.propagateChanges(),a)),g.get.promise(E)},update(E){const a=(0,c.ZP)("PUT",this._url(),E);a.then(u=>(this.telemetrySetting=u,this.propagateChanges(),u),u=>{v.Z.error(`Update failed: ${u}`,"Could not update telemetry settings.")}),g.update.promise(a)},propagateChanges(){this.trigger(this.getState())},getState(){return{telemetrySetting:this.telemetrySetting}},_url(){return(0,r.DC)(d)}}))},yTnlRDNA:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("oCSEoDew"),s=e.n(t),o=e("eFxcQyPT"),r=e("U1Iufsob"),n=e("MdYBRjRJ"),c=e("jAGDuYSC");const d={testNaturalDate(g,p){const{url:E}=r.Z.ToolsApiController.naturalDateTest(encodeURIComponent(g),encodeURIComponent(p)),a=(0,o.ZP)("GET",(0,n.DC)(E));return a.catch(u=>{u.additional.status!==422&&c.Z.error(`Loading keyword preview failed with status: ${u}`,"Could not load keyword preview")}),a},testGrok(g,p,E){const{url:a}=r.Z.ToolsApiController.grokTest(),u=(0,o.ZP)("POST",(0,n.DC)(a),{pattern:g,string:E,named_captures_only:p});return u.catch(f=>{c.Z.error(`Details: ${f}`,"We were not able to run the grok extraction. Please check your parameters.")}),u},testJSON(g,p,E,a,u,f,y,T){const{url:P}=r.Z.ToolsApiController.jsonTest(),O={flatten:g,list_separator:p,key_separator:E,kv_separator:a,replace_key_whitespace:u,key_whitespace_replacement:f,key_prefix:y,string:T},b=(0,o.ZP)("POST",(0,n.DC)(P),O);return b.catch(L=>{c.Z.error(`Details: ${L}`,"We were not able to run the JSON extraction. Please check your parameters.")}),b},testRegexValidity(g){const p=s().encode(g),{url:E}=r.Z.ToolsApiController.regexValidate(p),a=(0,o.ZP)("GET",(0,n.DC)(E));return a.catch(u=>{c.Z.error(`Details: ${u}`,"Could not validate regular expression. Make sure that it is valid.")}),a},urlWhiteListCheck(g){const{url:p}=r.Z.ToolsApiController.urlWhitelistCheck(),E=(0,o.ZP)("POST",(0,n.DC)(p),{url:g});return E.catch(a=>{c.Z.error(`Details: ${a}`,"Could not verify if the url is in the whitelist.")}),E},urlWhiteListGenerateRegex(g,p){const{url:E}=r.Z.ToolsApiController.urlWhitelistGenerateRegex(),a=(0,o.ZP)("POST",(0,n.DC)(E),{url_template:g,placeholder:p});return a.catch(u=>{c.Z.error(`Details: ${u}`,"Could not generate regex.")}),a},testRegex(g,p){const{url:E}=r.Z.ToolsApiController.regexTest(),a=(0,o.ZP)("POST",(0,n.DC)(E),{regex:g,string:p});return a.catch(u=>{c.Z.error(`Details: ${u}`,"Could not try regular expression. Make sure that it is valid.")}),a},testRegexReplace(g,p,E,a){const{url:u}=r.Z.ToolsApiController.regexReplaceTest(),f={regex:g,replacement:p,replace_all:E,string:a},y=(0,o.ZP)("POST",(0,n.DC)(u),f);return y.catch(T=>{c.Z.error(`Details: ${T}`,"Could not try regular expression. Make sure that it is valid.")}),y},testSplitAndIndex(g,p,E){const{url:a}=r.Z.ToolsApiController.splitAndIndexTest(),u={split_by:g,index:p,string:E},f=(0,o.ZP)("POST",(0,n.DC)(a),u);return f.catch(y=>{c.Z.error(`Details: ${y}`,"We were not able to run the split and index extraction. Please check your parameters.")}),f},testSubstring(g,p,E){const{url:a}=r.Z.ToolsApiController.substringTest(),u={start:g,end:p,string:E},f=(0,o.ZP)("POST",(0,n.DC)(a),u);return f.catch(y=>{c.Z.error(`Details: ${y}`,"We were not able to run the substring extraction. Please check index boundaries.")}),f},testContainsString(g,p){const{url:E}=r.Z.ToolsApiController.containsStringTest(),a=(0,o.ZP)("POST",(0,n.DC)(E),{search_string:g,string:p});return a.catch(u=>{c.Z.error(`Details: ${u}`,"Could not check if field contains the string")}),a},testLookupTable(g,p){const{url:E}=r.Z.ToolsApiController.lookupTableTest(),a=(0,o.ZP)("POST",(0,n.DC)(E),{lookup_table_name:g,string:p});return a.catch(u=>{c.Z.error(`Details: ${u}`,"Could not check if lookup table translates the string")}),a}}},orDZ6Vj2:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("lCPkTODq");const o=t.useDispatch},YcvsU7cw:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("lCPkTODq");const o=r=>(0,t.useSelector)(r)},"J1ga+jW6":(M,C,e)=>{"use strict";e.d(C,{D:()=>p});var t=e("JnTtTRmZ"),s=e.n(t),o=e("MdYBRjRJ"),r=e("eFxcQyPT"),n=e("U1Iufsob"),c=e("IA3Ku5lS"),v=e("CXwqYNRt"),d=e("pc+thvZE"),g=e("YTcgvcFD");const p=(0,c.dS)("core.CurrentUser",()=>s().createStore({listenables:[d.SessionActions],currentUser:void 0,init(){this.listenTo(d.SessionStore,this.sessionUpdate,this.sessionUpdate),this.listenTo(g.A,this.reload,this.reload),v.p.saveUserPreferences.completed.listen(this.reload)},getInitialState(){return{currentUser:this.currentUser}},get(){return this.currentUser},sessionUpdate(E){if(E.username){const{username:a}=E;this.update(a)}else this.currentUser=void 0,this.trigger({currentUser:this.currentUser})},reload(){return this.currentUser!==void 0?this.update(this.currentUser.username):Promise.resolve()},update(E){return(0,r.ZP)("GET",(0,o.DC)(n.Z.UsersApiController.loadByUsername(encodeURIComponent(E)).url)).then(a=>(this.currentUser=a,this.trigger({currentUser:this.currentUser}),a))}}))},CXwqYNRt:(M,C,e)=>{"use strict";e.d(C,{g:()=>g,p:()=>v});var t=e("JnTtTRmZ"),s=e.n(t),o=e("eFxcQyPT"),r=e("MdYBRjRJ"),n=e("jAGDuYSC"),c=e("IA3Ku5lS");const v=(0,c.ei)("core.Preferences",()=>s().createActions({loadUserPreferences:{asyncResult:!0},saveUserPreferences:{asyncResult:!0}})),d=p=>{const E={};return Object.entries(p).forEach(([a,u])=>{u==="true"?E[a]=!0:u==="false"?E[a]=!1:E[a]=u}),E},g=(0,c.dS)("core.Preferences",()=>s().createStore({listenables:[v],URL:(0,r.DC)("/users/"),saveUserPreferences(p,E,a=()=>{},u=!0){const f=d(E),y=`${this.URL+encodeURIComponent(p)}/preferences`,T=(0,o.ZP)("PUT",y,{preferences:f}).then(()=>{u&&n.Z.success("User preferences successfully saved"),a(E)},P=>{n.Z.error(`Saving of preferences for "${p}" failed with status: ${P}`,"Could not save user preferences")});return v.saveUserPreferences.promise(T),T},loadUserPreferences(p,E=()=>{}){const a=this.URL+encodeURIComponent(p),u=y=>{n.Z.error(`Loading of user preferences for "${p}" failed with status: ${y}. Try reloading the page`,"Could not retrieve user preferences from server")},f=(0,o.ZP)("GET",a).then(y=>E(y==null?void 0:y.preferences),u);return v.loadUserPreferences.promise(f),f}}))},YTcgvcFD:(M,C,e)=>{"use strict";e.d(C,{A:()=>d});var t=e("JnTtTRmZ"),s=e.n(t),o=e("U1Iufsob"),r=e("jAGDuYSC"),n=e("MdYBRjRJ"),c=e("eFxcQyPT"),v=e("IA3Ku5lS");const d=(0,v.dS)("core.Startpage",()=>s().createStore({listenables:[],set(g,p,E){const a=(0,n.DC)(o.Z.UsersApiController.update(g).url),u={};return p&&E&&(u.type=p,u.id=E),(0,c.ZP)("PUT",a,{startpage:u}).then(f=>(this.trigger(),r.Z.success("Your start page was changed successfully"),f),f=>r.Z.error(`Changing your start page failed with error: ${f}`,"Could not change your start page"))}}))},AH3j8PqJ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.ColorSchemeContext",()=>o)},Ds5vWZ1u:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("J6y4/h8P");const o=(0,t.createGlobalStyle)(({theme:r})=>(0,t.css)` #editor { height: 256px; } html { font-size: ${r.fonts.size.root} !important; /* override Bootstrap default */ } body { background-color: ${r.colors.global.background}; color: ${r.colors.global.textDefault}; font-family: ${r.fonts.family.body}; font-size: ${r.fonts.size.body}; line-height: 1.25; height: 100vh; } #app-root { height: 100%; } ul { list-style-type: none; margin: 0; } ul.no-padding { padding: 0; } hr { border-top: 1px solid ${r.colors.global.background}; } h1, h2 { font-family: ${r.fonts.family.navigation}; } h1, h2, h3, h4, h5, h6 { font-weight: normal; padding: 0; margin: 0; color: ${r.colors.global.textDefault}; } h1 { font-size: ${r.fonts.size.h1}; } h2 { font-size: ${r.fonts.size.h2}; } h3 { font-size: ${r.fonts.size.h3}; } h4 { font-size: ${r.fonts.size.h4}; } h5 { font-size: ${r.fonts.size.h5}; } h6 { font-size: ${r.fonts.size.h6}; font-weight: bold; } a { color: ${r.colors.global.link}; } a:hover, a:focus { color: ${r.colors.global.linkHover}; } /* Remove boostrap outline */ a:active, select:active, input[type='file']:active, input[type='radio']:active, input[type='checkbox']:active, .btn:active { outline: none; outline-offset: 0; } input.form-control, select.form-control, textarea, textarea.form-control { color: ${r.colors.input.color}; background-color: ${r.colors.input.background}; border-color: ${r.colors.input.border}; border-radius: 0; font-family: ${r.fonts.family.body}; &::placeholder { color: ${r.colors.input.placeholder}; } &:focus { border-color: ${r.colors.input.borderFocus}; box-shadow: ${r.colors.input.boxShadow}; } &[disabled], &[readonly], fieldset[disabled] & { background-color: ${r.colors.input.backgroundDisabled}; color: ${r.colors.input.colorDisabled}; } } textarea { max-width: 100%; } legend small { color: ${r.colors.gray[60]}; margin-left: 5px; } small { font-size: ${r.fonts.size.small}; } .input-group-addon.input-group-separator { border-right-width: 0; border-left-width: 0; } .content { padding-top: 15px; padding-bottom: 15px; background-color: ${r.colors.global.contentBackground}; border: 1px solid ${r.colors.gray[80]}; margin-bottom: 10px; p.description { margin-top: 3px; color: ${r.colors.gray[50]}; } } .notifications-none { margin-top: 10px; } .no-bm { margin-bottom: 0; } .has-bm { margin-bottom: 10px; } .modal form { margin-bottom: 0; } .alert-bar { margin: 10px -20px 0; } .xtrc-converter-subfields { margin-left: 20px; } .u-light { border-bottom: 1px dotted ${r.colors.gray[70]}; margin-bottom: 5px; padding-bottom: 5px; } .input-docs { margin-left: 3px; } .input-docs:hover { text-decoration: none; } .timerange-selector select { margin-bottom: 0; } .leader-node { color: ${r.colors.variant.dark.warning}; } .loglevel-metrics-row { margin-top: 2px; margin-left: 10px; } .loglevel-metrics dl { margin-bottom: 5px; margin-top: 5px; } .loglevel-metrics dt { float: left; margin-right: 5px; } .subsystems { margin-top: 10px; margin-left: 10px; } .sources.overlay { background-color: ${r.colors.gray[60]}; height: 200px; line-height: 200px; opacity: 0.2; position: absolute; text-align: center; font-size: 50px; } .metrics-filter { margin-bottom: 15px !important; } dl.metric-timer dd { margin-left: 145px; } td.centered { text-align: center; } td.limited { max-width: 180px; overflow: hidden; text-overflow: ellipsis; } .configuration-field-optional { margin-left: 5px; font-size: ${r.fonts.size.small}; } .index-description { margin-bottom: 7px; } .index-description .index-info { margin-top: 5px; } .index-description .index-info dl { margin-top: 5px; } .index-details { margin-left: 5px; } .index-label { vertical-align: text-top; } .index-label .label { margin-right: 5px; } .index-more-actions { font-size: 90%; margin-left: 5px; } .shard-meters { margin-top: 10px; } .shard-meters dl { margin-bottom: 0; margin-top: 0; } .shard-meters dl dt { float: left; } .shard-meters dl dd { margin-left: 65px; } .shards { margin: 0; padding: 0; margin-top: 5px; } dl.system-journal { margin-top: 5px; margin-bottom: 0; } .system-journal dt { float: left; } .system-journal dd { margin-left: 120px; } dl.system-dl { margin: 0; } .system-dl dt { float: left; clear: left; } .system-dl dd { margin-left: 180px; } .no-widgets { margin-top: 15px; } table .dc-table-column { word-break: break-all; } .sources th { background-color: ${r.colors.gray[20]}; color: ${r.utils.readableColor(r.colors.gray[20])}; font-weight: normal; } .sources .dc-table-column._3 { padding-right: 0; text-align: right; } .parse-error { background-color: ${r.colors.variant.light.danger}; color: ${r.utils.contrastingColor(r.colors.variant.light.danger)}; padding-left: 2px; padding-right: 2px; } .add-alert-type { margin-bottom: 0; } .alerts { margin-top: 15px; } .alerts tbody { border: none; } .alerts th { background-color: ${r.colors.gray[10]}; color: ${r.colors.global.textAlt}; font-weight: normal; } .alerts th a { display: block; } .alerts th a:focus { color: ${r.colors.global.textAlt}; } .result-highlight-colored { background-color: ${r.colors.variant.warning}; } .annotation .content { margin-bottom: 10px; cursor: auto !important; } .scrollable-table { width: 100%; overflow: auto; } .well.configuration-well { margin-top: 5px; margin-bottom: 0; padding: 9px; font-family: ${r.fonts.family.monospace}; word-wrap: break-word; } .well.configuration-well > ul { padding: 0; margin: 0; } .well.react-configuration-well { white-space: pre-line; } .well.configuration-well .configuration-section { margin-bottom: 10px; } .well.configuration-well li:not(:last-child) { margin-bottom: 5px; } .well.configuration-well .key { display: inline; } .alert-callback .well.configuration-well .key { display: inline-block; min-width: 140px; vertical-align: top; } .well.configuration-well .value { display: inline; } .alert-callback .well.configuration-well .value { display: inline-block; } .form-inline label { margin-right: 10px; } .form-horizontal .help-block.help-standalone { line-height: 20px; margin-top: 7px; } .form-horizontal.pull-left label.control-label { width: auto; } .form-horizontal.pull-left div.controls { display: inline-block; float: right; margin-left: 20px; } .form-horizontal .input-description { margin-bottom: 0 !important; } form.extractor-form .control-group label { display: inline-block; } .configuration-bundles input[type='file'] { line-height: inherit !important; } table th.actions, table td.actions { width: 110px; } .btn-text { font-family: ${r.fonts.family.body}; font-size: ${r.fonts.size.small}; padding: 0; vertical-align: baseline; } .message-loader-form input { margin-right: 5px; } table.indexer-failures { margin-top: 10px; } div.row-sm { margin-bottom: 5px; } .table-sm { margin-bottom: 0; } .graylog-input-metrics { margin-top: 5px; } .filter .form-inline .form-group { display: inline-block; margin-bottom: 0; vertical-align: middle; } div.alert-callback hr { margin-top: 10px; margin-bottom: 10px; } div.alert-callbacks { margin-top: 10px; } .alarm-callbacks { padding: 0; } .alarm-callbacks li:not(:last-child) { margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px solid ${r.colors.gray[90]}; } .threaddump { font-size: ${r.fonts.size.small}; } h2.extractor-title { margin-bottom: 2px; } .stream-loader { margin-top: 5px; } .form-inline .typeahead-wrapper { display: inline-block; vertical-align: middle; width: auto; } .typeahead-wrapper .tt-menu { background-color: ${r.colors.global.contentBackground}; box-shadow: 0 3px 3px ${r.colors.global.navigationBoxShadow}; color: ${r.colors.global.textDefault}; .tt-suggestion:hover, .tt-suggestion.tt-cursor { color: ${r.colors.variant.darkest.info}; background-color: ${r.colors.variant.lighter.info}; background-image: none; } } .form-group-inline { display: inline-block; margin: 0; } .form-control-feedback { line-height: inherit; display: flex; align-items: center; justify-content: center; } ul.tag-list, ul.pill-list { display: inline-block; list-style: none; padding: 0; position: relative; } ul.pill-list { margin-left: 10px; vertical-align: middle; } ul.tag-list > li, ul.pill-list > li { display: inline-block; vertical-align: middle; } .tags-input ul.tag-list > li { padding-top: 10px; padding-bottom: 5px; } .tag, .pill { font-size: ${r.fonts.size.body}; margin-right: 5px; } .pill { color: ${r.colors.global.textDefault}; background-color: ${r.colors.gray[90]}; padding: 6px 12px; } .tag-remove, .pill-remove { color: ${r.colors.global.textDefault}; cursor: pointer; margin-left: 5px; } .tag-remove::before, .pill-remove::before { content: '×'; } .save-button-margin { margin-right: 5px; } .form-control.message-id-input { width: 300px; } /* additional styles for 'StyledAceEditor' */ .ace_editor.ace_autocomplete { width: 600px !important; margin-top: 6px; background-color: ${r.colors.input.background}; color: ${r.colors.input.color}; } .ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line { background-color: ${r.utils.opacify(r.colors.variant.info,.7)}; color: ${r.colors.input.colorDisabled}; } .ace_editor.ace_autocomplete .ace_text-layer .ace_completion-highlight { color: ${r.colors.variant.info}; } code { color: ${r.colors.variant.darker.danger}; background-color: ${r.colors.variant.lightest.danger}; } pre { color: ${r.colors.variant.darker.default}; background-color: ${r.colors.variant.lightest.default}; border-color: ${r.colors.variant.lighter.default}; } input[type='range'], input[type='range']:focus { box-shadow: none; height: auto; } `)},oBEvVL7M:(M,C,e)=>{"use strict";e.d(C,{Z:()=>Y});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("Uzk4A5PI"),c=e.n(n),v=e("sylc7v7C"),d=e.n(v),g=e("U7y/BNwM"),p=e("0hhBr0/b"),E=e("AH3j8PqJ"),a=e("CCNXj2ra"),u=e("8fnsnG21"),f=e("7GNmVOX8"),y=e("J1ga+jW6"),T=e("CXwqYNRt"),P=e("lFNn3iUc");const b=()=>{if(!window.matchMedia)return null;const ae=window.matchMedia("(prefers-color-scheme: light)"),ee=window.matchMedia("(prefers-color-scheme: dark)"),ue=ee.matches?P.COLOR_SCHEME_DARK:P.COLOR_SCHEME_LIGHT,[H,ye]=(0,t.useState)(ue);return(0,t.useEffect)(()=>{if(window.matchMedia){const we=ht=>{ht.matches&&ye(P.COLOR_SCHEME_LIGHT)},ut=ht=>{ht.matches&&ye(P.COLOR_SCHEME_DARK)};return ae.addListener(we),ee.addListener(ut),()=>{ae.removeListener(we),ee.removeListener(ut)}}return null},[]),H};var L=e("lN93Sbbu");const x=ae=>ae===a.su?a.TN:ae===a.Et?a.cC:ae,W=(ae,ee,ue)=>{var H,ye;if(ue)return ue;const we=(H=ae[a.eb])!=null?H:x(f.Z.get(a.eb));return(ye=we!=null?we:ee)!=null?ye:a.MU},Z=ae=>{const ee=b(),{userIsReadOnly:ue,username:H}=(0,u.o)(y.D,Re=>{var le,me,re;return{username:(le=Re.currentUser)==null?void 0:le.username,userIsReadOnly:(re=(me=Re.currentUser)==null?void 0:me.read_only)!=null?re:!0}}),ye=(0,t.useContext)(L.Z),we=W(ye,ee,ae),[ut,ht]=(0,t.useState)(we),Je=(0,t.useCallback)(Re=>{if(ht(Re),f.Z.set(a.eb,Re),!ue){const le={...ye,[a.eb]:Re};T.g.saveUserPreferences(H,le)}},[ue,ye,H]);return[ut,Je]},j=(ae,ee,ue,H)=>{var ye;const{data:we}=(ye=ue==null?void 0:ue())!=null?ye:{};return(0,t.useMemo)(()=>({...c()({colorScheme:ae,customColors:we==null?void 0:we[ae]}),changeMode:ee,mantine:H}),[ee,ae,we,H])},z=(ae,ee)=>{var ue;const{data:H}=(ue=ee==null?void 0:ee())!=null?ue:{};return(0,t.useMemo)(()=>d()({colorScheme:ae,customColors:H==null?void 0:H[ae]}),[ae,H])},ne=({children:ae,initialThemeModeOverride:ee})=>{var ue;const[H,ye]=Z(ee),we=(0,p.Z)("customization.theme.customizer"),ut=(ue=we==null?void 0:we[0])==null?void 0:ue.hooks.useCustomThemeColors,ht=z(H,ut),Je=j(H,ye,ut,ht);return t.createElement(E.Z.Provider,{value:H},t.createElement(g.MantineProvider,{theme:ht},t.createElement(r.ThemeProvider,{theme:Je},ae)))};ne.propTypes={children:o().node.isRequired,initialThemeModeOverride:o().oneOf(a.R)},ne.defaultProps={initialThemeModeOverride:void 0};const Y=ne},CCNXj2ra:(M,C,e)=>{"use strict";e.d(C,{Et:()=>v,L$:()=>E,MU:()=>d,R:()=>p,TN:()=>t.COLOR_SCHEME_LIGHT,cC:()=>t.COLOR_SCHEME_DARK,dr:()=>n,eb:()=>r,su:()=>c,xR:()=>a});var t=e("lFNn3iUc"),s=e.n(t);const o=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,r="themeMode",n=16,c="teint",v="noir",d=o?t.COLOR_SCHEME_DARK:t.COLOR_SCHEME_LIGHT,g=null,p=[t.COLOR_SCHEME_LIGHT,t.COLOR_SCHEME_DARK],E=0,a="50px"},RCNj0OY4:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("VPaD/Np4"),s=e.n(t);const o=()=>window.appConfig||{},c={contentStream(){var v;return(v=o())==null?void 0:v.contentStream},features:(()=>t.Map(o().featureFlags).filter(v=>v.trim().toLowerCase()==="on").keySeq().toList().filter(v=>typeof v=="string"))(),gl2ServerUrl(){return o().gl2ServerUrl},gl2AppPathPrefix(){return o().gl2AppPathPrefix},gl2DevMode(){return typeof DEVELOPMENT<"u"&&DEVELOPMENT},isFeatureEnabled(v){return this.features&&this.features.map(d=>d.trim().toLowerCase()).includes(v.toLowerCase())},rootTimeZone(){return o().rootTimeZone},isCloud(){return typeof IS_CLOUD<"u"?IS_CLOUD:o().isCloud},customThemeColors(){var v,d,g;return(g=(d=(v=o())==null?void 0:v.pluginUISettings)==null?void 0:d["org.graylog.plugins.customization.theme"])!=null?g:{}},telemetry(){var v;return(v=o())==null?void 0:v.telemetry},publicNotifications(){var v,d,g;return(g=(d=(v=o())==null?void 0:v.pluginUISettings)==null?void 0:d["org.graylog.plugins.customization.notifications"])!=null?g:{}},pluginUISettings(v){var d,g,p;return(p=(g=(d=o())==null?void 0:d.pluginUISettings)==null?void 0:g[v])!=null?p:{}}}},IZYxBTgT:(M,C,e)=>{"use strict";e.d(C,{Od:()=>p,Qc:()=>a,U2:()=>f,eZ:()=>o,qb:()=>u,rG:()=>v,x_:()=>g,zG:()=>E});var t=e("ASBo/Til"),s=e.n(t);const o={default:"YYYY-MM-DD HH:mm:ss",complete:"YYYY-MM-DD HH:mm:ss.SSS",withTz:"YYYY-MM-DD HH:mm:ss Z",readable:"dddd D MMMM YYYY, HH:mm ZZ",shortReadable:"MMM D, YYYY",internal:"YYYY-MM-DDTHH:mm:ss.SSSZ",internalIndexer:"YYYY-MM-DDTHH:mm:ss.SSS[Z]",date:"YYYY-MM-DD",hourAndMinute:"HH:mm"},r="UTC",n=(y,T,P)=>{if(!y.isValid()){let O=`Date time ${T} is not valid.`;P&&(O=`${O} ${P}`),console.error(O)}return y},c=y=>y==null?void 0:y.map(T=>{const P=o[T];if(!P)throw new Error(`Provided date time format "${T}" is not supported.`);return P}),v=(y,T,P=r)=>{const O=c(T),b=s().utc(y,O,!0).tz(P),L=T!=null&&T.length?`Expected formats: ${O.join(", ")}.`:void 0;return n(b,y,L)},d=(y,T=r)=>v(y,["internal"],T),g=()=>s().tz.guess(),p=(y,T="default",P=r)=>v(y,void 0,P).format(o[T]),E=(y,T="default")=>p(y,T,g()),a=y=>{const T=v(y);return n(T,y).fromNow()},u=y=>s()(y,Object.values(o),!0).isValid(),f=(y,T)=>{if(!T)throw new Error("It is required to define the time zone of the date time provided for internalUTCTime.");return s().tz(y,T)}},"E+CaPsQD":(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const s={PAGES:{ALERTS:"alerts",AUDIT_LOG:"auditlog",AUTHENTICATORS:"permission-management#authentication",CHANGELOG:"changelog",CLUSTER_STATUS_EXPLAINED:"elasticsearch#cluster-status-explained",COLLECTOR:"sidecar",COLLECTOR_SIDECAR:"sidecar",COLLECTOR_STATUS:"sidecar#sidecar-status",CONFIGURING_ES:"elasticsearch",DASHBOARDS:"dashboards",DECORATORS:"decorators",ENTERPRISE_SETUP:"setup",ES_CLUSTER_STATUS_RED:"elasticsearch#cluster-status-explained",ES_CLUSTER_UNAVAILABLE:"elasticsearch#configuration",ES_OPEN_FILE_LIMITS:"elasticsearch#configuration",EXTRACTORS:"extractors",GRAYLOG_DATA_NODE:"graylog-data-node",INDEXER_FAILURES:"indexer-failures",INDEX_MODEL:"index-model",LICENSE:"license",LOAD_BALANCERS:"load-balancers",LOOKUPTABLES:"lookuptables",OPERATIONS_CHANGELOG:"changelog-graylog",OPEN_SEARCH_SETUP:"open-search-setup",PAGE_FLEXIBLE_DATE_CONVERTER:"extractors#normalization",PAGE_STANDARD_DATE_CONVERTER:"extractors#normalization",PERMISSIONS:"permission-management",PIPELINE_FUNCTIONS:"functions",PIPELINE_RULES:"rules",PIPELINES:"pipelines",REPORTING:"reporting",ROLLING_ES_UPGRADE:"rolling-es-upgrade",SEARCH_QUERY_ERRORS:{UNKNOWN_FIELD:"query-language#unknown-field",QUERY_PARSING_ERROR:"query-language#parse-exception",INVALID_OPERATOR:"query-language#invalid-operator",UNDECLARED_PARAMETER:"query-language#undeclared-parameter"},SEARCH_QUERY_LANGUAGE:"query-language",STREAMS:"streams",STREAM_PROCESSING_RUNTIME_LIMITS:"streams#stream-processing-runtime-limits",TIME_FRAME_SELECTOR:"time-frame-selector",UPGRADE_GUIDE:"upgrading-graylog",USERS_ROLES:"permission-management",WELCOME:""},DOCS_URL:"https://docs.graylog.org/docs",toString(o){const r=this.DOCS_URL;return o===""?r:`${r}/${o}`},versionedDocsHomePage(){return this.toString("")}}},xS8q27Jr:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("d4kzUuQm");const s=Object.freeze({COPY_INPUT:"copy_input",GROK:"grok",JSON:"json",REGEX:"regex",REGEX_REPLACE:"regex_replace",SPLIT_AND_INDEX:"split_and_index",SUBSTRING:"substring",LOOKUP_TABLE:"lookup_table"}),r={ConverterTypes:Object.freeze({NUMERIC:"numeric",DATE:"date",HASH:"hash",SPLIT_AND_COUNT:"split_and_count",IP_ANONYMIZER:"ip_anonymizer",SYSLOG_PRI_LEVEL:"syslog_pri_level",SYSLOG_PRI_FACILITY:"syslog_pri_facility",TOKENIZER:"tokenizer",CSV:"csv",LOWERCASE:"lowercase",UPPERCASE:"uppercase",FLEXDATE:"flexdate",LOOKUP_TABLE:"lookup_table"}),ExtractorTypes:s,EXTRACTOR_TYPES:Object.keys(s).map(n=>n.toLocaleLowerCase()),getNewExtractorRoutes(n,c,v,d,g){const p={};return this.EXTRACTOR_TYPES.forEach(E=>{p[E]=t.ZP.new_extractor(n,c,E,v,d,g)}),p},getReadableExtractorTypeName(n){switch(n){case s.COPY_INPUT:return"Copy input";case s.GROK:return"Grok pattern";case s.JSON:return"JSON";case s.REGEX:return"Regular expression";case s.REGEX_REPLACE:return"Replace with regular expression";case s.SPLIT_AND_INDEX:return"Split & Index";case s.SUBSTRING:return"Substring";case s.LOOKUP_TABLE:return"Lookup Table";default:return n}},getReadableConverterTypeName(n){switch(n){case this.ConverterTypes.NUMERIC:return"Numeric";case this.ConverterTypes.DATE:return"Date";case this.ConverterTypes.FLEXDATE:return"Flexible Date";case this.ConverterTypes.HASH:return"Hash";case this.ConverterTypes.LOWERCASE:return"Lowercase";case this.ConverterTypes.UPPERCASE:return"Uppercase";case this.ConverterTypes.TOKENIZER:return"Key = Value Pairs To Fields";case this.ConverterTypes.CSV:return"CSV To Fields";case this.ConverterTypes.SPLIT_AND_COUNT:return"Split & Count";case this.ConverterTypes.IP_ANONYMIZER:return"Anonymize IPv4 Addresses";case this.ConverterTypes.SYSLOG_PRI_LEVEL:return"Syslog Level From PRI";case this.ConverterTypes.SYSLOG_PRI_FACILITY:return"Syslog Facility From PRI";case this.ConverterTypes.LOOKUP_TABLE:return"Lookup Table";default:return n}},getEffectiveConfiguration(n,c){const v={};for(const d in n)n.hasOwnProperty(d)&&(v[d]=n[d]);for(const d in c)c.hasOwnProperty(d)&&(v[d]=c[d]);return v}}},S6FuRS7B:(M,C,e)=>{"use strict";e.d(C,{ZP:()=>g,Sy:()=>c,n6:()=>r,_X:()=>n,OP:()=>d});var t=e("zkmy/ViL");const o=p=>{const E={bubbles:!0,cancelable:!0};if(typeof Event=="function")return new Event(p,E);const a=document.createEvent("Event");return a.initEvent(p,E.bubbles,E.cancelable),a},r=p=>{switch(p.type){case"radio":return p.value==="true"||p.value==="false"?p.value==="true":p.value;case"checkbox":return p.checked;case"number":return p.value===""||!t.Z.isNumber(p.value)?void 0:Number(p.value);default:return p.value}},n=p=>{const E=p._valueTracker,a=o("change");a.simulated=!0,E&&E.setValue(""),p.dispatchEvent(a)},c=(p={})=>Object.keys(p).length>0,v=(p,E,a)=>{switch(E){case"required":if(!p||(p==null?void 0:p.size)===0)return"Field is required.";break;case"min":if(pNumber(a))return`Must be smaller than ${a}.`;break;default:return}},d=(p={})=>E=>{let a;return Object.entries(p).some(([u,f])=>{const y=v(E,u,f);return y?(a=y,!0):!1}),a},g={getValueFromInput:r,triggerInput:n,formHasErrors:c,validateField:d}},HvPssUok:(M,C,e)=>{"use strict";e.d(C,{El:()=>c,LU:()=>v,g0:()=>d,jO:()=>n});var t=e("9oVghaOd"),s=e.n(t),o=e("gtXNkEXl"),r=e.n(o);const n=(g,p)=>p(s().duration(g).asMilliseconds(),g),c=(g,p,E="error")=>n(g,p)?null:E,v=(g,p,E="error")=>n(g,p)?s().duration(g).format():E,d=(g,p,E="error")=>n(g,p)?s().duration(g).humanize():E},"zkmy/ViL":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("9pdI12pI"),s=e.n(t);const r={JAVA_INTEGER_MIN_VALUE:2**31*-1,JAVA_INTEGER_MAX_VALUE:2**31-1,normalizeNumber(n){switch(n){case"NaN":return NaN;case"Infinity":return Number.MAX_VALUE;case"-Infinity":return Number.MIN_VALUE;default:return n}},normalizeGraphNumber(n){switch(n){case"NaN":case"Infinity":case"-Infinity":return 0;default:return n}},formatNumber(n){try{return s()(this.normalizeNumber(n)).format("0,0.[00]")}catch{return n}},formatPercentage(n){try{return s()(this.normalizeNumber(n)).format("0.00%")}catch{return n}},formatBytes(n){s().zeroFormat("0B");let c;try{c=s()(this.normalizeNumber(n)).format("0.0ib")}catch{c=n}return s().zeroFormat(null),c},isNumber(n){return n!==""&&!Number.isNaN(Number(n))}}},QdZ7Yq43:(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const s={clone(o){return JSON.parse(JSON.stringify(o))},isEmpty(o){const r=Object.keys(o);return r&&r.length===0},trimObjectFields(o,r){const n={...o};return r.length>0&&r.forEach(c=>{c in o&&typeof o[c]=="string"&&(n[c]=o[c].trim())}),n}}},gyRmhZSW:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("oCSEoDew"),s=e.n(t);const o=(r,n,c,v,d={})=>{let g=new(s())(r).addSearch("page",n).addSearch("per_page",c);return d&&Object.keys(d).forEach(p=>{const E=d[p],a=u=>typeof u.toString=="function"?u.toString():u;if(E!==void 0){if(Array.isArray(E)){E.forEach(u=>{g=g.addSearch(p,a(u))});return}g=g.addSearch(p,a(E))}}),v&&g.addSearch("query",encodeURIComponent(v)),g.toString()}},"0TVxnHwi":(M,C,e)=>{"use strict";e.d(C,{Tv:()=>r,ZP:()=>c,rq:()=>o});const t=v=>v.indexOf("*")>-1,s=(v,d)=>{if(v.indexOf(d)>-1||v.indexOf("*")>-1)return!0;const g=d.split(":");if(g.length>=2){const p=g[0],E=`${g[0]}:${g[1]}`;return v.indexOf(p)>-1||v.indexOf(`${p}:*`)>-1||v.indexOf(E)>-1||v.indexOf(`${E}:*`)>-1}return v.indexOf(`${d}:*`)>-1},o=(v,d)=>!d||d.length===0?!0:v?t(v)?!0:d.every?d.every(g=>s(v,g)):s(v,d):!1,r=(v,d)=>!d||d.length===0?!0:v?t(v)?!0:d.some(g=>s(v,g)):!1,c={isPermitted:o,isAnyPermitted:r}},TJOheZRu:(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const t={tempDocument:document.createElement("textarea"),capitalizeFirstLetter(o){return o.charAt(0).toUpperCase()+o.slice(1)},escapeHTML(o){return this.tempDocument.textContent=o,this.tempDocument.innerHTML},unescapeHTML(o){return this.tempDocument.innerHTML=o,this.tempDocument.textContent},pluralize(o,r,n){return o===1||o==="1"?r:n},stringify(o){return(typeof o=="object"?JSON.stringify(o):String(o))||""},replaceSpaces(o,r="-"){return o.replace(/\s/g,r)},toTitleCase(o,r=" "){return o.toLowerCase().split(r).map(n=>`${n.charAt(0).toUpperCase()}${n.slice(1)}`).join(" ")},truncateWithEllipses(o="",r=10,n="..."){return o.length>r?`${o.substring(0,r)}${n}`:o},getRecursiveChildText(o){if(typeof o=="string")return o;const{children:r}=(o==null?void 0:o.props)||{};if(Array.isArray(o)){const n=[];return o.forEach(c=>{typeof c=="object"?n.push(t.getRecursiveChildText(c)):typeof c=="string"&&n.push(c)}),n.join(" ")}return typeof r=="object"?t.getRecursiveChildText(r):typeof r=="string"?r:""}},s=t},"5NVsf39r":(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const s={nowInSeconds(){return Math.floor(Date.now()/1e3)}}},MdYBRjRJ:(M,C,e)=>{"use strict";e.d(C,{DC:()=>f,K2:()=>P,ZP:()=>g,av:()=>u,em:()=>T,er:()=>O,s6:()=>p});var t=e("pjsNBHWI"),s=e.n(t),o=e("oCSEoDew"),r=e.n(o),n=e("RCNj0OY4");const c=["http:","https:"],v=b=>{const L=new(r())(b);if(!L.hostname()||!L.scheme()){const x=new(r())(window.location);return L.absoluteTo(x).toString()}return b},d={qualifyUrl(b){var L;if(new(r())(b).is("absolute"))return b;const W=v((L=n.Z.gl2ServerUrl())!=null?L:"");return new(r())(W+b).normalizePathname().toString()},appPrefixed(b){return d.concatURLPath(n.Z.gl2AppPathPrefix(),b)},getParsedSearch(b){let L={},x=b.search;return x&&x.indexOf("?")===0&&x.length>1&&(x=x.substr(1,x.length-1),L=s().parse(x)),L},getParsedHash(b){let L={},{hash:x}=b;return x&&x.indexOf("#")===0&&x.length>1&&(x=x.substr(1,x.length-1),L=s().parse(x)),L},replaceHashParam(b,L){const x=this.getParsedHash(window.location);x[b]=L,window.location.replace(`#${s().stringify(x)}`)},concatURLPath(...b){const L=Array(b.length);for(let W=0;W{"use strict";e.d(C,{Z:()=>x});var t=e("ieFRrI0A"),s=e.n(t),o=e("dFpwyWHg"),r=e.n(o),n=e("C2ikvoS0"),c=e.n(n),v=e("1IntWRSu"),d=e.n(v),g=e("8nGWeFnd"),p=e.n(g),E=e("TeAcaicX"),a=e.n(E),u=e("eE3+5goe"),f=e.n(u),y=e("OXMg8s84"),T={};T.styleTagTransform=f(),T.setAttributes=p(),T.insert=d().bind(null,"head"),T.domAPI=c(),T.insertStyleElement=a();var P=r()(y.Z,T);const O=y.Z&&y.Z.locals?y.Z.locals:void 0,b={debug:!1,positionClass:"toast-bottom-full-width",onclick:null,showDuration:300,hideDuration:1e3,timeOut:7e3,extendedTimeOut:1e3,escapeHtml:!0,closeButton:!0,closeHtml:"",progressBar:!0,preventDuplicates:!0},x={error(W,N){s().error(W,N||"Error",{...b,timeOut:1e4})},warning(W,N){s().warning(W,N||"Attention",b)},success(W,N){s().success(W,N||"Information",b)}}},kbGtT3aS:(M,C,e)=>{"use strict";e.d(C,{ZP:()=>v,VV:()=>n});const t={i8:"5.2.11"},s=/(?\d+)\.(?\d+)\.(?\d+)(-(?[\w.\d]+))?(\+(?\w+))?/,o=t.i8,r=(d=o)=>{const g=s.exec(d);if(!g||!g.groups){console.error("Failed to parse version",d);return}const p=g.groups;return{major:p==null?void 0:p.major,minor:p==null?void 0:p.minor,patch:p==null?void 0:p.patch,preRelease:p==null?void 0:p.preRelease,buildMetadata:p==null?void 0:p.buildMetadata}},n=()=>o,v={parseVersion:r,getMajorAndMinorVersion:()=>{const d=r();if(!d)return n();const{major:g,minor:p}=d;return`${g}.${p}`},getFullVersion:n}},"8wYeYPUw":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("RCNj0OY4");const r=({children:n,...c})=>s.Z.isCloud()?t.createElement(t.Fragment,null):t.Children.map(n,v=>t.isValidElement(v)?t.cloneElement(v,c):v)},"VVS+7KXv":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});const t=r=>{const n=c=>{c.clipboardData.setData("text/plain",r),c.preventDefault()};return document.addEventListener("copy",n),document.execCommand("copy"),document.removeEventListener("copy",n),Promise.resolve()},o=r=>navigator.clipboard&&window.isSecureContext?navigator.clipboard.writeText(r):t(r)},jtomkfYT:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("RCNj0OY4");const s="Graylog Deprecation Notice:",r=n=>t.Z.gl2DevMode()&&console.warn(s,n)},nxMFMmDQ:(M,C,e)=>{"use strict";e.d(C,{$4:()=>ut,CG:()=>u,J4:()=>ce,J6:()=>ae,LB:()=>a,N1:()=>v,N3:()=>ue,OV:()=>Je,QB:()=>L,Rn:()=>re,Sh:()=>H,TI:()=>r,Up:()=>ht,Vm:()=>P,XR:()=>me,YN:()=>ne,Yc:()=>Z,ZA:()=>c,ZB:()=>Re,ZW:()=>E,as:()=>ee,bj:()=>j,f0:()=>we,fH:()=>z,gj:()=>f,ht:()=>p,iM:()=>W,kX:()=>N,lY:()=>b,m4:()=>g,nn:()=>x,pR:()=>O,qN:()=>Q,qq:()=>le,r$:()=>y,rg:()=>n,tY:()=>Y,v8:()=>J,w_:()=>T});var t=e("ww+BtWnX"),s=e.n(t),o=e("NhiTWmq4");const r="full_message",n="timestamp",c="message",v="source",g=["_id","_ttl","_source","_all","_index","_type","_score","gl2_accounted_message_size","gl2_message_id","gl2_source_node","gl2_source_input","gl2_source_collector","gl2_source_collector_input","gl2_remote_ip","gl2_remote_port","gl2_remote_hostname","streams","gl2_source_radio","gl2_source_radio_input"],p=[r,c,n,v],E="(Empty Value)",a=15,u={type:"auto",scaling:1},f=[n,v],y=0,T={type:"relative",range:y},P={DEFAULT_LIMIT:150},O="relative",b=300,L=b-60,x={type:O,from:b},W={},N=o.WS.create("#ffec3d"),Z=s().scale(["lightyellow","lightgreen","lightblue","red"]).mode("lch").colors(40),j="linear",z=["linear","step-after","spline"],ne=[25,50,75,90,95,99].map(ie=>({label:ie,value:ie})),Y=[{label:"Document Count",value:"COUNT"},{label:"Field Sum",value:"SUM"}],ae={seconds:"Seconds",minutes:"Minutes",hours:"Hours",days:"Days",weeks:"Weeks",months:"Months"},ee=[{type:"seconds",label:"Seconds"},{type:"minutes",label:"Minutes"},{type:"hours",label:"Hours"},{type:"days",label:"Days"}],ue="/views",H=`${ue}/:viewId`,ye="/search",we=`${ye}/new`,ut=`${ye}/:viewId`,ht="/dashboards",Je=`${ht}/new`,Re=`${ht}/tv/:viewId`,le=`${ht}/:viewId`,me="/extendedsearch",re=[{type:"relative",name:"Relative"},{type:"absolute",name:"Absolute"},{type:"keyword",name:"Keyword"}],ce=28,Q="\u2E31",J="-"},baf4E2h0:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("JnTtTRmZ"),s=e.n(t),o=e("IA3Ku5lS");const n=(0,o.ei)("views.QueryValidation",()=>s().createActions({displayValidationErrors:{asyncResult:!1}}))},Xt0X5Kl4:(M,C,e)=>{"use strict";e.d(C,{Z:()=>W});var t=e("ii0bleBb"),s=e.n(t),o=e("GaFHk8Qk"),r=e.n(o),n=e("/yh+QgO6"),c=e.n(n),v=e("jlRcBdjT"),d=e("8Crd7QGv"),g=e("UmnljV2q");const p=s().oneOf(["relative","absolute","keyword"]),E=s().instanceOf(v.ZP),a=s().instanceOf(d.Z),u=r().listOf(a),f=s().exact({activeQuery:s().string.isRequired,view:s().instanceOf(g.Z).isRequired,dirty:s().bool.isRequired,isNew:s().bool.isRequired}),y=s().exact({index:s().string.isRequired,message:s().exact({_id:s().string.isRequired}).isRequired}),T=s().exact({id:s().string.isRequired,index:s().string.isRequired,fields:s().object.isRequired,formatted_fields:s().object,highlight_ranges:s().object,decoration_stats:s().exact({added_fields:s().object,changed_fields:s().object,removed_fields:s().object})}),P=s().oneOfType([s().element,s().string]),O=s().oneOfType([P,s().arrayOf(P)]),b=N=>{let Z=N;const j=[];for(;Z;)try{const z=Object.getPrototypeOf(Z);j.push(z),Z=z}catch{Z=void 0}return j},L=(N,Z=!1)=>{const j=c()(N,"name");return(z,ne,Y)=>{const ae=z[ne];if(!ae)return Z?new Error(`Invalid prop ${ne} supplied to ${Y}: expected to be instance of ${j} but found ${ae} instead`):void 0;const ee=c()(b(ae)[0],["constructor","name"]);if(!b(ae).map(H=>c()(H,["constructor","name"])).filter(H=>H!==void 0).includes(j))return new Error(`Invalid prop ${ne} supplied to ${Y}: ${ee} expected to be instance of ${j}`)}},x=N=>Object.assign(L(N,!1),{isRequired:L(N,!0)}),W={...s(),BackendMessage:y,Message:T,CurrentView:f,FieldListType:u,FieldType:E,OneOrMoreChildren:O,TimeRangeType:p,instanceOf:x,ValidElements:P}},Tqc935YZ:(M,C,e)=>{"use strict";e.d(C,{Q:()=>o,Z:()=>n});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o={isLoading:!1,externalValueActions:[],isError:!1},r=t.createContext(o),n=(0,s.ri)("contexts.ExternalValueActionsContext",()=>r)},YwMFjcSm:(M,C,e)=>{"use strict";e.d(C,{Z:()=>y});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("/GOzvPf6"),r=e("DUKaTDO2"),n=e("eFxcQyPT"),c=e("MdYBRjRJ"),v=e("jAGDuYSC");const d="/favorites",g=async T=>{const P=`${d}/${T}`;return(0,n.ZP)("PUT",(0,c.DC)(P))},p=T=>{const P=`${d}/${T}`;return(0,n.ZP)("DELETE",(0,c.DC)(P))},a=()=>{const T=(0,r.useMutation)(g,{onError:O=>{v.Z.error(`Adding item to favorites failed with status: ${O}`,"Could not add item to favorites")}}),P=(0,r.useMutation)(p,{onError:O=>{v.Z.error(`Deleting item from favorites failed with status: ${O}`,"Could not delete item from favorites")}});return{putItem:T.mutateAsync,deleteItem:P.mutateAsync}},u=(0,s.default)(o.JO)(({theme:T,$isFavorite:P})=>(0,s.css)` color: ${P?T.colors.variant.info:void 0}; cursor: pointer; `),f=({isFavorite:T,grn:P,onChange:O,className:b})=>{const{putItem:L,deleteItem:x}=a(),W=(0,t.useCallback)(()=>{T?x(P).then(()=>O(!1)):L(P).then(()=>O(!0))},[T,x,P,O,L]),N=T?"Remove from favorites":"Add to favorites";return t.createElement(u,{className:b,onClick:W,title:N,$isFavorite:T,name:"star",type:T?"solid":"regular"})};f.defaultProps={className:void 0};const y=f},"SnOQy/BL":(M,C,e)=>{"use strict";e.d(C,{Z:()=>u});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("Xt0X5Kl4"),n=e("J6y4/h8P"),c=e("gSdhV+tG"),v=e("gIAgj/hR");const d=n.default.span.attrs({className:"field-element"})(({$active:f,$disabled:y,theme:T})=>(0,n.css)` color: ${f?T.colors.variant.info:"currentColor"}; opacity: ${y?"0.3":"1"}; `),p=({children:f,disabled:y,element:T,menuContainer:P,name:O,type:b,queryId:L})=>{const x=(0,t.useContext)(c.f),W=({active:Z})=>t.createElement(d,{$active:Z,$disabled:y},T),N={queryId:L,field:O,type:b,contexts:x};return t.createElement(v.Z,{element:W,handlerArgs:N,menuContainer:P,type:"field"},f)};var E=e("GFJVQ2dX");const a=({children:f,disabled:y=!1,menuContainer:T,name:P,queryId:O,type:b})=>t.createElement(E.Z.Consumer,null,L=>L?t.createElement(p,{element:f||P,disabled:!L||y,menuContainer:T,name:P,type:b,queryId:O},P," = ",b.type):t.createElement("span",null,f));a.propTypes={children:o().node,disabled:o().bool,name:o().string.isRequired,menuContainer:o().object,queryId:o().string,type:r.Z.FieldType.isRequired},a.defaultProps={children:null,disabled:!1,menuContainer:document.body,queryId:void 0};const u=a},tITy3x4L:(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("9oVghaOd"),s=e.n(t),o=e("PwTFiGSp"),r=e("IZYxBTgT");const n="Format must be: YYYY-MM-DD [HH:mm:ss[.SSS]].",c="Range is outside limit duration.",v="Date is outside limit duration.",d='The "Until" date must come after the "From" date.',g=(y,T,P)=>{if(T===0)return!1;switch(y==null?void 0:y.type){case"absolute":case"keyword":{const O=y.from,b=P((0,r.rG)(new Date).subtract(Number(T),"seconds"),"complete");return s()(O).isBefore(b)}default:return!1}},p=(y,T,P)=>{let O={};return(0,r.qb)(y.from)||(O={...O,from:n}),(0,r.qb)(y.to)||(O={...O,to:n}),y.from>=y.to&&(O={...O,to:d}),g(y,T,P)&&(O={...O,from:v}),O},E=(y,T)=>{let P={};return T>0&&((y.from>T||!y.from)&&(P={...P,from:c}),y.to>T&&(P={...P,to:c})),y.from===null&&(P={...P,from:"Cannot be empty."}),y.from&&y.to===null&&(P={...P,to:"Cannot be empty."}),y.from&&y.from<=y.to&&(P={...P,to:d}),P},a=(y,T,P)=>{let O={};return g(y,T,P)&&(O={keyword:c}),O},f=(y,T,P)=>(0,o.je)(y)?a(y,T,P):(0,o.SP)(y)?E(y,T):(0,o.yH)(y)?p(y,T,P):{}},rKq6XZKM:(M,C,e)=>{"use strict";e.d(C,{h:()=>o});var t=e("nxMFMmDQ"),s=e("PwTFiGSp");const o=(r,n)=>{const{type:c}=r;switch(r.type){case"absolute":return{type:r.type,from:n(r.from,"complete"),to:n(r.to,"complete")};case"relative":if((0,s.a_)(r))return r.range===t.r$?{type:r.type,range:r.range}:{type:r.type,from:r.range};if((0,s.SP)(r))return"to"in r?{type:r.type,from:r.from,to:r.to}:{type:r.type,from:r.from};throw new Error("Invalid relative time range");case"keyword":return r;default:throw new Error(`Invalid time range type: ${c}`)}}},"/zlmJemQ":(M,C,e)=>{"use strict";e.d(C,{Z:()=>ce});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("X6P4SH4J"),n=e.n(r),c=e("sWSSTOXR"),v=e.n(c),d=e("axYmp8ly"),g=e.n(d),p=e("Ex+j8X3w"),E=e("jlRcBdjT"),a=e("DUKaTDO2"),u=e("2ufZf/Iw"),f=e("0hhBr0/b");const y=(Q,J)=>{var ie;const{fetchForwarderInput:ge}=(ie=(0,f.Z)("forwarder")[0])!=null?ie:{},{data:fe,isError:Ce,isLoading:Oe}=(0,a.useQuery)(["forwarder","input",Q],()=>ge(Q),{enabled:ge&&J});return Oe||Ce?void 0:fe},P=({value:Q})=>{var J,ie,ge;const fe=(0,u.Z)(),Ce=y(Q,fe&&!fe[Q]),Oe=(ge=(ie=(J=fe[Q])==null?void 0:J.title)!=null?ie:Ce==null?void 0:Ce.title)!=null?ge:Q;return t.createElement("span",{title:Q},Oe)};var O=e("64CQykkG");const b=(Q,J)=>{var ie;const{fetchForwarderNode:ge}=(ie=(0,f.Z)("forwarder")[0])!=null?ie:{},{data:fe,isError:Ce,isLoading:Oe}=(0,a.useQuery)(["forwarder","node",Q],()=>ge(Q),{enabled:ge&&J});return Oe||Ce?void 0:fe},x=({value:Q})=>{var J;const ie=(0,O.Z)(),ge=ie==null?void 0:ie[Q],fe=b(Q,ie&&!ge),Ce=(J=ge?`${ge.short_node_id} / ${ge.hostname}`:fe==null?void 0:fe.title)!=null?J:Q;return t.createElement("span",{title:Q},Ce)};var W=e("J6y4/h8P"),N=e("gvNRgdyu");const Z=W.default.span` span:not(:last-child)::after { content: ', '; } `,z=({value:Q})=>{const J=(0,t.useContext)(N.Z),ie=(0,t.useMemo)(()=>{var fe;return Object.fromEntries((fe=J.map(Ce=>[Ce.id,Ce]))!=null?fe:[])},[J]),ge=(0,t.useCallback)(fe=>{var Ce,Oe;return t.createElement("span",{title:fe},(Oe=(Ce=ie[fe])==null?void 0:Ce.title)!=null?Oe:fe)},[ie]);return Array.isArray(Q)?t.createElement(Z,null,Q.map(ge)):ge(Q)};var ne=e("9pdI12pI"),Y=e.n(ne);const ae=W.default.span` float: right; `,ue=({value:Q})=>{const J=(0,t.useMemo)(()=>Y()(Q).format("0.00%"),[Q]);return t.createElement(ae,{title:String(Q)},J)},H=W.default.i` color: darkgray; `,we=()=>t.createElement(H,null,"");var ut=e("Xt0X5Kl4");const ht=(Q,J,ie,ge,fe)=>{const Ce=n()(J)?J:JSON.stringify(J),Oe=ge;return v()(Ce)===""?t.createElement(we,null):t.createElement(Oe,{field:Q,value:ie?g()(Ce):Ce,type:fe})},Re=({field:Q,value:J,truncate:ie,render:ge,type:fe})=>{if(J&&J.href&&J.type){const Ce=ht(Q,J.href,ie,ge,fe);return t.createElement("a",{href:J.href,target:"_blank",rel:"noreferrer"},Ce)}return ht(Q,J,ie,ge,fe)},le=(Q,J,ie,ge,fe)=>{const Ce=n()(J)?J:JSON.stringify(J),Oe=ge;return v()(Ce)===""?t.createElement(we,null):t.createElement(Oe,{field:Q,value:ie?g()(Ce):Ce,type:fe})},me=({value:Q})=>Q,re=({field:Q,value:J,render:ie=me,type:ge=E.ZP.Unknown,truncate:fe=!1})=>{const Ce=ie;if(J===void 0)return null;if(ge.isDecorated())return t.createElement(Re,{value:J,field:Q,render:ie,type:ge,truncate:fe});switch(ge.type){case"date":return t.createElement(p.Z,{dateTime:J,render:ie,field:Q,format:"complete"});case"boolean":return t.createElement(Ce,{value:String(J),field:Q});case"input":return t.createElement(P,{value:String(J)});case"node":return t.createElement(x,{value:String(J)});case"streams":return t.createElement(z,{value:J});case"percentage":return t.createElement(ue,{value:J});default:return le(Q,J,fe,ie,ge)}};re.propTypes={truncate:o().bool,type:ut.Z.FieldType,value:o().any},re.defaultProps={truncate:!1,render:me,type:void 0,value:void 0};const ce=re},UPOvISKg:(M,C,e)=>{"use strict";e.d(C,{Z:()=>O});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("jlRcBdjT"),r=e("Jvb3Ez/Z"),n=e("ii0bleBb"),c=e.n(n),v=e("gIAgj/hR"),d=e("gSdhV+tG"),g=e("Xt0X5Kl4");const p=({children:b,element:L,field:x,menuContainer:W,queryId:N,type:Z,value:j})=>{const z=(0,t.useContext)(d.f),ne=(0,t.useMemo)(()=>({queryId:N,field:x,type:Z,value:j,contexts:z}),[z,x,N,Z,j]),Y=()=>L;return t.createElement(v.Z,{element:Y,handlerArgs:ne,menuContainer:W,type:"value"},b)};p.propTypes={children:c().node.isRequired,element:c().node.isRequired,field:c().string.isRequired,menuContainer:c().object,queryId:c().string.isRequired,type:g.Z.FieldType,value:c().oneOfType([c().node,c().object]).isRequired},p.defaultProps={menuContainer:document.body,type:o.ZP.Unknown};const E=p;var a=e("/zlmJemQ"),u=e("GFJVQ2dX");const f=s.default.span` white-space: nowrap; `,y=({value:b})=>b,T=({field:b,value:L,render:x,type:W})=>{const N=(0,r.Z)(),Z=(0,t.useMemo)(()=>x!=null?x:ne=>ne.value,[x]),j=(0,t.useCallback)(({value:ne})=>t.createElement(Z,{field:b,value:ne}),[Z,b]),z=t.createElement(a.Z,{field:b,value:L,type:W,render:j});return t.createElement(E,{element:z,field:b,queryId:N,type:W,value:L},t.createElement(f,{"data-testid":"value-actions-title"},b," = ",t.createElement(a.Z,{field:b,value:L,type:W,truncate:!0})))};T.defaultProps={render:y};const P=({field:b,value:L,render:x=y,type:W=o.ZP.Unknown})=>t.createElement(u.Z.Consumer,null,N=>N?t.createElement(T,{field:b,value:L,render:x,type:W}):t.createElement("span",null,t.createElement(a.Z,{field:b,value:L,render:x,type:W})));P.defaultProps={render:y};const O=P},SqY3hYJN:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("TJOheZRu");const o=({type:r,capitalize:n=!1})=>{if(!r)return"";const c=r.toLowerCase();return n?t.Z.capitalizeFirstLetter(c):c}},"gIAgj/hR":(M,C,e)=>{"use strict";e.d(C,{Z:()=>le});var t=e("Z7aTuO5B"),s=e("F3uT4N0K"),o=e("J6y4/h8P"),r=e("0hhBr0/b"),n=e("uZqmR+ju"),c=e("PfG+ecgN"),v=e.n(c),d=e("93yMNhQL"),g=e("m/3sLmyX"),p=e("iltCXley");function E(me){return"linkTarget"in me}function a(me,re,ce){if("handler"in re)return re.handler;if("thunk"in re)return async Q=>me(re.thunk(Q));if(re.component){const Q=re.component;return({queryId:J,field:ie,value:ge,type:fe})=>{const Ce=(0,p.Z)(),Oe=()=>ce(({[Ce]:et,...Fe})=>Fe),nt=t.createElement(Q,{key:re.title,onClose:Oe,queryId:J,field:ie,value:ge,type:fe});return ce(et=>({[Ce]:nt,...et})),Promise.resolve()}}throw new Error(`Invalid binding for action: ${String(re)} - has neither 'handler' nor 'component'.`)}var u=e("6tmAsyUP"),f=e("orDZ6Vj2"),y=e("8OvTct/Z"),T=e("v4GbOr/o"),P=e("MdYBRjRJ"),O=e("0t7Ye+61");const b=(0,o.default)(n.MenuItem)` && > a { display: flex; justify-content: space-between; align-items: center; } `,L=(0,o.default)(d.Z)(({theme:me})=>` margin-left: ${me.spacings.xxs}; `),x=(0,o.default)(me=>t.createElement(u.Z,{...me}))` margin-left: 5px; `,W=({action:me,handlerArgs:re})=>{if(me.help){const ce=me.help(re);if(ce){const{title:Q,description:J}=ce;return t.createElement(t.Fragment,null,me.title,t.createElement(x,{title:Q,testId:"menu-item-help"},J))}}return t.createElement(t.Fragment,null,me.title)},N=({action:me,disabled:re,field:ce,handlerArgs:Q,onMenuToggle:J,type:ie})=>{const{unsetWidgetFocusing:ge}=(0,t.useContext)(g.Z),fe={href:me.linkTarget(Q),target:"_blank",rel:"noopener noreferrer"},Ce=(0,t.useCallback)(()=>{const{resetFocus:Oe=!1}=me;Oe&&ge(),J()},[me,J,ge]);return t.createElement(b,{disabled:re,eventKey:{action:ie,field:ce},onSelect:Ce,...fe},t.createElement(W,{action:me,handlerArgs:Q}),t.createElement(L,{name:"external-link"}))},Z=({disabled:me,action:re,handlerArgs:ce,setOverflowingComponents:Q,overflowingComponents:J,type:ie,onMenuToggle:ge})=>{const{unsetWidgetFocusing:fe}=(0,t.useContext)(g.Z),Ce=(0,f.Z)(),Oe=(0,O.Z)(),nt=(0,y.Z)(),et=(0,t.useCallback)(Ot=>{Q(Ot(J))},[J,Q]),Fe=(0,t.useMemo)(()=>a(Ce,re,et),[re,Ce,et]),Pe=(0,t.useCallback)(()=>{const{resetFocus:Ot=!1,title:ft}=re;nt(T.A.SEARCH_FIELD_VALUE_ACTION[v()(ft).replace(/\s|\//g,"_")],{app_pathname:(0,P.av)(Oe.pathname),app_section:"search-field-value",event_details:{}}),Ot&&fe(),ge(),Fe(ce)},[re,Fe,ce,Oe.pathname,ge,nt,fe]),{field:$e}=ce;return t.createElement(b,{disabled:me,eventKey:{action:ie,field:$e},onSelect:Pe},t.createElement(W,{action:re,handlerArgs:ce}))},z=({action:me,handlerArgs:re,setOverflowingComponents:ce,overflowingComponents:Q,type:J,onMenuToggle:ie})=>{const{isEnabled:ge=()=>!0}=me,Ce=(0,f.Z)()((nt,et)=>!ge(re,et)),{field:Oe}=re;return E(me)?t.createElement(N,{action:me,disabled:Ce,field:Oe,handlerArgs:re,onMenuToggle:ie,type:J}):t.createElement(Z,{action:me,disabled:Ce,field:Oe,handlerArgs:re,onMenuToggle:ie,overflowingComponents:Q,setOverflowingComponents:ce,type:J})};var ne=e("/GOzvPf6"),Y=e("Tqc935YZ");const ee=()=>(0,t.useContext)(Y.Z),ue=o.default.span` padding-left: 10px; padding-right: 10px; padding-bottom: 5px; margin-bottom: 5px; font-weight: 600; `,H=o.default.li` margin-bottom: 10px; list-style: none; `,ye=(me,re,ce=[])=>ce.filter(Q=>{const{isHidden:J=()=>!1}=Q;return me((ie,ge)=>!J(re,ge))}),we=(me,re)=>{const ce=(0,r.Z)("valueActions"),Q=(0,r.Z)("fieldActions"),J=(0,f.Z)();return me==="value"?ye(J,re,ce):me==="field"?ye(J,re,Q):[]},ut=(me,re)=>{const{isLoading:ce,isError:Q,externalValueActions:J}=ee(),ie=(0,f.Z)();if(me!=="value")return{isLoading:ce,isError:Q,externalValueActions:[]};const ge=ye(ie,re,J);return{isLoading:ce,isError:Q,externalActions:ge}},Je=({children:me,type:re,handlerArgs:ce,setOverflowingComponents:Q,overflowingComponents:J,onMenuToggle:ie})=>{const ge=we(re,ce),{externalActions:fe,isLoading:Ce}=ut(re,ce);return t.createElement(t.Fragment,null,t.createElement(H,null,t.createElement(ue,null,me)),t.createElement(n.MenuItem,{divider:!0}),t.createElement(n.MenuItem,{header:!0},"Actions"),ge.map(Oe=>t.createElement(z,{action:Oe,key:`${re}-action-${Oe.type}`,handlerArgs:ce,setOverflowingComponents:Q,overflowingComponents:J,type:re,onMenuToggle:ie})),Ce&&t.createElement(t.Fragment,null,t.createElement(n.MenuItem,{divider:!0}),t.createElement(n.MenuItem,{disabled:!0},t.createElement(ne.$j,{text:"Loading"}))),!Ce&&fe&&fe.length!==0&&t.createElement(t.Fragment,null,t.createElement(n.MenuItem,{divider:!0}),fe.map(Oe=>t.createElement(z,{action:Oe,key:`${re}-action-${Oe.type}`,handlerArgs:ce,setOverflowingComponents:Q,overflowingComponents:J,type:re,onMenuToggle:ie}))))},le=({type:me,handlerArgs:re,menuContainer:ce,element:Q,children:J})=>{const[ie,ge]=(0,t.useState)(!1),[fe,Ce]=(0,t.useState)({}),Oe=(0,t.useCallback)(()=>ge(!ie),[ie]),nt=Object.values(fe),et=t.createElement(t.Fragment,null,t.createElement(Q,{active:ie}),t.createElement("span",{className:"caret"}));return t.createElement(t.Fragment,null,t.createElement(s.Z,{show:ie,toggleChild:et,placement:"right",onToggle:Oe,menuContainer:ce},t.createElement(Je,{handlerArgs:re,type:me,setOverflowingComponents:Ce,onMenuToggle:Oe,overflowingComponents:fe},J)),nt)}},vVgHnCl1:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("/GOzvPf6");const r=s.default.div(({theme:p})=>(0,s.css)` display: flex; padding: 6px 5px 3px 7px; margin-bottom: 5px; border-radius: 3px; border: 1px solid ${p.colors.variant.lighter.default}; background-color: ${p.colors.variant.lightest.default}; `),n=s.default.div` display: flex; flex-direction: column; min-width: 25px; margin-left: 5px; `,c=s.default.div` flex: 1; // The min-width is required to avoid an overflow problem with the parent component. min-width: 0; `,v=s.default.div` display: flex; align-items: center; justify-content: center; min-height: 25px; `,d=(0,t.forwardRef)(({children:p,onRemove:E,testIdPrefix:a,dragHandleProps:u,className:f,draggableProps:y,elementTitle:T},P)=>t.createElement(r,{className:f,ref:P,...y!=null?y:{}},t.createElement(c,null,p),t.createElement(n,null,u&&t.createElement(v,{...u,"data-testid":`${a}-drag-handle`},t.createElement(o.JO,{name:"bars"})),E&&t.createElement(o.hU,{onClick:E,name:"trash-alt",title:`Remove ${T}`}))));d.defaultProps={className:void 0,draggableProps:void 0,dragHandleProps:void 0,onRemove:void 0,testIdPrefix:"configuration"};const g=d},W7wTd14e:(M,C,e)=>{"use strict";e.d(C,{b:()=>p,Z:()=>T});var t=e("Z7aTuO5B"),s=e("UiXZqrDE"),o=e("J6y4/h8P"),r=e("utbMO9sg"),n=e("/GOzvPf6"),c=e("uZqmR+ju");const d=({aggregationElements:P,onSelect:O,formValues:b})=>{const L=P.filter(({allowCreate:x})=>x(b)).map(({key:x,title:W})=>t.createElement(c.MenuItem,{key:`element-select-${x}`,onSelect:()=>O(x)},W));return t.createElement(c.DropdownButton,{id:"add-aggregation-element",dropup:!0,title:"Add"},L)};var g=e("DAqOYyf8");const p="Update preview",E=Object.fromEntries(g.Z.map(P=>[P.key,P])),a=(0,o.default)(c.ButtonToolbar)` margin-bottom: 10px; `,u=(P,O,b)=>{var L;const x=E[P];x!=null&&x.onCreate?b(x.onCreate(O)):b({...O,[P]:[...(L=O[P])!=null?L:[],{}]})},f=o.default.div` margin-left: 5px; `,T=()=>{const{dirty:P,isSubmitting:O,isValid:b,values:L,setValues:x}=(0,s.useFormikContext)();return t.createElement(a,null,t.createElement(f,{"data-testid":"add-element-section",className:"pull-left"},t.createElement(d,{onSelect:W=>u(W,L,x),aggregationElements:g.Z,formValues:L})),t.createElement(r.Z,{bsStyle:"info",className:"pull-right",type:"submit",disabled:!b||O||!P},O?t.createElement(n.$j,{text:"Updating preview...",delay:0}):p))}},AKYezHev:(M,C,e)=>{"use strict";e.d(C,{Z:()=>y});var t=e("Z7aTuO5B"),s=e("VPaD/Np4"),o=e.n(s),r=e("J6y4/h8P"),n=e("4E3oowBb"),c=e("hC1XaH+L"),v=e("hhdCSTZj"),d=e("i3LesQt8"),g=e("Jvb3Ez/Z");const p=r.default.span` display: inline-flex; gap: 2px; align-items: center; `,E=({label:T},{label:P})=>(0,n.S)(T,P),a=r.default.span(({theme:T})=>(0,r.css)` color: ${T.colors.variant.light.default}; `),u=({label:T,qualified:P,type:O})=>{const b=t.createElement(p,null,O&&t.createElement(t.Fragment,null,t.createElement(d.Z,{type:O})," "),T);return P?t.createElement("span",null,b):t.createElement(a,null,b)};u.defaultProps={type:void 0};const f=({ariaLabel:T,autoFocus:P,allowCreate:O,className:b,clearable:L,excludedFields:x,id:W,isFieldQualified:N,menuPortalTarget:Z,name:j,onChange:z,onMenuClose:ne,openMenuOnFocus:Y,persistSelection:ae,placeholder:ee,selectRef:ue,size:H,value:ye})=>{const we=(0,g.Z)(),ut=(0,t.useContext)(c.Z),ht=(0,t.useMemo)(()=>ut.queryFields.get(we,s.List()).filter(Je=>!x.includes(Je.name)).map(Je=>({label:Je.name,value:Je.name,type:Je.type,qualified:N(Je)})).toArray().sort(E),[we,x,ut.queryFields,N]);return t.createElement(v.Z,{options:ht,inputId:`select-${W}`,forwardedRef:ue,allowCreate:O,className:b,onMenuClose:ne,openMenuOnFocus:Y,persistSelection:ae,clearable:L,placeholder:ee,name:j,value:ye,"aria-label":T,optionRenderer:u,size:H,autoFocus:P,menuPortalTarget:Z,onChange:z})};f.defaultProps={allowCreate:!1,ariaLabel:void 0,autoFocus:void 0,className:void 0,clearable:!1,isFieldQualified:()=>!0,excludedFields:[],onMenuClose:void 0,openMenuOnFocus:void 0,persistSelection:void 0,placeholder:void 0,selectRef:void 0,size:"small",menuPortalTarget:void 0};const y=f},TNM0kxJ5:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("Z7aTuO5B");const o=t.createContext(()=>{})},DAqOYyf8:(M,C,e)=>{"use strict";e.d(C,{Z:()=>Yo});var t=e("oc9db6Tt"),s=e.n(t),o=e("o+5fKqZg"),r=e("iltCXley");const c=te=>{if(te===void 0||typeof te=="number")return te;const Te=Number.parseInt(te,10);return Number.isNaN(Te)?void 0:Te};var v=e("nxMFMmDQ"),d=e("Z7aTuO5B"),g=e("UiXZqrDE"),p=e("J6y4/h8P"),E=e("X6P4SH4J"),a=e.n(E),u=e("/GOzvPf6"),f=e("uZqmR+ju"),y=e("ii0bleBb"),T=e.n(y);const P=p.default.div(({theme:te})=>(0,p.css)` width: 100%; margin-top: 3px; color: ${te.colors.variant.danger}; > * { margin-right: 5px; &:last-child { margin-right: 0; } } `),O=({errors:te})=>s()(te)||Object.values(te).every(Te=>!Te)?null:d.createElement(P,null,Object.entries(te).map(([Te,Le])=>d.createElement("span",{key:Te},String(Le),".")));O.propTypes={errors:T().object},O.defaultProps={errors:{}};const b=O,L=p.default.div` display: flex; div:first-child { margin-right: 5px; } `,W=({groupingIndex:te})=>d.createElement(g.Field,{name:`groupBy.groupings.${te}.direction`},({field:{name:Te,value:Le,onChange:st,onBlur:St},meta:{error:$t}})=>d.createElement(f.Input,{id:"group-by-direction",label:"Direction",error:$t,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},d.createElement(L,null,d.createElement(f.Input,{checked:Le==="row",formGroupClassName:"",id:Te,label:"Row",onBlur:St,onChange:st,type:"radio",value:"row"}),d.createElement(f.Input,{checked:Le==="column",formGroupClassName:"",id:Te,label:"Column",onBlur:St,onChange:st,type:"radio",value:"column"}))));var N=e("GrokUsBg"),Z=e("hC1XaH+L"),j=e("yDuYCNwc"),z=e("Jvb3Ez/Z");const ne=te=>{var Te;return(Te=te.fields)!=null&&Te.length?te.type===o.Uv?"Add another date field":"Add another field":"Add a field"},ae=({groupingIndex:te})=>{var Te,Le,st,St;const $t=(0,d.useContext)(Z.Z),{setFieldValue:cn,values:In,errors:Mn}=(0,g.useFormikContext)(),Zn=In.groupBy.groupings[te],qn=(0,z.Z)(),be=ne(Zn),ze=We=>{Tt({fieldTypes:$t,activeQueryId:qn,groupingIndex:te,grouping:Zn,newFields:We,setFieldValue:cn})},Ve=(0,d.useCallback)(We=>{var vt;if(!((vt=Zn.fields)!=null&&vt.length))return!0;const Et=We.type.type==="date"?o.Uv:o.RK;return Zn.type===Et},[(Te=Zn.fields)==null?void 0:Te.length,Zn.type]);return d.createElement(j.Z,{id:"group-by-field-select",label:"Fields",labelClassName:"col-sm-3",error:(St=(st=(Le=Mn==null?void 0:Mn.groupBy)==null?void 0:Le.groupings)==null?void 0:st[te])==null?void 0:St.fields,wrapperClassName:"col-sm-9"},d.createElement(N.Z,{onChange:ze,selectedFields:Zn.fields,menuPortalTarget:document.body,createSelectPlaceholder:be,isFieldQualified:Ve,testPrefix:`grouping-${te}`}))};var ee=e("HQjpSCKK");const ue=p.default.div` display: flex; align-items: center; `,H=p.default.div` min-width: 30px; margin-left: 5px; text-align: right; `,ye=p.default.div` margin-bottom: 5px; `,we=p.default.div` display: flex; align-items: center; `,ut=(0,p.default)(te=>d.createElement(u.kF,{...te}))` margin-left: 5px; `,ht=()=>d.createElement(we,null,"Auto",d.createElement(ut,{title:"Interval Types"},d.createElement("ul",null,d.createElement("li",null,d.createElement("h4",null,"Auto bucket size"),"For example, 1.5x. A smaller granularity leads to ",d.createElement("strong",null,"less"),"; conversely, a larger one shows ",d.createElement("strong",null,"more")," values."),d.createElement("li",null,d.createElement("h4",null,"Fixed bucket size"),"For example, 2 minutes. The time defines the size of the buckets for this timestamp type.")))),Je=(te,Te,Le)=>{Le(Te==="auto"?{target:{name:te,value:{type:"timeunit",value:1,unit:"minutes"}}}:{target:{name:te,value:{type:"auto",scaling:1}}})},Re=(0,p.default)(f.FormControl)` padding: 0; border: 0; `,me=({index:te})=>d.createElement(g.Field,{name:`groupBy.groupings.${te}.interval`},({field:{name:Te,value:Le,onChange:st},meta:{error:St}})=>d.createElement(f.Input,{id:"group-by-interval",label:"Interval",error:St,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},d.createElement(ye,null,d.createElement(f.Checkbox,{onChange:()=>Je(Te,Le.type,st),checked:Le.type==="auto"},d.createElement(ht,null))),Le.type==="auto"&&d.createElement(ue,null,d.createElement(u.JO,{name:"search-minus",size:"lg",style:{paddingRight:"0.5rem"}}),d.createElement(Re,{type:"range",min:.5,max:10,step:.5,value:Le.scaling?1/Le.scaling:1,onChange:$t=>st({target:{name:Te,value:{...Le,scaling:1/parseFloat($t.target.value)}}})}),d.createElement(u.JO,{name:"search-plus",size:"lg",style:{paddingLeft:"0.5rem"}}),d.createElement(H,null,Le.scaling?1/Le.scaling:1,"x")),Le.type!=="auto"&&d.createElement(f.InputGroup,null,d.createElement(f.FormControl,{type:"number",value:Le.value,step:"1",min:"1",onChange:$t=>st({target:{name:Te,value:{...Le,value:$t.target.value}}})}),d.createElement(f.InputGroup.Button,null,d.createElement(ee.Z,{title:v.J6[Le.unit]||""},Object.keys(v.J6).map($t=>d.createElement(f.MenuItem,{key:$t,onSelect:()=>st({target:{name:Te,value:{...Le,unit:$t}}})},v.J6[$t]))))))),re=p.default.div``,ce=(0,p.default)(te=>d.createElement(u.kF,{...te}))` margin-left: 5px; `,Q=(0,p.default)(f.Checkbox)` &.checkbox { padding-top: 0; } `,J=p.default.div` display: flex; align-items: center; `,ie=({index:te})=>d.createElement(g.Field,{name:`groupBy.groupings.${te}.skipEmptyValues`},({field:{name:Te,value:Le,onChange:st}})=>d.createElement(Q,{onChange:()=>st({target:{name:Te,value:!Le}}),checked:Le!=null?Le:!1},d.createElement(J,null,"Skip Empty Values",d.createElement(ce,{title:"Skip Empty Values"},"When this is enabled, messages which do not contain the configured fields will be skipped.",d.createElement("p",null),'Otherwise an "(Empty Value)" bucket will be created.')))),fe=d.memo(({index:te})=>{const{values:{groupBy:Te}}=(0,g.useFormikContext)(),Le=Te.groupings[te].type;return d.createElement(re,{"data-testid":`grouping-${te}`},d.createElement(W,{groupingIndex:te}),d.createElement(ae,{groupingIndex:te}),Le===o.Uv&&d.createElement(me,{index:te}),Le===o.RK&&d.createElement(d.Fragment,null,d.createElement(u.Fe,{label:"Limit",name:`groupBy.groupings.${te}.limit`,type:"number",bsSize:"small"}),d.createElement(ie,{index:te})))});var Ce=e("vVgHnCl1");const Oe=(0,p.default)(f.Checkbox)` &.checkbox { padding-top: 0; } `,nt=p.default.div` display: flex; align-items: center; `,et=(0,p.default)(te=>d.createElement(u.kF,{...te}))` margin-left: 5px; `,Fe=p.default.hr(({theme:te})=>(0,p.css)` border-style: dashed; border-color: ${te.colors.variant.lighter.default}; margin-top: 5px; margin-bottom: 5px; `),$e=()=>{var te,Te;const{values:{groupBy:Le},values:st,errors:St,setValues:$t,setFieldValue:cn}=(0,g.useFormikContext)(),In=!((te=Le==null?void 0:Le.groupings)!=null&&te.find(({direction:ze})=>ze==="column")),Mn=(0,d.useCallback)(ze=>()=>{$t(pt.onRemove(ze,st))},[$t,st]),Zn=((Te=Le==null?void 0:Le.groupings)!=null?Te:[]).length===0,qn=(0,d.useCallback)(({item:ze,index:Ve,dragHandleProps:We,draggableProps:vt,className:Et,ref:At})=>d.createElement(Ce.Z,{key:`grouping-${ze.id}`,dragHandleProps:We,draggableProps:vt,className:Et,testIdPrefix:`grouping-${Ve}`,onRemove:Mn(Ve),elementTitle:pt.title,ref:At},d.createElement(fe,{index:Ve})),[Mn]),be=a()(St==null?void 0:St.groupBy);return d.createElement(d.Fragment,null,d.createElement(g.FieldArray,{name:"groupBy.groupings",validateOnChange:!1,render:()=>d.createElement(u.cm,{items:Le==null?void 0:Le.groupings,onMoveItem:ze=>cn("groupBy.groupings",ze),customListItemRender:qn})}),!Zn&&d.createElement(d.Fragment,null,d.createElement(Fe,null),d.createElement(Ce.Z,{elementTitle:"Settings"},d.createElement(g.Field,{name:"groupBy.columnRollup"},({field:{name:ze,onChange:Ve,value:We}})=>d.createElement(Oe,{onChange:()=>Ve({target:{name:ze,value:!(Le!=null&&Le.columnRollup)}}),checked:We!=null?We:!1,disabled:In},d.createElement(nt,null,"Rollup Columns",d.createElement(et,{title:"Rollup Columns"},"When rollup is enabled, an additional trace totalling individual subtraces will be included.")))))),be&&d.createElement(b,{errors:{groupBy:St==null?void 0:St.groupBy}}))},Ot=te=>{const Te={...te,type:o.RK,limit:v.LB};return"interval"in Te&&delete Te.interval,Te},ft=te=>{const Te={...te,type:o.Uv,interval:v.CG};return"limit"in Te&&delete Te.limit,Te},Tt=({fieldTypes:te,activeQueryId:Te,groupingIndex:Le,grouping:st,newFields:St,setFieldValue:$t})=>{const cn=Zn=>$t(`groupBy.groupings.${Le}`,Zn);if(!St.length){cn({...Ot(st),fields:[]});return}const Mn=te.queryFields.get(Te,te.all).some(({name:Zn,type:qn})=>St.includes(Zn)&&qn.type!=="date")?o.RK:o.Uv;if(st.type===Mn){cn({...st,fields:St});return}st.type!==Mn&&(Mn===o.RK&&cn({...Ot(st),fields:St}),Mn===o.Uv&&cn({...ft(st),fields:St}))},Lt=te=>{var Te;const Le={};return(Te=te.fields)!=null&&Te.length||(Le.fields="Field is required."),te.interval.type==="auto"&&(te.interval.scaling||(Le.interval="Scaling is required."),te.interval.scaling&&(te.interval.scaling<=0||te.interval.scaling>=10)&&(Le.interval="Must be greater than 0 and smaller or equals 10.")),te.interval.type==="timeunit"&&(te.interval.value||(Le.interval="Value is required."),te.interval.value&&te.interval.value<=0&&(Le.interval="Must be greater than 0.")),Le},Be=te=>{var Te;const Le={};return(Te=te.fields)!=null&&Te.length||(Le.fields="Field is required."),c(te.limit)===void 0&&(Le.limit="Limit is required."),te.limit<=0&&(Le.limit="Must be greater than 0."),Le},lt=te=>te.filter(Te=>Object.keys(Te).length>0).length>0,mt=te=>"interval"in te?Lt(te):Be(te),Rt=({values:te})=>{var Te,Le,st;return((Te=te==null?void 0:te.visualization)==null?void 0:Te.type)==="numeric"&&((st=(Le=te==null?void 0:te.groupBy)==null?void 0:Le.groupings)==null?void 0:st.length)>0?{groupBy:"Single Number widget does not support Group By"}:{}},zt=te=>{const Te={};if(!te.groupBy)return Te;const{groupings:Le}=te.groupBy,st=Le.map(mt),St=Rt({values:te});return lt([St])?St:lt(st)?{groupBy:{groupings:st}}:Te},xt=te=>({...te,id:(0,r.Z)()}),nn=(te,Te)=>{const{fields:Le,config:st}=te,{interval:St}=st;return xt({direction:Te,fields:Le,type:o.Uv,interval:St})},Vt=(te,Te)=>{const{fields:Le,config:st}=te,{limit:St,skip_empty_values:$t}=st;return xt({direction:Te,fields:Le,type:o.RK,limit:St,skipEmptyValues:$t})},jn=(te,Te)=>{if(te.type===o.Uv)return nn(te,Te);if(te.type===o.RK)return Vt(te,Te);throw new Error(`Widget has not supported pivot type "${te.type}"`)},Mt=te=>{const Te=te.rowPivots.map(st=>jn(st,"row")),Le=te.columnPivots.map(st=>jn(st,"column"));return[...Te,...Le]},On=te=>{const Te="interval"in te?{interval:te.interval}:{limit:c(te.limit),skip_empty_values:te.skipEmptyValues};return o.ZP.create(te.fields,te.type,Te)},rt=(te,Te)=>{const Le=te.groupings.filter($t=>$t.direction==="row").map(On),st=te.groupings.filter($t=>$t.direction==="column").map(On),{columnRollup:St}=te;return Te.rowPivots(Le).columnPivots(st).rollup(St)},Bn=()=>xt({direction:"row",fields:[],type:o.RK,limit:v.LB}),pt={sectionTitle:"Group By",title:"Grouping",key:"groupBy",order:1,allowCreate:te=>te.visualization.type!=="numeric",onCreate:te=>{var Te,Le;return{...te,groupBy:{columnRollup:te.groupBy?te.groupBy.columnRollup:!1,groupings:[...(Le=(Te=te.groupBy)==null?void 0:Te.groupings)!=null?Le:[],Bn()]}}},onRemove:(te,Te)=>{var Le,st;const St={...Te},$t=(Le=Te.groupBy)==null?void 0:Le.groupings.filter((cn,In)=>te!==In);return{...St,groupBy:{columnRollup:(st=St.groupBy.columnRollup)!=null?st:!1,groupings:$t}}},fromConfig:te=>{const Te=Mt(te);if(!s()(Te))return{groupBy:{columnRollup:te.rollup,groupings:Te}}},toConfig:(te,Te)=>rt(te.groupBy,Te),component:$e,validate:zt,isEmpty:te=>{var Te;return((Te=te==null?void 0:te.groupings)!=null?Te:[]).length===0}},Gt=pt;var gn=e("uzwJl55m");const Jt=gn.Z;var An=e("7VrSCphN"),xe=e("Wk8izdHL"),Pn=e("hhdCSTZj");const sn=[{label:"Ascending",value:"Ascending"},{label:"Descending",value:"Descending"}],no=te=>{var Te;const Le=`${te.function}(${(Te=te.field)!=null?Te:""})`;return{label:te.name||Le,field:Le}},Co=te=>te.fields,Mo=d.memo(({index:te})=>{var Te,Le;const{values:st,setFieldValue:St}=(0,g.useFormikContext)(),{metrics:$t=[],groupBy:{groupings:cn=[]}={}}=st,In=(Le=(Te=st==null?void 0:st.sort)==null?void 0:Te.filter((Ct,Kt)=>te!==Kt))!=null?Le:[],Mn=In.find(Ct=>Ct.type==="metric"),Zn=In.find(Ct=>Ct.type==="groupBy"),qn=Zn?[]:$t.filter(Ct=>Ct.function!=="latest").map(no).map(({field:Ct,label:Kt})=>({type:"metric",field:Ct,label:Kt})),be=Zn||Mn?[]:cn.filter(Ct=>Ct.direction==="row").flatMap(Co).map(Ct=>({type:"groupBy",field:Ct,label:Ct})),ze=[...qn,...be],Ve=ze.map((Ct,Kt)=>({label:Ct.label,value:Kt})),We=st.sort[te],vt=ze.findIndex(Ct=>Ct.type===We.type&&Ct.field===We.field),Et=vt>-1?vt:void 0,At=Et===void 0&&"field"in We;return d.createElement("div",{"data-testid":`sort-element-${te}`},d.createElement(g.Field,{name:`sort.${te}.field`},({field:{name:Ct,onChange:Kt},meta:{error:en}})=>d.createElement(f.Input,{id:"field-select",label:"Field",error:en,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},d.createElement(Pn.Z,{options:At?[{label:We.field,value:0}]:Ve,disabled:At,allowCreate:At,clearable:!1,name:Ct,value:At?0:Et,placeholder:"Specify field/metric to be sorted on","aria-label":"Select field for sorting",size:"small",menuPortalTarget:document.body,onChange:dn=>{const En=ze[dn];St(`sort.${te}.type`,En.type),Kt({target:{name:Ct,value:En.field}})}}))),d.createElement(g.Field,{name:`sort.${te}.direction`},({field:{name:Ct,value:Kt,onChange:en},meta:{error:dn}})=>d.createElement(f.Input,{id:"direction-select",label:"Direction",error:dn,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},d.createElement(Pn.Z,{options:sn,disabled:At,clearable:!1,name:Ct,"aria-label":"Select direction for sorting",value:Kt,size:"small",menuPortalTarget:document.body,onChange:En=>{en({target:{name:Ct,value:En}})}}))))}),Zt=()=>{const{values:{sort:te},setFieldValue:Te,setValues:Le,values:st}=(0,g.useFormikContext)(),St=(0,d.useCallback)($t=>()=>{Le(It.onRemove($t,st))},[Le,st]);return d.createElement(g.FieldArray,{name:"sort",validateOnChange:!1,render:()=>d.createElement(u.cm,{items:te,onMoveItem:$t=>Te("sort",$t),customListItemRender:({item:$t,index:cn,dragHandleProps:In,draggableProps:Mn,className:Zn,ref:qn})=>d.createElement(Ce.Z,{key:`sort-${$t.id}`,dragHandleProps:In,draggableProps:Mn,className:Zn,testIdPrefix:`sort-${cn}`,onRemove:St(cn),elementTitle:It.title,ref:qn},d.createElement(Mo,{index:cn}))})})},Me=te=>te.filter(Te=>Object.keys(Te).length>0).length>0,Ye=te=>{const Te={};if(!te.sort)return Te;const Le=te.sort.map(st=>{var St;const $t={};(!st.field||st.field==="")&&($t.field="Field is required."),st.direction||($t.direction="Direction is required.");const cn=!!((St=te.groupBy)!=null&&St.groupings.find(Mn=>Mn.direction==="row"&&Mn.type==="time")),In=te.visualization&&te.visualization.type!=="table";return cn&&In&&($t.field="Sort on non data table with time based row grouping does not work."),$t});return Me(Le)?{sort:Le}:{}},Ke=(te={})=>({...te,id:(0,r.Z)()}),dt=te=>{switch(te){case"pivot":return"groupBy";case"series":return"metric";default:throw new Error(`Invalid sort type: ${te}`)}},it=te=>{switch(te){case"groupBy":return"pivot";case"metric":return"series";default:throw new Error(`Invalid sort type: ${te}`)}},It={title:"Sort",key:"sort",order:3,allowCreate:()=>!0,onCreate:te=>({...te,sort:[...te.sort,Ke({})]}),component:Zt,fromConfig:te=>({sort:te.sort.map(Te=>{var Le;return Ke({type:dt(Te.type),field:Te.field,direction:(Le=Te.direction)==null?void 0:Le.direction})})}),toConfig:(te,Te)=>Te.sort(te.sort.map(Le=>new xe.Z(it(Le.type),Le.field,An.Z.fromString(Le.direction)))),onRemove:(te,Te)=>({...Te,sort:Te.sort.filter((Le,st)=>te!==st)}),validate:Ye,isEmpty:te=>(te!=null?te:[]).length===0},ot=It;var yt=e("QL8i6bcz"),Xt=e("87D/Fijl"),rn=e.n(Xt),Cn=e("0hhBr0/b"),bn=e("4E3oowBb");const hn=(0,p.default)(g.Field)` &&[type='checkbox'] { margin-top: 8px; } `,Xn=({field:te,name:Te,error:Le,title:st})=>d.createElement(d.Fragment,null,d.createElement(f.Input,{id:`${Te}-input`,label:st,error:Le,labelClassName:"col-sm-11",wrapperClassName:"col-sm-1"},d.createElement(hn,{type:"checkbox",className:"pull-right","aria-label":te.title,name:Te})),d.createElement(f.HelpBlock,null,te.description)),vo=(te,Te)=>({target:{name:te,value:Te}}),Jn=({onChange:te,value:Te,error:Le,name:st,title:St,field:$t})=>{const cn=(0,d.useCallback)(In=>{te(vo(In.target.name,Number.parseFloat(In.target.value)))},[te]);return d.createElement(f.Input,{id:`${st}-input`,bsSize:"small",type:"number",name:st,onChange:cn,value:Te!=null?Te:"",label:St,error:Le,placeholder:$t.description,step:$t.step,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"})},Wn=te=>te.map(Te=>{if(typeof Te=="string")return{label:Te,value:Te};const[Le,st]=Te;return{label:Le,value:st}}),bo=(te,Te)=>({target:{name:te,value:Te}}),zo=({name:te,field:Te,title:Le,error:st,value:St,onChange:$t})=>{if(Te.type!=="select")throw new Error("Invalid field type passed!");return d.createElement(f.Input,{id:`${te}-select`,label:Le,error:st,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},d.createElement(Pn.Z,{options:Wn(Te.options),"aria-label":`Select ${Te.title}`,clearable:!Te.required,name:te,value:St,size:"small",menuPortalTarget:document.body,onChange:cn=>$t(bo(te,cn))}))},Xo=te=>{const Te=new Set;return[te.map(st=>{if(typeof st=="string")return Te.add(st),{key:st,value:st};const[St,$t]=st;return Te.add($t),{key:St,value:$t}}),Te]},Do=(te,Te)=>({target:{name:te,value:Te}}),Zo=({name:te,field:Te,title:Le,error:st,value:St,onChange:$t,values:cn})=>{if(Te.type!=="multi-select")throw new Error("Invalid field type passed!");const[In,Mn]=(0,d.useMemo)(()=>rn()(Te.options)?Xo(Te.options({formValues:cn})):Xo(Te.options),[cn,Te]),Zn=(0,d.useCallback)(be=>$t(Do(te,be===""?[]:be.split(","))),[te,$t]),qn=(0,d.useMemo)(()=>St.join(","),[St]);return(0,d.useEffect)(()=>{const be=St.filter(ze=>Mn.has(ze)).join(",");qn!==be&&Zn(be)},[Mn,St,Zn,qn]),d.createElement(f.Input,{id:`${te}-select`,label:Le,error:st,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},d.createElement(Pn.Z,{options:In,name:te,value:qn,multi:!0,menuPortalTarget:document.body,onChange:Zn,inputProps:{"aria-label":`Select ${Te.title}`},displayKey:"key",inputId:"multi-select-visualization"}))},yo=p.default.div` display: flex; align-items: center; `,Vo=(0,p.default)(te=>d.createElement(u.kF,{...te}))` margin-left: 5px; `,_s=te=>{switch(te){case"select":return zo;case"boolean":return Xn;case"numeric":return Jn;case"multi-select":return Zo;default:throw new Error(`Invalid configuration field type: ${te}`)}},Cs=te=>{const{helpComponent:Te}=te;return Te?d.createElement(yo,null,te.title,d.createElement(Vo,{title:`Help for ${te.title}`,placement:"top"},d.createElement(Te,null))):te.title},Yn=({name:te,fields:Te=[]})=>{const{values:Le}=(0,g.useFormikContext)(),st=(0,g.getIn)(Le,te);return d.createElement(d.Fragment,null,Te.filter(St=>St.isShown?St.isShown(st):!0).map(St=>{const $t=_s(St.type),cn=Cs(St);return d.createElement(g.Field,{key:`${te}.${St.name}`,name:`${te}.${St.name}`},({field:{name:In,value:Mn,onChange:Zn},meta:{error:qn}})=>d.createElement($t,{key:`${te}.${St.name}`,name:In,value:Mn,values:Le,onChange:Zn,error:qn,field:St,title:cn}))}))},xo=(0,p.default)(f.Checkbox)` input[type='checkbox'] { margin-right: 0; right: 0; } `,Ls=te=>{var Te,Le;if(!((Te=te.groupBy)!=null&&Te.groupings)||te.groupBy.groupings.length===0)return!1;const st=te.groupBy.groupings.find(St=>St.direction==="row");return(st==null?void 0:st.type)===o.Uv&&((Le=st==null?void 0:st.fields)==null?void 0:Le[0])===v.rg},Bs=()=>{var te,Te,Le;const st=(0,Cn.Z)("visualizationTypes"),St=(0,d.useCallback)(Ve=>st.find(We=>We.type===Ve),[st]),$t=(0,d.useMemo)(()=>st.sort((Ve,We)=>(0,bn.S)(Ve.displayName,We.displayName)).map(({displayName:Ve,type:We})=>({label:Ve,value:We})),[st]),{values:cn,setFieldValue:In}=(0,g.useFormikContext)(),Mn=St(cn.visualization.type),Zn=(0,d.useCallback)(Ve=>{var We,vt;const At=(vt=(We=St(Ve).config)==null?void 0:We.createConfig)!=null?vt:()=>({});In("visualization",{type:Ve,config:At()},!0)},[St,In]),qn=Ls(cn),be=(Te=(te=Mn.capabilities)==null?void 0:te.includes("event-annotations"))!=null?Te:!1,ze=(0,d.useMemo)(()=>{var Ve;const We=(Ve=Mn.config)==null?void 0:Ve.fields;return rn()(We)?We({formValues:cn}):We!=null?We:[]},[(Le=Mn.config)==null?void 0:Le.fields,cn]);return d.createElement(Ce.Z,{elementTitle:gs.title},d.createElement(g.Field,{name:"visualization.type"},({field:{name:Ve,value:We},meta:{error:vt}})=>d.createElement(f.Input,{id:"visualization-type-select",label:"Type",error:vt,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},d.createElement(Pn.Z,{options:$t,"aria-label":"Select visualization type",clearable:!1,name:Ve,value:We,menuPortalTarget:document.body,onChange:Et=>{Et!==We&&Zn(Et)},size:"small"}))),qn&&be&&d.createElement(g.Field,{name:"visualization.eventAnnotation"},({field:{name:Ve,value:We=!1},meta:{error:vt}})=>d.createElement(f.Input,{id:`${Ve}-input`,label:"Show Event annotations",error:vt,labelClassName:"col-sm-11",wrapperClassName:"col-sm-1"},d.createElement(xo,{id:`${Ve}-input`,name:Ve,onChange:()=>In(Ve,!We),checked:We,className:"pull-right"}))),d.createElement(Yn,{name:"visualization.config",fields:ze}))},Ts=te=>{const Te=yt.G.exports("visualizationTypes").find(({type:Le})=>Le===te);if(!Te)throw new Error(`Invalid visualization type: ${te}`);return Te},Us=()=>{},ws=(te,Te)=>{const{config:{toConfig:Le=Us}={}}=Ts(te);return Le(Te)},Lo=()=>({}),co=(te,Te)=>{const{config:{fromConfig:Le=Lo}={}}=Ts(te);return Le(Te)},ns=te=>{var Te;return{visualization:{type:te.visualization,config:co(te.visualization,te.visualizationConfig),eventAnnotation:(Te=te.eventAnnotation)!=null?Te:!1}}},os=(te,Te)=>Te.visualization(te.visualization.type).visualizationConfig(ws(te.visualization.type,te.visualization.config)).eventAnnotation(te.visualization.eventAnnotation),Ws=te=>Object.values(te).filter(Te=>Te!==void 0).length>0,ps=(te,Te)=>{const{fields:Le=[]}=te.config;return Le.filter(st=>"required"in st&&st.required).filter(st=>!st.isShown||st.isShown(Te)).filter(({name:st})=>Te[st]===void 0||Te[st]==="").map(({name:st,title:St})=>({[st]:`${St} is required.`})).reduce((st,St)=>({...st,...St}),{})},gs={title:"Visualization",key:"visualization",order:4,allowCreate:te=>s()(te.visualization),component:Bs,fromConfig:ns,toConfig:os,validate:te=>{var Te,Le;const{visualization:{type:st,config:St}}=te;if(!st)return{"visualization.type":"Type is required."};const $t=Ts(st),cn=(Le=(Te=$t.validate)==null?void 0:Te.call($t,te))!=null?Le:{},In=$t.config?ps($t,St):{};return Ws(In)||Ws(cn)?{visualization:{...cn,config:In}}:{}},isEmpty:()=>!1},Yo=[Gt,Jt,ot,gs]},QBkrNAIi:(M,C,e)=>{"use strict";e.d(C,{t:()=>ce,l:()=>d});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("fCul1Qwh"),r=e("UiXZqrDE"),n=e("6KiaUlHf"),c=e("0IW4P5Zs");const d=({formKey:Q,disableSubmission:J})=>{const{setDisabled:ie}=(0,t.useContext)(c.Z);return(0,t.useEffect)(()=>ie(Q,J),[Q,J,ie]),null},g=(0,s.default)(r.Form)` display: flex; width: 100%; `,p=(Q,J)=>{const{bindApplyElementConfigurationChanges:ie}=(0,t.useContext)(n.Z);(0,t.useEffect)(()=>{ie(()=>{if(Q.current){const{dirty:ge,values:fe,isValid:Ce}=Q.current;if(ge&&Ce)return Re(fe,J)}})},[Q,ie,J])},a=({children:Q,onSubmit:J,initialValues:ie,validate:ge,config:fe})=>{const Ce=(0,t.useRef)(null);return p(Ce,fe),t.createElement(r.Formik,{initialValues:ie,validate:ge,enableReinitialize:!0,innerRef:Ce,validateOnChange:!0,validateOnMount:!0,onSubmit:J},(...Oe)=>t.createElement(g,{className:"form form-horizontal"},t.createElement(d,{formKey:"widget-config",disableSubmission:!Oe[0].isValid||Oe[0].isValidating||Oe[0].isSubmitting}),typeof Q=="function"?Q(...Oe):Q))};var u=e("i/Bor0y0"),f=e("ocYLQ/BD"),y=e("Ofda/4py");const T=s.default.div(({theme:Q})=>(0,s.css)` border-radius: 6px; margin-bottom: 6px; &:last-child { margin-bottom: 0; } div[class^='col-'] { padding-right: 0; padding-left: 0; } input { font-size: ${Q.fonts.size.body}; } .form-group { margin: 0 0 3px; } .control-label { padding-left: 0; padding-right: 5px; padding-top: 5px; font-weight: normal; text-align: left; hyphens: auto; } .help-block { margin: 0; hyphens: auto; } .checkbox { min-height: auto; } `),P=s.default.div(({theme:Q,$isEmpty:J})=>(0,s.css)` display: flex; justify-content: space-between; align-items: center; margin-bottom: 1px; min-height: 26px; font-weight: bold; background-color: ${Q.colors.global.contentBackground}; position: sticky; top: 0; z-index: 1; &::before { content: ' '; top: 50%; width: 100%; border-bottom: 1px solid ${J?Q.colors.gray[70]:Q.utils.contrastingColor(Q.colors.global.contentBackground,"AA")}; position: absolute; } `),O=s.default.div(({theme:Q,$isEmpty:J})=>(0,s.css)` background-color: ${Q.colors.global.contentBackground}; color: ${J?Q.colors.gray[70]:Q.colors.global.textDefault}; z-index: 1; padding-right: 8px; `),b=s.default.div(({theme:Q})=>(0,s.css)` background-color: ${Q.colors.global.contentBackground}; z-index: 1; padding-left: 5px; `),L=(0,s.default)(y.Z)(({theme:Q})=>` color: ${Q.colors.global.textDefault}; `),x=({allowCreate:Q,children:J,elementTitle:ie,isEmpty:ge,onCreate:fe,sectionTitle:Ce})=>{const Oe=Ce!=null?Ce:ie;return t.createElement(T,{"data-testid":`${Oe}-section`},t.createElement(P,{$isEmpty:ge},t.createElement(O,{$isEmpty:ge},Oe),t.createElement(b,null,Q&&t.createElement(L,{title:`Add a ${ie}`,name:"plus",onClick:fe}))),t.createElement("div",null,J))};x.defaultProps={sectionTitle:void 0,isEmpty:!1};const W=x;var N=e("W7wTd14e");const Z=s.default.div` position: relative; height: 100%; `,j=(Q,J)=>Object.keys(J).map(ie=>[ie,Q[J[ie].key]]).sort(([ie],[ge])=>J[ie].order-J[ge].order),ne=({aggregationElementsByKey:Q,config:J,onConfigChange:ie,onCreate:ge,onSubmit:fe,onCancel:Ce})=>{const{values:Oe,setValues:nt}=(0,r.useFormikContext)();return t.createElement(Z,null,t.createElement(u.Z,{actions:t.createElement(t.Fragment,null,t.createElement(N.Z,null),t.createElement(f.Z,{onCancel:Ce,onSubmit:fe}))},t.createElement("div",null,j(Oe,Q).map(([et,Fe])=>{const Pe=Q[et];if(!Pe)throw new Error(`Aggregation element with key ${et} is missing but configured for this widget.`);const{component:$e,isEmpty:Ot}=Pe,ft=Ot(Fe);return t.createElement(W,{allowCreate:Pe.allowCreate(Oe),isEmpty:ft,onCreate:()=>ge(Pe.key,Oe,nt),elementTitle:Pe.title,sectionTitle:Pe.sectionTitle,key:Pe.key},t.createElement($e,{config:J,onConfigChange:ie}))}))))};var Y=e("DAqOYyf8"),ae=e("TNM0kxJ5");const ee=s.default.div` height: 100%; flex: 3; `,H=({children:Q})=>{const{setFieldValue:J,values:ie}=(0,r.useFormikContext)(),ge=(0,t.useCallback)(fe=>{J("visualization",{...ie.visualization,config:{...ie.visualization.config,...fe}})},[ie.visualization,J]);return t.createElement(ee,null,t.createElement(ae.Z.Provider,{value:ge},Q))},ye=Object.fromEntries(Y.Z.map(Q=>[Q.key,Q])),we=Q=>Y.Z.reduce((J,ie)=>({...J,...ie.fromConfig?ie.fromConfig(Q):{}}),{}),ut=s.default.div` height: 100%; min-width: 315px; max-width: 500px; flex: 1.2; padding-right: 15px; `,ht=s.default.div` height: 100%; margin-bottom: 10px; &:last-child { margin-bottom: 0; } `,Je=(Q,J,ie)=>{var ge;const fe=ye[Q];fe!=null&&fe.onCreate?ie(fe.onCreate(J)):ie({...J,[Q]:[...(ge=J[Q])!=null?ge:[],{}]})},Re=(Q,J=o.Z.builder().build())=>{const ie=Object.fromEntries(Y.Z.map(({key:fe,toConfig:Ce})=>[fe,Ce]));return Object.keys(Q).map(fe=>{var Ce;const Oe=(Ce=ie[fe])!=null?Ce:(nt,et)=>et;if(!Oe)throw new Error(`Aggregation element with key ${fe} is missing toConfig.`);return Oe}).reduce((fe,Ce)=>Ce(Q,fe),J.toBuilder()).build()},le=(Q,J,ie)=>{const ge=Re(Q,ie);return J(ge)},me=Q=>Y.Z.map(ge=>{var fe;return(fe=ge.validate)!=null?fe:()=>({})}).map(ge=>ge(Q)).reduce((ge,fe)=>({...ge,...fe}),{}),ce=({onChange:Q,config:J,children:ie,onSubmit:ge,onCancel:fe})=>{const Ce=we(J);return t.createElement(a,{onSubmit:Oe=>le(Oe,Q,J),initialValues:Ce,config:J,validate:me},t.createElement(t.Fragment,null,t.createElement(ut,null,t.createElement(ht,{"data-testid":"configure-elements-section"},t.createElement(ne,{aggregationElementsByKey:ye,config:J,onCreate:Je,onSubmit:ge,onCancel:fe,onConfigChange:Q}))),t.createElement(H,null,ie)))}},uzwJl55m:(M,C,e)=>{"use strict";e.d(C,{Z:()=>ht,u:()=>we});var t=e("7J1sc9Ol"),s=e("WyXFCd64"),o=e("Z7aTuO5B"),r=e("UiXZqrDE"),n=e("J6y4/h8P"),c=e("VPaD/Np4"),v=e("4E3oowBb"),d=e("uZqmR+ju"),g=e("hhdCSTZj"),p=e("/GOzvPf6"),E=e("jlRcBdjT"),a=e("DUKaTDO2"),u=e("MdYBRjRJ"),f=e("eFxcQyPT");const y=u.DC("/views/functions"),T=()=>(0,f.ZP)("GET",y),O=()=>(0,a.useQuery)(["aggregationFunctions"],T);var b=e("nxMFMmDQ"),L=e("AKYezHev");const x=n.default.div``,W=({label:Je},{label:Re})=>(0,v.S)(Je,Re),N=(Je,Re)=>{var le,me;const re=(me=(le=Je==null?void 0:Je.type)==null?void 0:le.properties)!=null?me:c.Set();return Re.map(ce=>re.contains(ce)).find(ce=>ce===!1)===void 0},j=({index:Je})=>{const Re=(0,o.useRef)(null),{data:le,isLoading:me}=O(),re=(0,o.useMemo)(()=>me?[]:Object.values(le).map(({type:ft,description:Tt})=>({label:Tt,value:ft})).sort(W),[le,me]),{values:{metrics:ce},errors:{metrics:Q},setFieldValue:J}=(0,r.useFormikContext)(),ie=ce[Je],ge=ie.function,fe=ge!=="percentage",Ce=!["count","percentage"].includes(ge),Oe=ge==="percentile",nt=ge==="percentage",et=nt&&ie.strategy==="SUM"||!["card","count","latest","percentage"].includes(ge),Fe=(0,o.useCallback)(ft=>et?N(ft,[E.E.Numeric]):!0,[et]),[Pe,$e]=(0,o.useState)(!1),Ot=(0,o.useCallback)(ft=>{J(`metrics.${Je}.function`,ft),$e(!0)},[J,Je]);return(0,o.useEffect)(()=>{(0,r.getIn)(Q==null?void 0:Q[Je],"field")&&Pe&&Re.current.focus()},[Pe,Q,Je,Re]),o.createElement(x,{"data-testid":`metric-${Je}`},o.createElement(r.Field,{name:`metrics.${Je}.function`},({field:{name:ft,value:Tt},meta:{error:Lt}})=>o.createElement(d.Input,{id:"metric-function-select",label:"Function",error:Lt,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},o.createElement(g.Z,{options:re,clearable:!1,name:ft,value:Tt,"aria-label":"Select a function",size:"small",menuPortalTarget:document.body,onChange:Ot}))),fe&&o.createElement(r.Field,{name:`metrics.${Je}.field`},({field:{name:ft,value:Tt,onChange:Lt},meta:{error:Be}})=>o.createElement(d.Input,{id:"metric-field",label:"Field",error:Be,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},o.createElement(L.Z,{id:"metric-field-select",selectRef:Re,menuPortalTarget:document.body,onChange:lt=>Lt({target:{name:ft,value:lt}}),clearable:!Ce,isFieldQualified:Fe,name:ft,value:Tt,ariaLabel:"Select a field"}))),Oe&&o.createElement(r.Field,{name:`metrics.${Je}.percentile`},({field:{name:ft,value:Tt,onChange:Lt},meta:{error:Be}})=>o.createElement(d.Input,{id:"metric-percentile-select",label:"Percentile",error:Be,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},o.createElement(g.Z,{options:b.YN,clearable:!1,name:ft,value:Tt,"aria-label":"Select percentile",size:"small",menuPortalTarget:document.body,onChange:lt=>Lt({target:{name:ft,value:lt}})}))),nt&&o.createElement(o.Fragment,null,o.createElement(r.Field,{name:`metrics.${Je}.strategy`},({field:{name:ft,value:Tt,onChange:Lt},meta:{error:Be}})=>o.createElement(d.Input,{id:"metric-percentage-strategy-select",label:"Strategy",error:Be,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},o.createElement(g.Z,{options:b.tY,clearable:!1,name:ft,value:Tt!=null?Tt:"COUNT","aria-label":"Select strategy",size:"small",menuPortalTarget:document.body,onChange:lt=>Lt({target:{name:ft,value:lt}})}))),o.createElement(r.Field,{name:`metrics.${Je}.field`},({field:{name:ft,value:Tt,onChange:Lt},meta:{error:Be}})=>o.createElement(d.Input,{id:"metric-field",label:"Field",error:Be,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"},o.createElement(L.Z,{id:"metric-field-select",selectRef:Re,onChange:lt=>Lt({target:{name:ft,value:lt}}),clearable:!Ce,isFieldQualified:Fe,name:ft,value:Tt,menuPortalTarget:document.body,ariaLabel:"Select a field"})))),o.createElement(p.jc,{id:"name",label:o.createElement(o.Fragment,null,"Name ",o.createElement(p.Sr,null)),bsSize:"small",placeholder:"Specify display name",name:`metrics.${Je}.name`,labelClassName:"col-sm-3",wrapperClassName:"col-sm-9"}))};var z=e("vVgHnCl1");const Y=()=>{const{values:{metrics:Je},setValues:Re,values:le}=(0,r.useFormikContext)(),me=(0,o.useCallback)(re=>()=>{Re(ht.onRemove(re,le))},[Re,le]);return o.createElement(r.FieldArray,{name:"metrics",validateOnChange:!1,render:()=>o.createElement(o.Fragment,null,Je.map((re,ce)=>o.createElement(z.Z,{key:`metrics-${ce}`,onRemove:me(ce),elementTitle:ht.title},o.createElement(j,{index:ce}))))})},ae=Je=>Je.filter(Re=>Object.keys(Re).length>0).length>0,ee=Je=>{const Re={};if(!Je.metrics)return Re;const le=Je.metrics.map(me=>{const re={};return me.function||(re.function="Function is required."),me.function!=="count"&&(me.function!=="percentage"||me.strategy==="SUM")&&!me.field&&(re.field=`Field is required for function ${me.function}.`),me.function==="percentile"&&!me.percentile&&(re.percentile="Percentile is required."),me.name&&Je.metrics.filter(({name:Q})=>Q===me.name).length>1&&(re.name="Name must be unique."),re});return ae(le)?{metrics:le}:{}},ue=Je=>{switch(Je.function){case"percentage":return Je.strategy;case"percentile":return Je.percentile;default:return}},H=Je=>(Je==null?void 0:Je.trim())===""?void 0:Je,ye=Je=>Je.map(Re=>t.ZP.create(Re.function,H(Re.field),ue(Re)).toBuilder().config(s.Z.empty().toBuilder().name(Re.name).build()).build()),we=Je=>Je.map(Re=>{var le,me;const{type:re,field:ce,percentile:Q,strategy:J}=(le=(0,t.mg)(Re.function))!=null?le:{},ie={function:re,field:ce,name:(me=Re.config)==null?void 0:me.name};if(Q){const ge=Number.parseFloat(Q);return{...ie,percentile:ge}}return J?{...ie,strategy:J}:ie}),ht={sectionTitle:"Metrics",title:"Metric",key:"metrics",order:2,allowCreate:()=>!0,fromConfig:Je=>({metrics:we(Je.series)}),toConfig:(Je,Re)=>Re.series(ye(Je.metrics)),onRemove:(Je,Re)=>({...Re,metrics:Re.metrics.filter((le,me)=>Je!==me)}),component:Y,validate:ee,isEmpty:Je=>(Je!=null?Je:[]).length===0}},"5s1wXXQQ":(M,C,e)=>{"use strict";e.d(C,{Z:()=>N});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("dFpwyWHg"),c=e.n(n),v=e("C2ikvoS0"),d=e.n(v),g=e("1IntWRSu"),p=e.n(g),E=e("8nGWeFnd"),a=e.n(E),u=e("TeAcaicX"),f=e.n(u),y=e("eE3+5goe"),T=e.n(y),P=e("kK/tJf6e"),O={};O.styleTagTransform=T(),O.setAttributes=a(),O.insert=p().bind(null,"head"),O.domAPI=d(),O.insertStyleElement=f();var b=c()(P.Z,O);const L=P.Z&&P.Z.locals?P.Z.locals:void 0,x=r.default.span(({theme:Z})=>(0,r.css)` border: 1px solid ${Z.colors.global.contentBackground}; font-size: ${Z.fonts.size.large}; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; `),W=r.default.input(({theme:Z})=>(0,r.css)` border: 1px solid ${Z.colors.input.border}; background-color: ${Z.colors.input.background}; color: ${Z.colors.input.color}; border-radius: 4px; padding: 2px 3px; font-size: ${Z.fonts.size.large}; &:focus { border-color: ${Z.colors.input.borderFocus}; outline: none; } `);class N extends t.Component{constructor(j){super(j),this._toggleEditing=()=>{const{disabled:ne}=this.props;ne||this.setState(Y=>({editing:!Y.editing}))},this._onBlur=()=>{this._toggleEditing(),this._submitValue()},this._onChange=ne=>{ne.preventDefault(),this.setState({value:ne.target.value})},this._submitValue=()=>{const{value:ne}=this.state,{onChange:Y,value:ae}=this.props;ne!==""?Y(ne):this.setState({value:ae})},this._onSubmit=ne=>{ne.preventDefault(),ne.stopPropagation(),this._toggleEditing(),this._submitValue()};const{value:z}=j;this.state={editing:!1,value:z}}render(){const{editing:j,value:z}=this.state;return j?t.createElement("span",null,t.createElement("form",{onSubmit:this._onSubmit,className:L.inlineForm},t.createElement(W,{autoFocus:!0,type:"text",value:z,onBlur:this._onBlur,title:"Edit title",onChange:this._onChange}))):t.createElement(x,{onDoubleClick:this._toggleEditing,title:`${z} - Double click the title to edit it.`},z)}}N.propTypes={disabled:o().bool,onChange:o().func,value:o().string.isRequired},N.defaultProps={disabled:!1,onChange:()=>{}}},"0IW4P5Zs":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext({disabled:!1,setDisabled:()=>{}}),r=(0,s.ri)("contexts.DisableSubmissionState",()=>o)},"4zkAw1kt":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("Z7aTuO5B"),s=e("CHWvwBKE"),o=e("nxMFMmDQ");const r={query:(0,s.Eg)(""),streams:[],timerange:o.nn},c=t.createContext(r)},"hC1XaH+L":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.FieldTypesContext",()=>o)},"5CYElDLi":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("Z7aTuO5B");const o=t.createContext(void 0)},RTnJ3JrH:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(void 0),r=(0,s.ri)("contexts.HighlightingRules",()=>o)},GFJVQ2dX:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(!0),r=(0,s.ri)("views.components.contexts.InteractiveContext",()=>o)},GPuPro0F:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o={showDropdownButton:!0,showPresetsButton:!0,showAddToQuickListButton:!0,ignoreLimitDurationInTimeRangeDropdown:!1},r=t.createContext(o),n=(0,s.ri)("views.components.contexts.TimeRangeInputSettingsContext",()=>r)},"S/tO1idZ":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("Z7aTuO5B");const o=t.createContext(void 0)},"6KiaUlHf":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext({applyAllWidgetChanges:()=>Promise.resolve(),bindApplyElementConfigurationChanges:()=>{},bindApplySearchControlsChanges:()=>{}}),r=(0,s.ri)("contexts.WidgetEditApplyAllChangesContext",()=>o)},"m/3sLmyX":(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o={focusedWidget:void 0,setWidgetFocusing:()=>{},setWidgetEditing:()=>{},unsetWidgetFocusing:()=>{},unsetWidgetEditing:()=>{}},r=t.createContext(o),n=(0,s.ri)("contexts.WidgetFocus",()=>r)},B6TE4HBJ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("S6FuRS7B"),n=e("gTexEe+8"),c=e("yDuYCNwc"),v=e("qZ8Wpsbl");const d=({onClose:p,onSave:E,show:a,view:u,title:f,submitButtonText:y})=>{const[T,P]=(0,t.useState)(u),O=(0,v.Z)(),b=x=>{const{name:W}=x.target;let N=r.n6(x.target);const Z=N.trim();switch(Z===""&&(N=Z),W){case"title":P(j=>j.toBuilder().title(N).build());break;case"summary":P(j=>j.toBuilder().summary(N).build());break;case"description":P(j=>j.toBuilder().description(N).build());break;default:}},L=x=>{x.stopPropagation(),E(T),p()};return t.createElement(n.Z,{show:a,title:f,"data-telemetry-title":"Dashboard Properties",onCancel:p,onSubmitForm:L,submitButtonText:y,bsSize:"large"},t.createElement(t.Fragment,null,t.createElement(c.Z,{id:"title",type:"text",name:"title",label:"Title",help:"The title of the dashboard.",required:!0,onChange:b,value:T.title}),t.createElement(c.Z,{id:"summary",type:"text",name:"summary",label:"Summary",help:"A helpful summary of the dashboard.",onChange:b,value:T.summary}),t.createElement(c.Z,{id:"description",type:"textarea",name:"description",label:"Description",help:"A longer, helpful description of the dashboard and its functionality.",onChange:b,value:T.description}),O==null?void 0:O.map(({component:x,id:W})=>x&&t.createElement(x,{key:W}))))};d.propTypes={onClose:o().func.isRequired,onSave:o().func.isRequired,show:o().bool.isRequired,submitButtonText:o().string.isRequired,title:o().string.isRequired,view:o().object.isRequired};const g=d},wfOnu0E0:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("GFJVQ2dX");const r=({children:n})=>t.createElement(s.Z.Consumer,null,c=>c?n:null)},"+gqrR506":(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("DUKaTDO2"),s=e("jAGDuYSC"),o=e("UmnljV2q"),r=e("eFxcQyPT"),n=e("MdYBRjRJ"),c=e("gyRmhZSW");const v={pagination:{total:0},list:[],attributes:[]},d=(0,n.DC)("/dashboards"),g=a=>{const u=(0,c.Z)(d,a.page,a.pageSize,a.query,{sort:a.sort.attributeId,order:a.sort.direction});return(0,r.ZP)("GET",(0,n.DC)(u)).then(({elements:f,total:y,count:T,page:P,per_page:O,attributes:b})=>({list:f.map(L=>o.Z.fromJSON(L)),pagination:{total:y,count:T,page:P,perPage:O},attributes:b}))},E=(a,{enabled:u}={enabled:!0})=>{const{data:f,refetch:y,isInitialLoading:T}=(0,t.useQuery)(["dashboards","overview",a],()=>g(a),{onError:P=>{s.Z.error(`Loading dashboards failed with status: ${P}`,"Could not load dashboards")},keepPreviousData:!0,enabled:u});return{data:f!=null?f:v,refetch:y,isInitialLoading:T}}},qhwXAFlw:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("13uboeDm"),s=e.n(t),o=e("mTnbNx1k");const r=({type:v})=>`Untitled ${v.replace("_"," ").split(" ").map(s()).join(" ")}`,c=v=>((0,o.FZ)(v.type).titleGenerator||r)(v)},BQipOvpT:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("RTnJ3JrH"),n=e("J6y4/h8P");const c=n.default.span(({theme:a,$color:u})=>(0,n.css)` background-color: ${u}; color: ${a.utils.contrastingColor(u)}; width: fit-content; `),d=({children:a,color:u})=>t.createElement(c,{$color:u},a),g=({fieldName:a,fieldValue:u,highlightingRules:f=[]})=>f.filter(y=>y.field===a).find(y=>y.conditionFunc(u,y.value)),p=({children:a,field:u,value:f})=>{const y=(0,t.useContext)(r.Z),T=(0,t.useMemo)(()=>g({fieldName:u,fieldValue:f,highlightingRules:y}),[u,f,y]);return T?t.createElement(d,{color:T.color.colorFor(f)},a):a};p.propTypes={children:o().element,field:o().string.isRequired,value:o().any},p.defaultProps={children:void 0,value:void 0};const E=p},fh5GG281:(M,C,e)=>{"use strict";e.d(C,{Z:()=>Lt});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("VPaD/Np4"),n=e.n(r),c=e("GaFHk8Qk"),v=e.n(c),d=e("J6y4/h8P"),g=e("gSdhV+tG"),p=e("ty2gyrHp"),E=e("uZqmR+ju"),a=e("Wh5iba66"),u=e("hOf/Kwna"),f=e("Y2DdPzXi"),y=e("/GOzvPf6"),T=e("d4kzUuQm"),P=e("Xt0X5Kl4"),O=e("8fnsnG21"),b=e("PYFLluwn"),L=e("Vg8s2y9S");const x=d.default.span` word-break: 'break-word'; `,W=({nodeId:Be})=>{const lt=(0,O.o)(L.S,mt=>{var Rt;return(Rt=mt==null?void 0:mt.nodes)==null?void 0:Rt[Be]});if(lt){const mt=T.ZP.node(Be);return o.createElement(p.r,{to:mt},o.createElement(y.JO,{name:"circle-nodes"}),"\xA0",o.createElement(x,null,lt.short_node_id),"\xA0/\xA0",o.createElement(x,null,lt.hostname))}return o.createElement(x,null,"stopped node")};W.propTypes={nodeId:s().string.isRequired};const N=W;var Z=e("0hhBr0/b");const j=(Be,lt)=>{const mt=Be.get(lt);return mt?o.createElement("span",{style:{wordBreak:"break-word"}},mt.title):"deleted input"},ne=({isLocalNode:Be,inputs:lt,sourceInputId:mt,sourceNodeId:Rt})=>{var zt;const xt=(0,Z.Z)("forwarder"),nn=(zt=xt==null?void 0:xt[0])==null?void 0:zt.ForwarderReceivedBy;return Rt?Be===void 0?o.createElement(y.$j,null):Be===!1?o.createElement(nn,{inputId:mt,forwarderNodeId:Rt}):o.createElement("div",null,o.createElement("dt",null,"Received by"),o.createElement("dd",null,o.createElement("em",null,j(lt,mt))," ","on ",o.createElement(N,{nodeId:Rt}))):null};var Y=e("Jvb3Ez/Z"),ae=e("L2qXWCIB"),ee=e("orDZ6Vj2");const ue=(Be,lt,mt,Rt)=>{const zt="associated_assets";return Be((0,ae.Z)({queryId:lt,field:zt,value:mt,type:Rt}))},ye=({associated_assets:Be,fieldType:lt})=>{const mt=(0,Z.Z)("views.components.assetInformationActions"),Rt=(0,Y.Z)(),zt=(0,ee.Z)(),xt=o.useMemo(()=>mt.map(({component:nn})=>o.createElement(nn,{identifiers:Be,addToQuery:Vt=>ue(zt,Rt,Vt,lt)})),[mt,Be,zt,Rt,lt]);return Be.length===0?null:o.createElement("div",null,o.createElement("dt",null,"Associated Assets"),xt.map(nn=>o.createElement("div",{key:nn.props.identifiers[0]},nn)))};var we=e("XEgUer9K"),ut=e("hC1XaH+L"),ht=e("y2LHvPyS");const Re=({children:Be,message:lt})=>{const mt=(0,Z.Z)("views.components.widgets.messageDetails.contextProviders");return!mt||(mt==null?void 0:mt.length)===0?Be:mt.reduce((Rt,zt)=>o.createElement(ht.SV,{FallbackComponent:()=>Rt},o.createElement(zt,{message:lt},Rt)),Be)};var le=e("E9JT2cEW"),me=e("v4GbOr/o"),re=e("8OvTct/Z"),ce=e("0t7Ye+61"),Q=e("MdYBRjRJ");const J=(Be,lt,mt)=>{const Rt=(0,re.Z)(),zt=(0,ce.Z)(),xt=()=>{Rt(me.A.SEARCH_MESSAGE_TABLE_TEST_AGAINST_STREAM,{app_pathname:(0,Q.av)(zt.pathname),app_section:"search-message-table",app_action_value:"seach-message-table-test-against-stream"})},nn=Be.map(Vt=>Vt.is_default?o.createElement(E.MenuItem,{key:Vt.id,onClick:()=>xt(),disabled:!0,title:"Cannot test against the default stream"},Vt.title):o.createElement(p.J,{key:Vt.id,to:T.ZP.stream_edit_example(Vt.id,lt,mt)},o.createElement(E.MenuItem,{onClick:()=>xt()},Vt.title)));return o.createElement(E.DropdownButton,{pullRight:!0,bsSize:"small",title:"Test against stream",id:"select-stream-dropdown"},nn||o.createElement(E.MenuItem,{header:!0},"No streams available"))},ge=({index:Be,id:lt,fields:mt,decorationStats:Rt,disabled:zt,disableSurroundingSearch:xt,disableTestAgainstStream:nn,showOriginal:Vt,toggleShowOriginal:jn,streams:Mt,searchConfig:On})=>{const rt=(0,Z.Z)("views.components.widgets.messageTable.messageActions"),Bn=(0,o.useMemo)(()=>rt.map(({component:An,key:xe})=>o.createElement(An,{key:xe,id:lt,index:Be})),[lt,Be,rt]);if(zt)return o.createElement(E.ButtonGroup,{bsSize:"small"});const de=Be?T.ZP.message_show(Be,lt):"#",{timestamp:pt,...Gt}=mt,gn=xt||o.createElement(le.Z,{id:lt,timestamp:pt,searchConfig:On,messageFields:Gt}),Jt=Rt&&o.createElement(E.Button,{onClick:jn,active:Vt},"Show changes");return o.createElement(E.ButtonGroup,{bsSize:"small"},Jt,o.createElement(E.Button,{href:de},"Permalink"),Bn,o.createElement(y.mU,{title:"Copy ID",text:lt,bsSize:"small"}),o.createElement(y.mU,{title:"Copy message",bsSize:"small",text:JSON.stringify(mt,null,2)}),gn,nn?null:J(Mt,Be,lt))};var fe=e("AfN6xyeM"),Ce=e.n(fe),Oe=e("UeAH/0t7");const nt=(0,d.default)(Ce())` position: static !important; `,Fe=({message:Be})=>{const lt=(0,d.useTheme)(),mt=(0,Z.Z)("messageAugmentations"),zt=(0,o.useContext)(Oe.Z).width>=lt.breakpoints.px.max.md;return!mt||mt.length===0?null:o.createElement(nt,{boundaryElement:`#sticky-augmentations-boundary-${Be.id}`,disabled:!zt,positionRecheckInterval:400,scrollElement:"#sticky-augmentations-container"},o.createElement("dl",null,mt.map(({component:xt,id:nn})=>o.createElement(xt,{key:nn,message:Be}))))},$e=({timestamp:Be,receivedBy:lt,index:mt,streams:Rt,assets:zt})=>o.createElement(y.pb,null,Be,lt,o.createElement("dt",null,"Stored in index"),o.createElement("dd",null,mt||"Message is not stored"),Rt.size>0&&o.createElement(o.Fragment,null,o.createElement("dt",null,"Routed into streams"),o.createElement("dd",{className:"stream-list"},o.createElement("ul",null,Rt.toArray()))),zt),Ot=(Be,lt)=>Be?o.createElement(p.r,{to:T.ZP.message_show(Be,lt)},lt):o.createElement("span",null,lt," ",o.createElement(E.Label,{bsStyle:"warning"},"Not stored")),ft=d.default.div` display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px; `,Tt=({disableMessageActions:Be,disableSurroundingSearch:lt,disableTestAgainstStream:mt,expandAllRenderAsync:Rt,fields:zt,message:xt,streams:nn,inputs:Vt,showTimestamp:jn,allStreams:Mt})=>{var On;const{searchesClusterConfig:rt}=(0,O.o)(b.s),[Bn,de]=(0,o.useState)(!1),{fields:pt,index:Gt,id:gn,decoration_stats:Jt}=xt,{gl2_source_node:An,gl2_source_input:xe,associated_assets:Pn}=pt,{isLocalNode:sn}=(0,we.Z)(An),no=(0,o.useMemo)(()=>({isLocalNode:sn}),[sn]),{all:Co}=(0,o.useContext)(ut.Z),Go=()=>{de(!Bn)},Mo=(0,o.useCallback)(Ke=>Co.find(dt=>dt.name===Ke),[Co]);if(Rt)return o.createElement(E.Row,null,o.createElement(E.Col,{md:12},o.createElement(y.$j,null)));const Zt=n().Set(pt.streams).map(Ke=>{const dt=nn.get(Ke);return dt!==void 0?o.createElement("li",{key:dt.id},o.createElement(a.Z,{stream:dt})):null}).toSet();let Me=null;if(jn){Me=[];const Ke=pt.timestamp;Me.push(o.createElement("dt",{key:`dt-${Ke}`},"Timestamp")),Me.push(o.createElement("dd",{key:`dd-${Ke}`},o.createElement(y.EK,{dateTime:Ke,format:"complete"})))}const Ye=Ot(Gt,gn);return o.createElement(g.v.Provider,{value:no},o.createElement(Re,{message:xt},o.createElement(o.Fragment,null,o.createElement(E.Row,{className:"row-sm"},o.createElement(E.Col,{md:12},o.createElement(ft,null,o.createElement(f.Z,null,o.createElement(y.JO,{name:"envelope"}),"\xA0",Ye),o.createElement(ge,{index:Gt,id:gn,fields:pt,decorationStats:Jt,disabled:Be,disableSurroundingSearch:lt,disableTestAgainstStream:mt,showOriginal:Bn,toggleShowOriginal:Go,searchConfig:rt,streams:Mt})))),o.createElement(E.Row,{id:`sticky-augmentations-boundary-${xt.id}`},o.createElement(E.Col,{md:3},o.createElement($e,{timestamp:Me,index:Gt,receivedBy:o.createElement(ne,{isLocalNode:sn,inputs:Vt,sourceNodeId:An,sourceInputId:xe}),streams:Zt,assets:Pn?o.createElement(ye,{associated_assets:Pn,fieldType:(On=Mo("associated_assets"))==null?void 0:On.type}):o.createElement("div",null)}),o.createElement(Fe,{message:xt})),o.createElement(E.Col,{md:9},o.createElement(u.T$,{message:xt,fields:zt}))))))};Tt.propTypes={allStreams:v().list,disableMessageActions:s().bool,disableSurroundingSearch:s().bool,disableTestAgainstStream:s().bool,expandAllRenderAsync:s().bool,fields:v().list,inputs:v().map,message:P.Z.Message.isRequired,showTimestamp:s().bool,streams:v().map},Tt.defaultProps={allStreams:n().List(),disableMessageActions:!1,disableSurroundingSearch:!1,disableTestAgainstStream:!1,expandAllRenderAsync:!1,fields:n().List(),inputs:n().Map(),showTimestamp:!0,streams:n().Map()};const Lt=Tt},y5LMk7Rh:(M,C,e)=>{"use strict";e.d(C,{Z:()=>ee});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("gSdhV+tG"),n=e("nxMFMmDQ"),c=e("w7+AQV2V"),v=e.n(c),d=e("PpCK0BgN"),g=e.n(d),p=e("J6y4/h8P"),E=e("TJOheZRu"),a=e("7J1sc9Ol"),u=e("9pdI12pI"),f=e.n(u);const T=ue=>f()(ue).format("0,0.[0000000]"),O=ue=>typeof ue=="number"?!0:typeof ue!="string"||ue.trim()===""?!1:!Number.isNaN(Number(ue)),b=(ue,H,ye={})=>t.createElement("span",{key:`highlight-${H}`,style:ye},ue);function L(ue,H){if(ue.length!==1)return!1;const{start:ye,length:we}=ue[0],ut=E.Z.stringify(H);return ye===0&&we===ut.length}const x=(ue,H)=>(0,a.mf)(ue)&&O(H),W=({color:ue=n.kX,field:H,value:ye,highlightRanges:we={}})=>{const ut=(0,p.useTheme)();if(ye==null)return"";if(!we||!we[H])return x(H,ye)?T(ye):ye;const ht=ue.colorFor(ye),Je={backgroundColor:ht,color:ut.utils.contrastingColor(ht),padding:"0 1px"};if(L(we[H],ye)){const J=x(H,ye)?T(ye):ye;return b(J,0,Je)}const Re=E.Z.stringify(ye),le=g()(we[H],J=>J.start),me=(J,ie)=>Re.substring(J,J+ie),re=J=>Re.substring(J,Re.length),ce=le.filter(({start:J})=>J>=0).filter(({length:J})=>J>=0).reduce(([J,ie],ge,fe)=>[[...J,me(ie,Math.max(0,ge.start-ie)),b(me(Math.max(ge.start,ie),Math.max(0,ge.length-Math.max(0,ie-ge.start))),fe,Je)],ge.start+ge.length],[[],0])[0],Q=v()(g()(le,J=>J.start+J.length));return ce.push(re(Q.start+Q.length)),t.createElement("div",null,ce)};W.propTypes={color:o().object,field:o().string.isRequired,value:o().any,highlightRanges:o().object},W.defaultProps={color:n.kX,highlightRanges:{},value:void 0};const N=W,Z=({field:ue,value:H})=>t.createElement(r.v.Consumer,null,({message:ye})=>t.createElement(N,{field:ue,color:n.kX,value:H,highlightRanges:ye==null?void 0:ye.highlight_ranges}));Z.propTypes={field:o().string.isRequired,value:o().any.isRequired};const j=Z,ne=t.createContext([j]),Y=ue=>({value:ye,...we})=>t.createElement(t.Fragment,null,ue.reduce((ut,ht)=>t.createElement(ht,{...we,value:ye},ut),null)),ee=ue=>t.createElement(ne.Consumer,null,H=>{const ye=Y(H);return t.createElement(ye,{...ue})})},"H1J/o4st":(M,C,e)=>{"use strict";e.d(C,{Z:()=>L});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("kqAR+wt5"),n=e.n(r),c=e("J6y4/h8P"),v=e("Jg5wVMAu"),d=e.n(v),g=e("+qc3iAHh"),p=e("/GOzvPf6"),E=e("fc14XwmC"),a=e("uZqmR+ju"),u=e("7dh0vSOR"),f=e("E+CaPsQD"),y=e("mSSPPdLK");const T=()=>{const x=o.createElement(a.Popover,{id:"decorators-help",className:y.Z.helpPopover},o.createElement("p",{className:"description"},"Decorators can modify messages shown in the search results on the fly. These changes are not stored, but only shown in the search results. Decorator config is stored ",o.createElement("strong",null,"per stream"),"."),o.createElement("p",{className:"description"},"Use drag and drop to modify the order in which decorators are processed."),o.createElement("p",null,"Read more about message decorators in the ",o.createElement(u.Z,{page:f.Z.PAGES.DECORATORS,text:"documentation"}),"."));return o.createElement(p.Ox,{trigger:"click",rootClose:!0,placement:"right",overlay:x},o.createElement(a.Button,{bsStyle:"link",className:y.Z.helpLink},"What are message decorators?"))};T.propTypes={};const P=T,O=c.default.div(({theme:x})=>(0,c.css)` margin-bottom: 10px; margin-top: 10px; margin-left: 5px; display: inline-block; border-style: solid; border-color: ${x.colors.gray[80]}; border-radius: 5px; border-width: 1px; padding: 10px; background: ${x.colors.global.background}; `);class b extends o.Component{constructor(W){super(W),this._formatDecoratorType=(N,Z)=>({value:Z,label:N.name}),this._handleCancel=()=>this.setState({typeName:void 0,typeDefinition:void 0}),this._handleSubmit=N=>{const{stream:Z,nextOrder:j,onCreate:z}=this.props,ne={id:new(d())().toString(),stream:Z,type:N.type,config:N.configuration,order:j};z(ne),this.setState({typeName:void 0})},this._openModal=()=>{var N,Z;return(Z=(N=this.configurationForm)==null?void 0:N.current)==null?void 0:Z.open()},this._onTypeChange=N=>{const{decoratorTypes:Z}=this.props;this.setState({typeName:N}),Z[N]?this.setState({typeDefinition:Z[N]}):this.setState({typeDefinition:{}})},this.configurationForm=o.createRef(),this.state={}}render(){const{typeDefinition:W,typeName:N}=this.state,{decoratorTypes:Z,disabled:j,showHelp:z=!0}=this.props,ne=n().map(Z,this._formatDecoratorType),Y=(0,E.Z)(),ae=N!==void 0?o.createElement(g.fI,{ref:this.configurationForm,key:"configuration-form-output",configFields:W.requested_configuration,title:`Create new ${W.name}`,typeName:N,includeTitleField:!1,wrapperComponent:Y,submitAction:this._handleSubmit,cancelAction:this._handleCancel}):null;return o.createElement(o.Fragment,null,o.createElement("div",{className:`${y.Z.decoratorBox} ${y.Z.addDecoratorButtonContainer}`},o.createElement("div",{className:y.Z.addDecoratorSelect},o.createElement(p.Ph,{placeholder:"Select decorator",onChange:this._onTypeChange,options:ne,matchProp:"label",disabled:j,value:N}))),z&&o.createElement(P,null),N&&o.createElement(O,null,ae))}}b.propTypes={decoratorTypes:s().object.isRequired,nextOrder:s().number.isRequired,stream:s().string,disabled:s().bool,onCreate:s().func.isRequired,showHelp:s().bool},b.defaultProps={disabled:!1,showHelp:!0,stream:null};const L=b},B6AO2vlN:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("J6y4/h8P"),n=e("uZqmR+ju"),c=e("/GOzvPf6"),v=e("mSSPPdLK");const d=r.default.div` margin-bottom: 20px; `;class g extends o.Component{constructor(){super(...arguments),this._onReorderWrapper=a=>{const{onReorder:u}=this.props;u(a)}}render(){const{decorators:a,disableDragging:u}=this.props;return!a||a.length===0?o.createElement(d,null,o.createElement(n.Alert,{bsStyle:"info",className:v.Z.noDecoratorsAlert},"No decorators configured.")):o.createElement(c.cm,{items:a,onMoveItem:this._onReorderWrapper,disableDragging:u,displayOverlayInPortal:!0})}}g.propTypes={decorators:s().arrayOf(s().object).isRequired,disableDragging:s().bool,onReorder:s().func},g.defaultProps={disableDragging:!1,onReorder:()=>{}};const p=g},"0l+/Cv54":(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("ii0bleBb"),s=e.n(t),o=e("Z7aTuO5B"),r=e("J6y4/h8P"),n=e("uZqmR+ju"),c=e("+qc3iAHh"),v=e("fc14XwmC"),d=e("mSSPPdLK");const g=r.default.div` margin-left: 5px; `;class p extends o.Component{constructor(u){super(u),this._handleDeleteClick=()=>{const{onDelete:f,decorator:y}=this.props;window.confirm("Do you really want to delete this decorator?")&&f(y.id)},this._handleEditClick=()=>{this.setState({editing:!0})},this._closeEditForm=()=>{this.setState({editing:!1})},this._handleSubmit=f=>{const{decorator:y}=this.props,{stream:T,id:P,order:O}=y,{onUpdate:b}=this.props;b(P,{id:P,type:f.type,config:f.configuration,order:O,stream:T}),this._closeEditForm()},this._resolveConfigurationIds=f=>{const{typeDefinition:y}=this.props,T=y.requested_configuration,P={};return Object.keys(f).forEach(b=>{const L=T[b]?T[b].additional_info.values:void 0,x=f[b];L&&L[x]&&(P[b]=L[x])}),{...f,...P}},this._formatActionsMenu=()=>{const{decorator:f}=this.props;return o.createElement(g,null,o.createElement(n.DropdownButton,{id:`decorator-${f.id}-actions`,bsStyle:"default",bsSize:"xsmall",title:"Actions"},o.createElement(n.MenuItem,{onSelect:this._handleEditClick},"Edit"),o.createElement(n.MenuItem,{divider:!0}),o.createElement(n.MenuItem,{onSelect:this._handleDeleteClick},"Delete")))},this.state={editing:!1}}render(){const{disableMenu:u=!1,decorator:f,decoratorTypes:y,typeDefinition:T}=this.props,{editing:P}=this.state,O=this._resolveConfigurationIds(f.config),b=y[f.type]||{name:"Unknown decorator type"},L=u||this._formatActionsMenu(),{name:x,requested_configuration:W}=T,N=(0,v.Z)("Update"),Z=f.id||"new",j=P?o.createElement(c.fI,{key:"configuration-form-decorator",configFields:W,title:`Edit ${x}`,typeName:f.type,includeTitleField:!1,submitAction:this._handleSubmit,cancelAction:this._closeEditForm,wrapperComponent:N,values:f.config}):o.createElement(c.$O,{key:`configuration-well-decorator-${Z}`,id:Z,configuration:O,typeDefinition:T});return o.createElement("span",{className:d.Z.fixedWidth},o.createElement("div",{className:d.Z.decoratorBox},o.createElement("h6",null,b.name),L),j)}}p.propTypes={decorator:s().object.isRequired,decoratorTypes:s().object.isRequired,disableMenu:s().bool,typeDefinition:s().object.isRequired,onDelete:s().func.isRequired,onUpdate:s().func.isRequired},p.defaultProps={disableMenu:!1};const E=p},fc14XwmC:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("uZqmR+ju");const r=(n="Create")=>t.forwardRef(({children:c,disabled:v,onCancel:d,onSubmitForm:g},p)=>{const E=a=>{a.stopPropagation();const{target:u}=a;if(typeof u.checkValidity=="function"&&!u.checkValidity()){a.preventDefault();return}typeof g=="function"&&(a.preventDefault(),g(a))};return t.createElement("form",{onSubmit:E,ref:p},c,t.createElement(s.Button,{type:"submit",bsStyle:"success",disabled:v},n)," ",t.createElement(s.Button,{type:"button",disabled:v,onClick:d},"Cancel"))})},"hOf/Kwna":(M,C,e)=>{"use strict";e.d(C,{T$:()=>Z,y$:()=>et});var t=e("fh5GG281"),s=e("ii0bleBb"),o=e.n(s),r=e("Z7aTuO5B"),n=e("J6y4/h8P"),c=e("SnOQy/BL"),v=e("UPOvISKg"),d=e("jlRcBdjT"),g=e("nxMFMmDQ"),p=e("Jvb3Ez/Z"),E=e("y5LMk7Rh"),a=e("Xt0X5Kl4"),u=e("GFJVQ2dX");const f=[g.TI,"level"],y=n.default.small(({theme:Fe})=>(0,n.css)` color: ${Fe.colors.gray[70]}; font-weight: normal; `),T=n.default.dd(({theme:Fe})=>` font-family: ${Fe.fonts.family.monospace}; `),P=({fieldName:Fe,fieldType:Pe,message:$e,value:Ot})=>{const ft=f.indexOf(Fe)!==-1?$e.fields[Fe]:Ot,Tt=(0,p.Z)(),{decoration_stats:Lt={added_fields:{},changed_fields:{},removed_fields:{}}}=$e,Be=Lt&&(Lt.added_fields[Fe]!==void 0||Lt.changed_fields[Fe]!==void 0),lt=Be?({children:mt})=>r.createElement(u.Z.Provider,{value:!1},mt," ",r.createElement(y,null,"(decorated)")):({children:mt})=>mt;return r.createElement(r.Fragment,null,r.createElement("dt",{"data-testid":`message-field-name-${Fe}`},r.createElement(c.Z,{queryId:Tt,name:Fe,type:Be?d.ZP.Decorated:Pe},Fe)),r.createElement(T,{"data-testid":`message-field-value-${Fe}`},r.createElement(lt,null,r.createElement(v.Z,{field:Fe,value:ft,type:Be?d.ZP.Decorated:Pe,render:E.Z}))))};P.propTypes={fieldName:o().string.isRequired,fieldType:a.Z.FieldType.isRequired,message:a.Z.Message.isRequired,value:o().any.isRequired};const O=P;var b=e("/GOzvPf6"),L=e("8Crd7QGv"),x=e("BQipOvpT");const W=(0,n.default)(b.pb)(({theme:Fe})=>(0,n.css)` color: ${Fe.colors.global.textDefault}; dd { &:not(:last-child) { border-bottom: 1px solid ${Fe.colors.gray[90]}; } } `),Z=({message:Fe,fields:Pe})=>{const $e=Fe.formatted_fields,Ot=Object.keys($e).sort().map(ft=>{const{type:Tt}=Pe.find(Lt=>Lt.name===ft,void 0,L.Z.create(ft,d.ZP.Unknown));return r.createElement(x.Z,{key:ft,field:ft,value:$e[ft]},r.createElement(O,{fieldName:ft,fieldType:Tt,message:Fe,value:$e[ft]}))});return r.createElement(W,{className:"message-details-fields"},Ot)};var j=e("VPaD/Np4"),z=e("gSdhV+tG"),ne=e("8fnsnG21"),Y=e("Cd4wX32x"),ae=e("yEuO7gC5"),ee=e("8OvTct/Z"),ue=e("v4GbOr/o"),H=e("MdYBRjRJ"),ye=e("0t7Ye+61"),we=e("0hhBr0/b"),ut=e("/zlmJemQ");const ht=n.default.div` white-space: pre-line; max-height: 6em; /* show 4 lines: line-height * 4 */ overflow: hidden; `,Re=({message:Fe,messageFieldType:Pe})=>r.createElement(ht,null,r.createElement(x.Z,{field:"message",value:Fe.fields[g.ZA]},r.createElement(ut.Z,{field:"message",value:Fe.fields[g.ZA],type:Pe,render:E.Z}))),le=n.default.tr(({theme:Fe})=>(0,n.css)` && { cursor: pointer; td { border-top: 0; padding-top: 0; padding-bottom: 4px; font-family: ${Fe.fonts.family.monospace}; color: ${Fe.colors.variant.dark.info}; } } `),me=(Fe,Pe)=>r.createElement(Re,{message:Fe,messageFieldType:Pe}),re=({onRowClick:Fe,colSpanFixup:Pe,message:$e,messageFieldType:Ot,showMessageRow:ft,config:Tt})=>{var Lt;const Be=(Lt=(0,we.Z)("views.components.widgets.messageTable.messageRowOverride"))==null?void 0:Lt[0];return r.createElement(le,{onClick:Fe},r.createElement("td",{colSpan:Pe},ft&&!!Be&&r.createElement(Be,{messageFields:$e.fields,config:Tt,renderMessageRow:()=>me($e,Ot)}),ft&&!Be&&me($e,Ot)))};re.defaultProps={showMessageRow:!1};const ce=re;var Q=e("5CYElDLi");const J=n.default.tbody(({$expanded:Fe,$highlighted:Pe,theme:$e})=>` && { border-top: 0; ${Fe?(0,n.css)` border-left: 7px solid ${$e.colors.variant.light.info}; `:""} ${Pe?(0,n.css)` border-left: 7px solid ${$e.colors.variant.light.success}; `:""} } `),ie=n.default.tr` cursor: pointer; && td { min-width: 50px; word-break: break-word; padding: 4px 5px 2px; } time { line-height: 1; } `,ge=n.default.tr` td { padding-top: 5px; border-top: 0; } .row { margin-right: 0; } div[class*='col-'] { padding-right: 0; } `,fe=(Fe,Pe)=>Pe&&(Pe.added_fields[Fe]!==void 0||Pe.changed_fields[Fe]!==void 0),Ce=(Fe,{decoration_stats:Pe},$e)=>fe(Fe,Pe)?d.ZP.Decorated:($e&&$e.find(Ot=>Ot.name===Fe)||{type:d.ZP.Unknown}).type,Oe=(Fe,Pe=!1)=>Pe?r.createElement("strong",null,Fe):Fe,nt=({config:Fe,disableSurroundingSearch:Pe,expandAllRenderAsync:$e,expanded:Ot,fields:ft,message:Tt,showMessageRow:Lt,selectedFields:Be=j.OrderedSet(),toggleDetail:lt})=>{const{inputs:mt=[]}=(0,ne.o)(ae.Q),{streams:Rt=[]}=(0,ne.o)(Y.h),zt=(0,r.useContext)(Q.Z),xt=(0,ye.Z)(),nn=(0,ee.Z)(),Vt=(0,r.useMemo)(()=>({message:Tt}),[Tt]),jn=j.List(Rt),Mt=j.Map(Rt.map(de=>[de.id,de])),On=j.Map(mt.map(de=>[de.id,de])),rt=()=>{var de;!!((de=window.getSelection())!=null&&de.toString())||(nn(ue.A.SEARCH_MESSAGE_TABLE_DETAILS_TOGGLED,{app_pathname:(0,H.av)(xt.pathname),app_section:"widget",app_action_value:"widget-message-table-toggle-details"}),lt(`${Tt.index}-${Tt.id}`))},Bn=Be.size+1;return r.createElement(z.v.Provider,{value:Vt},r.createElement(J,{$expanded:Ot,$highlighted:Tt.id===zt},r.createElement(ie,{onClick:rt},Be.toArray().map((de,pt)=>{const Gt=Ce(de,Tt,ft);return r.createElement("td",{key:de,"data-testid":`message-summary-field-${de}`},Oe(r.createElement(x.Z,{field:de,value:Tt.fields[de]},r.createElement(ut.Z,{value:Tt.fields[de],field:de,type:Gt,render:E.Z})),pt===0))})),r.createElement(ce,{showMessageRow:Lt,config:Fe,colSpanFixup:Bn,messageFieldType:Ce(g.ZA,Tt,ft),onRowClick:rt,message:Tt}),Ot&&r.createElement(ge,null,r.createElement("td",{colSpan:Bn},r.createElement(t.Z,{message:Tt,fields:ft,streams:Mt,allStreams:jn,inputs:On,disableSurroundingSearch:Pe,expandAllRenderAsync:$e})))))};nt.propTypes={disableSurroundingSearch:o().bool,expandAllRenderAsync:o().bool.isRequired,expanded:o().bool.isRequired,fields:o().object.isRequired,message:o().shape({fields:o().object.isRequired,highlight_ranges:o().object,id:o().string.isRequired,index:o().string.isRequired,decoration_stats:o().shape({added_fields:o().object,changed_fields:o().object,removed_fields:o().object})}).isRequired,selectedFields:o().instanceOf(j.OrderedSet),showMessageRow:o().bool,toggleDetail:o().func.isRequired},nt.defaultProps={disableSurroundingSearch:!1,selectedFields:j.OrderedSet(),showMessageRow:!1};const et=nt},xsbnunTq:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("UmnljV2q"),o=e("xudoaDQq");const n=({children:c})=>(0,o.Z)()===s.Z.Type.Search?t.createElement(t.Fragment,null,c):null},"2XdKdJGP":(M,C,e)=>{"use strict";e.d(C,{Fy:()=>d,M8:()=>v,V:()=>o,Vi:()=>r,dD:()=>n,hF:()=>c});var t=e("J6y4/h8P"),s=e("/GOzvPf6");const o="10px",r=(0,t.default)(s.q)` display: flex; flex-direction: column; gap: ${o}; `,n=t.default.div(({theme:g})=>(0,t.css)` display: flex; gap: ${o}; align-items: flex-start; @media (max-width: ${g.breakpoints.max.sm}) { flex-direction: column; > div { width: 100%; } } `),c=t.default.div` flex: 1; display: flex; align-items: flex-start; gap: ${o}; `,v=t.default.div` display: flex; flex: 1; `,d=t.default.div(({theme:g})=>(0,t.css)` display: flex; gap: ${o}; align-items: flex-start; @media (max-width: ${g.breakpoints.max.md}) { flex-direction: column; > div { width: 100%; } } `)},"2MZA4BUT":(M,C,e)=>{"use strict";e.d(C,{ZP:()=>a,a$:()=>c,w6:()=>g});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("PwTFiGSp"),r=e("Ii+QL2UH"),n=e("vT7mdtQI");const c="----/--/-- --:--:--.---",v={from:c,until:c},d=s.default.div(({theme:u})=>(0,s.css)` width: 100%; padding: 3px 13px; display: flex; justify-content: space-around; background-color: ${u.colors.table.backgroundAlt}; align-items: center; > span { flex: 1; } `),g=u=>{let f=c,y=c;if(!(u!=null&&u.type))return v;const{type:T}=u;switch(T){case"relative":return(0,o.a_)(u)&&(f=(0,r.U)(u,"range")),(0,o.SP)(u)&&(f=(0,r.U)(u,"from")),y=(0,r.U)(u,"to","Now"),{from:f,until:y};case"absolute":return{from:u.from,until:u.to};default:return(0,n.Z)(T,"Invalid time range type")}},p=({timerange:u})=>{if((0,o.je)(u))return t.createElement("span",null,"Keyword: ",t.createElement("b",null,u.keyword));const{from:f,until:y}=g(u);return t.createElement(t.Fragment,null,t.createElement("span",{"data-testid":"from"},"From: ",t.createElement("b",null,f)),t.createElement("span",{"data-testid":"to"},"Until: ",t.createElement("b",null,y)))},E=({timerange:u,toggleDropdownShow:f})=>t.createElement(d,{"aria-label":"Search Time Range, Opens Time Range Selector On Click",role:"button",onClick:f},(0,o.j9)(u)?t.createElement("span",null,"No Override"):t.createElement(p,{timerange:u}));E.defaultProps={toggleDropdownShow:void 0};const a=E},f2ImtPH2:(M,C,e)=>{"use strict";e.d(C,{Z:()=>qn});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("VgplIV7d"),c=e("2XdKdJGP"),v=e("8OvTct/Z"),d=e("GPuPro0F"),g=e("UiXZqrDE"),p=e("9oVghaOd"),E=e.n(p),a=e("uZqmR+ju"),u=e("/GOzvPf6"),f=e("PwTFiGSp"),y=e("QV1daZoe"),T=e("tITy3x4L"),P=e("O/XpfGnR"),O=e("MdYBRjRJ"),b=e("0t7Ye+61"),L=e("v4GbOr/o"),x=e("z45xmHGk"),W=e("nxMFMmDQ");const N=be=>(0,x.vQ)(be)?(0,x.Pp)(be.from):W.lY,Z=be=>(0,x.vQ)(be)?(0,x.Pp)(be.to):0,j={absolute:(be,ze)=>({type:"absolute",from:ze(E()().subtract(N(be),"seconds"),"complete"),to:ze(E()().subtract(Z(be),"seconds"),"complete")}),relative:()=>({type:"relative",from:(0,x.ny)(W.lY),to:x.RU}),keyword:()=>({type:"keyword",keyword:"Last five minutes"}),disabled:()=>{}},ne=(be,ze,Ve)=>{const We=be&&"type"in be?be.type:"disabled";if(ze===We)return be;if(!j[ze])throw new Error(`Invalid time range type: ${ze}`);return j[ze](be,Ve)};var Y=e("IZYxBTgT"),ae=e("awUYZK9l");const ee=({dateTime:be,onChange:ze,startDate:Ve})=>{const{userTimezone:We,formatTime:vt}=(0,P.Z)(),Et=(0,Y.U2)(be,We),At=Ct=>{if(Ve&&ae.ED.isDayBefore(Ct,Ve))return!1;const Kt=(0,Y.rG)(Ct),en=Et.set({year:Kt.year(),month:Kt.month(),date:Kt.date()});return ze(vt(en,"default"))};return t.createElement(u.Mt,{date:Et,onChange:At,fromDate:Ve})};ee.propTypes={dateTime:o().string.isRequired,onChange:o().func,startDate:o().instanceOf(Date)},ee.defaultProps={onChange:()=>{},startDate:void 0};const ue=ee,H="hourglass-start",ye="hourglass-half",we="hourglass-end",ut=["hours","minutes","seconds","milliseconds"],ht=r.default.div` display: flex; align-items: center; justify-content: center; flex: 1; padding-top: 12px; b { padding: 0 3px; } `,Je=(0,r.default)(a.FormControl)` padding: 0 6px 0 9px; &:nth-of-type(1) { grid-area: 2 / 2 / 2 / 2; } &:nth-of-type(2) { grid-area: 2 / 4 / 2 / 4; } &:nth-of-type(3) { grid-area: 2 / 6 / 2 / 6; } `,Re=(0,r.default)(a.InputGroup.Addon)(({theme:be})=>(0,r.css)` padding: 0; background: ${be.colors.variant.lightest.default}; font-weight: bold; width: auto; display: flex; align-items: center; &:not(:first-child, :last-child) { border-right: 0; border-left: 0; padding: 0 3px; } &:nth-of-type(1) { grid-area: 2 / 1 / 2 / 1; } &:nth-of-type(2) { grid-area: 2 / 3 / 2 / 3; } &:nth-of-type(3) { grid-area: 2 / 5 / 2 / 5; } &:nth-of-type(4) { grid-area: 2 / 7 / 2 / 7; } `),le=(0,r.default)(a.Button)` padding: 6px 9px; line-height: 1; `,me=(0,r.default)(a.FormGroup)` display: grid; grid-template-columns: max-content repeat(3, 1fr max-content); grid-template-rows: auto 1fr; label { padding-left: 6px; margin: 0; &:nth-child(1) { grid-area: 1 / 2 / 1 / 2; } &:nth-child(2) { grid-area: 1 / 4 / 1 / 4; } &:nth-child(3) { grid-area: 1 / 6 / 1 / 6; } } `,re=(0,r.default)(a.InputGroup)` display: contents; `,ce=be=>{be.target.select()},Q=(be,ze=2)=>String(be).padStart(ze,"0"),J=(be,ze)=>{const Ve=be.match(/[^0-9]/g),We=Number(Ve?0:be);if(ze==="hours"){if(We>23)return 23}else if(We>59)return 59;return We},ie=(be,ze)=>{const Ve=E()(be).toObject();return ut.forEach(At=>{Ve[At]=Q(Ve[At])}),{initialDateTime:Ve,handleChangeSetTime:At=>{const Ct=At.target.getAttribute("id").split("-").pop(),Kt=J(At.target.value,Ct);return E()({...Ve,[Ct]:Kt}).format(Y.eZ.default)},handleClickTimeNow:()=>{const At=ze(new Date).toObject();return E()({...Ve,hours:At.hours,minutes:At.minutes,seconds:At.seconds}).format(Y.eZ.default)},handleTimeToggle:(At=!1)=>E()({...Ve,hours:At?23:0,minutes:At?59:0,seconds:At?59:0}).format(Y.eZ.default)}},ge=({dateTime:be,range:ze,onChange:Ve})=>{var We,vt,Et;const At=(0,t.useRef)(ye),{toUserTimezone:Ct}=(0,P.Z)(),{initialDateTime:Kt,handleChangeSetTime:en,handleClickTimeNow:dn,handleTimeToggle:En}=ie(be,Ct),xn=Dn=>{At.current=ye,Ve(en(Dn))},zn=()=>{const Dn=At.current===H;Dn?At.current=we:At.current=H,Ve(En(Dn))},fn=()=>{At.current=ye,Ve(dn())};return t.createElement(ht,null,t.createElement(me,null,t.createElement("label",{htmlFor:`${ze}-time-hours`,title:`${ze} hours label`},"HH"),t.createElement("label",{htmlFor:`${ze}-time-minutes`,title:`${ze} minutes label`},"mm"),t.createElement("label",{htmlFor:`${ze}-time-seconds`,title:`${ze} seconds label`},"ss"),t.createElement(re,null,t.createElement(Re,null,t.createElement(le,{bsStyle:"link",bsSize:"small",onClick:zn,title:"Toggle between beginning and end of day"},t.createElement(u.JO,{name:At.current}))),t.createElement(Je,{type:"number",id:`${ze}-time-hours`,title:`${ze} hour`,value:(We=Kt.hours)!=null?We:"",onChange:xn,onFocus:ce,bsSize:"sm"}),t.createElement(Re,null,":"),t.createElement(Je,{type:"number",id:`${ze}-time-minutes`,title:`${ze} minutes`,value:(vt=Kt.minutes)!=null?vt:"",onChange:xn,onFocus:ce,bsSize:"sm"}),t.createElement(Re,null,":"),t.createElement(Je,{type:"number",id:`${ze}-time-seconds`,title:`${ze} seconds`,value:(Et=Kt.seconds)!=null?Et:"",onChange:xn,onFocus:ce,bsSize:"sm"}),t.createElement(Re,null,t.createElement(le,{bsStyle:"link",bsSize:"small",onClick:fn,title:"Set to current local time"},t.createElement(u.JO,{name:"magic"}))))))};ge.propTypes={dateTime:o().string.isRequired,range:o().string.isRequired,onChange:o().func},ge.defaultProps={onChange:()=>{}};const fe=ge,Ce=r.default.span(({theme:be})=>(0,r.css)` color: ${be.colors.variant.dark.danger}; font-size: ${be.fonts.size.small}; font-style: italic; padding: 3px 3px 9px; height: 1.5em; `),Oe=({startDate:be,timeRange:ze,range:Ve})=>t.createElement(g.Field,{name:`timeRangeTabs.absolute.${Ve}`},({field:{value:We,onChange:vt,name:Et},meta:{error:At}})=>{const Ct=en=>vt({target:{name:Et,value:en}}),Kt=At?ze[Ve]:We||ze[Ve];return t.createElement(t.Fragment,null,t.createElement(ue,{onChange:Ct,startDate:be,dateTime:Kt}),t.createElement(fe,{onChange:Ct,range:Ve,dateTime:Kt}),t.createElement(Ce,null,At))});Oe.propTypes={timeRange:o().shape({from:o().string,to:o().string}).isRequired,startDate:o().instanceOf(Date),range:o().oneOf(["to","from"]).isRequired},Oe.defaultProps={startDate:void 0};const nt=Oe;var et=e("Y15zKX1V");const Fe=r.default.span(({theme:be})=>(0,r.css)` color: ${be.colors.variant.dark.danger}; font-size: ${be.fonts.size.small}; font-style: italic; padding: 3px 3px 9px; height: 1.5em; `),Pe=({disabled:be,timeRange:ze,range:Ve})=>t.createElement(g.Field,{name:`timeRangeTabs.absolute.${Ve}`},({field:{value:We,onChange:vt,name:Et},meta:{error:At}})=>{const Ct=en=>vt({target:{name:Et,value:en}}),Kt=At?ze[Ve]:We||ze[Ve];return t.createElement(t.Fragment,null,t.createElement(et.Z,{name:Et,disabled:be,value:Kt,onChange:Ct}),t.createElement(Fe,null,At))});Pe.propTypes={disabled:o().bool,timeRange:o().shape({from:o().string,to:o().string}).isRequired,range:o().oneOf(["to","from"]).isRequired},Pe.defaultProps={disabled:!1};const $e=Pe,Ot=r.default.div` display: flex; align-items: stretch; justify-content: space-around; `,ft=r.default.div` flex: 4; align-items: center; display: flex; flex-direction: column; .DayPicker-wrapper { padding-bottom: 0; } `,Tt=r.default.div` flex: 0.75; display: flex; align-items: center; justify-content: center; transform: translateY(-0.65em); `,Lt=(0,r.default)(u.UQ)` width: 100%; .panel-body { display: flex; } `,Be=r.default.div` flex: 1; `,lt=r.default.div` display: flex; `,mt=({disabled:be,limitDuration:ze})=>{const{values:{timeRangeTabs:Ve}}=(0,g.useFormikContext)(),We=Ve.absolute,{toUserTimezone:vt}=(0,P.Z)(),[Et,At]=(0,t.useState)(),Ct=E()(We.from).toDate(),Kt=ze?vt(new Date).seconds(-ze).toDate():void 0,en=dn=>{At(dn!=null?dn:Et)};return t.createElement(Ot,null,t.createElement(Lt,{defaultActiveKey:"calendar",onSelect:en,id:"absolute-time-ranges","data-testid":"absolute-time-ranges",activeKey:Et},t.createElement(u.Qd,{name:"Calendar"},t.createElement(ft,null,t.createElement(nt,{startDate:Kt,timeRange:We,range:"from"})),t.createElement(Tt,null,t.createElement(u.JO,{name:"arrow-right"})),t.createElement(ft,null,t.createElement(nt,{startDate:Ct,timeRange:We,range:"to"}))),t.createElement(u.Qd,{name:"Timestamp"},t.createElement(Be,null,t.createElement("p",null,"Date should be formatted as ",t.createElement("code",null,"YYYY-MM-DD [HH:mm:ss[.SSS]]"),"."),t.createElement(lt,null,t.createElement(ft,null,t.createElement($e,{disabled:be,timeRange:We,range:"from"})),t.createElement(Tt,null,t.createElement(u.JO,{name:"arrow-right"})),t.createElement(ft,null,t.createElement($e,{disabled:be,timeRange:We,range:"to"})))))))};mt.propTypes={disabled:o().bool,limitDuration:o().number},mt.defaultProps={disabled:!1,limitDuration:0};const Rt=mt;var zt=e("sWSSTOXR"),xt=e.n(zt),nn=e("+KM7MH1U"),Vt=e.n(nn),jn=e("7dh0vSOR"),Mt=e("E+CaPsQD"),On=e("yTnlRDNA"),rt=e("2MZA4BUT");const Bn=r.default.h3` margin-bottom: 5px; `,de=(0,r.default)(a.FormControl)(({theme:be})=>(0,r.css)` min-height: 34px; font-size: ${be.fonts.size.large}; `),pt=r.default.table` margin-bottom: 5px; td:first-child { padding-right: 10px; } `,Gt=(be,ze)=>{const{timezone:Ve}=be;return{from:ze(be.from,"complete"),to:ze(be.to,"complete"),timezone:Ve}},gn=({defaultValue:be,disabled:ze,setValidatingKeyword:Ve})=>{const{formatTime:We,userTimezone:vt}=(0,P.Z)(),[Et,,At]=(0,g.useField)("timeRangeTabs.keyword"),Ct=(0,t.useRef)(!0),Kt=(0,t.useRef)(),[en,dn]=(0,t.useState)({from:"",to:"",timezone:""}),En=(0,t.useCallback)(fn=>(Ve(!1),dn(Gt(fn,We))),[Ve,We]),xn=(0,t.useCallback)(()=>(dn({from:rt.a$,to:rt.a$,timezone:vt}),"Unable to parse keyword."),[vt]),zn=(0,t.useCallback)(fn=>{if(fn!==void 0&&Kt.current!==fn)return Kt.current=fn,Ve(!0),xt()(fn)===""?Promise.resolve("Keyword must not be empty!"):On.Z.testNaturalDate(fn,vt).then(Dn=>{Ct.current&&En(Dn)}).catch(xn)},[xn,En,Ve,vt]);return(0,t.useEffect)(()=>()=>{Ct.current=!1},[]),(0,t.useEffect)(()=>{zn(Kt.current)},[zn]),(0,t.useEffect)(()=>{if(Et!=null&&Et.value){const{type:fn,keyword:Dn,...Hn}=Et.value;Vt()(Hn,en)||At.setValue({type:fn,keyword:Dn,...Hn,...en})}},[Et.value,en,At]),t.createElement(a.Row,{className:"no-bm"},t.createElement(a.Col,{sm:5},t.createElement(Bn,null,"Time range:"),t.createElement(g.Field,{name:"timeRangeTabs.keyword.keyword",validate:zn},({field:{name:fn,value:Dn,onChange:Hn},meta:{error:_o}})=>t.createElement(a.FormGroup,{controlId:"form-inline-keyword",style:{marginRight:5,width:"100%",marginBottom:0},validationState:_o?"error":null},t.createElement(de,{type:"text",className:"input-sm mousetrap",name:fn,disabled:ze,placeholder:"Last week",title:"Keyword input","aria-label":"Keyword input",onChange:Hn,required:!0,value:Dn||be}),t.createElement(u.d2,{error:_o,help:"Specify the time frame for the search in natural language."}))),t.createElement("b",null,"Preview"),t.createElement(pt,null,t.createElement("tbody",null,t.createElement("tr",null,t.createElement("td",null,"From"),t.createElement("td",null,en.from)),t.createElement("tr",null,t.createElement("td",null,"To"),t.createElement("td",null,en.to))))),t.createElement(a.Col,{sm:7},t.createElement(a.Panel,null,t.createElement(a.Panel.Body,null,t.createElement("p",null,t.createElement("code",null,"last month")," searches between one month ago and now"),t.createElement("p",null,t.createElement("code",null,"4 hours ago")," searches between four hours ago and now"),t.createElement("p",null,t.createElement("code",null,"1st of april to 2 days ago")," searches between 1st of April and 2 days ago"),t.createElement("p",null,t.createElement("code",null,"yesterday midnight +0200 to today midnight +0200")," searches between yesterday midnight and today midnight in timezone +0200 - will be 22:00 in UTC"),t.createElement("p",null,"Please consult the ",t.createElement(jn.Z,{page:Mt.Z.PAGES.TIME_FRAME_SELECTOR,title:"Keyword Time Range Documentation",text:"documentation"})," for more details.")))))};gn.propTypes={defaultValue:o().string,disabled:o().bool,setValidatingKeyword:o().func},gn.defaultProps={defaultValue:"",disabled:!1,setValidatingKeyword:()=>{}};const Jt=gn;var An=e("yDuYCNwc");const Pn=t.memo(({fieldName:be,unsetRange:ze,value:Ve,onChange:We,disabled:vt,error:Et})=>t.createElement(An.Z,{id:`relative-timerange-${be}-value`,name:`relative-timerange-${be}-value`,disabled:vt||ze,type:"number",min:"1",value:Ve===null?"":Ve,className:"mousetrap",title:`Set the ${be} value`,onChange:We,bsStyle:Et?"error":null})),sn=r.default.div` flex: 4; align-items: center; display: grid; grid-template-columns: max-content repeat(5, 1fr) max-content; grid-template-rows: repeat(2, 1fr) minmax(1.5em, auto); grid-gap: 0; `,no=r.default.div` grid-area: 2 / 1 / 3 / 3; position: relative; .form-group { margin: 0; } `,Co=(0,r.default)(u.Ph)` grid-area: 2 / 3 / 3 / 7; margin: 0 12px; `,Go=r.default.h3` grid-area: 1 / 1 / 2 / 2; `,Mo=r.default.span(({theme:be})=>(0,r.css)` grid-area: 2 / 7 / 3 / 8; font-size: ${be.fonts.size.large}; &::after { content: 'ago'; } `),jo=r.default.label(({theme:be})=>(0,r.css)` font-size: ${be.fonts.size.small}; grid-area: 1 / 2 / 2 / 8; margin-left: 15px; font-weight: normal; align-self: self-end; &.shortened { grid-area: 1 / 2 / 2 / 4; text-decoration: line-through; cursor: not-allowed; } input { margin-right: 6px; } `),Zt=r.default.span(({theme:be})=>(0,r.css)` color: ${be.colors.variant.dark.danger}; grid-area: 3 / 1 / 3 / 4; font-size: ${be.fonts.size.small}; font-style: italic; padding: 3px; `),Me=be=>W.as.map(({label:ze,type:Ve})=>{const We=E().duration(1,Ve).asSeconds();return be===0||We<=be?{label:ze,value:Ve}:null}).filter(Boolean),Ye=({classifiedRange:be,defaultRange:ze,disableUnsetRange:Ve,disabled:We,error:vt,fieldName:Et,limitDuration:At,name:Ct,onChange:Kt,onUnsetRange:en,title:dn,unsetRangeLabel:En})=>{const{initialValues:xn}=(0,g.useFormikContext)(),zn=Me(At),{isAllTime:fn,value:Dn,unit:Hn}=be,_o=t.useCallback(Fo=>{Kt({target:{name:Ct,value:Fo}})},[Ct,Kt]),Ss=t.useCallback(Fo=>{const De=Fo.target.value===""?null:Fo.target.value;_o({value:De,isAllTime:fn,unit:Hn})},[_o,Hn,fn]),As=Fo=>{_o({value:Dn,isAllTime:fn,unit:Fo})},Hs=Fo=>{var uo;const De=Fo.target.checked,Wr=(0,x.vQ)(xn.timeRangeTabs.relative)&&!((uo=xn.timeRangeTabs.relative)!=null&&uo[Et].isAllTime)?xn.timeRangeTabs.relative[Et]:ze;De&&en&&en(),_o(De?x.RU:Wr)};return t.createElement(sn,null,t.createElement(Go,null,dn),t.createElement(jo,{htmlFor:`relative-unset-${Et}`,className:Ve&&"shortened"},t.createElement("input",{checked:fn,className:"mousetrap",disabled:Ve,id:`relative-unset-${Et}`,onChange:Hs,type:"checkbox",value:"0"}),En),t.createElement(no,null,t.createElement(Pn,{disabled:We,error:vt,fieldName:Et,onChange:Ss,unsetRange:fn,value:Dn})),t.createElement(Co,{clearable:!1,disabled:We||fn,id:`relative-timerange-${Et}-unit`,inputProps:{className:"mousetrap"},name:`relative-timerange-${Et}-unit`,onChange:As,options:zn,placeholder:"Select a range length",value:Hn}),t.createElement(Mo,null),vt&&t.createElement(Zt,null,vt))},Ke=({defaultRange:be,disableUnsetRange:ze,disabled:Ve,fieldName:We,limitDuration:vt,onUnsetRange:Et,title:At,unsetRangeLabel:Ct})=>t.createElement(g.Field,{name:`timeRangeTabs.relative.${We}`},({field:{value:Kt,onChange:en,name:dn},meta:{error:En}})=>t.createElement(Ye,{classifiedRange:Kt,defaultRange:be,disableUnsetRange:ze,disabled:Ve,error:En,fieldName:We,limitDuration:vt,name:dn,onUnsetRange:Et,onChange:en,title:At,unsetRangeLabel:Ct}));Ke.defaultProps={disabled:!1,disableUnsetRange:!1,onUnsetRange:void 0};const dt=Ke,it=r.default.div` display: flex; align-items: center; flex-wrap: wrap; justify-content: space-around; `,gt=(0,r.default)(u.JO)` flex: 0.75; `,It=({disabled:be,limitDuration:ze})=>{const{values:{timeRangeTabs:Ve},setFieldValue:We}=(0,g.useFormikContext)(),vt=Ve.relative,Et=be||(0,f.SP)(vt)&&vt.from===W.r$;return t.createElement("div",null,t.createElement(it,null,t.createElement(t.Fragment,null,t.createElement(dt,{defaultRange:(0,x.ny)(W.lY),disableUnsetRange:ze!==0,disabled:be,fieldName:"from",limitDuration:ze,onUnsetRange:()=>{We("timeRangeTabs.relative.to",x.RU)},title:"From:",unsetRangeLabel:"All Time"}),t.createElement(gt,{name:"arrow-right"}),t.createElement(dt,{defaultRange:(0,x.tc)(W.QB),disableUnsetRange:Et,disabled:Et,fieldName:"to",limitDuration:ze,title:"Until:",unsetRangeLabel:"Now"}))))};It.propTypes={limitDuration:o().number,disabled:o().bool},It.defaultProps={disabled:!1,limitDuration:0};const ot=It,yt=r.default.div` padding: 12px 6px; h5 { font-weight: bold; margin: 0 0 6px; } `,rn=()=>t.createElement(yt,null,t.createElement("h5",null,"No Date/Time Override chosen."),t.createElement("p",null,"Use the tabs above to choose a Date & Time Range to Search.")),Cn={absolute:Rt,relative:ot,keyword:Jt},bn=(0,r.default)(a.Tabs)` margin-top: 1px; margin-bottom: 9px; `,hn=({activeTab:be,limitDuration:ze,setValidatingKeyword:Ve,tabs:We})=>W.Rn.filter(({type:vt})=>We.includes(vt)).map(({type:vt,name:Et})=>{const At=Cn[vt];return t.createElement(a.Tab,{title:Et,key:`time-range-type-selector-${vt}`,eventKey:vt},vt===be&&t.createElement(At,{disabled:!1,limitDuration:ze,setValidatingKeyword:vt==="keyword"?Ve:void 0}))}),ao=be=>({absolute:{type:"absolute",from:be((0,Y.rG)(new Date).subtract(300,"seconds"),"complete"),to:be((0,Y.rG)(new Date),"complete")},relative:{type:"relative",from:{value:5,unit:"minutes",isAllTime:!1},to:x.RU},keyword:{type:"keyword",keyword:"Last five minutes"},disabled:void 0}),Xn=({activeTab:be,nextTab:ze,timeRangeTabs:Ve,formatTime:We,defaultRanges:vt})=>Ve[ze]?Ve[ze]:(0,f.o0)(Ve[be])?ne(Ve[be],ze,We):vt[ze],Kn=({limitDuration:be,validTypes:ze,setValidatingKeyword:Ve})=>{const We=(0,v.Z)(),vt=(0,b.Z)(),{formatTime:Et}=(0,P.Z)(),{setValues:At,values:{activeTab:Ct,timeRangeTabs:Kt}}=(0,g.useFormikContext)(),en=(0,t.useMemo)(()=>ao(Et),[Et]),dn=(0,t.useCallback)(xn=>{At({timeRangeTabs:{...Kt,[xn]:Xn({activeTab:Ct,nextTab:xn,timeRangeTabs:Kt,formatTime:Et,defaultRanges:en})},activeTab:xn}),We(L.A.SEARCH_TIMERANGE_PICKER_TAB_SELECTED,{app_pathname:(0,O.av)(vt.pathname),app_section:"search-bar",app_action_value:"search-time-range",event_details:{tab:xn}})},[Ct,en,Et,vt.pathname,We,At,Kt]),En=(0,t.useMemo)(()=>hn({activeTab:Ct,limitDuration:be,setValidatingKeyword:Ve,tabs:ze}),[Ct,be,Ve,ze]);return t.createElement(bn,{id:"dateTimeTypes",defaultActiveKey:W.Rn[0].type,activeKey:Ct!=null?Ct:-1,onSelect:dn,animation:!1},En,!Ct&&t.createElement(rn,null))};var Jn=e("d4iC/0eA"),Wn=e("rKq6XZKM");const bo=(0,r.default)(u.JO)` margin-left: 6px; `,ds=(0,r.default)(a.MenuItem)(({theme:be})=>(0,r.css)` font-size: ${be.fonts.size.small}; `),zo=be=>{switch(be.type){case"relative":return(0,f.SP)(be)?be.from:be.range;case"absolute":return E()().diff(be.from,"seconds");case"keyword":return On.Z.testNaturalDate(be.keyword,be.timezone).then(({from:ze})=>E()().diff(ze,"seconds"));default:throw Error("Time range type doesn't not exist")}},Xo=async(be,ze)=>(await Promise.all(be==null?void 0:be.map(async We=>{const vt=await zo(We.timerange);return vt&&vt<=ze?We:null}))).filter(We=>!!We),Do=async(be,ze,Ve)=>{const We=ze?await Xo(be,ze):be;return We!=null&&We.length?We.map(({description:vt,timerange:Et,id:At})=>({eventKey:Et,key:`timerange-option-${At}`,disabled:Ve,label:vt})):[{disabled:!0,label:"No available presets",key:"no-available-presets"}]},Jo=be=>{const{config:ze}=(0,Jn.Z)(),[Ve,We]=(0,t.useState)(),vt=(0,t.useMemo)(()=>E().duration(ze==null?void 0:ze.query_time_range_limit).asSeconds(),[ze==null?void 0:ze.query_time_range_limit]),Et=(0,t.useCallback)(async()=>{We(await Do(ze==null?void 0:ze.quick_access_timerange_presets,vt,be))},[ze==null?void 0:ze.quick_access_timerange_presets,be,vt]);return{options:Ve,setOptions:Et}},Zo=({disabled:be,onChange:ze,onToggle:Ve,className:We,displayTitle:vt,bsSize:Et,header:At})=>{const Ct=(0,v.Z)(),{formatTime:Kt}=(0,P.Z)(),en=(0,b.Z)(),{options:dn,setOptions:En}=Jo(be),xn=(0,t.useCallback)(Dn=>{Dn!=null&&ze((0,Wn.h)(Dn,Kt)),Ct(L.A.SEARCH_TIMERANGE_PRESET_SELECTED,{app_pathname:(0,O.av)(en.pathname),app_section:"search-bar",app_action_value:"timerange-preset-selector",event_details:{timerange:Dn}})},[Kt,en.pathname,ze,Ct]),zn=(0,t.useCallback)(async Dn=>{typeof Ve=="function"&&Ve(Dn)},[Ve]),fn=(0,t.useCallback)(async()=>{await En()},[En]);return t.createElement(a.DropdownButton,{title:vt&&"Load Preset",id:"relative-timerange-selector","aria-label":"Open time range preset select",bsSize:Et,className:We,onToggle:zn,onMouseDown:fn,onSelect:xn},At&&t.createElement(a.MenuItem,{header:!0},At),dn?dn.map(({eventKey:Dn,key:Hn,disabled:_o,label:Ss})=>t.createElement(a.MenuItem,{eventKey:Dn,key:Hn,disabled:_o},Ss)):t.createElement(a.MenuItem,{eventKey:"loading",key:"loading",disabled:!0},"Loading..."),t.createElement(u.AE,{permissions:"clusterconfigentry:edit"},t.createElement(a.MenuItem,{divider:!0}),t.createElement(ds,{href:"/system/configurations",target:"_blank"},"Configure presets ",t.createElement(bo,{name:"external-link-alt"}))))};Zo.propTypes={bsSize:o().string,className:o().string,disabled:o().bool,displayTitle:o().bool,header:o().string,onChange:o().func,onToggle:o().func},Zo.defaultProps={bsSize:"small",className:void 0,disabled:!1,onChange:void 0,onToggle:void 0,header:void 0,displayTitle:!0};const yo=Zo;var Vo=e("ibdPvtmL"),_s=e("i+sOEQiN"),Cs=e("ty2gyrHp"),ms=e("d4kzUuQm"),Yn=e("iltCXley");const xo=(0,r.default)(u.os)` margin-top: 15px; `,Ls=(be,ze)=>be.type!==ze.type?!1:be.type==="keyword"?be.keyword===ze.keyword:Vt()(be,ze),Vs=({description:be})=>be?{}:{description:"Description is required"},Bs=({addTimerange:be,toggleModal:ze,target:Ve})=>{const{userTimezone:We}=(0,P.Z)(),{config:vt}=(0,Jn.Z)(),{values:{timeRangeTabs:Et,activeTab:At}}=(0,g.useFormikContext)(),Ct=Et[At],Kt=(0,t.useMemo)(()=>{var dn;return(dn=vt==null?void 0:vt.quick_access_timerange_presets)==null?void 0:dn.find(En=>Ls(En.timerange,(0,y.P3)((0,y.MD)(Ct),We)))},[vt,Ct,We]),en=({description:dn})=>be(dn);return t.createElement(u.Uv,null,t.createElement(n.Ly,{placement:"left",target:Ve},t.createElement(a.Popover,{title:"Save as preset",id:"time-range-preset-popover","data-testid":"time-range-preset-popover"},t.createElement(g.Formik,{onSubmit:en,initialValues:{description:""},validate:Vs},({isValid:dn})=>t.createElement(g.Form,null,t.createElement(u.jc,{type:"text",name:"description",id:"time-range-preset-description",placeholder:"Add description...","aria-label":"Time range description",formGroupClassName:""}),!!Kt&&t.createElement("p",null,t.createElement(u.JO,{name:"exclamation-triangle"}),"You already have similar time range in"," ",t.createElement(Cs.r,{to:ms.ZP.SYSTEM.CONFIGURATIONS,target:"_blank"},"Range configuration"),t.createElement("br",null),t.createElement("i",null,"(",Kt.description,")")),t.createElement(xo,{disabledSubmit:!dn,submitButtonText:"Save preset",isAsyncSubmit:!1,displayCancel:!0,onCancel:ze,bsSize:"small"}))))))},Us=()=>{var be;const{userTimezone:ze}=(0,P.Z)(),{values:{timeRangeTabs:Ve,activeTab:We},errors:vt}=(0,g.useFormikContext)(),Et=(0,t.useRef)(),At=Ve[We],{config:Ct,refresh:Kt}=(0,Jn.Z)(),[en,dn]=(0,t.useState)(!1),En=(0,v.Z)(),xn=!((be=vt.timeRangeTabs)!=null&&be[We]),zn=(0,t.useCallback)(()=>{dn(Dn=>!Dn)},[]),fn=(0,t.useCallback)(Dn=>{const Hn={description:Dn,timerange:At?(0,y.P3)((0,y.MD)(At),ze):W.iM,id:(0,Yn.Z)()};Vo.h.update(_s.c.SEARCHES_CLUSTER_CONFIG,{...Ct,quick_access_timerange_presets:[...Ct.quick_access_timerange_presets,Hn]}).then(()=>{Kt(),zn()}),Hn&&En(L.A.SEARCH_TIMERANGE_PRESET_ADD_QUICK_ACCESS,{app_pathname:"search",app_section:"search-bar",event_details:{timerange:Hn.timerange,id:Hn.id}})},[Ct,Kt,En,At,zn,ze]);return t.createElement(t.Fragment,null,t.createElement(a.Button,{disabled:!xn,title:"Save current time range as preset",ref:Et,bsSize:"small",onClick:zn},"Save as preset"),en&&t.createElement(Bs,{addTimerange:fn,toggleModal:zn,target:Et.current}))},ws=(0,r.default)(a.ButtonToolbar)` float: right; margin-top: 6px; `,Lo=be=>(0,f.ow)(be)?(0,x.TI)(be):be,ns=()=>{const{showAddToQuickListButton:be}=(0,t.useContext)(d.Z),{showPresetsButton:ze}=(0,t.useContext)(d.Z),{values:Ve,setValues:We}=(0,g.useFormikContext)(),{activeTab:vt,timeRangeTabs:Et}=Ve,At=(0,t.useCallback)(Ct=>{We({...Ve,timeRangeTabs:{...Ve.timeRangeTabs,[Ct.type]:Lo(Ct)},activeTab:Ct.type})},[We,Ve]);return t.createElement(ws,null,be&&(0,f.o0)(Et[vt])&&t.createElement(u.AE,{permissions:"clusterconfigentry:edit"},t.createElement(Us,null)),ze&&t.createElement(yo,{onChange:At}))},os=Object.keys(Cn),Ws=(0,r.default)(a.Popover)(({theme:be})=>(0,r.css)` min-width: 750px; background-color: ${be.colors.variant.lightest.default}; .popover-title { border: none; } `),ps=r.default.p(({theme:be})=>(0,r.css)` font-size: ${be.fonts.size.small}; padding-left: 3px; margin: 0; min-height: 34px; display: flex; align-items: center; `),Tr=r.default.span` display: flex; justify-content: space-between; align-items: center; > span { font-weight: 600; } `,Ns=r.default.span(({theme:be})=>(0,r.css)` > svg { margin-right: 3px; color: ${be.colors.variant.dark.warning}; } > span { font-size: ${be.fonts.size.small}; color: ${be.colors.variant.darkest.warning}; } `),gs=(be,ze,Ve)=>{if(!be)return{};const We=(0,x.PQ)(be),vt=(0,T.Z)(We,ze,Ve);return Object.keys(vt).length!==0?{timeRangeTabs:{[be.type]:vt}}:{}},Ho=be=>(0,f.o0)(be)?{timeRangeTabs:{[be.type]:(0,f.ow)(be)?(0,x.TI)(be):be},activeTab:be.type}:{timeRangeTabs:{},activeTab:void 0},Yo=({noOverride:be,toggleDropdownShow:ze,currentTimeRange:Ve,setCurrentTimeRange:We,validTypes:vt=os,position:Et,limitDuration:At})=>{const{ignoreLimitDurationInTimeRangeDropdown:Ct}=(0,t.useContext)(d.Z),Kt=(0,t.useMemo)(()=>Ct?0:At,[At,Ct]),{formatTime:en,userTimezone:dn}=(0,P.Z)(),[En,xn]=(0,t.useState)(!1),zn=(0,v.Z)(),fn=(0,b.Z)(),Dn=Et==="bottom",Hn=(0,t.useCallback)(()=>{We({}),ze()},[We,ze]),_o=(0,t.useCallback)(()=>{ze(),zn(L.A.SEARCH_TIMERANGE_PICKER_CANCELED,{app_pathname:(0,O.av)(fn.pathname),app_section:"search-bar",app_action_value:"search-time-range-cancel-button"})},[fn.pathname,zn,ze]),Ss=(0,t.useCallback)(({timeRangeTabs:uo,activeTab:De})=>{const ss=(0,y.MD)(uo[De]);We(ss),ze(),zn(L.A.SEARCH_TIMERANGE_PICKER_UPDATED,{app_pathname:(0,O.av)(fn.pathname),app_section:"search-bar",app_action_value:"search-time-range-confirm-button",event_details:{timerange:ss}})},[fn.pathname,zn,We,ze]),As=t.createElement(Tr,null,t.createElement("span",null,"Search Time Range"),Kt>0&&t.createElement(Ns,null,t.createElement(u.JO,{name:"exclamation-triangle"}),t.createElement("span",null,"Admin has limited searching to ",E().duration(-Kt,"seconds").humanize(!0)))),Hs=(0,t.useCallback)(({timeRangeTabs:uo,activeTab:De})=>gs(uo[De],Kt,en),[en,Kt]),Fo=(0,t.useMemo)(()=>Ho(Ve),[Ve]);return t.createElement(Ws,{id:"timerange-type","data-testid":"timerange-type",placement:Et,positionTop:Dn?36:-10,positionLeft:Dn?-15:45,arrowOffsetTop:Dn?void 0:25,arrowOffsetLeft:Dn?34:-11,title:As},t.createElement(g.Formik,{initialValues:Fo,validate:Hs,onSubmit:Ss,validateOnMount:!0},({isValid:uo,submitForm:De})=>t.createElement(u.Vs,{shortcuts:[{actionKey:"submit-form",callback:De,scope:"general",options:{displayInOverview:!1}},{actionKey:"close-modal",callback:_o,scope:"general",options:{displayInOverview:!1}}]},t.createElement(g.Form,null,t.createElement(a.Row,null,t.createElement(a.Col,{md:12},t.createElement(ns,null),t.createElement(Kn,{limitDuration:Kt,validTypes:vt,setValidatingKeyword:xn}))),t.createElement(a.Row,{className:"row-sm"},t.createElement(a.Col,{md:6},t.createElement(ps,null,"All timezones using: ",t.createElement("b",null,dn))),t.createElement(a.Col,{md:6},t.createElement(u.os,{leftCol:be&&t.createElement(a.Button,{bsStyle:"link",onClick:Hn},"No Override"),onCancel:_o,disabledSubmit:!uo||En,submitButtonText:"Update time range"})))))))};Yo.defaultProps={noOverride:!1,validTypes:os};const Te=Yo;var Le=e("qC/AOIKG");const st=(0,r.default)(yo)` padding: 6px; `,St=(0,r.default)(a.ButtonGroup)` display: flex; align-items: start; `,$t=({disabled:be,hasErrorOnMount:ze,onPresetSelectOpen:Ve,setCurrentTimeRange:We,showPresetDropdown:vt=!0,toggleShow:Et})=>{const{submitForm:At,isValid:Ct}=(0,g.useFormikContext)(),Kt=En=>{En.currentTarget.blur(),Et()},en=En=>{We((0,y.uc)(En)),Ct&&At()},dn=En=>{En&&Ve()};return t.createElement(St,null,t.createElement(Le.Z,{hasError:ze,disabled:be,onClick:Kt}),vt&&t.createElement(st,{disabled:be,displayTitle:!1,onChange:en,onToggle:dn,header:"Select time range",bsSize:null}))};$t.defaultProps={hasErrorOnMount:!1,disabled:!1,showPresetDropdown:!0};const cn=$t,In=r.default.div` display: flex; align-items: stretch; justify-content: space-between; flex: 1; min-width: 430px; gap: ${c.V}; position: relative; `,Mn=({disabled:be,hasErrorOnMount:ze,noOverride:Ve,value:We=W.iM,onChange:vt,validTypes:Et,position:At,className:Ct,showPresetDropdown:Kt=!0,limitDuration:en})=>{const dn=(0,t.useRef)(),{showDropdownButton:En}=(0,t.useContext)(d.Z),xn=(0,v.Z)(),zn=(0,b.Z)(),[fn,Dn]=(0,t.useState)(!1);if(Et&&We&&"type"in We&&!Et.includes(We==null?void 0:We.type))throw new Error(`Value is of type ${We.type}, but only these types are valid: ${Et}`);const Hn=()=>{Dn(!fn),xn(L.A.SEARCH_TIMERANGE_PICKER_TOGGLED,{app_pathname:(0,O.av)(zn.pathname),app_section:"search-bar",app_action_value:"time-range-picker",event_details:{showing:!fn}})},_o=()=>fn&&Hn();return t.createElement(In,{className:Ct,ref:dn},En&&t.createElement(cn,{disabled:be,toggleShow:Hn,onPresetSelectOpen:_o,setCurrentTimeRange:vt,showPresetDropdown:Kt,hasErrorOnMount:ze}),t.createElement(n.aV,{show:fn,trigger:"click",placement:"bottom",onHide:Hn,container:dn.current},t.createElement(Te,{currentTimeRange:We,limitDuration:en,noOverride:Ve,setCurrentTimeRange:vt,toggleDropdownShow:Hn,validTypes:Et,position:At})),t.createElement(rt.ZP,{timerange:We,toggleDropdownShow:Hn}))};Mn.propTypes={className:o().string,disabled:o().bool,hasErrorOnMount:o().bool,noOverride:o().bool,validTypes:o().arrayOf(o().string)},Mn.defaultProps={className:void 0,disabled:!1,hasErrorOnMount:!1,noOverride:!1,validTypes:void 0,position:"bottom",showPresetDropdown:!0};const qn=Mn},Y15zKX1V:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("/GOzvPf6"),c=e("uZqmR+ju"),v=e("IZYxBTgT"),d=e("O/XpfGnR");const g=r.default.div` width: 100%; .form-group { margin: 0; } `,p=({name:a,disabled:u,onChange:f,value:y,hasError:T,className:P})=>{const{formatTime:O}=(0,d.Z)(),b=()=>f(O(new Date,"complete")),L=x=>f(x.target.value);return t.createElement(g,{className:P},t.createElement(c.Input,{type:"text",id:`date-input-${a}`,name:a,autoComplete:"off",disabled:u,onChange:L,placeholder:v.eZ.default,value:y,buttonAfter:t.createElement(c.Button,{disabled:u,onClick:b,title:"Insert current date"},t.createElement(n.JO,{name:"magic"})),className:"mousetrap",bsStyle:T?"error":null}))};p.propTypes={disabled:o().bool,hasError:o().bool,name:o().string.isRequired,onChange:o().func,value:o().string},p.defaultProps={className:void 0,disabled:!1,hasError:!1,onChange:()=>{},value:""};const E=p},z45xmHGk:(M,C,e)=>{"use strict";e.d(C,{PQ:()=>u,Pp:()=>a,RU:()=>c,TI:()=>p,ny:()=>d,tc:()=>g,vQ:()=>E});var t=e("9oVghaOd"),s=e.n(t),o=e("nxMFMmDQ"),r=e("PwTFiGSp");const n={value:5,unit:"minutes",isAllTime:!1},c={value:0,unit:"seconds",isAllTime:!0},v=(f,y)=>f===null?n:f===y?c:o.as.map(({type:T})=>{const P=s().duration(f,"seconds").as(T);return P-Math.floor(P)===0?{value:P||0,unit:T,isAllTime:!1}:null}).filter(Boolean).pop(),d=f=>v(f,o.r$),g=f=>v(f,void 0),p=f=>(0,r.a_)(f)?{type:"relative",from:d(f.range),to:g(void 0)}:{type:"relative",from:d(f.from),to:g(f.to)},E=f=>f&&"type"in f&&f.type==="relative"&&"from"in f&&typeof(f==null?void 0:f.from)=="object"&&"to"in f&&typeof f.to=="object",a=({value:f,unit:y,isAllTime:T})=>T?o.r$:s().duration(f||1,y).asSeconds(),u=f=>{if(E(f)){const y=f.from.value!==null?a(f.from):null,T=f.to.value!==null?a(f.to):null;return f.to.isAllTime?{type:"relative",from:y}:{type:"relative",from:y,to:T}}return f}},"qC/AOIKG":(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("uZqmR+ju"),o=e("/GOzvPf6");const r=({hasError:c,disabled:v,onClick:d})=>t.createElement(s.Button,{bsStyle:c?"danger":"info",disabled:v,onClick:d,"aria-label":"Open Time Range Selector"},t.createElement(o.JO,{name:c?"exclamation-triangle":"clock"}));r.defaultProps={hasError:!1,disabled:!1,onClick:void 0};const n=r},i3LesQt8:(M,C,e)=>{"use strict";e.d(C,{Z:()=>z});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("/GOzvPf6"),c=e("jlRcBdjT"),v=e("dFpwyWHg"),d=e.n(v),g=e("C2ikvoS0"),p=e.n(g),E=e("1IntWRSu"),a=e.n(E),u=e("8nGWeFnd"),f=e.n(u),y=e("TeAcaicX"),T=e.n(y),P=e("eE3+5goe"),O=e.n(P),b=e("d39qUqyh"),L={};L.styleTagTransform=O(),L.setAttributes=f(),L.insert=a().bind(null,"head"),L.domAPI=p(),L.insertStyleElement=T();var x=d()(b.Z,L);const W=b.Z&&b.Z.locals?b.Z.locals:void 0,N=ne=>{switch(ne){case"string":return"font";case"boolean":return"toggle-on";case"byte":case"double":case"float":case"int":case"long":case"short":return"chart-line";case"date":return"calendar-alt";case"ip":return"network-wired";case"node":return"circle-nodes";case"streams":return"code-branch";case"input":return"tower-broadcast";default:return"question-circle"}},Z=r.default.div` display: inline-flex; min-width: 20px; justify-content: center; align-items: center; vertical-align: -2px; `,j=({type:ne,monospace:Y})=>{const ae=t.createElement(n.JO,{name:N(ne.type),className:W.fieldTypeIcon});return Y?t.createElement(Z,null,ae):ae};j.propTypes={type:o().instanceOf(c.ZP).isRequired,monospace:o().bool},j.defaultProps={monospace:!0};const z=j},gajRAEyE:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("n/pWmEhD"),s=e.n(t),o=e("ww+BtWnX"),r=e.n(o);const n=d=>{const g=d.map(([E])=>E),p=d.map(([,E])=>E);return o.scale(p).domain(g)},v=d=>{switch(d){case"Blackbody":case"Bluered":case"Cividis":case"Earth":case"Electric":case"Hot":case"Jet":case"Picnic":case"Portland":case"Rainbow":return n(t.scales[d]);default:return o.scale(d)}}},G0W2UiZR:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS"),o=e("oxGoxcS7");const r=t.createContext({colors:o.Z.create(),setColor:()=>Promise.resolve([])}),n=(0,s.ri)("views.components.visualizations.ChartColorContext",()=>r)},oxGoxcS7:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("VPaD/Np4"),s=e.n(t),o=e("e50u4lQu"),r=e("b2fGY8bZ");class n{constructor(g=(0,t.Map)(),p=-1){this._value=g,this._currentDefaultColor=p}_incrementColor(){this._currentDefaultColor=(this._currentDefaultColor+1)%o.P.length}_nextFreeColor(){return this._incrementColor(),o.P[this._currentDefaultColor]}get(g,p){const E=this._value.get(g);if(E)return g!==r.Xo&&this._incrementColor(),E;if(p)return g!==r.Xo&&this._incrementColor(),this._value=this._value.set(g,p),p;const a=this._nextFreeColor();return this._value=this._value.set(g,a),a}set(g,p){this._value=this._value.set(g,p)}toBuilder(){return new c(this._value,this._currentDefaultColor)}static builder(){return new c}static create(g=(0,t.Map)()){return new n(g)}}class c{constructor(g=(0,t.Map)(),p=-1){this.value=g,this.colorIndex=p}set(g,p){return new c(this.value.set(g,p))}build(){return new n(this.value,this.colorIndex)}}const v=n},e50u4lQu:(M,C,e)=>{"use strict";e.d(C,{O:()=>L,P:()=>x});const t=["#b71c1c","#ce5246","#e27c72","#f3a4a1","#ffcdd2"],s=["#880e4f","#a5426d","#c16b8d","#dd93ae","#f8bbd0"],o=["#4a148c","#7240a3","#9869b9","#bc93d0","#e1bee7"],r=["#311b92","#6044a8","#876dbe","#ad98d3","#d1c4e9"],n=["#1a237e","#4e4998","#7772b3","#9e9dce","#c5cae9"],c=["#0d47a1","#4b6ab7","#738fce","#97b5e4","#bbdefb"],v=["#01579b","#4478b3","#6b9bcb","#8fbfe3","#b3e5fc"],d=["#006064","#3a8185","#62a3a8","#8ac6cc","#b2ebf2"],g=["#004d40","#356f64","#5e9389","#87b8b1","#b2dfdb"],p=["#194d33","#447155","#6e967a","#9abda1","#c8e6c9"],E=["#33691e","#5d8947","#87a970","#b1cb9b","#dcedc8"],a=["#827717","#9e9544","#bab36d","#d5d398","#f0f4c3"],u=["#f57f17","#fd9e48","#ffbe73","#ffdc9c","#fff9c4"],f=["#ff6f00","#ff943f","#ffb368","#ffd08e","#ffecb3"],y=["#e65100","#f17837","#fa9c5f","#febe88","#ffe0b2"],T=["#bf360c","#d35f39","#e58463","#f4a88f","#ffccbc"],P=["#3e2723","#624c48","#877470","#af9f9b","#d7ccc8"],O=["#263238","#4c575d","#758085","#a1abb0","#cfd8dc"],L=[t,s,o,r,n,c,v,d,g,p,E,a,u,f,y,T,P,O,["#000000","#3b3b3b","#777777","#b9b9b9","#ffffff"]],x=[v[1],u[1],E[1],t[1],o[1],P[1],s[1],u[3],d[3],n[0],y[0],g[0],r[0],O[2],o[4],T[0]]},"9RXNqxkm":(M,C,e)=>{"use strict";e.d(C,{Z:()=>me});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("wXrUUKFq"),c=e.n(n),v=e("VgplIV7d"),d=e("uZqmR+ju"),g=e("6nsVPoEI"),p=e("3+X6e5zE"),E=e("e50u4lQu"),a=e("b2fGY8bZ"),u=e("CCNXj2ra"),f=e("G0W2UiZR"),y=e("dFpwyWHg"),T=e.n(y),P=e("C2ikvoS0"),O=e.n(P),b=e("1IntWRSu"),L=e.n(b),x=e("8nGWeFnd"),W=e.n(x),N=e("TeAcaicX"),Z=e.n(N),j=e("eE3+5goe"),z=e.n(j),ne=e("lM0K4xME"),Y={};ne.Z&&ne.Z.locals&&(Y.locals=ne.Z.locals);var ae=0,ee,ue={};ue.styleTagTransform=z(),ue.setAttributes=W(),ue.insert=L().bind(null,"head"),ue.domAPI=O(),ue.insertStyleElement=Z(),Y.use=function(re){return ue.options=re||{},ae++||(ee=T()(ne.Z,ue)),Y},Y.unuse=function(){ae>0&&!--ae&&(ee(),ee=null)};const H=Y;var ye=e("GFJVQ2dX"),we=e("pLyxMSSz");const ut=(0,r.default)(p.Z)(({theme:re})=>(0,r.css)` .hoverlayer .hovertext { rect { fill: ${re.colors.global.contentBackground} !important; opacity: 0.9 !important; } .name { fill: ${re.colors.global.textDefault} !important; } path { stroke: ${re.colors.global.contentBackground} !important; } } `),ht={yaxis:{fixedrange:!0},xaxis:{fixedrange:!0},hovermode:!1},Je={height:"100%",width:"100%"},Re={displayModeBar:!1,doubleClick:!1,responsive:!0};class le extends t.Component{constructor(ce){super(ce),this._onRelayout=Q=>{if(!Q.autosize&&Q["xaxis.range[0]"]&&Q["xaxis.range[1]"]){const{onZoom:J}=this.props,ie=Q["xaxis.range[0]"],ge=Q["xaxis.range[1]"];return J(ie,ge)}return!0},this._onLegendClick=Q=>{const J=Q.node.textContent,ie=Q.node.querySelector("g.layers"),{getChartColor:ge}=this.props;if(ge){const fe=ge(Q.fullData,J);this.setState({legendConfig:{name:J,target:ie,color:fe}})}return!1},this._onColorSelect=(Q,J,ie)=>Q(J,ie).then(this._onCloseColorPopup),this._onCloseColorPopup=()=>this.setState({legendConfig:void 0}),this.state={}}componentDidMount(){H.use()}componentWillUnmount(){H.unuse()}render(){const{chartData:ce,layout:Q,setChartColor:J,theme:ie}=this.props,ge={color:ie.colors.global.textDefault,size:u.dr*Number(ie.fonts.size.small.replace(/rem|em/i,"")),family:ie.fonts.family.body},fe={shapes:[],autosize:!0,showlegend:!0,margin:{t:10,l:40,r:10,b:0,pad:0},legend:{orientation:"h",font:ge},hoverlabel:{namelength:-1},paper_bgcolor:"transparent",plot_bgcolor:"transparent",title:{font:ge},yaxis:{automargin:!0,gridcolor:ie.colors.variant.lightest.default,tickfont:ge,title:{font:ge}},xaxis:{automargin:!0,tickfont:ge,title:{font:ge}}},Ce=c()({},fe,Q),{legendConfig:Oe}=this.state;return t.createElement(f.Z.Consumer,null,({colors:nt,setColor:et})=>{Ce.shapes=Ce.shapes.map(Pe=>{var $e;return{...Pe,line:{color:(($e=Pe==null?void 0:Pe.line)==null?void 0:$e.color)||nt.get(a.Xo,a.Ce)}}});const Fe=ce.map(Pe=>{if(J&&nt){const $e=J(Pe,nt);if(Pe.type==="pie"&&($e.outsidetextfont={color:ie.colors.global.textDefault}),(Pe==null?void 0:Pe.name)===a.Xo){const Ot=nt.get(a.Xo,a.Ce);$e.marker={color:Ot,size:5}}return $e.line||$e.marker?c()(Pe,$e):Pe}return Pe});return t.createElement(ye.Z.Consumer,null,Pe=>t.createElement(we.Z.Consumer,null,$e=>t.createElement(t.Fragment,null,t.createElement(ut,{data:Fe,useResizeHandler:!0,layout:Pe?Ce:c()({},ht,Ce),style:Je,onAfterPlot:$e,onClick:Pe?null:()=>!1,onLegendClick:Pe?this._onLegendClick:()=>!1,onRelayout:Pe?this._onRelayout:()=>!1,config:Re}),Oe&&t.createElement(v.zx,{event:"mousedown",onRootClose:this._onCloseColorPopup},t.createElement(v.aV,{show:!0,placement:"top",target:Oe.target},t.createElement(d.Popover,{id:"legend-config",title:`Configuration for ${Oe.name}`,className:H.locals.customPopover},t.createElement(g.Z,{color:Oe.color,colors:E.O,onChange:Ot=>this._onColorSelect(et,Oe.name,Ot)})))))))})}}le.propTypes={chartData:o().array.isRequired,layout:o().object,onZoom:o().func,getChartColor:o().func,setChartColor:o().func},le.defaultProps={layout:{},onZoom:()=>!0,getChartColor:void 0,setChartColor:void 0};const me=(0,r.withTheme)(le)},"3+X6e5zE":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("8jTixuP6");const o=(0,t.Z)(()=>Promise.all([e.e("1255d548-626"),e.e("1255d548-8601")]).then(e.bind(e,"EnVHAx3T")))},"9FNnmA1r":(M,C,e)=>{"use strict";e.d(C,{Z:()=>ne});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("/GOzvPf6"),c=e("O+BThgTi"),v=e("dFpwyWHg"),d=e.n(v),g=e("C2ikvoS0"),p=e.n(g),E=e("1IntWRSu"),a=e.n(E),u=e("8nGWeFnd"),f=e.n(u),y=e("TeAcaicX"),T=e.n(y),P=e("eE3+5goe"),O=e.n(P),b=e("BcnLA9qD"),L={};L.styleTagTransform=O(),L.setAttributes=f(),L.insert=a().bind(null,"head"),L.domAPI=p(),L.insertStyleElement=T();var x=d()(b.Z,L);const W=b.Z&&b.Z.locals?b.Z.locals:void 0,N=r.default.div` max-width: 700px; `,Z=r.default.ul` padding: 0; `,j=r.default.div` margin-bottom: 5px; &:last-child { margin-bottom: 0; } `,z=({errors:Y,title:ae})=>t.createElement(n.M5,null,t.createElement(n.JO,{name:"exclamation-triangle",size:"3x",className:W.iconMargin}),t.createElement(N,null,t.createElement(j,null,t.createElement("strong",null,ae)),t.createElement(Z,null,Y.map(ee=>t.createElement(j,{as:"li",key:ee.description},ee.description)))));z.propTypes={errors:c.gw.isRequired,title:o().string},z.defaultProps={title:"While retrieving data for this widget, the following error(s) occurred:"};const ne=z},GrokUsBg:(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("/GOzvPf6"),r=e("AKYezHev"),n=e("M04itGxI");const c=s.default.div` display: flex; justify-content: space-between; align-items: center; margin-top: 3px; `,v=(0,s.default)(r.Z)` flex: 1; `,d=(0,s.default)(n.Z)` flex: 1; `,g=s.default.div` display: flex; align-items: center; justify-content: center; min-height: 25px; margin-right: 5px; `,p=(0,t.forwardRef)(({selectSize:y,className:T,dragHandleProps:P,draggableProps:O,item:b,onChange:L,onRemove:x,selectedFields:W,testIdPrefix:N},Z)=>{const[j,z]=(0,t.useState)(!1),ne=Y=>{L(Y),z(!1)};return t.createElement(c,{className:T,ref:Z,...O!=null?O:{}},j&&t.createElement(v,{id:"add-field-select",onChange:ne,onMenuClose:()=>z(!1),autoFocus:!0,openMenuOnFocus:!0,clearable:!1,size:y,excludedFields:W.filter(Y=>Y!==b.id),ariaLabel:"Fields",name:"add-field-select",value:b.id,"aria-label":`Edit ${b.title} field`}),!j&&t.createElement(t.Fragment,null,t.createElement(g,{...P,"data-testid":`${N}-drag-handle`},t.createElement(o.JO,{name:"bars"})),t.createElement(d,null,b.title),t.createElement("div",null,t.createElement(o.hU,{name:"edit",title:`Edit ${b.title} field`,onClick:()=>z(!0)}),t.createElement(o.hU,{name:"trash-alt",title:`Remove ${b.title} field`,onClick:x}))))}),E=({testPrefix:y,selectedFields:T,onChange:P,selectSize:O,displayOverlayInPortal:b})=>{const L=(0,t.useMemo)(()=>T==null?void 0:T.map(j=>({id:j,title:j})),[T]),x=(0,t.useCallback)((j,z)=>{const ne=[...T];ne[j]=z,P(ne)},[P,T]),W=(0,t.useCallback)(j=>{const z=T.filter(ne=>ne!==j);P(z)},[P,T]),N=(0,t.useCallback)(({item:j,index:z,dragHandleProps:ne,draggableProps:Y,className:ae,ref:ee})=>t.createElement(p,{onChange:ue=>x(z,ue),onRemove:()=>W(j.id),selectSize:O,selectedFields:T!=null?T:[],item:j,testIdPrefix:`${y}-field-${z}`,dragHandleProps:ne,draggableProps:Y,className:ae,ref:ee}),[O,T,y,x,W]),Z=(0,t.useCallback)(j=>{P(j.map(({id:z})=>z))},[P]);return T!=null&&T.length?t.createElement(o.cm,{items:L,onMoveItem:Z,customListItemRender:N,displayOverlayInPortal:b}):null};E.defaultProps={displayOverlayInPortal:!1,testPrefix:void 0,selectSize:void 0};const a=E,u=({createSelectPlaceholder:y,displaySortableListOverlayInPortal:T,menuPortalTarget:P,onChange:O,isFieldQualified:b,selectSize:L,selectedFields:x,testPrefix:W})=>{const N=(0,t.useCallback)(Z=>O([...x,Z]),[O,x]);return t.createElement(t.Fragment,null,t.createElement(a,{testPrefix:W,selectedFields:x,selectSize:L,displayOverlayInPortal:T,onChange:O}),t.createElement(r.Z,{id:"field-create-select",onChange:N,clearable:!1,isFieldQualified:b,persistSelection:!1,name:"field-create-select",value:void 0,size:L,menuPortalTarget:P,excludedFields:x!=null?x:[],placeholder:y,ariaLabel:y}))};u.defaultProps={createSelectPlaceholder:"Add a field",displaySortableListOverlayInPortal:!1,isFieldQualified:void 0,selectSize:void 0,menuPortalTarget:void 0,testPrefix:""};const f=u},pLyxMSSz:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=t.createContext(()=>{}),r=(0,s.ri)("views.components.widgets.RenderCompletionCallback",()=>o)},hfAjrXHN:(M,C,e)=>{"use strict";e.d(C,{Z:()=>T,a:()=>f});var t=e("Z7aTuO5B"),s=e("J6y4/h8P"),o=e("oCSEoDew"),r=e.n(o),n=e("Ofda/4py"),c=e("93yMNhQL"),v=e("/8lbhT5j"),d=e("7GNmVOX8"),g=e("CHWvwBKE"),p=e("iltCXley");const E=s.default.a` display: inline-flex; align-items: center; color: inherit; text-decoration: none; &:visited { color: inherit; } `,a=(0,s.default)(c.Z)` margin-left: 6px; `,u=(P,O,b,L,x)=>{let W=v.Z.builder().query((0,g.Eg)(b)).timerange(O).streams(L).build().toURL();return x!=null&&x.size&&(W=new(r())(W).setSearch("session-id",P).toString()),W},f=({searchLink:P,children:O,onClick:b})=>t.createElement(E,{href:P,target:"_blank",rel:"noopener noreferrer",title:"Replay search",onClick:b},O?t.createElement(t.Fragment,null,O," ",t.createElement(a,{name:"play"})):t.createElement(n.Z,{name:"play",focusable:!1})),y=({queryString:P,timerange:O,streams:b,parameters:L,children:x,parameterBindings:W})=>{const N=(0,t.useMemo)(()=>`replay-search-${(0,p.Z)()}`,[]),Z=u(N,O,P,b,L),j=(0,t.useCallback)(()=>{L!=null&&L.size&&d.Z.set(N,JSON.stringify({parameters:L,parameterBindings:W}))},[N,L,W]);return t.createElement(f,{searchLink:Z,onClick:j},x)};y.defaultProps={queryString:void 0,timerange:void 0,streams:void 0,parameters:void 0,parameterBindings:void 0,children:void 0},f.defaultProps={children:void 0,onClick:void 0};const T=y},"ocYLQ/BD":(M,C,e)=>{"use strict";e.d(C,{Z:()=>v,i:()=>n});var t=e("Z7aTuO5B"),s=e("6KiaUlHf"),o=e("/GOzvPf6"),r=e("0IW4P5Zs");const n="Update widget",v=({onSubmit:d,onCancel:g})=>{const{applyAllWidgetChanges:p}=(0,t.useContext)(s.Z),[E,a]=(0,t.useState)(!1),{disabled:u}=(0,t.useContext)(r.Z),f=()=>(a(!0),p().then(()=>{a(!1),d()}).catch(()=>{a(!1)}));return t.createElement(o.os,{isAsyncSubmit:!0,submitButtonText:n,submitLoadingText:"Updating widget...",onSubmit:f,submitButtonType:"button",disabledSubmit:u,isSubmitting:E,displayCancel:!0,onCancel:g})}},"i/Bor0y0":(M,C,e)=>{"use strict";e.d(C,{Z:()=>p});var t=e("Z7aTuO5B"),s=e("J6y4/h8P");const o=s.default.div` height: 100%; display: flex; flex-flow: column nowrap; `,r=s.default.div` overflow-y: auto; `,n=s.default.div` position: relative; `,c=s.default.div(({theme:E,$scrolledToBottom:a,$alignAtBottom:u})=>(0,s.css)` position: sticky; width: 100%; bottom: 0; background: ${E.colors.global.contentBackground}; z-index: 1; display: flex; flex-direction: column; flex: 1; justify-content: ${u?"flex-end":"space-between"}; padding-top: 5px; &::before { box-shadow: 1px -2px 3px rgb(0 0 0 / 25%); content: ' '; display: ${a?"block":"none"}; height: 3px; position: absolute; left: 0; right: 0; top: 0; } `),v=s.default.div` width: 1px; position: absolute; bottom: 0; height: 5px; z-index: 0; `,d=()=>{const[E,a]=(0,t.useState)(null),[u,f]=(0,t.useState)(!1);return(0,t.useEffect)(()=>{const y=new IntersectionObserver(([T])=>{f(!T.isIntersecting)},{threshold:.9});return E&&y.observe(E),()=>{E&&y.unobserve(E)}},[E]),{setScrolledToBottomIndicatorRef:a,scrolledToBottom:u}},g=({actions:E,children:a,className:u,alignActionsAtBottom:f})=>{const{setScrolledToBottomIndicatorRef:y,scrolledToBottom:T}=d();return t.createElement(o,{className:u},t.createElement(r,null,t.createElement(n,null,a,t.createElement(v,{ref:y}))),t.createElement(c,{$scrolledToBottom:T,$alignAtBottom:f},E))};g.defaultProps={className:void 0,alignActionsAtBottom:!1};const p=g},FYGzXHJc:(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("Z7aTuO5B"),s=e("ii0bleBb"),o=e.n(s),r=e("J6y4/h8P"),n=e("/GOzvPf6"),c=e("5s1wXXQQ"),v=e("Xt0X5Kl4");const d=(0,r.default)(n.$j)` margin-left: 10px; `,g=r.default.div(({theme:y})=>(0,r.css)` font-size: ${y.fonts.size.large}; text-overflow: ellipsis; margin-bottom: 5px; display: grid; grid-template-columns: minmax(35px, 1fr) max-content; align-items: center; `),p=r.default.div` display: flex; align-items: center; `,E=(0,r.default)(n.JO)` cursor: move; opacity: 0.3; margin-right: 5px; `,a=r.default.span` position: relative; `,u=({children:y,onRename:T,hideDragHandle:P,title:O,loading:b})=>t.createElement(g,null,t.createElement(p,null,P||t.createElement("span",{className:"widget-drag-handle",title:`Drag handle for ${O}`},t.createElement(E,{name:"bars"})),t.createElement(c.Z,{key:O,disabled:!T,value:O,onChange:T}),b&&t.createElement(d,{text:"",delay:0})),t.createElement(a,null,y));u.propTypes={children:v.Z.OneOrMoreChildren,onRename:o().func,hideDragHandle:o().bool,title:o().node.isRequired,loading:o().bool},u.defaultProps={children:null,onRename:void 0,hideDragHandle:!1,loading:!1};const f=u},"O+BThgTi":(M,C,e)=>{"use strict";e.d(C,{Ly:()=>d,gw:()=>T});var t=e("ii0bleBb"),s=e.n(t),o=e("GaFHk8Qk"),r=e.n(o),n=e("64Qr82UM"),c=e("mPEBamrX"),v=e("Xt0X5Kl4");const d={col:s().number.isRequired,row:s().number.isRequired,height:s().number.isRequired,width:s().number.isRequired},g=s().objectOf(s().shape(d)),p=r().mapOf(r().mapContains(d),s().string),E=s().objectOf(v.Z.instanceOf(n.Z)),a=r().mapOf(v.Z.instanceOf(n.Z),s().string),u=s().oneOfType([s().arrayOf(s().object),s().object]),f=s().objectOf(u),y=s().instanceOf(c.Z),T=s().arrayOf(y),P=s().objectOf(T)},"2eB4xxdN":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("SwOo9/Yp"),s=e("UmnljV2q"),o=e("RhFA9EKs"),r=e("g2NQZb9A");const c=async({query:v,view:d,executionState:g})=>{if(d.type!==s.Z.Type.Search)return[d,g];const{queryString:p,timeRange:E,streamsFilter:a}=(0,o.Z)(v);if(!p&&!E&&!a)return[d,g];const{queries:u}=d.search;if(u.size!==1)throw new Error("Searches must only have a single query!");const f=u.first();let y=f.toBuilder();p&&(y=y.query(p)),E&&(y=y.timerange(E)),a&&(y=y.filter(a));const T=y.build();if((0,t.Z)(T,f))return[d,g];const P=d.search.toBuilder().newId().queries([T]).build(),O=await(0,r.Z)(P);return[d.toBuilder().search(O).build(),g]}},MXZnZFI9:(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const s=async(o,...r)=>{for(const n of o)try{const c=await n(...r);if(c!==null)return c===!0}catch(c){console.trace("Exception occurred in deletion confirmation hook: ",c)}return null}},"Jvb3Ez/Z":(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("YcvsU7cw"),s=e("NS75yjmB");const r=()=>(0,t.Z)(s.cE),c=()=>r()},XEgUer9K:(M,C,e)=>{"use strict";e.d(C,{R:()=>o,Z:()=>n});var t=e("QL8i6bcz"),s=e("Z7aTuO5B");const o=async c=>{var v;const d=t.G.exports("forwarder"),g=(v=d==null?void 0:d[0])==null?void 0:v.isLocalNode;try{if(c&&g)return g(c)}catch{}return!0},n=c=>{const[v,d]=(0,s.useState)();return(0,s.useEffect)(()=>{(async()=>{const p=await o(c);d(p)})().catch(()=>d(!0))},[c,v]),{isLocalNode:v}}},Gkq4qIYY:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("YcvsU7cw"),s=e("NS75yjmB");const r=()=>(0,t.Z)(s.Fr)},cFn5u42x:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("Z7aTuO5B"),s=e("YcvsU7cw"),o=e("KAQaaMh7");const n=c=>{const v=(0,s.Z)(o.LB),d=(0,t.useRef)();(0,t.useEffect)(()=>{d.current!==v&&c(),d.current=v},[v])}},qZ8Wpsbl:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("Z7aTuO5B"),s=e("0hhBr0/b");const r=()=>{const n=(0,s.Z)("views.components.saveViewForm");return(0,t.useMemo)(()=>n.map(c=>c()).filter(c=>!!c),[n])}},crOrxG1u:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("DUKaTDO2"),s=e("jAGDuYSC"),o=e("UmnljV2q"),r=e("eFxcQyPT"),n=e("MdYBRjRJ"),c=e("gyRmhZSW");const v={pagination:{total:0},list:[],attributes:[]},d=(0,n.DC)("/search/saved"),g=a=>{const u=(0,c.Z)(d,a.page,a.pageSize,a.query,{sort:a.sort.attributeId,order:a.sort.direction});return(0,r.ZP)("GET",(0,n.DC)(u)).then(({elements:f,attributes:y,total:T,count:P,page:O,per_page:b})=>({list:f.map(L=>o.Z.fromJSON(L)),pagination:{total:T,count:P,page:O,perPage:b},attributes:y}))},E=(a,{enabled:u}={enabled:!0})=>{const{data:f,refetch:y,isInitialLoading:T}=(0,t.useQuery)(["saved-searches","overview",a],()=>g(a),{onError:P=>{s.Z.error(`Loading saved searches failed with status: ${P}`,"Could not load saved searches")},keepPreviousData:!0,enabled:u});return{data:f!=null?f:v,refetch:y,isInitialLoading:T}}},n6M7NB8F:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("YcvsU7cw"),s=e("NS75yjmB");const r=()=>(0,t.Z)(s.fv)},uEPrrliZ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("zIjJeS8Y"),s=e("SqY3hYJN");const o=(g,p)=>g!=null?g:`Unsaved ${(0,s.Z)({type:p,capitalize:!0})}`;var r=e("YcvsU7cw"),n=e("NS75yjmB");const c=(0,t.P1)(n.fv,n.BY,(g,p)=>o(g==null?void 0:g.title,p)),d=()=>(0,r.Z)(c)},xudoaDQq:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("YcvsU7cw"),s=e("NS75yjmB");const r=()=>(0,t.Z)(s.BY)},"gSdhV+tG":(M,C,e)=>{"use strict";e.d(C,{f:()=>o,v:()=>r});var t=e("Z7aTuO5B"),s=e("IA3Ku5lS");const o=(0,s.ri)("contexts.ActionContext",()=>t.createContext({})),r={Provider:({children:n,value:c})=>{const v=(0,t.useContext)(o),d=(0,t.useMemo)(()=>({...v,...c}),[v,c]);return t.createElement(o.Provider,{value:d},n)},Consumer:o.Consumer}},InkdxEOv:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("nxMFMmDQ");const o=r=>t.m4.includes(r)},RhFA9EKs:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p,k:()=>g});var t=e("Z7aTuO5B"),s=e("CHWvwBKE"),o=e("WncxYZtK"),r=e("nxMFMmDQ"),n=e("brbjQOmY");const c=E=>E&&"rangetype"in E?(0,o.g)(E):"relative"in E?(0,o.g)({...E,rangetype:r.pR}):void 0,v=(E={})=>{const a=E.streams;return a==null?[]:String(a).split(",").map(u=>u.trim()).filter(u=>u!=="")},d=E=>{const{q:a}=E!=null?E:{},u=c(E),f=(0,s.en)(v(E));return{timeRange:u,streamsFilter:f,queryString:a?(0,s.Eg)(a):void 0}},g=()=>{const E=(0,n.Z)();return(0,t.useMemo)(()=>{const{timeRange:a,queryString:u,streamsFilter:f}=d(E);return{timeRange:a,queryString:u,streams:(0,s.Fp)(f).toArray()}},[E])},p=d},mPEBamrX:(M,C,e)=>{"use strict";e.d(C,{Z:()=>t});class t{constructor(o){const{backtrace:r,description:n,query_id:c,search_type_id:v,type:d}=o;this._state={backtrace:r,description:n,query_id:c,search_type_id:v,type:d}}get backtrace(){return this._state.backtrace}get description(){return this._state.description}get queryId(){return this._state.query_id}get searchTypeId(){return this._state.search_type_id}get type(){return this._state.type}}},"53I4yQGE":(M,C,e)=>{"use strict";e.d(C,{Z:()=>f});var t=e("VPaD/Np4"),s=e("7FTHePOw"),o=e.n(s),r=e("X8pjX0rJ"),n=e.n(r),c=e("WExy2xUc"),v=e("mPEBamrX");const d=y=>Object.keys(y.searchTypes).map(T=>y.searchTypes[T]).find(T=>T.type.toLowerCase()==="messages"),g=y=>{const T=(0,c.Z)(y);return T&&T.handler?(0,c.Z)(y).handler:{convert:P=>(console.log(`No search type handler for type '${y}' result:`,P),P)}};class p{constructor(T){const{duration:P,timestamp:O,effective_timerange:b}=T.execution_stats;this._state={query:T.query,errors:T.errors.map(L=>new v.Z(L)),duration:P,timestamp:O,effectiveTimerange:b,searchTypes:o()(T.search_types,L=>g(L.type).convert(L))}}get documentCount(){const T=d(this);return T?T.total:0}get duration(){return this._state.duration}get effectiveTimerange(){return this._state.effectiveTimerange}get errors(){return this._state.errors}get messages(){return d(this)}get query(){return this._state.query}get searchTypes(){return this._state.searchTypes}get timestamp(){return this._state.timestamp}}const E=y=>(y==null?void 0:y.type)==="result_window_limit";class a extends v.Z{constructor(T,P){super(T);const{result_window_limit:O}=T;this._state={...this._state,description:a._extendDescription(P,this.description,this.queryId,this.searchTypeId,O)},this._resultWindowLimit=O}static _extendDescription(T,P,O,b,L){const x=a._getPageSizeFromResult(T,O,b),W=Math.floor(L/x);return`${`Elasticsearch limits the search result to ${L} messages. With a page size of ${x} messages, you can use the first ${W} pages.`} ${P}`}static _getPageSizeFromResult(T,P,O){return T.results[P].query.search_types.find(({id:x})=>x===O).limit}get resultWindowLimit(){return this._resultWindowLimit}}class u{constructor(T){var P;this._result=(0,t.fromJS)(T),this._results=(0,t.fromJS)(o()(T.results,O=>new p(O))),this._errors=(0,t.fromJS)(((P=T==null?void 0:T.errors)!=null?P:[]).map(O=>E(O)?new a(O,this):new v.Z(O)))}get result(){return this._result.toJS()}get results(){return this._results.toJS()}get errors(){return this._errors.toJS()}forId(T){return this._results.get(T)}updateSearchTypes(T){const P=this.result;return T.forEach(O=>{const b=this._getQueryBySearchTypeId(O.id);P.results[b.query.id].search_types[O.id]=O}),new u(P)}getSearchTypesFromResponse(T){const P=T.map(O=>{const b=this._getQueryBySearchTypeId(O);return u._getSearchTypeFromQuery(b,O)});return u._filterFailedSearchTypes(P)}_getQueryBySearchTypeId(T){return Object.values(this.result.results).find(P=>u._getSearchTypeFromQuery(P,T))}static _getSearchTypeFromQuery(T,P){return T&&T.search_types?T.search_types[P]:void 0}static _filterFailedSearchTypes(T){return n()(T)}}const f=u},WExy2xUc:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("QL8i6bcz");const s="searchTypes";function o(r){return t.G.exports(s).find(n=>n.type.toLocaleUpperCase()===r.toLocaleUpperCase())}},WncxYZtK:(M,C,e)=>{"use strict";e.d(C,{P:()=>o,g:()=>n});var t=e("PwTFiGSp"),s=e("vT7mdtQI");const o=c=>{switch(c.type){case"relative":return(0,t.a_)(c)?{rangetype:"relative",relative:String(c.range)}:(0,t.SP)(c)?"to"in c?{rangetype:"relative",from:String(c.from),to:String(c.to)}:{rangetype:"relative",from:String(c.from)}:(0,s.Z)(c,"Unexpected time range: ");case"keyword":return{rangetype:"keyword",keyword:c.keyword};case"absolute":return{rangetype:"absolute",from:c.from,to:c.to};default:return(0,s.Z)(c,"Unexpected time range type: ")}},r=c=>{const v=d=>parseInt(d,10);if("relative"in c)return{type:"relative",range:v(c.relative)};if("from"in c){const d={type:"relative",from:v(c.from)};return"to"in c?{...d,to:v(c.to)}:d}return(0,s.Z)(c,"Invalid relative range specified: ")},n=c=>{switch(c==null?void 0:c.rangetype){case"relative":return r(c);case"absolute":return"from"in c&&"to"in c?{type:c.rangetype,from:c.from,to:c.to}:(0,s.Z)(c,"Invalid absolute range specified: ");case"keyword":return"keyword"in c?{type:c.rangetype,keyword:c.keyword,timezone:c.timezone}:(0,s.Z)(c,"Invalid keyword range specified: ");default:return(0,s.Z)(c,"Unsupported range type in range: ")}}},mTnbNx1k:(M,C,e)=>{"use strict";e.d(C,{FZ:()=>u,VW:()=>f,c1:()=>y});var t=e("QL8i6bcz"),s=e("nxMFMmDQ"),o=e("iltCXley"),r=e("ugp+BYjv"),n=e("/QVctsfe"),c=e("fCul1Qwh"),v=e("d2pcYUML"),d=e("PmoDOvRy"),g=e("7J1sc9Ol"),p=e("jlRcBdjT");const E="enterpriseWidgets",a=T=>t.G.exports(E).find(P=>P.type.toLocaleUpperCase()===T.toLocaleUpperCase());function u(T){const P=a(T);if(P)return P;const O=a("default");if(O)return O;throw new Error(`Neither a widget of type "${T}" nor a default widget are registered!`)}const f=(T=(0,o.Z)())=>n.Z.builder().id(T).config(c.Z.builder().columnPivots([]).rowPivots([(0,r.Z)(s.rg,new p.ZP("date",[],[]))]).series([g.ZP.forFunction("count()")]).sort([]).visualization("bar").rollup(!0).build()).build(),y=(T=(0,o.Z)(),P=[])=>v.Z.builder().id(T).config(d.ZP.builder().fields(s.gj).showMessageRow(!0).showSummary(!0).decorators(P).build()).build()},"/QVctsfe":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("VPaD/Np4"),s=e.n(t),o=e("SwOo9/Yp"),r=e("zAtQmw72"),n=e("fCul1Qwh"),c=e("64Qr82UM");const v=class pu extends c.Z{constructor(E,a,u,f,y,T,P){super(E,pu.type,a,u,f,y,T,P)}static fromJSON(E){const{id:a,config:u,filter:f,timerange:y,query:T,streams:P,filters:O}=E;return new pu(a,n.Z.fromJSON(u),f,y,T,P,O)}toBuilder(){const{id:E,config:a,filter:u,timerange:f,query:y,streams:T,filters:P}=this._value;return new g((0,t.Map)({id:E,config:a,filter:u,timerange:f,query:y,streams:T,filters:P}))}static builder(){return new g}equals(E){return E instanceof pu?["id","config","filter","timerange","query","streams","filters"].every(a=>(0,o.Z)(this[a],E[a])):!1}equalsForSearch(E){return E instanceof pu?["id","config","filter","timerange","query","streams","filters"].every(a=>(0,r.Z)(this[a],E[a])):!1}};v.type="AGGREGATION",v.defaultTitle="Untitled Aggregation";let d=v;class g extends c.Z.Builder{build(){const{id:E,config:a,filter:u,timerange:f,query:y,streams:T,filters:P}=this.value.toObject();return new d(E,a,u,f,y,T,P)}}},fCul1Qwh:(M,C,e)=>{"use strict";e.d(C,{Z:()=>a});var t=e("VPaD/Np4"),s=e.n(t),o=e("SwOo9/Yp"),r=e("nxMFMmDQ"),n=e("zAtQmw72"),c=e("o+5fKqZg"),v=e("7J1sc9Ol"),d=e("Lc2t2FX7"),g=e("Wk8izdHL"),p=e("4U1brrvO"),E=e("uDndTqtw");class a extends E.Z{constructor(y,T,P,O,b,L,x,W,N=!1){super(),this._value={columnPivots:y,rowPivots:T,series:P,sort:O,visualization:b,rollup:L,visualizationConfig:x,formattingSettings:W,eventAnnotation:N}}get rowPivots(){return this._value.rowPivots}get columnPivots(){return this._value.columnPivots}get series(){return this._value.series}get sort(){return this._value.sort}get rollup(){return this._value.rollup}get visualization(){return this._value.visualization}get visualizationConfig(){if(this._value.visualizationConfig!==null)return this._value.visualizationConfig}get formattingSettings(){return this._value.formattingSettings}get eventAnnotation(){return this._value.eventAnnotation}get isTimeline(){var y;return this.rowPivots&&this.rowPivots.length===1&&this.rowPivots[0].type===c.Uv&&((y=this.rowPivots[0].fields)==null?void 0:y[0])===r.rg}get isEmpty(){const y=T=>!T.length;return y(this.rowPivots)&&y(this.columnPivots)&&y(this.series)}get rollupForBackendQuery(){return this.columnPivots.length>0?this.rollup:!0}static builder(){return new u().rowPivots([]).columnPivots([]).series([]).sort([]).eventAnnotation(!1).rollup(!1)}toBuilder(){return new u(t.Map(this._value))}toJSON(){const{columnPivots:y,formattingSettings:T,rollup:P,rowPivots:O,series:b,sort:L,visualization:x,visualizationConfig:W,eventAnnotation:N}=this._value;return{column_pivots:y,formatting_settings:T,rollup:P,row_pivots:O,series:b,sort:L,visualization:x,visualization_config:W,event_annotation:N}}equals(y){return y instanceof a?["columnPivots","rowPivots","series","sort","rollup","eventAnnotation","visualizationConfig","visualization","formattingSettings"].every(T=>(0,o.Z)(this[T],y[T])):!1}equalsForSearch(y){return y instanceof a?["rowPivots","columnPivots","series","sort","rollup","eventAnnotation","visualizationConfig"].every(T=>(0,n.Z)(this[T],y[T])):!1}static fromJSON(y){const{column_pivots:T,formatting_settings:P,rollup:O,row_pivots:b,series:L,sort:x,visualization:W,visualization_config:N,event_annotation:Z}=y;return new u().columnPivots(T.map(c.ZP.fromJSON)).rowPivots(b.map(c.ZP.fromJSON)).series(L.map(v.ZP.fromJSON)).sort(x.map(g.Z.fromJSON)).visualization(W).rollup(O).visualizationConfig(N!==null?d.Z.fromJSON(W,N):null).formattingSettings(P===null?void 0:p.Z.fromJSON(P)).eventAnnotation(Z).build()}}class u{constructor(y=t.Map()){this.value=y}columnPivots(y){return new u(this.value.set("columnPivots",y))}rowPivots(y){return new u(this.value.set("rowPivots",y))}series(y){return new u(this.value.set("series",y))}sort(y){return new u(this.value.set("sort",y))}visualization(y){return new u(this.value.set("visualization",y))}visualizationConfig(y){return new u(this.value.set("visualizationConfig",y))}rollup(y){return new u(this.value.set("rollup",y))}formattingSettings(y){return new u(this.value.set("formattingSettings",y))}eventAnnotation(y){return new u(this.value.set("eventAnnotation",y))}build(){const{rowPivots:y,columnPivots:T,series:P,sort:O,visualization:b,rollup:L,visualizationConfig:x,formattingSettings:W,eventAnnotation:N}=this.value.toObject(),Z=[].concat(y,T,P),j=O.filter(z=>Z.find(ne=>{var Y;return z.field===ne.function||((Y=ne.fields)==null?void 0:Y.includes(z.field))}));return new a(T,y,P,j,b,L,x,W,N)}}},"7VrSCphN":(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const t=class zm{constructor(r){this._direction=r}toJSON(){return this._direction}get direction(){return this._direction}equals(r){return r&&r.direction===this._direction}static fromJSON(r){return zm.fromString(r)}static fromString(r){switch(r){case"Ascending":return zm.Ascending;case"Descending":return zm.Descending;default:throw new Error(`Invalid direction: ${r}`)}}};t.Ascending=new t("Ascending"),t.Descending=new t("Descending");let s=t},"o+5fKqZg":(M,C,e)=>{"use strict";e.d(C,{RK:()=>o,Uv:()=>s,ZP:()=>n});var t=e("nxMFMmDQ");const s="time",o="values",r={limit:t.LB,skip_empty_values:!1};class n{constructor(v,d,g=r){this._value={fields:v,type:d,config:g}}get fields(){return this._value.fields}get type(){return this._value.type}get config(){return this._value.config}static create(v,d,g=r){return new n(v,d,g)}static createValues(v,d=r){return n.create(v,o,d)}static fromJSON(v){const{fields:d,type:g,config:p=r}=v;return new n(d,g,p)}toJSON(){const{fields:v,type:d,config:g}=this._value;return{fields:v,type:d,config:g}}}},"7J1sc9Ol":(M,C,e)=>{"use strict";e.d(C,{ZP:()=>a,mf:()=>p,mg:()=>E});var t=e("/yh+QgO6"),s=e.n(t),o=e("VPaD/Np4"),r=e.n(o),n=e("WyXFCd64");const c=/\((.+)\)/,v=/(\w+)\(/,d=/^(\w+)\((.*)(,(\w+))*\)$/,g=(f,y)=>{const[T,P]=y;return f==="percentile"?{type:f,field:T,percentile:P}:f==="percentage"?{type:f,field:T,strategy:P}:{type:f,field:T}},p=f=>d.test(f),E=f=>{const y=v.exec(f);if(!y)return null;const T=y[1],P={type:T},O=c.exec(f);return O?g(T,O[1].split(",")):P};class a{constructor(y,T=n.Z.empty()){this._value={function:y,config:T}}get function(){return this._value.function}get config(){return this._value.config}get effectiveName(){return s()(this,"config.name")||this.function}toString(){return`Series: ${this.effectiveName}, config={${JSON.stringify(this.config)}}`}toJSON(){return{config:this._value.config,function:this._value.function}}static fromJSON(y){return new a(y.function,n.Z.fromJSON(y.config))}static forFunction(y){return new u().function(y).config(n.Z.empty()).build()}static create(y,T,P){const O=P?`,${P}`:"",b=`${y}(${T!=null?T:""}${O})`;return a.forFunction(b)}toBuilder(){return new u(o.Map(this._value))}}class u{constructor(y=o.Map()){this.value=y}function(y){return new u(this.value.set("function",y))}config(y){return new u(this.value.set("config",y))}parameter(y){return new u(this.value.set("parameter",y))}build(){const{config:y}=this.value.toObject(),T=this.value.get("function");return new a(T,y)}}},WyXFCd64:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("VPaD/Np4"),s=e.n(t);class o{constructor(c){this._value={name:c}}get name(){return this._value.name}toJSON(){const{name:c}=this._value;return{name:c}}static fromJSON(c){const{name:v}=c;return new o(v)}static empty(){return new o(null)}toBuilder(){return new r(t.Map(this._value))}}class r{constructor(c=t.Map()){this.value=c}name(c){return new r(this.value.set("name",c))}build(){const{name:c}=this.value.toObject();return new o(c)}}},Wk8izdHL:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("VPaD/Np4"),s=e.n(t),o=e("7VrSCphN");class r{constructor(v,d,g){this._value={type:v,field:d,direction:g}}get type(){return this._value.type}get field(){return this._value.field}get direction(){return this._value.direction}toJSON(){const{type:v,field:d,direction:g}=this._value;return{type:v,field:d,direction:g}}static fromJSON(v){const{type:d,field:g,direction:p}=v;return new n().type(d).field(g).direction(o.Z.fromJSON(p)).build()}static registerSubtype(v,d){this.__registrations[v.toLowerCase()]=d}static fromSeries(v){return new n().type(this.SERIES_TYPE).field(v.function).direction(o.Z.Descending).build()}toBuilder(){const{type:v,field:d,direction:g}=this._value;return new n(t.Map({type:v,field:d,direction:g}))}}r.PIVOT_TYPE="pivot",r.SERIES_TYPE="series",r.__registrations={};class n{constructor(v=t.Map()){this.value=v}type(v){return new n(this.value.set("type",v))}field(v){return new n(this.value.set("field",v))}direction(v){return new n(this.value.set("direction",v))}build(){const{type:v,field:d,direction:g}=this.value.toObject();return new r(v,d,g)}}},"4U1brrvO":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("VPaD/Np4"),s=e.n(t);class o{constructor(c){this._value={chartColors:c}}get chartColors(){return this._value.chartColors}toBuilder(){return new r(t.Map(this._value))}static create(c){return new o(c)}static builder(){return new r().chartColors({})}static empty(){return o.builder().build()}toJSON(){const{chartColors:c}=this._value;return{chart_colors:Object.keys(c).map(d=>({field_name:d,chart_color:c[d]}))}}static fromJSON(c){const{chart_colors:v}=c,d=v.reduce((g,{field_name:p,chart_color:E})=>(g[p]=E,g),{});return o.create(d)}}class r{constructor(c=t.Map()){this.value=c}chartColors(c){return new r(this.value.set("chartColors",c))}build(){const{chartColors:c}=this.value.toObject();return new o(c)}}},hD3VAVgz:(M,C,e)=>{"use strict";e.d(C,{Xm:()=>r,ZP:()=>n});var t=e("VPaD/Np4"),s=e.n(t),o=e("Lc2t2FX7");const r=["Greys","YlGnBu","Greens","YlOrRd","Bluered","RdBu","Reds","Blues","Picnic","Rainbow","Portland","Jet","Hot","Blackbody","Earth","Electric","Viridis","Cividis"];class n extends o.Z{constructor(d,g,p,E,a,u,f){super(),this._value={colorScale:d,reverseScale:g,autoScale:p,zMax:a,zMin:E,useSmallestAsDefault:u,defaultValue:f}}get colorScale(){return this._value.colorScale}get reverseScale(){return this._value.reverseScale}get autoScale(){return this._value.autoScale}get zMin(){return this._value.zMin}get zMax(){return this._value.zMax}get defaultValue(){return this._value.defaultValue}get useSmallestAsDefault(){return this._value.useSmallestAsDefault}toBuilder(){return new c(t.Map(this._value))}static create(d,g,p,E,a,u,f){return new n(d,g,p,E,a,u,f)}static empty(){return new n("Viridis",!1,!0,void 0,void 0,!1,void 0)}toJSON(){const{colorScale:d,reverseScale:g,autoScale:p,zMin:E,zMax:a,useSmallestAsDefault:u,defaultValue:f}=this._value;return{color_scale:d,reverse_scale:g,auto_scale:p,z_min:E,z_max:a,use_smallest_as_default:u,default_value:f}}static fromJSON(d,g={color_scale:"Viridis",reverse_scale:!1,auto_scale:!0,z_min:void 0,z_max:void 0,use_smallest_as_default:!1,default_value:void 0}){const{color_scale:p,reverse_scale:E,auto_scale:a,z_min:u,z_max:f,use_smallest_as_default:y,default_value:T}=g;return n.create(p,E,a,u,f,y,T)}}class c{constructor(d=t.Map()){this.value=d}colorScale(d){return new c(this.value.set("colorScale",d))}reverseScale(d){return new c(this.value.set("reverseScale",d))}autoScale(d){return new c(this.value.set("autoScale",d))}zMin(d){return new c(this.value.set("zMin",d))}zMax(d){return new c(this.value.set("zMax",d))}useSmallestAsDefault(d){return new c(this.value.set("useSmallestAsDefault",d))}defaultValue(d){return new c(this.value.set("defaultValue",d))}build(){const{colorScale:d,reverseScale:g,autoScale:p,zMin:E,zMax:a,useSmallestAsDefault:u,defaultValue:f}=this.value.toObject();return new n(d,g,p,E,a,u,f)}}},Lc2t2FX7:(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const t=class Yh{static fromJSON(r,n){const c=Yh.__registrations[r.toLowerCase()];if(c)return c.fromJSON(r,n);throw new Error(`Unable to find visualization config of type: ${r} - missing plugin?`)}toBuilder(){throw new Error("Must not be called on abstract class!")}equalsForSearch(r){return!0}static registerSubtype(r,n){this.__registrations[r.toLowerCase()]=n}};t.__registrations={};let s=t},eZ5nxjAy:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("XB8LmyQb");const o=t.Z},jlRcBdjT:(M,C,e)=>{"use strict";e.d(C,{E:()=>o,Uv:()=>d,ZP:()=>c});var t=e("VPaD/Np4"),s=e.n(t);const o={Compound:"compound",Enumerable:"enumerable",FullTextSearch:"full-text-search",Numeric:"numeric",Decorated:"decorated"},r=class rf{constructor(p,E,a){this.value=t.Map({type:p,properties:t.Set(E),indexNames:t.Set(a)})}get type(){return this.value.get("type")}get properties(){return this.value.get("properties")}get indexNames(){return this.value.get("indexNames")}isNumeric(){return this.properties.has(o.Numeric)}isEnumerable(){return this.properties.has(o.Enumerable)}isCompound(){return this.properties.has(o.Compound)}isDecorated(){return this.properties.has(o.Decorated)}static fromJSON(p){const{type:E,properties:a,index_names:u}=p;return new rf(E,a,u)}static create(p,E=[],a=[]){return new rf(p,E,a)}};r.Unknown=new r("unknown",[],[]),r.Decorated=new r("decorated field",[o.Decorated],[]);let n=r;const c=n,v=(g,p=[])=>(E=[])=>n.create(g,p,E),d={STRING:v("string",[o.Enumerable]),STRING_FTS:v("string",[o.FullTextSearch]),LONG:v("long",[o.Numeric,o.Enumerable]),INT:v("int",[o.Numeric,o.Enumerable]),SHORT:v("short",[o.Numeric,o.Enumerable]),BYTE:v("byte",[o.Numeric,o.Enumerable]),DOUBLE:v("double",[o.Numeric,o.Enumerable]),FLOAT:v("float",[o.Numeric,o.Enumerable]),DATE:v("date",[o.Enumerable]),BOOLEAN:v("boolean",[o.Enumerable]),BINARY:v("binary",[]),GEO_POINT:v("geo-point",[]),IP:v("ip",[o.Enumerable]),PERCENTAGE:v("percentage",[o.Numeric])}},"8Crd7QGv":(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("jlRcBdjT");class s{constructor(n,c){this.value={name:n,type:c}}get name(){return this.value.name}get type(){return this.value.type}static fromJSON(n){const{name:c,type:v}=n;return new s(c,t.ZP.fromJSON(v))}static create(n,c){return new s(n,c)}}const o=s},kXOFp4bk:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("7J1sc9Ol"),s=e("jlRcBdjT"),o=e("8Crd7QGv");const r=["avg","min","max","percentile"],n={card:s.Uv.LONG,count:s.Uv.LONG,percentage:s.Uv.PERCENTAGE},v=(d,g)=>{const p=(0,t.mg)(d.function),E=f=>o.Z.create(d.function,f);if(p===null)return E(s.ZP.Unknown);const{type:a,field:u}=p;if(n[a])return E(n[a]());if(r.includes(a)){const f=g==null?void 0:g.find(y=>y.name===u);return E(f?f.type:s.ZP.Unknown)}return E(s.Uv.FLOAT())}},"9kZNWwre":(M,C,e)=>{"use strict";e.d(C,{Z:()=>y});var t=e("Z7aTuO5B"),s=e("DUKaTDO2"),o=e("MdYBRjRJ"),r=e("eFxcQyPT"),n=e("8Crd7QGv"),c=e("IZYxBTgT"),v=e("O/XpfGnR"),d=e("IA3Ku5lS");const g=(0,o.DC)("/views/fields"),p=T=>T.map(P=>n.Z.fromJSON(P)),E=(T,P)=>{let O={};return T&&T.length>0&&(O={streams:T}),P&&(O={...O,timerange:P}),O},a=(T,P)=>(0,r.ZP)("POST",g,E(T,P)).then(p),u=(T,P)=>{switch(T==null?void 0:T.type){case"absolute":return{type:"absolute",from:(0,c.Od)((0,c.U2)(T.from,P),"internal"),to:(0,c.Od)((0,c.U2)(T.to,P),"internal")};default:return T}},f=(T,P)=>{const{userTimezone:O}=(0,v.Z)(),b=(0,t.useMemo)(()=>u(P,O),[P,O]);return(0,s.useQuery)(["fieldTypes",T,b],()=>a(T,b),{staleTime:3e4,refetchOnWindowFocus:!1,cacheTime:0})},y=(0,d.ri)("hooks.useFieldTypes",()=>f)},fBC5XqGO:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("VPaD/Np4"),s=e.n(t),o=e("BcOICGB7");const r=class gu extends o.Z{constructor(d,g,p,E,a,u,f,y){super(gu.type,d,g,p,E,a,u),this._value2={lookupTable:f,key:y}}static create(d,g,p,E,a,u,f,y,T){return new gu(g,p,E,a,u,f,y,T)}toBuilder(){const{type:d,name:g,title:p,description:E,dataType:a,defaultValue:u,optional:f}=this._value,{lookupTable:y,key:T}=this._value2;return new c(t.Map({type:d,name:g,title:p,description:E,dataType:a,defaultValue:u,optional:f,lookupTable:y,key:T}))}get needsBinding(){return!1}get lookupTable(){return this._value2.lookupTable}get key(){return this._value2.key}toJSON(){const{type:d,name:g,title:p,description:E,dataType:a,defaultValue:u,optional:f}=this._value,{lookupTable:y,key:T}=this._value2;return{type:d,name:g,title:p,description:E,data_type:a,default_value:u,optional:f,binding:void 0,lookup_table:y,key:T}}static fromJSON(d){const{name:g,title:p,description:E,data_type:a,default_value:u,optional:f,lookup_table:y,key:T}=d;return new gu(g,p,E,a,u,f,y,T)}static builder(){return new c().type(gu.type).optional(!1).dataType("any")}};r.type="lut-parameter-v1";let n=r;class c{constructor(d=t.Map()){this.value=d}type(d){return new c(this.value.set("type",d))}name(d){return new c(this.value.set("name",d))}title(d){return new c(this.value.set("title",d))}description(d){return new c(this.value.set("description",d))}dataType(d){return new c(this.value.set("dataType",d))}defaultValue(d){return new c(this.value.set("defaultValue",d))}optional(d){return new c(this.value.set("optional",d))}lookupTable(d){return new c(this.value.set("lookupTable",d))}key(d){return new c(this.value.set("key",d))}build(){const{name:d,title:g,description:p,dataType:E,defaultValue:a,optional:u,lookupTable:f,key:y}=this.value.toObject();return new n(d,g,p,E,a,u,f,y)}}n.Builder=c},BcOICGB7:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("IA3Ku5lS");const s=class qh{constructor(v,d,g,p,E,a,u,f){this._value={type:v,name:d,title:g,description:p,dataType:E,defaultValue:a,optional:u,binding:f}}get type(){return this._value.type}get name(){return this._value.name}get title(){return this._value.title}get description(){return this._value.description}get dataType(){return this._value.dataType}get defaultValue(){return this._value.defaultValue}get optional(){return this._value.optional}get needsBinding(){return!0}get binding(){return this._value.binding}static fromJSON(v){const{type:d="value-parameter-v1"}=v,g=qh.__registrations[d.toLowerCase()];if(g)return g.fromJSON(v);throw new Error(`No class found for type <${d}>`)}static registerSubtype(v,d){this.__registrations[v.toLowerCase()]=d}toJSON(){throw new Error("Method toJSON has no implementation")}};s.__registrations={};let o=s;const n=(0,t.ri)("views.logic.parameters.Parameter",()=>o)},yM9BwDic:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("VPaD/Np4"),s=e.n(t);class o{constructor(c,v){this._value={type:c,value:v}}get type(){return this._value.type}get value(){return this._value.value}toBuilder(){const{type:c,value:v}=this._value;return new r(t.Map({type:c,value:v}))}static create(c,v){return new o(c,v)}static forValue(c){return o.create("value",c)}static empty(){return o.create("value","")}toJSON(){const{type:c,value:v}=this._value;return{type:c,value:v}}static fromJSON(c){if(c==null)return null;const{type:v,value:d}=c;return o.create(v,d)}}class r{constructor(c=t.Map()){this._value=c}type(c){return new r(this._value.set("type",c))}value(c){return new r(this._value.set("value",c))}build(){const{type:c,value:v}=this._value.toObject();return new o(c,v)}}},QV1daZoe:(M,C,e)=>{"use strict";e.d(C,{MD:()=>d,P3:()=>g,uc:()=>v});var t=e("nxMFMmDQ"),s=e("PwTFiGSp");const r=p=>(0,s.SP)(p)&&p.from===t.r$||(0,s.a_)(p)&&p.range===t.r$;var n=e("z45xmHGk"),c=e("IZYxBTgT");const v=p=>"type"in p&&r(p)?{type:p.type,range:t.r$}:p,d=p=>p?(a=>(0,s.je)(a)?{type:a.type,timezone:a.timezone,keyword:a.keyword}:a)(v((0,n.PQ)(p))):t.iM,g=(p,E)=>{const{type:a}=p;switch(p.type){case"absolute":return{type:p.type,from:(0,c.Od)((0,c.U2)(p.from,E),"internal"),to:(0,c.Od)((0,c.U2)(p.to,E),"internal")};case"relative":if((0,s.a_)(p))return{type:p.type,range:p.range};if((0,s.SP)(p))return"to"in p?{type:p.type,from:p.from,to:p.to}:{type:p.type,from:p.from};throw new Error("Invalid relative time range");case"keyword":return p;default:throw new Error(`Invalid time range type: ${a}`)}}},CHWvwBKE:(M,C,e)=>{"use strict";e.d(C,{Eg:()=>n,Fp:()=>d,ZP:()=>p,en:()=>v});var t=e("VPaD/Np4"),s=e.n(t),o=e("SwOo9/Yp"),r=e("iltCXley");const n=(a="")=>({type:"elasticsearch",query_string:a}),c=a=>t.List(a.map(u=>t.Map({type:"stream",id:u}))),v=a=>{if(!a||a.length===0)return null;const u=c(a);return t.Map({type:"or",filters:u})},d=a=>a?a.get("type")==="stream"?t.Set([a.get("id")]):a.get("filters",t.List()).map(d).reduce((y,T)=>y.merge(T),t.Set()):t.Set(),g=a=>a==null;class p{constructor(u,f,y,T,P,O){this._value={id:u,query:f,timerange:y,filter:T,filters:O,searchTypes:P}}get id(){return this._value.id}get query(){return this._value.query}get timerange(){return this._value.timerange}get filter(){return this._value.filter}get filters(){return this._value.filters}get searchTypes(){return this._value.searchTypes}toBuilder(){const{id:u,query:f,timerange:y,filter:T,filters:P,searchTypes:O}=this._value,b=p.builder().id(u).query(f).timerange(y).filter(T).filters(P).searchTypes(O);return T?b.filter(T):b}equals(u){return!(u===void 0||!(u instanceof p)||this.id!==u.id||!(0,o.Z)(this.query,u.query)||!(0,o.Z)(this.timerange,u.timerange)||!(g(this.filter)&&g(u.filter)||(0,o.Z)(this.filter,u.filter))||!(g(this.filters)&&g(u.filters)||(0,o.Z)(this.filters,u.filters))||!(0,o.Z)(this.searchTypes,u.searchTypes))}toJSON(){const{id:u,query:f,timerange:y,filter:T,filters:P,searchTypes:O}=this._value;return{id:u,query:f,timerange:y,filter:T,filters:P,search_types:O}}static builder(){return new E().searchTypes([])}static fromJSON(u){const{id:f,query:y,timerange:T,filter:P,filters:O,search_types:b}=u;return new p(f,y,T,t.fromJS(P),b,O&&t.List(O))}}class E{constructor(u=t.Map()){this.value=u}id(u){return new E(this.value.set("id",u))}newId(){return this.id((0,r.Z)())}query(u){return new E(this.value.set("query",u))}timerange(u){return new E(this.value.set("timerange",u))}filter(u){return new E(this.value.set("filter",t.fromJS(u)))}filters(u){return new E(this.value.set("filters",u&&t.List(u)))}searchTypes(u){return new E(this.value.set("searchTypes",u))}build(){const{id:u,query:f,timerange:y,filter:T,filters:P,searchTypes:O}=this.value.toObject();return new p(u,f,y,T,O,P)}}},ZJjLtB2e:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("nxMFMmDQ"),s=e("CHWvwBKE"),o=e("iltCXley");const r=(n,c=(0,o.Z)(),v,d)=>{const g=n?n instanceof Array?n:[n]:null,p=(0,s.en)(g),E=s.ZP.builder().id(c).query(d!=null?d:(0,s.Eg)()).timerange(v!=null?v:t.nn);return p?E.filter(p).build():E.build()}},"I4XORk+Y":(M,C,e)=>{"use strict";e.d(C,{$_:()=>n,YU:()=>r,_5:()=>c});var t=e("sWSSTOXR"),s=e.n(t);const o=v=>String(v).indexOf(" ")!==-1,r=v=>{let d=String(v);return d=d.replace(/\r\n/g," "),d=d.replace(/\n/g," "),d=d.replace(/
/g," "),o(d)?(d=String(d).replace(/(["\\])/g,"\\$&"),d=`"${d}"`):d=String(d).replace(/(&&|\|\||[:\\/+\-!(){}[\]^"~*?$])/g,"\\$&"),d},n=(v,d,g="AND")=>s()(v)==="*"||s()(v)===""?d:s()(d)==="*"||s()(d)===""?v:`${v} ${g} ${d}`,c=(v,{operator:d="AND",withBrackets:g=!0}={})=>{const p=v.filter(a=>!!(a!=null&&a.trim())),E=g&&p.length>1;return p.map(a=>E?`(${a})`:a).join(` ${d} `)}},pzHcYe8v:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("6BCpJW2W");const o=(r,n)=>r&&r.search&&r.search.queries?r.search.queries.keySeq().map((c,v)=>{if(n!==void 0&&c.id!==void 0&&n===c.id)return r.state?r.state.getIn([c.id],t.Z.create()).titles.getIn(["tab","title"],`Page#${v+1}`):`Page#${v+1}`}).filter(c=>c!==void 0).first():void 0},"Ii+QL2UH":(M,C,e)=>{"use strict";e.d(C,{U:()=>d,Z:()=>u});var t=e("9oVghaOd"),s=e.n(t),o=e("gtXNkEXl"),r=e.n(o),n=e("V4hxOpTk"),c=e.n(n),v=e("PwTFiGSp");const d=(f,y,T="All Time")=>{const P=f==null?void 0:f[y];if(!P)return T;const O=s()(),b=s()(O).subtract(P,"seconds");return`${s().preciseDiff(O,b)} ago`},g=f=>(0,v.a_)(f)?f.range===0?"All Time":`${d(f,"range")} - Now`:`${d(f,"from")} - ${d(f,"to","Now")}`,p=(f,y=T=>T)=>{const{from:T,to:P}=f;return`${y(T)} - ${y(P)}`},E=f=>f.keyword,u=(f,y)=>{const{type:T}=f||{};switch(T){case"relative":return g(f);case"absolute":return p(f,y);case"keyword":return E(f);default:return""}}},m7J9z16Z:(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("YcvsU7cw"),s=e("NS75yjmB");const r=()=>(0,t.Z)(s.zq)},LqPK8SLb:(M,C,e)=>{"use strict";e.d(C,{Z:()=>o});var t=e("VPaD/Np4"),s=e.n(t);class o{constructor(c,v,d,g,p){this._value={timerange:c,query:v,keepSearchTypes:d,searchTypes:g,keepQueries:p}}get timerange(){return this._value.timerange}get query(){return this._value.query}get keepSearchTypes(){return this._value.keepSearchTypes}get keepQueries(){return this._value.keepQueries}get searchTypes(){return this._value.searchTypes}toBuilder(){const{timerange:c,query:v,keepSearchTypes:d,searchTypes:g,keepQueries:p}=this._value;return new r(t.Map({timerange:c,query:v,keepSearchTypes:d,searchTypes:g,keepQueries:p}))}static create(c,v,d,g,p){return new o(c,v,d,g,p)}static empty(){return new o}toJSON(){const{timerange:c,query:v,keepSearchTypes:d,keepQueries:g,searchTypes:p}=this._value;return{timerange:c,query:v,keep_search_types:d,keep_queries:g,search_types:p}}static fromJSON(c){const{timerange:v,query:d,keep_search_types:g,search_types:p,keep_queries:E}=c;return o.create(v,d,g,p,E)}}class r{constructor(c=t.Map()){this.value=c}timerange(c){return new r(this.value.set("timerange",c))}query(c){return new r(this.value.set("query",c))}keepSearchTypes(c){return new r(this.value.set("keepSearchTypes",c))}keepQueries(c){return new r(this.value.set("keepQueries",c))}searchTypes(c){return new r(this.value.set("searchTypes",c))}build(){const{timerange:c,query:v,keepSearchTypes:d,searchTypes:g,keepQueries:p}=this.value.toObject();return new o(c,v,d,g,p)}}},"/coHI+Jz":(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("VPaD/Np4"),s=e.n(t),o=e("Jg5wVMAu"),r=e.n(o),n=e("CHWvwBKE"),c=e("BcOICGB7");class v{constructor(p,E,a){this._value={id:p,queries:t.OrderedSet(E),parameters:t.Set(a)}}static create(){return new d().newId().queries([]).parameters([]).build()}get id(){return this._value.id}get queries(){return this._value.queries}get parameters(){return this._value.parameters}get requiredParameters(){return this.parameters.filter(p=>!p.defaultValue&&!p.optional&&p.needsBinding).toSet()}toBuilder(){const{id:p,queries:E,parameters:a}=this._value;return new d(t.Map({id:p,queries:E,parameters:a}))}toJSON(){const{id:p,queries:E,parameters:a}=this._value;return{id:p,queries:E.toJS(),parameters:a.toJS()}}static fromJSON(p){const{id:E,parameters:a}=p,u=p.queries.map(f=>n.ZP.fromJSON(f));return new v(E,u,a.map(f=>c.Z.fromJSON(f)))}static builder(){return new d}}class d{constructor(p=t.Map()){this.value=p}id(p){return new d(this.value.set("id",p))}newId(){return this.id(new(r())().toString())}queries(p){return new d(this.value.set("queries",p))}parameters(p){return new d(this.value.set("parameters",p))}build(){const{id:p,queries:E,parameters:a}=this.value.toObject();return new v(p,E,a)}}},oMyijaIY:(M,C,e)=>{"use strict";e.d(C,{ZP:()=>r});var t=e("VPaD/Np4"),s=e.n(t),o=e("yM9BwDic");class r{constructor(g=t.Map(),p){this._value={parameterBindings:g,globalOverride:p}}get parameterBindings(){return this._value.parameterBindings}get globalOverride(){return this._value.globalOverride}toBuilder(){const{globalOverride:g,parameterBindings:p}=this._value;return new n(t.Map({globalOverride:g,parameterBindings:p}))}static create(g,p){return new r(g,p)}static empty(){return new r}toJSON(){const{globalOverride:g,parameterBindings:p}=this._value;return{global_override:g,parameter_bindings:p}}static fromJSON(g){const{global_override:p,parameter_bindings:E}=g;return r.create(E,p)}}class n{constructor(g=t.Map()){this.value=g}parameterBindings(g){return new n(this.value.set("parameterBindings",g))}globalOverride(g){return new n(this.value.set("globalOverride",g))}build(){const{globalOverride:g,parameterBindings:p}=this.value.toObject();return new r(p,g)}}const c=(d,g)=>d.parameterBindings.get(g,ParameterBinding.empty()).value,v=d=>d.flatMap((g,p)=>Immutable.Map({[p]:g.value}))},"/8lbhT5j":(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("VPaD/Np4"),s=e.n(t),o=e("oCSEoDew"),r=e.n(o),n=e("d4kzUuQm"),c=e("WncxYZtK"),v=e("I4XORk+Y");const d=(E,a={})=>Object.keys(a).filter(u=>a[u]!==null&&a[u]!==void 0).map(u=>`${u}:"${(0,v.YU)(String(a[u]))}"`).reduce((u,f)=>(0,v.$_)(u,f),E?E.query_string:"");class g{constructor(a,u,f,y,T,P){this._value={id:a,timerange:u,query:f,streams:y,highlightedMessage:T,filterFields:P}}get id(){return this._value.id}get timerange(){return this._value.timerange}get query(){return this._value.query}get streams(){return this._value.streams}get highlightedMessage(){return this._value.highlightedMessage}get filterFields(){return this._value.filterFields}static builder(){return new p}toURL(){const{id:a,query:u,highlightedMessage:f,streams:y,filterFields:T,timerange:P}=this._value,O=d(u,T),L={...P?(0,c.P)(P):{},q:O===""?void 0:O,highlightMessage:f},x=y&&y.length>0?{...L,streams:y.join(",")}:L,W=a?`${n.ZP.SEARCH}/${a}`:n.ZP.SEARCH;return new(r())(W).setSearch(x).toString()}}class p{constructor(a=t.Map()){this.value=a}id(a){return new p(this.value.set("id",a))}timerange(a){return new p(this.value.set("timerange",a))}query(a){return new p(this.value.set("query",a))}streams(a){return new p(this.value.set("streams",a))}highlightedMessage(a){return new p(this.value.set("highlightedMessage",a))}filterFields(a){return new p(this.value.set("filterFields",a))}build(){const{id:a,timerange:u,query:f,streams:y,highlightedMessage:T,filterFields:P}=this.value.toObject();return new g(a,u,f,y,T,P)}}},"ugp+BYjv":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("8u9vblRK"),s=e.n(t),o=e("o+5fKqZg");const r=(n,c)=>{const v=s()(n)?n:[n];switch(c.type){case"date":return o.ZP.create(v,"time",{interval:{type:"auto",scaling:1}});default:return o.ZP.createValues(v)}}},b2fGY8bZ:(M,C,e)=>{"use strict";e.d(C,{Ce:()=>o,Xo:()=>r,ZP:()=>n});var t=e("t5bvLtVB"),s=e.n(t);const o="#d3d3d3",r="Alerts",n={convert(c){return c},toVisualizationData(c,v){const d=s()(c,g=>g.timestamp);return{eventChartData:this.toChartData(d,v),shapes:this.toShapeData(Object.keys(d),v)}},transformGroupedEvents(c){return Object.entries(c).map(([v,d])=>{if(!(d instanceof Array))throw new Error("Unexpected data type");return d.length>1?[v,d.length]:[v,d[0]]})},toChartData(c,v){const d=this.transformGroupedEvents(c),g=d.map(a=>v(a[0])),p=d.map(a=>typeof a[1]!="number"&&"message"in a[1]?a[1].message:`${a[1]} alerts occurred.`),E=d.map(()=>0);return{hovertemplate:"%{text}",mode:"markers",name:r,type:"scatter",opacity:.5,x:g,y:E,text:p,originalName:r}},toShapeData(c,v){return c.map(d=>{const g=v(d);return{layer:"below",type:"line",yref:"paper",y0:0,y1:1,x0:g,x1:g,opacity:.5}})}}},g2NQZb9A:(M,C,e)=>{"use strict";e.d(C,{Z:()=>c});var t=e("MdYBRjRJ"),s=e("/coHI+Jz"),o=e("eFxcQyPT");const r=(0,t.DC)("/views/search"),c=v=>(0,o.ZP)("POST",r,JSON.stringify(v)).then(d=>s.Z.fromJSON(d))},gofDlXL2:(M,C,e)=>{"use strict";e.d(C,{K$:()=>a,XB:()=>d,lN:()=>c,lp:()=>p,u8:()=>v,vI:()=>E});var t=e("UnwAqHt2"),s=e("NS75yjmB"),o=e("4/JSMBsA"),r=e("rNH0cW39"),n=e("dogTzS57");const c=u=>async(f,y)=>{const T=(0,s.cE)(y()),P=(0,s.Sq)(y()),{formatting:O=o.Z.empty()}=P,b=P.toBuilder().formatting(O.toBuilder().highlighting(u).build()).build();return f((0,r.VN)(T,b))},v=(u,f)=>async(y,T)=>{const P=(0,n.e)(T());if(Object.entries(f).length===0)return Promise.resolve();const b=Object.entries(f).reduce((x,[W,N])=>x[W](N),u.toBuilder()).build(),L=P.map(x=>x===u?b:x);return y(c(L))},d=u=>async(f,y)=>{const T=(0,s.Sq)(y()),{formatting:P=o.Z.empty()}=T;return f(c([...P.highlighting,u]))},g=u=>async(f,y)=>{const T=(0,s.Sq)(y()),{formatting:P=o.Z.empty()}=T;return f(c([...P.highlighting,...u]))},p=(u,f)=>async y=>{const T=t.ZP.builder().field(u).value(f).color((0,t.p)()).build();return y(d(T))},E=u=>async f=>{const y=u.map(({field:T,value:P,color:O,condition:b})=>t.ZP.builder().field(T).value(P).condition(b||"equal").color(O||(0,t.p)()).build());return f(g(y))},a=u=>async(f,y)=>{const P=(0,n.e)(y()).filter(O=>O!==u);return f(c(P))}},dogTzS57:(M,C,e)=>{"use strict";e.d(C,{e:()=>o});var t=e("zIjJeS8Y"),s=e("NS75yjmB");const o=(0,t.P1)(s.Sq,r=>{var n,c;return(c=(n=r==null?void 0:r.formatting)==null?void 0:n.highlighting)!=null?c:[]})},"Gu/qTBta":(M,C,e)=>{"use strict";e.d(C,{Z:()=>g});var t=e("MdYBRjRJ"),s=e("eFxcQyPT"),o=e("VPaD/Np4");class r{constructor(E){this._value={usedParameterNames:E}}get usedParameterNames(){return this._value.usedParameterNames}static fromJSON(E){return new r(o.Set(E.used_parameters_names))}}var n=e("BcOICGB7");class c{constructor(E,a){const u=E.valueSeq().reduce((P,O)=>[...P,...O.usedParameterNames.toJS()],[]),f=a.keySeq().toJS(),y=o.Set(u.filter(P=>f.includes(P)).map(P=>a.get(P))),T=o.Set(u.filter(P=>!f.includes(P)));this._value={queryMetadata:E,declaredParameters:a,used:y,undeclared:T}}get queryMetadata(){return this._value.queryMetadata}get declaredParameters(){return this._value.declaredParameters}get used(){return this._value.used}get undeclared(){return this._value.undeclared}static empty(){return new c(o.Map(),o.Map())}static fromJSON(E){const{query_metadata:a,declared_parameters:u}=E,f=o.Map(a).map(T=>r.fromJSON(T)).toMap(),y=o.Map(u).map(T=>n.Z.fromJSON(T)).toMap();return new c(f,y)}}const v=t.DC("/views/search/metadata"),g=p=>(0,s.ZP)("POST",v,JSON.stringify(p)).then(E=>c.fromJSON(E),()=>{})},KAQaaMh7:(M,C,e)=>{"use strict";e.d(C,{AS:()=>n,Gu:()=>r,LB:()=>c,gX:()=>v,nK:()=>d,nR:()=>o});var t=e("zIjJeS8Y");const s=g=>g.searchExecution,o=(0,t.P1)(s,g=>g.executionState),r=(0,t.P1)(s,g=>g.widgetsToSearch),n=(0,t.P1)(s,g=>g.result),c=(0,t.P1)(n,g=>{var p,E;return(E=(p=g==null?void 0:g.result)==null?void 0:p.result)==null?void 0:E.id}),v=(0,t.P1)(o,g=>g.globalOverride),d=(0,t.P1)(o,g=>g.parameterBindings)},"6/nLyfIT":(M,C,e)=>{"use strict";e.d(C,{ht:()=>H,Q_:()=>ue,J8:()=>ee,YD:()=>ut,B3:()=>ye,A7:()=>we,Gd:()=>ne});var t=e("s98ZeFHv"),s=e("VPaD/Np4"),o=e("sWSSTOXR"),r=e("oMyijaIY"),n=e("iyGdd7jp"),c=e("LqPK8SLb"),v=e("eFxcQyPT"),d=e("MdYBRjRJ");const g=le=>d.DC(`/views/search/${le}/execute`),p=le=>d.DC(`/views/search/status/${le}`);function E(le,me){return(0,v.ZP)("POST",g(le.id),JSON.stringify(me))}function a(le){return(0,v.ZP)("GET",p(le))}var u=e("53I4yQGE");const f=le=>new Promise(me=>{setTimeout(me,le)}),y=le=>new Promise(me=>{var re,ce;(re=le==null?void 0:le.execution)!=null&&re.done||(ce=le==null?void 0:le.execution)!=null&&ce.completed_exceptionally?me(le):me(f(250).then(()=>a(le.id)).then(Q=>y(Q)))}),P=(le,me,re,ce=[])=>{var Q;const{widgetMapping:J,search:ie}=le,ge=((Q=re.globalOverride)!=null?Q:c.Z.empty()).toBuilder().keepQueries(ce).build();let fe=re.toBuilder().globalOverride(ge);if(me){const Oe=me.map(et=>J.get(et)).reduce((et,Fe)=>Fe?[...et,...Fe.toArray()]:et,ge.keepSearchTypes||[]),nt=ge.toBuilder().keepSearchTypes(Oe).build();fe=fe.globalOverride(nt)}const Ce=fe.build();return E(ie,Ce).then(Oe=>y(Oe)).then(Oe=>({widgetMapping:J,result:new u.Z(Oe)}))};var O=e("NS75yjmB"),b=e("KAQaaMh7"),L=e("yM9BwDic"),x=e("rNH0cW39"),W=e("CHWvwBKE");const N=(0,t.oM)({name:"searchExecution",initialState:{widgetsToSearch:void 0,executionState:r.ZP.empty(),isLoading:!1,result:void 0},reducers:{loading:le=>({...le,isLoading:!0}),finishedLoading:(le,me)=>({...le,isLoading:!1,result:me.payload}),updateGlobalOverride:(le,me)=>({...le,executionState:le.executionState.toBuilder().globalOverride(me.payload).build()}),setWidgetsToSearch:(le,me)=>({...le,widgetsToSearch:me.payload}),setParameterValues:(le,me)=>{const re=me.payload;let{parameterBindings:ce}=le.executionState;return re.forEach((Q,J)=>{ce=ce.set(J,L.Z.forValue(Q))}),{...le,executionState:le.executionState.toBuilder().parameterBindings(ce).build()}},setParameterBindings:(le,me)=>({...le,executionState:le.executionState.toBuilder().parameterBindings(me.payload).build()}),addParameterBindings:(le,me)=>{const{parameterBindings:re}=le.executionState,ce=me.payload,Q=s.Map(ce.filter(ie=>!!ie.defaultValue).map(ie=>[ie.name,L.Z.forValue(ie.defaultValue)])),J=re.merge(Q);return{...le,executionState:le.executionState.toBuilder().parameterBindings(J).build()}}}}),{loading:Z,finishedLoading:j,updateGlobalOverride:z,setWidgetsToSearch:ne,setParameterValues:Y,setParameterBindings:ae}=N.actions,ee=N.reducer,ue=(le,me,re,ce)=>(Q,J)=>Q((0,n.U)(le.search)).then(()=>{Q(Z());const ie=(0,O.cE)(J());return P(le,me,re,[ie]).then(ce).then(ge=>Q(j(ge)))}),H=()=>(le,me)=>{const re=me(),ce=(0,O.fv)(re),Q=(0,b.nR)(re),J=(0,b.Gu)(re);return le(ue(ce,J,Q,ie=>ie))},ye=le=>async(me,re)=>{var ce;const J=((ce=(0,b.gX)(re()))!=null?ce:c.Z.empty()).toBuilder().query((0,W.Eg)(le)).build();return me(N.actions.updateGlobalOverride(J))},we=le=>async(me,re)=>{var ce;const J=((ce=(0,b.gX)(re()))!=null?ce:c.Z.empty()).toBuilder().timerange(le).build();return me(N.actions.updateGlobalOverride(J))},ut=(le,me)=>(re,ce)=>{var Q;const ie=((Q=(0,b.gX)(ce()))!=null?Q:c.Z.empty()).toBuilder().query((0,W.Eg)(le)).timerange(me).build();return re(N.actions.updateGlobalOverride(ie))},ht=le=>async(me,re)=>{const ce=selectParameters(re()).toArray(),Q=le.valueSeq().toArray();return await me(N.actions.addParameterBindings(Q)),me(setParameters([...ce,...Q]))},Je=le=>async(me,re)=>{const Q=selectParameters(re()).filter(ge=>ge.name!==le).toArray(),ie=selectParameterBindings(re()).remove(le);return await me(setParameters(Q)),me(N.actions.setParameterBindings(ie))},Re=(le,me)=>async(re,ce)=>{const J=selectParameters(ce()).map(ge=>ge.name===le?me:ge).toArray(),ie=selectParameterBindings(ce());if(!trim(ie.get(le,ParameterBinding.empty()).value)&&me.defaultValue){const ge=ie.set(le,ParameterBinding.forValue(me.defaultValue));await re(N.actions.setParameterBindings(ge))}return re(setParameters(J))}},iyGdd7jp:(M,C,e)=>{"use strict";e.d(C,{T:()=>c,U:()=>v});var t=e("s98ZeFHv"),s=e("Gu/qTBta");const o=(0,t.oM)({name:"searchMetadata",initialState:{isLoading:!1,metadata:void 0},reducers:{loading:d=>({...d,isLoading:!0,metadata:void 0}),finishedLoading:(d,g)=>({...d,isLoading:!1,metadata:g.payload})}}),{finishedLoading:r,loading:n}=o.actions,c=o.reducer,v=d=>async g=>(g(n()),(0,s.Z)(d).then(p=>g(r(p))))},A2mY8G47:(M,C,e)=>{"use strict";e.d(C,{T:()=>v});var t=e("NS75yjmB"),s=e("rNH0cW39"),o=e("zIjJeS8Y");const r=(0,o.P1)(t.Sq,d=>d.titles),n=d=>(0,o.P1)((0,t.yF)(d),g=>g.titles),c=(d,g)=>async(p,E)=>{const u=selectViewState(d)(E()).toBuilder().titles(g).build();return p(updateViewState(d,u))},v=(d,g,p,E)=>async(a,u)=>{const f=(0,t.yF)(d)(u()),T=n(d)(u()).setIn([g,p],E),P=f.toBuilder().titles(T).build();return a((0,s.VN)(d,P))}},qIv98lrg:(M,C,e)=>{"use strict";e.d(C,{Z:()=>s,b:()=>o});var t=e("zIjJeS8Y");const s=r=>r.undoRedo,o=(0,t.P1)(s,({currentRevision:r,revisions:n})=>({isUndoAvailable:r>0,isRedoAvailable:r{"use strict";e.d(C,{ZT:()=>d,kJ:()=>v,oh:()=>n});var t=e("s98ZeFHv"),s=e("qIv98lrg");const o=10,r=(0,t.oM)({name:"undoRedo",initialState:{revisions:[],currentRevision:0},reducers:{setRevisions:(g,p)=>({...g,revisions:p.payload.revisions,currentRevision:p.payload.currentRevision}),setCurrentRevision:(g,p)=>({...g,currentRevision:p.payload})}}),n=r.reducer,{setRevisions:c,setCurrentRevision:v}=r.actions,d=(g,p=!0)=>async(E,a)=>{const{revisions:u,currentRevision:f}=(0,s.Z)(a()),T=f===u.length?u:u.slice(0,f),P=T.length{"use strict";e.d(C,{$o:()=>d,BY:()=>p,Fr:()=>g,Gn:()=>x,IB:()=>z,LM:()=>b,Ln:()=>ne,M7:()=>j,RM:()=>E,RN:()=>L,Sq:()=>u,cE:()=>v,fv:()=>c,sh:()=>P,vz:()=>T,yF:()=>a,zB:()=>n,zq:()=>O});var t=e("zIjJeS8Y"),s=e("KAQaaMh7"),o=e("UmnljV2q"),r=e("CHWvwBKE");const n=Y=>Y.view,c=(0,t.P1)(n,Y=>Y.view),v=(0,t.P1)(n,Y=>Y.activeQuery),d=(0,t.P1)(n,Y=>Y.isDirty),g=(0,t.P1)(n,Y=>Y.isNew),p=(0,t.P1)(c,Y=>Y.type),E=(0,t.P1)(c,Y=>Y.state),a=Y=>(0,t.P1)(E,ae=>ae.get(Y)),u=(0,t.P1)(v,E,(Y,ae)=>ae==null?void 0:ae.get(Y)),f=(0,t.P1)(c,Y=>Y.search),y=(0,t.P1)(f,Y=>Y.id),T=(0,t.P1)(f,Y=>Y.queries),P=Y=>(0,t.P1)(T,ae=>ae.find(ee=>ee.id===Y)),O=(0,t.P1)(v,T,(Y,ae)=>ae.find(ee=>ee.id===Y)),b=Y=>(0,t.P1)(T,ae=>ae.find(ee=>ee.id===Y)),L=(0,t.P1)(u,Y=>Y.widgets),x=Y=>(0,t.P1)(L,ae=>ae.find(ee=>ee.id===Y)),W=(0,t.P1)(u,Y=>Y.titles),N=Y=>(0,t.P1)(f,ae=>ae.queries.find(ee=>ee.id===Y).query.query_string),Z=(0,t.P1)(s.gX,Y=>{var ae;const{query_string:ee}=(ae=Y==null?void 0:Y.query)!=null?ae:(0,r.Eg)();return ee}),j=Y=>(0,t.P1)(p,N(Y),Z,(ae,ee,ue)=>ae===o.Z.Type.Search?ee:ue),z=(0,t.P1)(f,Y=>Y.parameters),ne=(0,t.P1)(v,s.AS,(Y,ae)=>{var ee;return(ee=ae==null?void 0:ae.result)==null?void 0:ee.forId(Y)})},rNH0cW39:(M,C,e)=>{"use strict";e.d(C,{rP:()=>H,xb:()=>ye,nR:()=>W,fV:()=>j,oq:()=>ut,hj:()=>ue,xM:()=>Z,hU:()=>b,de:()=>L,G3:()=>we,s4:()=>Je,rh:()=>ee,bj:()=>Re,NK:()=>ne,VN:()=>le,gY:()=>P});var t=e("s98ZeFHv"),s=e("VPaD/Np4"),o=e("ZJjLtB2e"),r=e("dcP8FKpJ");const n=async re=>{const ce=(0,o.Z)(),Q=await(0,r.Z)(re);return[ce,Q]};var c=e("2z9Zbpb8"),v=e("UmnljV2q"),d=e("6/nLyfIT"),g=e("zAtQmw72"),p=e("gbXdylj1"),E=e("NS75yjmB"),a=e("g2NQZb9A"),u=e("iltCXley"),f=e("CHWvwBKE"),y=e("PLPb65Bv");const T=(0,t.oM)({name:"view",initialState:{view:void 0,isDirty:!1,isNew:!1,activeQuery:void 0},reducers:{setActiveQuery:(re,ce)=>({...re,activeQuery:ce.payload}),setView:{reducer(re,ce){const[Q,J]=ce.payload;return{...re,view:Q,isDirty:J===void 0?re.isDirty:J}},prepare(re,ce){return{payload:[re,ce]}}},setIsNew:(re,ce)=>({...re,isNew:ce.payload}),setIsDirty:(re,ce)=>({...re,isDirty:ce.payload})}}),P=T.reducer,{setView:O,setIsDirty:b,setIsNew:L,setActiveQuery:x}=T.actions,W=(re,ce)=>{var Q,J;const ie=(Q=re==null?void 0:re.state)==null?void 0:Q.map(fe=>fe.widgets),ge=(J=ce==null?void 0:ce.state)==null?void 0:J.map(fe=>fe.widgets);return(0,g.Z)(ie,ge)},N=async re=>{const ce=(0,p.Z)(re),Q=await(0,a.Z)(ce.search);return ce.toBuilder().search(Q).build()},Z=re=>async(ce,Q)=>{const J=(0,E.cE)(Q());ce(x(re)),J!==re&&ce((0,d.ht)())},j=(re,ce=!1)=>async(Q,J)=>{const ie=(0,E.fv)(J());if(ce||!W(ie,re)){const ge=await N(re);return await Q(O(ge)),Q((0,d.ht)())}return Q(O(re))},z={hasToPushRevision:!0},ne=(re,ce=!1,Q=z)=>async(J,ie)=>{const ge=ie(),fe=(0,E.fv)(ge);if(Q.hasToPushRevision&&await J((0,y.ZT)({type:"view",state:{...ge.view}})),ce||!W(fe,re)){const Ce=await N(re);return await J(O(Ce,!0)),J((0,d.ht)())}return J(O(re,!0))},Y=re=>async(ce,Q)=>{const J=(0,E.fv)(Q()),{search:ie}=J,ge=ie.toBuilder().newId().queries(re).build(),fe=await(0,a.Z)(ge),Ce=J.state.filter((nt,et)=>!!re.find(Fe=>Fe.id===et)).toMap(),Oe=J.toBuilder().search(fe).state(Ce).build();return ce(ne(Oe))},ae=(re,ce)=>async(Q,J)=>{const ie=J(),ge=(0,E.fv)(ie),{search:fe}=ge,Ce=fe.queries.add(re),Oe=ge.state.set(re.id,ce),nt=ge.toBuilder().search(fe.toBuilder().queries(Ce).build()).state(Oe).build();return Q(ne(nt,!0)).then(()=>Q(Z(re.id))).then(()=>re.id)},ee=(re,ce)=>async(Q,J)=>{const ie=J(),ge=(0,E.fv)(ie),{queries:fe}=ge.search,Ce=fe.map(et=>et.id===re?ce:et).toOrderedSet(),Oe=ge.search.toBuilder().queries(Ce).build(),nt=ge.toBuilder().search(Oe).build();return Q(ne(nt,!0))},ue=re=>async(ce,Q)=>{const J=Q(),ie=(0,E.fv)(J),ge=(0,E.cE)(J),{search:fe}=ie,Ce=fe.queries.filter(Pe=>Pe.id!==re).toOrderedSet(),Oe=ie.state.remove(re),nt=ie.toBuilder().search(fe.toBuilder().queries(Ce).build()).state(Oe).build(),et=fe.queries.map(Pe=>Pe.id).toList(),Fe=(0,c.Z)(et,ge,s.List([re]));await ce(Z(Fe)),await ce(ne(nt,!0))},H=()=>async(re,ce)=>{const Q=(0,E.BY)(ce()),[J,ie]=await n(Q);return re(ae(J,ie))},ye=re=>async(ce,Q)=>{const J=(0,u.Z)(),ge=(0,E.yF)(re)(Q()).duplicate(),Ce=(0,E.sh)(re)(Q()).toBuilder().id(J).build();return await ce(ae(Ce,ge)),J},we=re=>async(ce,Q)=>{const J=(0,E.vz)(Q()),ie=re.map(ge=>J.find(fe=>fe.id===ge)).toOrderedSet();return ce(Y(ie))},ut=re=>async(ce,Q)=>{const J=(0,E.fv)(Q());let ie=J.state;re.forEach(({titlesMap:fe,queryId:Ce})=>{const Oe=ie.get(Ce);let nt=Oe.titles;fe.forEach((et,Fe)=>{et.forEach((Pe,$e)=>{nt=nt.setIn([Fe,$e],Pe)})}),ie=ie.set(Ce,Oe.toBuilder().titles(nt).build())});const ge=J.toBuilder().state(ie).build();return ce(ne(ge))},ht=(re,ce)=>(Q,J)=>{const ge=(0,E.LM)(re)(J()).toBuilder().query((0,f.Eg)(ce)).build();return Q(ee(re,ge))},Je=(re,ce)=>(Q,J)=>{const ge=(0,E.LM)(re)(J()).toBuilder().timerange(ce).build();return Q(ee(re,ge))},Re=(re,ce)=>(Q,J)=>(0,E.BY)(J())===v.Z.Type.Search?Q(ht(re,ce)):Q((0,d.B3)(ce)).then(()=>Q((0,d.ht)())),le=(re,ce)=>(Q,J)=>{const ie=(0,E.fv)(J()),ge=ie.state.set(re,ce),fe=ie.toBuilder().state(ge).build();return Q(ne(fe))},me=re=>async(ce,Q)=>{const J=selectView(Q()),ge=selectSearch(Q()).toBuilder().parameters(re).build(),fe=J.toBuilder().search(ge).build();return ce(ne(fe,!0))}},l8tl93Rz:(M,C,e)=>{"use strict";e.d(C,{w6:()=>f,W4:()=>P,tQ:()=>O,Yn:()=>b,QB:()=>y,YS:()=>T,OT:()=>a,lg:()=>E,o8:()=>u});var t=e("VPaD/Np4"),s=e("zIjJeS8Y"),o=e("NS75yjmB");const r=(0,s.P1)(o.Sq,L=>L.widgetPositions);var n=e("rNH0cW39"),c=e("iltCXley"),v=e("A2mY8G47"),d=e("4U1brrvO"),g=e("/vL3Sz6z"),p=e("STGxpovz");const E=L=>(x,W)=>{const N=(0,o.cE)(W()),j=(0,o.Sq)(W()).toBuilder().widgetPositions(L).build();return x((0,n.VN)(N,j))},a=(L,x)=>(W,N)=>{const j={...r(N()),[L]:x};return W(E(j))},u=L=>(x,W)=>{const N=(0,o.cE)(W()),j=(0,o.Sq)(W()).toBuilder().widgets(L).build(),z=(0,p.Z)(j);return x((0,n.VN)(N,z))},f=(L,x)=>(W,N)=>{if(L.id===void 0)throw new Error("Unable to add widget without id to query.");const Z=(0,o.RN)(N()),j=t.Map(r(N())),z=Z.push(L),ne=x?j.set(L.id,x):(0,g.Z)(j,z.toArray()),Y=(0,o.cE)(N()),ee=(0,o.Sq)(N()).toBuilder().widgetPositions(ne).widgets(z).build();return W((0,n.VN)(Y,ee))},y=(L,x)=>(W,N)=>{const j=(0,o.RN)(N()).map(z=>z.id===L?x:z).toList();return W(u(j))},T=(L,x)=>(W,N)=>{const j=(0,o.Gn)(L)(N()).toBuilder().config(x).build();return W(y(L,j))},P=(L,x)=>async(W,N)=>{const Z=(0,o.Gn)(L)(N());if(!Z)throw new Error(`Unable to duplicate widget with id "${L}", it is not found.`);const j=(0,o.cE)(N()),z=Z.duplicate((0,c.Z)());return W(f(z)).then(()=>W((0,v.T)(j,"widget",z.id,`${x} (copy)`)))},O=L=>async(x,W)=>{const Z=(0,o.RN)(W()).filter(j=>j.id!==L).toList();return x(u(Z))},b=(L,x,W)=>(N,Z)=>{var j,z;const ne=(0,o.Gn)(L)(Z()),Y=(z=(j=ne==null?void 0:ne.config)==null?void 0:j.formattingSettings)!=null?z:d.Z.empty(),{chartColors:ae}=Y,ee=ne.toBuilder().config(ne.config.toBuilder().formattingSettings(Y.toBuilder().chartColors({...ae,[x]:W}).build()).build()).build();return N(y(L,ee))}},L2qXWCIB:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("ASBo/Til"),s=e.n(t),o=e("IZYxBTgT"),r=e("nxMFMmDQ"),n=e("I4XORk+Y"),c=e("rNH0cW39"),v=e("NS75yjmB");const d=a=>`"${s()(a).tz("UTC").format(o.eZ.internalIndexer)}"`,g=(a,u,f,y)=>{const T=y.type==="date"?d(f):(0,n.YU)(f),P=f===r.ZW?`NOT _exists_:${u}`:`${u}:${T}`;return(0,n.$_)(a,P)},E=({queryId:a,field:u,value:f="",type:y})=>async(T,P)=>{const O=(0,v.M7)(a)(P()),b=g(O,u,f,y);return T((0,c.bj)(a,b))}},AEcypqf3:(M,C,e)=>{"use strict";e.d(C,{Dm:()=>c,OD:()=>n,Wf:()=>r,_D:()=>g,fV:()=>v,o2:()=>d});var t=e("pjsNBHWI"),s=e.n(t),o=e("d4kzUuQm");const r=p=>p.push(`${o.ZP.SEARCH}/new`),n=r,c=(p,E)=>p.push(`${o.ZP.stream_search(E)}/new`),v=(p,E)=>p.push(`${o.ZP.SEARCH}/${E}`),d=(p,E,a)=>p.push(`${o.ZP.pluginRoute("DASHBOARDS_VIEWID")(E)}${a?`?${(0,t.stringify)({page:a})}`:""}`),g=(p,E)=>p.pushWithState(o.ZP.pluginRoute("DASHBOARDS_NEW"),{view:E})},"2z9Zbpb8":(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const s=(o,r,n)=>{const c=o.indexOf(r),v=o.slice(0,c).toList();return(v.isEmpty()?o:v.reverse()).find(g=>!n.includes(g))}},"/vL3Sz6z":(M,C,e)=>{"use strict";e.d(C,{r:()=>c,Z:()=>v});var t=e("VPaD/Np4"),s=e("mTnbNx1k"),o=e("FfX57J1C");const n=d=>{const{defaultHeight:g,defaultWidth:p}=(0,s.FZ)(d.type);return o.Z.builder().height(g).width(p).col(1).row(1).build()},c=(d,g)=>{let p=0;const E=d.map(u=>{const f=u.height,y=p+u.row,T=u.toBuilder().row(y).build();return p+=f,T}).toMap(),a=g.map(u=>{const f=p+u.row;return u.toBuilder().row(f).build()}).toMap();return E.merge(a)},v=(d,g)=>{const p=g.filter(f=>d.has(f.id)),E=g.filter(f=>!d.has(f.id)),a=t.Map(E.map(f=>[f.id,n(f)])),u=t.Map(p.map(f=>{const y=d.get(f.id);return[f.id,y]}));return c(a,u)}},tt0llszK:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("jAGDuYSC"),s=e("iSSis/Yq"),o=e("rNH0cW39");const r=c=>c&&c.additional&&c.additional.body&&c.additional.body.message?c.additional.body.message:c,n=c=>async v=>{try{await s.T.update(c),v((0,o.de)(!1)),v((0,o.hU)(!1)),t.Z.success(`Saving view "${c.title}" was successful!`,"Success!")}catch(d){t.Z.error(`Saving view failed: ${r(d)}`,"Error!")}}},gbXdylj1:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p});var t=e("/yh+QgO6"),s=e.n(t),o=e("VPaD/Np4"),r=e("iltCXley"),n=e("mTnbNx1k"),c=e("WExy2xUc");const v=E=>E.filter?{filter:{type:"query_string",query:E.filter}}:{},d=E=>{let a=o.Map();const u=o.List(E).map(f=>(0,n.FZ)(f.type).searchTypes(f).map(y=>({id:(0,r.Z)(),timerange:f.timerange,query:f.query,streams:f.streams,...y,widgetId:f.id,...v(f),filters:f.filters}))).reduce((f,y)=>f.merge(y),o.Set()).map(f=>{a=a.update(f.widgetId,o.Set(),L=>L.add(f.id));const y=(0,c.Z)(f.type);(!y||!y.defaults)&&console.warn(`Unable to find type definition or defaults for search type ${f.type} - skipping!`);const{defaults:T={}}=y||{},{config:P,widgetId:O,...b}=f;return o.Map(T).merge(b).merge(P).merge({id:f.id,type:f.type}).toJS()}).toArray();return{widgetMapping:a,searchTypes:u}},p=E=>{const{state:a}=E,u=a.map(O=>d(O.widgets)),f=s()(E,"search"),y=f.queries.map(O=>{var b,L;return O.toBuilder().searchTypes((L=(b=u.get(O.id))==null?void 0:b.searchTypes)!=null?L:[]).build()}),T=f.toBuilder().newId().queries(y.toOrderedSet()).build();let P=E.toBuilder().search(T).build();return u.map(({widgetMapping:O})=>O).forEach((O,b)=>{const L=P.state;a.has(b)&&(P=P.toBuilder().state(L.update(b,x=>x.toBuilder().widgetMapping(O).build())).build())}),P}},UmnljV2q:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p});var t=e("VPaD/Np4"),s=e.n(t),o=e("Jy5RbH6g"),r=e.n(o),n=e("Jg5wVMAu"),c=e.n(n),v=e("qhwXAFlw"),d=e("6BCpJW2W");const g=class ev{constructor(u,f,y,T,P,O,b,L,x,W,N,Z){this._value={id:u,type:f,title:y,summary:T,description:P,search:O,properties:t.fromJS(b),state:t.fromJS(L),createdAt:x,owner:W,requires:N,favorite:Z}}static create(){return new E().createdAt(new Date).build()}get id(){return this._value.id}get type(){return this._value.type}get title(){return this._value.title}get summary(){return this._value.summary}get description(){return this._value.description}get search(){return this._value.search}get properties(){return this._value.properties}get state(){return this._value.state}get createdAt(){return this._value.createdAt}get widgetMapping(){return(this.state||t.Map()).valueSeq().map(u=>u.widgetMapping).reduce((u,f)=>t.fromJS(u).merge(t.fromJS(f)))}get owner(){return this._value.owner}get requires(){return this._value.requires||{}}get favorite(){return this._value.favorite||!1}getSearchTypeByWidgetId(u){const y=this.state.map(P=>P.widgetMapping).flatten(!0).get(u).first();if(!y)throw new Error(`Search type for widget with id ${u} does not exist`);return r()(this.search.queries.map(P=>P.searchTypes).toArray()).find(P=>P&&P.id&&P.id===y)}getWidgetTitleByWidget(u){const f=this.state.flatMap(T=>T.titles.get("widget")),y=(0,v.Z)(u);return f.get(u.id)||y}toBuilder(){const{id:u,title:f,summary:y,description:T,search:P,properties:O,state:b,createdAt:L,owner:x,requires:W,type:N,favorite:Z}=this._value;return new E(t.Map({id:u,title:f,summary:y,description:T,search:P,properties:O,state:b,createdAt:L,owner:x,requires:W,type:N,favorite:Z}))}toJSON(){const{id:u,type:f,title:y,summary:T,description:P,search:O,properties:b,state:L,createdAt:x,owner:W}=this._value;return{id:u,type:f,title:y,summary:T,description:P,search_id:O.id,properties:b,state:L,created_at:x,owner:W}}static fromJSON(u){const{id:f,type:y,title:T,summary:P,description:O,properties:b,state:L,created_at:x,owner:W,requires:N,favorite:Z}=u,j=t.Map(L).map(d.Z.fromJSON).toMap(),z=new Date(x);return ev.create().toBuilder().id(f).type(y).title(T).summary(P).description(O).properties(b).state(j).createdAt(z).owner(W).requires(N).favorite(Z).build()}static builder(){return new E}};g.Type={Search:"SEARCH",Dashboard:"DASHBOARD"};let p=g;class E{constructor(u=t.Map()){this.value=u}id(u){return new E(this.value.set("id",u))}toNewView(){return new E(this.value.set("id",void 0).set("title",void 0))}type(u){return new E(this.value.set("type",u))}newId(){return this.id(new(c())().toString())}title(u){return new E(this.value.set("title",u))}summary(u){return new E(this.value.set("summary",u))}description(u){return new E(this.value.set("description",u))}search(u){return new E(this.value.set("search",u))}properties(u){return new E(this.value.set("properties",u))}state(u){return new E(this.value.set("state",t.Map(u)))}createdAt(u){return new E(this.value.set("createdAt",u))}owner(u){return new E(this.value.set("owner",u))}requires(u){return new E(this.value.set("requires",u))}favorite(u){return new E(this.value.set("favorite",u))}build(){const{id:u,type:f,title:y,summary:T,description:P,search:O,properties:b,state:L,createdAt:x,owner:W,requires:N,favorite:Z}=this.value.toObject();return new p(u,f,y,T,P,O,b,L,x,W,N,Z)}}},"6BCpJW2W":(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("VPaD/Np4"),s=e.n(t),o=e("SwOo9/Yp"),r=e("64Qr82UM"),n=e("FfX57J1C"),c=e("i0LZga0C"),v=e("4/JSMBsA");class d{constructor(E,a,u,f,y,T,P){this._value={fields:E,titles:a,widgets:(0,t.List)(u),widgetMapping:f,widgetPositions:(0,t.Map)(y),formatting:T,staticMessageListId:P}}static create(){return new g().widgets((0,t.List)()).widgetPositions((0,t.Map)()).titles((0,t.Map)()).build()}get fields(){return this._value.fields}get formatting(){return this._value.formatting}get titles(){return this._value.titles}get widgets(){return this._value.widgets}get widgetMapping(){return this._value.widgetMapping}get widgetPositions(){return this._value.widgetPositions.toJS()}get staticMessageListId(){return this._value.staticMessageListId}duplicate(){const E={},a=this.widgets.map(T=>{const P=T.toBuilder().newId().build();return E[T.id]=P.id,P}).toList(),u=(0,t.Map)(this.titles.get(c.Z.Widget,(0,t.Map)()).mapEntries(([T,P])=>[E[T],P])),f=this.titles.set(c.Z.Widget,u).updateIn([c.Z.Tab,"title"],T=>T&&`${T} (Copy)`),y=(0,t.Map)(this.widgetPositions).mapEntries(([T,P])=>[E[T],P]).toJS();return this.toBuilder().widgetMapping((0,t.Map)()).widgetPositions(y).widgets(a).titles(f).build()}toBuilder(){const E=this._value;return new g((0,t.Map)(E))}equals(E){return E===void 0||!(E instanceof d)?!1:(0,o.Z)(this.fields,E.fields)&&(0,o.Z)(this.titles,E.titles)&&(0,o.Z)(this.widgets,E.widgets)&&(0,o.Z)(this.widgetMapping,E.widgetMapping)&&(0,o.Z)(this.widgetPositions,E.widgetPositions)&&(0,o.Z)(this.formatting,E.formatting)}toJSON(){const{fields:E,formatting:a,titles:u,widgets:f,widgetMapping:y,widgetPositions:T}=this._value;return{selected_fields:E,formatting:a,titles:u,widgets:f,widget_mapping:y,positions:T}}static fromJSON(E){const{selected_fields:a,titles:u,widgets:f,widget_mapping:y,positions:T,formatting:P}=E;return d.builder().titles((0,t.fromJS)(u)).widgets((0,t.List)(f.map(O=>r.Z.fromJSON(O)))).widgetMapping((0,t.fromJS)(y)).fields(a).widgetPositions((0,t.Map)(T).map(n.Z.fromJSON).toMap()).formatting(P?v.Z.fromJSON(P):v.Z.empty()).build()}static builder(){return new g}}class g{constructor(E=(0,t.Map)()){this.value=E}fields(E){return new g(this.value.set("fields",E))}formatting(E){return new g(this.value.set("formatting",E))}titles(E){return new g(this.value.set("titles",(0,t.fromJS)(E)))}widgets(E){return new g(this.value.set("widgets",(0,t.List)(E)))}widgetMapping(E){return new g(this.value.set("widgetMapping",E))}widgetPositions(E){return new g(this.value.set("widgetPositions",(0,t.Map)(E)))}build(){const{fields:E,formatting:a,titles:u,widgets:f,widgetMapping:y,widgetPositions:T}=this.value.toObject();return new d(E,u,f,y,T,a)}}},dcP8FKpJ:(M,C,e)=>{"use strict";e.d(C,{Z:()=>p,q:()=>d});var t=e("VPaD/Np4"),s=e.n(t),o=e("pa3lbc7X"),r=e("UmnljV2q"),n=e("6BCpJW2W"),c=e("mTnbNx1k"),v=e("FfX57J1C");const d=E=>E?E instanceof Array?({stream:a})=>E.includes(a):({stream:a})=>a===E:({stream:a})=>a===null,g={[r.Z.Type.Search]:async E=>{const a=await o.D.list(),u=d(E),f=a?a.filter(u):[],y=(0,c.VW)(),T=(0,c.c1)(void 0,f),P=[y,T],O={widget:{[y.id]:"Message Count",[T.id]:"All Messages"}},b={[y.id]:new v.Z(1,1,2,1/0),[T.id]:new v.Z(1,3,6,1/0)};return{titles:O,widgets:P,positions:b}},[r.Z.Type.Dashboard]:async E=>({titles:{},widgets:[],positions:{}})},p=async(E,a)=>{const{titles:u,widgets:f,positions:y}=await g[E](a);return n.Z.create().toBuilder().titles(u).widgets(t.List(f)).widgetPositions(y).build()}},"Y/YOqMWf":(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("eFxcQyPT"),s=e("MdYBRjRJ");const o=(0,s.DC)("/views/search"),n=c=>(0,t.ZP)("GET",`${o}/${c}`)},"4/JSMBsA":(M,C,e)=>{"use strict";e.d(C,{Z:()=>r});var t=e("VPaD/Np4"),s=e.n(t),o=e("UnwAqHt2");class r{constructor(v=[]){this._value={highlighting:v}}get highlighting(){return this._value.highlighting}toBuilder(){const{highlighting:v}=this._value;return new n(t.Map({highlighting:v}))}static create(v){return new r(v)}static empty(){return new n().build()}toJSON(){const{highlighting:v}=this._value;return{highlighting:v}}static fromJSON(v){const{highlighting:d=[]}=v;return r.create(d.map(g=>o.ZP.fromJSON(g)))}}class n{constructor(v=t.Map()){this.value=v}highlighting(v){return new n(this.value.set("highlighting",v))}build(){const{highlighting:v}=this.value.toObject();return new r(v)}}},NhiTWmq4:(M,C,e)=>{"use strict";e.d(C,{$W:()=>n,WS:()=>o,ZP:()=>c});var t=e("gajRAEyE");class s{static fromJSON(d){switch(d.type){case"gradient":return n.fromJSON(d);case"static":return o.fromJSON(d);default:throw new Error(`Invalid highlighting color type: ${d.type}`)}}isStatic(){return this.type==="static"}isGradient(){return this.type==="gradient"}}class o extends s{constructor(d){super(),this._color=d}get type(){return"static"}get color(){return this._color}colorFor(){return this.color}static fromJSON({color:d}){return new o(d)}static create(d){return new o(d)}toJSON(){const{color:d}=this;return{type:"static",color:d}}}const r=(v,d=0)=>{if(typeof v=="number")return v;try{return Number.parseFloat(v)}catch{return d}};class n extends s{constructor(d,g,p){super(),this._lower=g,this._upper=p,this._gradient=d,this._scale=(0,t.Z)(d)}get type(){return"gradient"}get gradient(){return this._gradient}get lower(){return this._lower}get upper(){return this._upper}get scale(){return this._scale}colorFor(d){const g=r(d,this.lower),p=this.upper-this.lower,E=Math.max(this.lower,Math.min(this.upper,g));return this._scale((E-this.lower)/p)}static fromJSON({gradient:d,lower:g,upper:p}){return new n(d,g,p)}static create(d,g,p){return new n(d,g,p)}withGradient(d){return n.create(d,this.lower,this.upper)}withLower(d){return n.create(this.gradient,d,this.upper)}withUpper(d){return n.create(this.gradient,this.lower,d)}toJSON(){const{gradient:d,lower:g,upper:p}=this;return{type:"gradient",gradient:d,lower:g,upper:p}}}const c=s},UnwAqHt2:(M,C,e)=>{"use strict";e.d(C,{Vm:()=>g,Qw:()=>d,ZP:()=>E,p:()=>p});var t=e("VPaD/Np4");const s=u=>typeof u=="number"?!0:typeof u!="string"||u.trim()===""?!1:!Number.isNaN(Number(u)),o=(u,f,y)=>s(u)&&s(f)?y(parseFloat(u),parseFloat(f)):!1,n={equal:(u,f)=>String(u)===String(f),not_equal:(u,f)=>String(u)!==String(f),less_equal:(u,f)=>o(u,f,(y,T)=>y<=T),greater_equal:(u,f)=>o(u,f,(y,T)=>y>=T),greater:(u,f)=>o(u,f,(y,T)=>y>T),less:(u,f)=>o(u,f,(y,T)=>y=",less:"<",greater:">"},p=()=>c.WS.create(v.Yc[Math.floor(Math.random()*v.Yc.length)]);class E{constructor(f,y,T,P){this._value={field:f,value:y,condition:T,color:P}}get field(){return this._value.field}get value(){return this._value.value}get condition(){var f;return(f=this._value.condition)!=null?f:"equal"}get conditionFunc(){var f;return n[(f=this._value.condition)!=null?f:"equal"]}get color(){return this._value.color}toBuilder(){const{field:f,value:y,condition:T,color:P}=this._value;return new a(t.Map({field:f,value:y,condition:T,color:P}))}static create(f,y,T,P){return new E(f,y,T,P)}static builder(){return new a}toJSON(){const{field:f,value:y,condition:T,color:P}=this._value;return{field:f,value:y,condition:T,color:P}}static fromJSON(f){const{field:y,value:T,condition:P,color:O}=f;return E.create(y,T,P,c.ZP.fromJSON(O))}}class a{constructor(f=t.Map()){this._value=f}field(f){return new a(this._value.set("field",f))}value(f){return new a(this._value.set("value",f))}condition(f){return new a(this._value.set("condition",f))}color(f){return new a(this._value.set("color",f))}build(){const{field:f,value:y,condition:T,color:P}=this._value.toObject();return new E(f,y,T,P)}}},STGxpovz:(M,C,e)=>{"use strict";e.d(C,{Z:()=>n});var t=e("3UCnSGqh"),s=e.n(t),o=e("hKs41owK");const n=c=>{const{widgetPositions:v,widgets:d}=c,g=s()(d.toArray(),"id"),p=(0,o.fZ)(v,g);return c.toBuilder().widgetPositions(p).build()}},d2pcYUML:(M,C,e)=>{"use strict";e.d(C,{Z:()=>d});var t=e("VPaD/Np4"),s=e.n(t),o=e("SwOo9/Yp"),r=e("zAtQmw72"),n=e("64Qr82UM"),c=e("PmoDOvRy");const v=class Wi extends n.Z{constructor(E,a,u,f,y,T,P){super(E,Wi.type,a,u,f,y,T,P)}get isExportable(){return!0}static fromJSON(E){const{id:a,config:u,filter:f,timerange:y,query:T,streams:P,filters:O}=E;return new Wi(a,c.ZP.fromJSON(u),f,y,T,P,O)}equals(E){return E instanceof Wi?["id","config","filter","timerange","query","streams","filters"].every(a=>(0,o.Z)(this._value[a],E[a])):!1}get config(){return this._value.config}equalsForSearch(E){return E instanceof Wi?["id","config","filter","timerange","query","streams","filters"].every(a=>(0,r.Z)(this._value[a],E[a])):!1}toBuilder(){const{id:E,config:a,filter:u,timerange:f,query:y,streams:T,filters:P}=this._value;return new g((0,t.Map)({id:E,config:a,filter:u,timerange:f,query:y,streams:T,filters:P}))}static builder(){return new g}static isMessagesWidget(E){return E&&E.type===Wi.type}};v.type="messages",v.defaultTitle="Untitled Message Table";let d=v;class g extends n.Z.Builder{build(){const{id:E,config:a,filter:u,timerange:f,query:y,streams:T,filters:P}=this.value.toObject();return new d(E,a,u,f,y,T,P)}}},PmoDOvRy:(M,C,e)=>{"use strict";e.d(C,{ZP:()=>E,bd:()=>g});var t=e("VPaD/Np4"),s=e.n(t),o=e("SwOo9/Yp"),r=e("zAtQmw72"),n=e("Wk8izdHL"),c=e("7VrSCphN"),v=e("nxMFMmDQ"),d=e("uDndTqtw");const g=c.Z.Descending,p=[new n.Z(n.Z.PIVOT_TYPE,v.rg,g)];class E extends d.Z{constructor(f,y,T,P,O){super(),this._value={decorators:P,fields:f.slice(0),showMessageRow:y,showSummary:T,sort:O&&O.length>0?O:p}}get decorators(){return this._value.decorators}get fields(){return this._value.fields}get sort(){return this._value.sort}get showMessageRow(){return this._value.showMessageRow}get showSummary(){return this._value.showSummary}toBuilder(){return new a(t.Map(this._value))}toJSON(){const{decorators:f,fields:y,showMessageRow:T,showSummary:P,sort:O}=this._value;return{decorators:f,fields:y,show_message_row:T,show_summary:P,sort:O}}equals(f){return f instanceof E&&(0,o.Z)(this.decorators,f.decorators)&&(0,o.Z)(this.fields,f.fields)&&(0,o.Z)(this.sort,f.sort)&&this.showMessageRow===f.showMessageRow&&this.showSummary===f.showSummary}equalsForSearch(f){return f instanceof E&&(0,r.Z)(f.decorators,this.decorators)&&(0,r.Z)(f.sort,this.sort)}static builder(){return new a().decorators([]).fields([]).sort([])}static fromJSON(f){const{decorators:y,show_message_row:T,show_summary:P,fields:O,sort:b}=f;return new E(O,T,P,y,b.map(n.Z.fromJSON))}}class a{constructor(f=t.Map()){this.value=f}decorators(f){return new a(this.value.set("decorators",f.slice(0)))}fields(f){return new a(this.value.set("fields",f.slice(0)))}showMessageRow(f){return new a(this.value.set("showMessageRow",f))}showSummary(f){return new a(this.value.set("showSummary",f))}sort(f){return new a(this.value.set("sort",f))}build(){const{decorators:f,fields:y,showMessageRow:T,showSummary:P,sort:O}=this.value.toObject();return new E(y,T,P,f,O)}}},"64Qr82UM":(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("VPaD/Np4"),s=e.n(t),o=e("IA3Ku5lS"),r=e("iltCXley"),n=e("SwOo9/Yp");const c=a=>a==null,v=class Vm{constructor(u,f,y,T,P,O,b,L){this._value={id:u,type:f,config:y,filter:T===null?void 0:T,filters:(0,t.List)(L),timerange:P,query:O,streams:b}}get id(){return this._value.id}get type(){return this._value.type}get config(){return this._value.config}get filter(){return this._value.filter}get filters(){return this._value.filters}get timerange(){return this._value.timerange}get query(){return this._value.query}get streams(){return this._value.streams}get isExportable(){return!1}equals(u){return u===void 0||!(u instanceof Vm)?!1:this.id===u.id&&(c(this.filter)&&c(u.filter)||(0,n.Z)(this.filter,u.filter))&&(c(this.filters)&&c(u.filters)||(0,n.Z)(this.filters,u.filters))&&(0,n.Z)(this.config,u.config)&&(0,n.Z)(this.timerange,u.timerange)&&(0,n.Z)(this.query,u.query)&&(0,n.Z)(this.streams,u.streams)}duplicate(u){return this.toBuilder().id(u).build()}toBuilder(){const{id:u,type:f,config:y,filter:T,filters:P,timerange:O,query:b,streams:L}=this._value;return new g((0,t.Map)({id:u,type:f,config:y,filter:T,filters:P,timerange:O,query:b,streams:L}))}toJSON(){const{id:u,type:f,config:y,filter:T,filters:P,timerange:O,query:b,streams:L}=this._value;return{id:u,type:f.toLowerCase(),config:y,filter:T,filters:P,timerange:O,query:b,streams:L}}static fromJSON(u){const{id:f,type:y,config:T,filter:P,filters:O,timerange:b,query:L,streams:x}=u,W=Vm.__registrations[y.toLowerCase()];return W?W.fromJSON(u):new Vm(f,y,T,P,b,L,x,O)}static empty(){return this.builder().build()}static builder(){return new g}static registerSubtype(u,f){this.__registrations[u.toLowerCase()]=f}};v.__registrations={};let d=v;class g{constructor(u=(0,t.Map)()){this.value=u}id(u){return this.value=this.value.set("id",u),this}newId(){return this.id((0,r.Z)())}type(u){return this.value=this.value.set("type",u),this}config(u){return this.value=this.value.set("config",u),this}filter(u){return this.value=this.value.set("filter",u),this}filters(u){return this.value=this.value.set("filters",u&&t.List(u)),this}timerange(u){return this.value=this.value.set("timerange",u),this}query(u){return this.value=this.value.set("query",u),this}streams(u){return this.value=this.value.set("streams",u),this}build(){const{id:u,type:f,config:y,filter:T,filters:P,timerange:O,query:b,streams:L}=this.value.toObject();return new d(u,f,y,T,O,b,L,P)}}d.Builder=g;const E=(0,o.ri)("views.logic.widgets.Widget",()=>d)},uDndTqtw:(M,C,e)=>{"use strict";e.d(C,{Z:()=>t});class t{}},FfX57J1C:(M,C,e)=>{"use strict";e.d(C,{Z:()=>v});var t=e("VPaD/Np4"),s=e.n(t),o=e("IA3Ku5lS");class r{constructor(g,p,E,a){this._value={col:g,row:p,height:E,width:a}}static fromJSON(g){const{col:p,row:E,height:a,width:u}=g,f=p==="Infinity"?1/0:p,y=E==="Infinity"?1/0:E,T=a==="Infinity"?1/0:a,P=u==="Infinity"?1/0:u;return new r(f,y,T,P)}get col(){return this._value.col}get row(){return this._value.row}get height(){return this._value.height}get width(){return this._value.width}toJSON(){const{col:g,row:p,height:E,width:a}=this._value;return{col:g===1/0?"Infinity":g,row:p===1/0?"Infinity":p,height:E===1/0?"Infinity":E,width:a===1/0?"Infinity":a}}toBuilder(){return new n((0,t.Map)(this._value))}static builder(){return new n}equals(g){return g instanceof r?this.col===g.col&&this.row===g.row&&this.height===g.height&&this.width===g.width:!1}}class n{constructor(g=(0,t.Map)()){this.value=g}col(g){return this.value=this.value.set("col",g),this}row(g){return this.value=this.value.set("row",g),this}height(g){return this.value=this.value.set("height",g),this}width(g){return this.value=this.value.set("width",g),this}build(){const{col:g,row:p,height:E,width:a}=this.value.toObject();return new r(g,p,E,a)}}const v=(0,o.ri)("views.logic.widgets.WidgetPosition",()=>r)},hKs41owK:(M,C,e)=>{"use strict";e.d(C,{LU:()=>E,fZ:()=>f,q1:()=>u});var t=e("V09ZIpgK"),s=e.n(t),o=e("9xJxp5+I"),r=e.n(o),n=e("3UCnSGqh"),c=e.n(n),v=e("7FTHePOw"),d=e.n(v),g=e("FfX57J1C");const p=({i:y,x:T,y:P,w:O,h:b})=>({id:y,col:T+1,row:P+1,height:b,width:O}),E=y=>y.map(p),a=([y,T])=>{const{col:P,row:O,height:b,width:L}=T;return{i:y,x:P?Math.max(P-1,0):0,y:O===void 0||O<=0?1/0:O-1,h:b||1,w:L||1}},u=y=>Object.entries(y).map(a),f=(y,T)=>{const P=r()(y,(x,W)=>!T[W]),O=u(P),b=t.utils.compact(O,"vertical",12),L=c()(E(b),"id");return d()(L,({col:x,row:W,width:N,height:Z})=>g.Z.builder().row(W).col(x).width(N).height(Z).build())}},VcneZdh2:(M,C,e)=>{"use strict";e.d(C,{Z:()=>LE});var t=e("Z7aTuO5B");const o=t.createContext(void 0),n=t.createContext(()=>{});var c=e("J6y4/h8P"),v=e("0eB11aFj"),d=e("8fnsnG21"),g=e("ww+BtWnX"),p=e.n(g),E=e("ii0bleBb"),a=e.n(E),u=e("IA3Ku5lS");const f=t.createContext(void 0),y=(0,u.ri)("contexts.SearchPagePreferences",()=>f);var T=e("Jvb3Ez/Z"),P=e("8OvTct/Z"),O=e("v4GbOr/o"),b=e("MdYBRjRJ"),L=e("0t7Ye+61"),x=e("93yMNhQL");const W=c.default.button(({theme:{colors:m,fonts:_},$isSelected:A,$sidebarIsPinned:R,$disabled:B})=>(0,c.css)` position: relative; z-index: 4; /* to render over SidebarNav::before */ width: 100%; height: 40px; text-align: center; cursor: ${B?"not-allowed":"pointer"}; font-size: ${_.size.h3}; color: ${m.variant.darkest.default}; background: ${A?m.gray[90]:m.global.contentBackground}; border: 0; padding: 0; &:hover { color: ${A?m.variant.darkest.default:m.variant.darker.default}; background: ${A?m.gray[80]:m.variant.lightest.default}; } &:active { background: ${m.variant.lighter.default}; } /* stylelint-disable selector-max-empty-lines, indentation */ ${A&&!R&&(0,c.css)` &::before, &::after { content: ''; position: absolute; right: -5px; height: 15px; width: 5px; background-color: ${m.global.contentBackground}; } &::before { transform: skewY(-45deg); top: calc(50% - 12px); } &::after { transform: skewY(45deg); bottom: calc(50% - 12px); } `} /* stylelint-enable selector-max-empty-lines, indentation */ `),N=c.default.span(({$showTitleOnHover:m,$isSelected:_,$disabled:A,$sidebarIsPinned:R,theme:{colors:B}})=>(0,c.css)` display: flex; width: 100%; height: 100%; align-items: center; justify-content: center; position: relative; opacity: ${A?.65:1}; &:hover { + div { display: ${m&&!_?"flex":"none"}; } &::after { display: ${m?"block":"none"}; } } &::after { display: ${_?"block":"none"}; box-shadow: ${_&&!R?`inset 2px -2px 2px 0 ${B.global.navigationBoxShadow}`:"none"}; background-color: ${_?B.global.contentBackground:B.variant.lightest.info}; border: ${_?"none":`1px solid ${B.variant.light.info}`}; content: ' '; position: absolute; left: 82.5%; top: calc(50% - 9px); width: 18px; height: 18px; transform: rotate(45deg); } `),Z=c.default.div(({theme:{colors:m,fonts:_}})=>(0,c.css)` display: none; position: absolute; padding: 0 10px; left: 100%; top: calc(50% - 13px); height: 26px; background-color: ${m.variant.lightest.info}; border: 1px solid ${m.variant.light.info}; border-left: none; box-shadow: 3px 3px 3px ${m.global.navigationBoxShadow}; z-index: 4; border-radius: 0 3px 3px 0; align-items: center; span { color: ${m.variant.darker.info}; font-size: ${_.size.body}; font-weight: bold; text-transform: uppercase; } `),j=({isSelected:m,title:_,icon:A,onClick:R,showTitleOnHover:B,sidebarIsPinned:U,disabled:F,ariaLabel:V})=>t.createElement(W,{"aria-label":V,$isSelected:m,onClick:F?void 0:R,title:B?"":_,$sidebarIsPinned:U,$disabled:F},t.createElement(N,{$showTitleOnHover:B,$isSelected:m,$sidebarIsPinned:U,$disabled:F},t.createElement(x.Z,{name:A})),B&&!m&&t.createElement(Z,null,t.createElement("span",null,_)));j.propTypes={icon:a().node.isRequired,isSelected:a().bool,showTitleOnHover:a().bool,sidebarIsPinned:a().bool.isRequired,title:a().string.isRequired,disabled:a().bool},j.defaultProps={isSelected:!1,showTitleOnHover:!0,disabled:!1};const z=j,ne=c.default.div(({$isOpen:m,$sidebarIsPinned:_,theme:A})=>(0,c.css)` background: ${A.colors.global.navigationBackground}; color: ${A.utils.contrastingColor(A.colors.global.navigationBackground,"AA")}; box-shadow: ${_&&m?"none":`3px 3px 3px ${A.colors.global.navigationBoxShadow}`}; width: 50px; height: 100%; position: relative; z-index: 1031; &::before { content: ''; position: absolute; top: 0; right: -6px; height: 6px; width: 6px; border-top-left-radius: 50%; background: transparent; box-shadow: -6px -6px 0 3px ${A.colors.global.navigationBackground}; z-index: 4; /* to render over Sidebar ContentColumn */ } `),Y=c.default.div` > * { margin-bottom: 5px; &:last-child { margin-bottom: 0; } } `,ae=c.default.div` padding: 0 10px; hr { border-color: currentColor; margin: 5px 0 10px; } `,ue=({sections:m,activeSection:_,selectSidebarSection:A,sidebarIsPinned:R,actions:B})=>{const U=_==null?void 0:_.key;return t.createElement(ne,{$sidebarIsPinned:R,$isOpen:!!_},t.createElement(Y,null,m.map(({key:F,icon:V,title:se})=>{const Se=U===F;return t.createElement(z,{isSelected:Se,ariaLabel:Se?`Close ${se} section`:`Open ${se} section`,icon:V,onClick:()=>A(F),key:F,title:se,sidebarIsPinned:R})})),t.createElement(ae,null,t.createElement("hr",null)),t.createElement(Y,null,B.map(({key:F,Component:V})=>t.createElement(V,{key:F,sidebarIsPinned:R}))))};var H=e("/GOzvPf6"),ye=e("uEPrrliZ");const we=c.default.div(({theme:m,$sidebarIsPinned:_})=>(0,c.css)` position: ${_?"relative":"fixed"}; width: 270px; height: ${_?"100%":"calc(100% - 50px)"}; /* subtract the nav height */ top: ${_?0:"50px"}; left: ${_?0:"50px"}; background: ${m.colors.global.contentBackground}; border-right: ${_?"none":`1px solid ${m.colors.variant.light.default}`}; box-shadow: ${_?`3px 3px 3px ${m.colors.global.navigationBoxShadow}`:"none"}; z-index: ${_?1030:6}; ${_&&(0,c.css)` &::before { content: ''; position: absolute; top: 0; right: -6px; height: 6px; width: 6px; border-top-left-radius: 50%; background: transparent; box-shadow: -6px -6px 0 3px ${m.colors.global.contentBackground}; z-index: 5; /* to render over Sidebar ContentColumn */ } `} `),ut=c.default.div(({theme:m})=>(0,c.css)` display: grid; display: -ms-grid; grid-template-columns: 1fr; grid-template-rows: auto minmax(1px, 1fr); -ms-grid-columns: 1fr; -ms-grid-rows: auto 1fr; height: 100%; overflow-y: auto; padding: 5px 15px 0; color: ${m.colors.global.textDefault}; `),ht=c.default.div` grid-column: 1; -ms-grid-column: 1; grid-row: 1; -ms-grid-row: 1; `,Je=c.default.div` height: 35px; display: grid; display: -ms-grid; grid-template-columns: 1fr auto; -ms-grid-columns: 1fr auto; > *:nth-child(1) { grid-column: 1; -ms-grid-column: 1; } > *:nth-child(2) { grid-column: 2; -ms-grid-column: 2; } `,Re=c.default.h1` color: inherit; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; `,le=c.default.div(({theme:m,$sidebarIsPinned:_})=>(0,c.css)` > * { font-size: ${m.fonts.size.large}; color: ${_?m.colors.variant.info:m.colors.gray[30]}; } `),me=c.default.hr` margin: 5px 0 10px; `,re=c.default.h2` margin-bottom: 10px; `,ce=c.default.div` display: inline-grid; display: -ms-inline-grid; align-content: center; `,Q=c.default.div` grid-column: 1; -ms-grid-column: 1; grid-row: 2; -ms-grid-row: 2; /* Fixes padding problem with padding-bottom from container */ > *:last-child { padding-bottom: 15px; } `,J=m=>{if(!m)return;const{actions:{toggleSidebarPinning:_}}=m;_()},ge=({children:m,sectionTitle:_,closeSidebar:A,searchPageLayout:R})=>{const B=R==null?void 0:R.config.sidebar.isPinned,U=(0,ye.Z)();return t.createElement(we,{$sidebarIsPinned:B},t.createElement(ut,null,t.createElement(ht,null,t.createElement(Je,{title:U},t.createElement(ce,null,t.createElement(Re,{onClick:A},U)),t.createElement(ce,null,t.createElement(le,{$sidebarIsPinned:B},t.createElement(H.hU,{onClick:()=>J(R),title:`Display sidebar ${B?"as overlay":"inline"}`,name:"thumbtack"})))),t.createElement(me,null),t.createElement(re,null,_)),t.createElement(Q,null,m)))};var fe=e("SqY3hYJN"),Ce=e("xudoaDQq"),Oe=e("zIjJeS8Y"),nt=e("YcvsU7cw"),et=e("NS75yjmB");const Fe=(0,Oe.P1)(et.cE,et.fv,(m,_)=>_?{id:_==null?void 0:_.id,title:_==null?void 0:_.title,description:_==null?void 0:_.description,summary:_==null?void 0:_.summary,activeQuery:m}:{}),$e=()=>(0,nt.Z)(Fe);var Ot=e("9pdI12pI"),ft=e.n(Ot),Tt=e("oc9db6Tt"),Lt=e.n(Tt),Be=e("KAQaaMh7");const mt=()=>(0,nt.Z)(Be.gX);var Rt=e("UmnljV2q");const zt=c.default.div` margin-bottom: 10px; `,xt=c.default.table` margin-bottom: 5px; td:first-child { padding-right: 10px; } `,nn=({results:m})=>{var _;const{timerange:A}=(_=mt())!=null?_:{},R=(0,Ce.Z)();if(Lt()(m))return t.createElement("i",null,"No query executed yet.");const{timestamp:B,duration:U,effectiveTimerange:F}=m;return t.createElement(t.Fragment,null,t.createElement("p",null,"Query executed in ",t.createElement("br",null),ft()(U).format("0,0"),"ms at ",t.createElement(H.EK,{dateTime:B})),t.createElement(zt,null,"Effective time range",t.createElement("br",null),R===Rt.Z.Type.Dashboard&&!A?t.createElement("i",null,"Varies per widget"):t.createElement(xt,null,t.createElement("tbody",null,t.createElement("tr",null,t.createElement("td",null,"From"),t.createElement("td",null,t.createElement(H.EK,{dateTime:F.from,format:"complete"}))),t.createElement("tr",null,t.createElement("td",null,"To"),t.createElement("td",null,t.createElement(H.EK,{dateTime:F.to,format:"complete"})))))))};nn.propTypes={results:a().object.isRequired};const Vt=nn,Mt=c.default.p(({theme:m})=>(0,c.css)` color: ${m.colors.global.textDefault}; margin-bottom: 15px; `),rt=c.default.h3` margin-bottom: 10px; `,Bn=({results:m})=>{const _=$e(),A=!_.id,R=(0,Ce.Z)(),B=R?(0,fe.Z)({type:R}):"",U=t.createElement(t.Fragment,null,t.createElement(rt,null,"Execution"),t.createElement(Vt,{results:m}));return A?t.createElement(t.Fragment,null,t.createElement(Mt,null,"Save the search or export it to a dashboard to add a custom summary and description."),U):t.createElement(t.Fragment,null,(!_.summary||!_.description)&&t.createElement(Mt,null,"To add a description and summary for this ",B," click on the ",t.createElement(H.JO,{name:"ellipsis-h"}),' icon in the search bar to open its action menu. The action menu includes the option "Edit metadata".'),U,t.createElement(rt,null,"Search"),t.createElement("p",null,_.summary||t.createElement("i",null,"This ",B," has no summary.")),t.createElement("p",null,_.description||t.createElement("i",null,"This ",B," has no description.")))};Bn.propTypes={results:a().object.isRequired};const de=Bn;var pt=e("QL8i6bcz"),Gt=e("PpCK0BgN"),gn=e.n(Gt),Jt=e("PfG+ecgN"),An=e.n(Jt),xe=e("uZqmR+ju"),Pn=e("iltCXley"),sn=e("orDZ6Vj2"),no=e("BqxuktKK"),Co=e("HCsT5Gmk");const Go=c.default.div` margin-bottom: 20px; &:last-child { margin-bottom: 0; } `,Mo=(0,c.default)(xe.Button)` display: block; margin: 5px 0; width: 100%; `,jo=m=>"func"in m,Zt=({children:m})=>{const _=(0,sn.Z)();return m(_)};class Me extends t.Component{constructor(_){super(_),this._createHandlerFor=(A,R)=>{const{onClick:B,sendTelemetry:U,location:F}=this.props;if(jo(R))return()=>{U(O.A.SEARCH_WIDGET_CREATE[An()(R.title).replace(/ /g,"_")],{app_pathname:(0,b.av)(F.pathname),app_section:"search-sidebar",event_details:{widgetType:R.type}}),B(),A(R.func())};if(R.component){const V=R.component;return()=>{const se=(0,Pn.Z)(),Se=()=>this.setState(Ee=>{const{overflowingComponents:Ze}=Ee;return delete Ze[se],B(),{overflowingComponents:Ze}}),Ae=t.createElement(V,{key:R.title,onClose:Se});this.setState(Ee=>{const{overflowingComponents:Ze}=Ee;return Ze[se]=Ae,{overflowingComponents:Ze}})}}throw new Error(`Invalid binding for creator: ${JSON.stringify(R)} - has neither 'func' nor 'component'.`)},this._createMenuItem=A=>{var R;const B=((R=A.condition)==null?void 0:R.call(A))===!1;return t.createElement(Zt,{key:A.title},U=>t.createElement(Mo,{key:A.title,onClick:this._createHandlerFor(U,A),disabled:B},A.title))},this._createGroup=(A,R)=>{const B=A.filter(F=>F.type===R);return gn()(B,"title").map(this._createMenuItem)},this.state={overflowingComponents:{}}}render(){const{overflowingComponents:_}=this.state,A=pt.G.exports("creators"),R=this._createGroup(A,"preset"),B=this._createGroup(A,"generic"),U=Object.values(_);return t.createElement(t.Fragment,null,t.createElement(Mt,null,"Use the following options to add an aggregation, log view (enterprise feature) or parameters (enterprise feature) to your search."),t.createElement(Go,null,t.createElement(rt,null,"Generic"),B),t.createElement(Go,null,t.createElement(rt,null,"Predefined Aggregation"),R),U)}}const Ye=(0,Co.Z)((0,no.Z)(Me));var Ke=e("nxMFMmDQ"),dt=e("RTnJ3JrH"),it=e("Ofda/4py"),gt=e("gofDlXL2"),It=e("UnwAqHt2"),ot=e("VPaD/Np4"),yt=e("UiXZqrDE"),Xt=e("yt/z6tOx"),rn=e.n(Xt),Cn=e("4E3oowBb"),bn=e("hC1XaH+L"),hn=e("hhdCSTZj"),ao=e("sWSSTOXR"),Xn=e.n(ao),vo=e("gajRAEyE");const Kn=c.default.div` height: 25px; width: 25px; margin-right: 0.4rem; border-radius: 4px; border: 1px solid rgb(0 126 255 / 24%); `,Jn=(0,c.default)(Kn)(({color:m})=>(0,c.css)` background-color: ${m}; `),Wn=(m,_=5)=>(0,vo.Z)(m).colors(_),bo=(0,c.default)(Kn)(({$gradient:m})=>{const _=Wn(m);return(0,c.css)` border: none; background: linear-gradient(0deg, ${_.map((A,R)=>`${A} ${R*(100/_.length)}%`).join(", ")}); `}),ds=t.forwardRef(({color:m,onClick:_=()=>{}},A)=>{if(m.type==="static")return t.createElement(Jn,{ref:A,"data-testid":"static-color-preview",onClick:_,color:m.color});if(m.type==="gradient")return t.createElement(bo,{ref:A,onClick:_,$gradient:m.gradient});throw new Error(`Invalid highlighting color type: ${m}`)});ds.propTypes={color:a().any.isRequired,onClick:a().func},ds.defaultProps={onClick:()=>{}};const zo=ds;var Xo=e("NhiTWmq4"),Do=e("hD3VAVgz");const Jo=()=>t.createElement(yt.Field,{name:"color.color"},({field:{name:m,value:_,onChange:A},meta:R})=>t.createElement(xe.Input,{id:m,error:R==null?void 0:R.error,label:"Color"},t.createElement(H.h4,{id:"formatting-rule-color",placement:"right",color:_,colors:Ke.Yc.map(B=>[B]),triggerNode:t.createElement(zo,{color:Xo.WS.create(_)}),onChange:(B,U,F)=>{F(),A({target:{name:m,value:B}})}}))),Zo=c.default.div` display: flex; `,yo=m=>({label:t.createElement(Zo,null,t.createElement(bo,{$gradient:m}),m),value:m}),Vo=[...Do.Xm].sort(Cn.S).map(yo),_s=/^-?[0-9]+$/,Cs=m=>{const _={};return(m==null?void 0:m.type)==="gradient"&&(Xn()(m==null?void 0:m.gradient)===""&&(_.gradient="Must be selected."),Xn()(m==null?void 0:m.lower)===""?_.lower="Must be present.":_s.test(m==null?void 0:m.lower)||(_.lower="Must be a number."),Xn()(m==null?void 0:m.upper)===""?_.upper="Must be present.":_s.test(m==null?void 0:m.upper)||(_.upper="Must be a number."),(m==null?void 0:m.upper)<=(m==null?void 0:m.lower)&&(_.upper="Must be higher than lowest value.")),Object.keys(_).length>0?_:void 0},ms=()=>t.createElement(yt.Field,{name:"color",validate:Cs},()=>t.createElement(t.Fragment,null,t.createElement(yt.Field,{name:"color.gradient"},({field:{name:m,value:_,onChange:A},meta:R})=>t.createElement(xe.Input,{id:`${m}-name`,error:R==null?void 0:R.error,label:"Gradient Name"},t.createElement(H.Ph,{options:Vo,inputProps:{"aria-label":"Select gradient colors"},value:_,onChange:B=>A({target:{name:m,value:B}})}))),t.createElement(yt.Field,{name:"color.lower"},({field:{name:m,value:_,onChange:A},meta:R})=>t.createElement(xe.Input,{id:m,"aria-label":"Specify lowest value",label:"Lowest Value",type:"number",value:_,error:R==null?void 0:R.error,onChange:A,help:"The lowest value expected in the field/series.",required:!0})),t.createElement(yt.Field,{name:"color.upper"},({field:{name:m,value:_,onChange:A},meta:R})=>t.createElement(xe.Input,{id:m,"aria-label":"Specify highest value",label:"Highest Value",type:"number",value:_,error:R==null?void 0:R.error,onChange:A,help:"The highest value expected in the field/series.",required:!0})))),Yn=({type:m})=>{switch(m){case"static":return t.createElement(Jo,null);case"gradient":return t.createElement(ms,null);default:return null}},xo=c.default.div` margin-left: 10px; `,Ls=()=>Ke.Yc[Math.floor(Math.random()*Ke.Yc.length)],Vs=m=>{if(m==="static")return{type:"static",color:Ls()};if(m==="gradient")return{type:"gradient",gradient:"Viridis",upper:0,lower:0};throw new Error(`Invalid color type: ${m}`)},Bs=(m,_)=>{if(!m||m==="")return"Coloring is required";if(!_&&m==="gradient")return"A gradient can only be defined for numeric fields."},Us=({field:m})=>{var _,A;const R=(A=(_=m==null?void 0:m.type)==null?void 0:_.isNumeric())!=null?A:!1,{setFieldValue:B}=(0,yt.useFormikContext)(),U=(0,t.useCallback)(F=>{const{target:{value:V}}=F;B("color",Vs(V))},[B]);return t.createElement(yt.Field,{name:"color.type",validate:F=>Bs(F,R)},({field:{name:F,value:V},meta:se})=>t.createElement(t.Fragment,null,t.createElement(xe.Input,{id:`${F}-coloring`,label:"Coloring",error:se==null?void 0:se.error},t.createElement(xo,null,t.createElement(xe.Input,{checked:V==="static",formGroupClassName:"",id:F,label:"Static Color",onChange:U,type:"radio",value:"static"}),t.createElement(xe.Input,{checked:V==="gradient",formGroupClassName:"",id:F,disabled:!R,label:"Gradient",onChange:U,type:"radio",value:"gradient"}))),V&&t.createElement(Yn,{type:V})))};var ws=e("7J1sc9Ol"),Lo=e("kXOFp4bk");const co=m=>_=>{if(["",null,void 0].includes(_))return`${m} is required`},ns=Object.entries(It.Vm).map(([m,_])=>({value:m,label:_})),os=Object.entries(It.Qw).map(([m,_])=>({value:m,label:_})),Ws=(m,_)=>(0,ws.mf)(_)?(0,Lo.Z)(ws.ZP.forFunction(_),m):m.find(A=>A.name===_),ps=m=>{const _="static";if((m==null?void 0:m.type)==="static"){const{type:A,color:R}=m;return{type:A,color:R}}if((m==null?void 0:m.type)==="gradient"){const{type:A,gradient:R,upper:B,lower:U}=m;return{type:A,gradient:R,upper:B,lower:U}}return Vs(_)},Tr=m=>{if((m==null?void 0:m.type)==="static")return Xo.WS.create(m.color);if((m==null?void 0:m.type)==="gradient"){const{gradient:_,lower:A,upper:R}=m;return Xo.$W.create(_,A,R)}},Ns=({onClose:m,rule:_})=>{var A;const R=(0,t.useContext)(bn.Z),B=(0,P.Z)(),U=(0,L.Z)(),F=R!=null&&R.all?R.all:ot.List(),V=(0,t.useMemo)(()=>F.map(({name:Ze})=>({value:Ze,label:Ze})).sort((Ze,je)=>(0,Cn.S)(Ze.label,je.label)).toArray(),[F]),se=(0,sn.Z)(),Se=(0,t.useCallback)(({field:Ze,value:je,color:ke,condition:_t})=>{const Dt=Tr(ke);return B(O.A[`SEARCH_SIDEBAR_HIGHLIGHT_${_?"UPDATED":"CREATED"}`],{app_pathname:(0,b.av)(U.pathname),app_action_value:"search-sidebar-highlight"}),_?se((0,gt.u8)(_,{field:Ze,value:je,condition:_t,color:Dt})).then(m):se((0,gt.XB)(It.ZP.create(Ze,je,_t,Dt))).then(m)},[se,U.pathname,m,_,B]),Ae=_?"Edit":"Create",Ee=_?"Update":"Create";return t.createElement(yt.Formik,{onSubmit:Se,validateOnMount:!0,initialValues:{field:_==null?void 0:_.field,value:rn()(_==null?void 0:_.value)?"":String(_==null?void 0:_.value),condition:(A=_==null?void 0:_.condition)!=null?A:"equal",color:ps(_==null?void 0:_.color)}},({isValid:Ze,values:{field:je}})=>{var ke,_t;const Dt=Ws(F,je),jt=(_t=(ke=Dt==null?void 0:Dt.type)==null?void 0:ke.isNumeric())!=null?_t:!1;return t.createElement(xe.BootstrapModalWrapper,{showModal:!0,onHide:m},t.createElement(yt.Form,{className:"form","data-testid":`${Ae}-highlighting-rule-dialog`},t.createElement(xe.Modal.Header,null,t.createElement(xe.Modal.Title,null,Ae," Highlighting Rule")),t.createElement(xe.Modal.Body,null,t.createElement(yt.Field,{name:"field",validate:co("Field")},({field:{name:Pt,value:Yt,onChange:Ht},meta:qt})=>t.createElement(xe.Input,{id:"field_type_controls",error:qt==null?void 0:qt.error,label:"Field"},t.createElement(hn.Z,{inputId:"field-select",onChange:pn=>Ht({target:{name:Pt,value:pn}}),options:V,allowCreate:!0,value:Yt,placeholder:"Pick a field"}))),t.createElement(yt.Field,{name:"condition",validate:co("Condition")},({field:{name:Pt,value:Yt,onChange:Ht},meta:qt})=>t.createElement(xe.Input,{id:"condition-controls",error:qt==null?void 0:qt.error,label:"Condition"},t.createElement(hn.Z,{inputId:"condition-select",onChange:pn=>Ht({target:{name:Pt,value:pn}}),options:jt?ns:os,value:Yt,placeholder:"Choose a condition"}))),t.createElement(yt.Field,{name:"value",validate:co("Value")},({field:{name:Pt,value:Yt,onChange:Ht},meta:qt})=>t.createElement(xe.Input,{id:Pt,type:"text",error:qt==null?void 0:qt.error,onChange:Ht,value:Yt!=null?Yt:"",label:"Value"})),t.createElement(Us,{field:Dt})),t.createElement(xe.Modal.Footer,null,t.createElement(H.os,{onCancel:m,disabledSubmit:!Ze,submitButtonText:`${Ee} rule`}))))})};Ns.propTypes={onClose:a().func.isRequired,rule:a().object},Ns.defaultProps={rule:void 0};const gs=Ns,Ho=c.default.div(({theme:m,$displayBorder:_=!0})=>(0,c.css)` display: flex; padding-top: 5px; padding-bottom: 5px; word-break: break-word; &:not(:last-child) { border-bottom: ${_?`1px solid ${m.colors.global.background}`:"none"}; } `),Yo=c.default.div` flex: 1; `,te=c.default.div` display: inline-flex; float: right; `,Te=c.default.div` padding-top: 2px; display: inline-block; `,Le=c.default.div` display: flex; align-items: center; justify-content: center; height: 25px; width: 25px; `,st=(m,_,A)=>async R=>R((0,gt.u8)(m,{color:_})).then(A),St=m=>async _=>window.confirm("Do you really want to remove this highlighting?")?_((0,gt.K$)(m)):Promise.resolve(),$t=({color:m,onChange:_})=>{const A=(0,t.useCallback)((R,B,U)=>_(Xo.WS.create(R),U),[_]);if(m.isStatic())return t.createElement(H.h4,{id:"formatting-rule-color",placement:"right",color:m.color,colors:Ke.Yc.map(R=>[R]),triggerNode:t.createElement(zo,{color:m}),onChange:A});if(m.isGradient())return t.createElement(zo,{color:m});throw new Error(`Invalid highlighting color: ${m}`)},cn=(0,t.forwardRef)(({rule:m,className:_,draggableProps:A,dragHandleProps:R},B)=>{const{field:U,value:F,color:V,condition:se}=m,[Se,Ae]=(0,t.useState)(!1),Ee=(0,sn.Z)(),Ze=(0,P.Z)(),je=(0,L.Z)(),ke=(0,t.useCallback)((Dt,jt)=>(Ze(O.A.SEARCH_SIDEBAR_HIGHLIGHT_UPDATED,{app_pathname:(0,b.av)(je.pathname),app_action_value:"search-sidebar-highlight-color-update"}),Ee(st(m,Dt,jt))),[Ee,je.pathname,m,Ze]),_t=(0,t.useCallback)(()=>(Ze(O.A.SEARCH_SIDEBAR_HIGHLIGHT_DELETED,{app_pathname:(0,b.av)(je.pathname),app_action_value:"search-sidebar-highlight-delete"}),Ee(St(m))),[Ee,je.pathname,m,Ze]);return t.createElement(Ho,{className:_,ref:B,...A!=null?A:{}},t.createElement($t,{color:V,onChange:ke}),t.createElement(Yo,null,t.createElement(Te,{"data-testid":"highlighting-rule"},t.createElement("strong",null,U)," ",It.Vm[se]," ",t.createElement("i",null,'"',String(F),'"'),"."),t.createElement(te,null,t.createElement(H.hU,{title:"Edit this Highlighting Rule",name:"edit",onClick:()=>Ae(!0)}),t.createElement(H.hU,{title:"Remove this Highlighting Rule",name:"trash-alt",onClick:_t}),R&&t.createElement(Le,{...R},t.createElement(H.JO,{name:"bars"})))),Se&&t.createElement(gs,{onClose:()=>Ae(!1),rule:m}))});cn.defaultProps={className:void 0,draggableProps:void 0,dragHandleProps:void 0},cn.propTypes={rule:a().instanceOf(It.ZP).isRequired};const In=cn,Mn=({item:{id:m,rule:_},draggableProps:A,dragHandleProps:R,className:B,ref:U})=>t.createElement(In,{key:m,rule:_,dragHandleProps:R,draggableProps:A,className:B,ref:U});Mn.defaultProps={className:void 0};const qn=()=>{var m;const[_,A]=(0,t.useState)(!1),B=((m=(0,t.useContext)(dt.Z))!=null?m:[]).map(V=>({rule:V,id:`${V.field}-${V.value}-${V.color}-${V.condition}`})),U=(0,sn.Z)(),F=(0,t.useCallback)(V=>{const se=V.map(({rule:Se})=>Se);return U((0,gt.lN)(se))},[U]);return t.createElement(t.Fragment,null,t.createElement(Mt,null,'Search terms and field values can be highlighted. Highlighting your search query in the results can be enabled/disabled in the graylog server config. Any field value can be highlighted by clicking on the value and selecting "Highlight this value". If a term or a value has more than one rule, the first matching rule is used.'),t.createElement(rt,null,"Active highlights ",t.createElement(it.Z,{className:"pull-right",name:"plus",onClick:()=>A(!_)})," "),_&&t.createElement(gs,{onClose:()=>A(!1)}),t.createElement(Ho,{$displayBorder:!!(B!=null&&B.length)},t.createElement(zo,{color:Ke.kX}),t.createElement(Te,null,"Search terms")),t.createElement(H.cm,{items:B,onMoveItem:F,customListItemRender:Mn}))},ze=[{key:"viewDescription",title:"Description",icon:"info",content:({results:m})=>t.createElement(de,{results:m})},{key:"create",icon:"plus",title:"Create",content:({toggleSidebar:m,sidebarIsPinned:_})=>t.createElement(Ye,{onClick:_?()=>{}:m})},{key:"highlighting",icon:"paragraph",title:"Highlighting",content:()=>t.createElement(qn,null)},{key:"fieldList",icon:"subscript",title:"Fields",content:({sidebarChildren:m})=>m}];var Ve=e("qIv98lrg"),We=e("rNH0cW39"),vt=e("PLPb65Bv"),Et=e("zAtQmw72");const At=(m,_)=>(0,Et.Z)(m,_),Ct=(m,{hasToPushRevision:_,dispatch:A,currentView:R})=>A((0,We.xM)(m.activeQuery)).then(()=>{const B=!(0,We.nR)(m.view,R)||!At(m.view.search,R.search);return A((0,We.NK)(m.view,B,{hasToPushRevision:_}))}),Kt=()=>async(m,_)=>{const A=_(),{revisions:R,currentRevision:B}=(0,Ve.Z)(A),{isUndoAvailable:U}=(0,Ve.b)(A),{view:F}=(0,et.zB)(A),V=B===R.length;if(U){const se=B-1,{state:Se}=R[se];Ct(Se,{hasToPushRevision:V,dispatch:m,currentView:F}).then(()=>m((0,vt.kJ)(se)))}},en=()=>async(m,_)=>{const A=_(),{revisions:R,currentRevision:B}=(0,Ve.Z)(A),{view:U}=(0,et.zB)(A),{isRedoAvailable:F}=(0,Ve.b)(A);if(F){const V=B+1,{state:se}=R[V];Ct(se,{dispatch:m,hasToPushRevision:!1,currentView:U}).then(()=>m((0,vt.kJ)(V)))}};var dn=e("D/X+X5ed");const En="Undo",zn=({sidebarIsPinned:m})=>{const _=(0,Ce.Z)(),A=(0,sn.Z)(),{isUndoAvailable:R}=(0,nt.Z)(Ve.b),B=(0,P.Z)(),U=(0,L.Z)(),F=(0,t.useCallback)(()=>(B(O.A.SEARCH_SIDEBAR_UNDO,{app_pathname:(0,b.av)(U.pathname),app_action_value:"search-sidebar-undo"}),A(Kt())),[A,U.pathname,B]);return(0,dn.Z)({actionKey:"undo",callback:()=>A(Kt()),scope:_.toLowerCase()}),t.createElement(z,{disabled:!R,onClick:F,icon:"undo",title:En,ariaLabel:En,sidebarIsPinned:m})},fn="Redo",Ss=[{key:"undoAction",Component:zn},{key:"redoAction",Component:({sidebarIsPinned:m})=>{const _=(0,Ce.Z)(),A=(0,sn.Z)(),{isRedoAvailable:R}=(0,nt.Z)(Ve.b),B=(0,P.Z)(),U=(0,L.Z)(),F=(0,t.useCallback)(()=>(B(O.A.SEARCH_SIDEBAR_REDO,{app_pathname:(0,b.av)(U.pathname),app_action_value:"search-sidebar-redo"}),A(en())),[A,U.pathname,B]);return(0,dn.Z)({actionKey:"redo",callback:()=>A(en()),scope:_.toLowerCase()}),t.createElement(z,{disabled:!R,onClick:F,icon:"redo",title:fn,ariaLabel:fn,sidebarIsPinned:m})}}];var As=e("Xt0X5Kl4");const Hs=c.default.div` display: flex; height: 100%; width: min-content; `,Fo=c.default.div(({theme:m})=>(0,c.css)` position: fixed; inset: 0 0 0 50px; background: ${p()(m.colors.brand.tertiary).alpha(.25).css()}; z-index: 5; `),uo=(m,_,A)=>{if(_){A(null);return}A(m)},De=(m,_,A,R)=>{if(m===_){R();return}A(m)},ss=({searchPageLayout:m,results:_,children:A,sections:R,actions:B})=>{var U;const F=(0,P.Z)(),V=(0,L.Z)(),se=(0,T.Z)(),Se=(U=m==null?void 0:m.config.sidebar.isPinned)!=null?U:!1,Ae=R[0].key,[Ee,Ze]=(0,t.useState)(Se?Ae:null),je=R.find(jt=>jt.key===Ee),ke=()=>{F(O.A.SEARCH_SIDEBAR_TOGGLE,{app_pathname:(0,b.av)(V.pathname),app_action_value:"search_sidebar",initialSectionKey:Ae,activeSectionKey:Ee}),uo(Ae,Ee,Ze)},_t=jt=>De(jt,Ee,Ze,ke),Dt=je==null?void 0:je.content;return t.createElement(Hs,null,t.createElement(ue,{activeSection:je,selectSidebarSection:_t,sections:R,sidebarIsPinned:Se,actions:B}),je&&!!Dt&&t.createElement(ge,{closeSidebar:ke,searchPageLayout:m,sectionTitle:je.title},t.createElement(Dt,{results:_,queryId:se,sidebarChildren:A,sidebarIsPinned:Se,toggleSidebar:ke})),je&&!Se&&t.createElement(Fo,{onClick:ke}))};ss.propTypes={children:As.Z.OneOrMoreChildren.isRequired,results:a().object,sections:a().arrayOf(a().object)},ss.defaultProps={results:{},sections:ze,actions:Ss,searchPageLayout:void 0};const Sr=({children:m,..._})=>t.createElement(y.Consumer,null,A=>t.createElement(ss,{..._,searchPageLayout:A},m));var ir=e("dsvqAVKU"),Ps=e("E+CaPsQD"),Nr=e("7dh0vSOR");const Bo=({children:m})=>(0,Ce.Z)()===Rt.Z.Type.Dashboard?t.createElement(t.Fragment,null,m):null;var ks=e("xsbnunTq"),ia=e("g6WV7s1k"),Es=e("mTnbNx1k"),Ar=e("FfX57J1C"),Ie=e("m/3sLmyX"),Qe=e("GFJVQ2dX"),bt=e("IdpefXWm"),Ut=e("efAt+LzL"),Qt=e.n(Ut);const un=(m,_)=>[...Array(_+1-m).keys()].map(A=>A+m),Ln=({width:m,height:_,col:A,row:R},B)=>({col:A,row:R,height:_,width:Number.isFinite(m)?m:B}),Vn=(m,_,A,R=A)=>{let B=!1;return un(_.col,_.col+_.width-1).forEach(U=>{un(_.row,_.row+_.height-1).forEach(F=>{var V,se,Se;((V=m[F])==null?void 0:V[U])!==void 0&&(B=!0),((se=m[F])!=null?se:m[F]=[])[U]=((Se=m[F])==null?void 0:Se[U])!==void 0?R:A})}),B},vn=m=>{if(m.length===0)return!1;const _=[];for(const A of m)if(Vn(_,A,!0))return!0;return!1},Nn=(m,_)=>{var A;return((A=m[_])!=null?A:[]).every(R=>R===void 0)},Ko=(m,_=1,A=13)=>{var R,B;if(m.length===0)return[];const U=m.map(Ae=>Ln(Ae,A)),F=Math.min(...U.map(({row:Ae})=>Ae)),V=Math.max(...U.map(({row:Ae,height:Ee})=>Ae+Ee-1));if(vn(U))return[];const se=[];U.forEach(Ae=>Vn(se,Ae,!0));const Se=[];for(let Ae=_;Ae1){for(;!Nn(se,Ze.row+Ze.height)&&Ze.row+Ze.height<=V&&un(Ze.col,Ze.col+Ze.width-1).every(je=>{var ke;return!((ke=se[Ze.row+Ze.height])!=null&&ke[je])});)Ze.height+=1;Vn(se,Ze,!0),Se.push(Ze)}}return Qt()(Se)},wo=c.default.div(({theme:m})=>(0,c.css)` opacity: 0; transition: visibility 0s, opacity 0.2s linear; height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; padding: 10px; background-color: ${m.colors.global.contentBackground}; color: ${m.colors.gray[30]}; margin-bottom: ${m.spacings.xs}; &:hover { opacity: 1; } cursor: pointer; `),Oo=(0,c.default)(H.JO)(({theme:m})=>(0,c.css)` font-size: ${m.fonts.size.huge}; margin-bottom: 10px; `),Zs=t.forwardRef(({style:m,position:_,component:A},R)=>{const[B,U]=(0,t.useState)(!1),F=(0,t.useCallback)(()=>U(!1),[]),V=(0,t.useCallback)(()=>U(!0),[]),se={...m,transition:"none"};return t.createElement("div",{style:se,ref:R},t.createElement(wo,{onClick:V},t.createElement(Oo,{name:"circle-plus"}),"Create a new widget here"),B&&t.createElement(A,{onCancel:F,position:_}))});Zs.defaultProps={style:{}};const Qs=Zs;var Fn=e("0hhBr0/b"),To=e("n6M7NB8F"),Ro=e("l8tl93Rz");const fs="Create new widget",hs=c.default.div` display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; `,ur=(0,c.default)(xe.Button)` display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; padding: 10px; width: 8rem; white-space: normal; && { background: transparent; border-radius: 4px; } `,Xs=c.default.div(({theme:m})=>(0,c.css)` font-size: ${m.fonts.size.huge}; `),Zr=({onCancel:m,position:_})=>{const A=(0,Fn.Z)("widgetCreators"),R=(0,To.Z)(),B=(0,sn.Z)(),U=(0,L.Z)(),F=(0,P.Z)(),V=(0,t.useMemo)(()=>A.map(({title:se,func:Se,icon:Ae})=>{const Ee=async()=>{F(O.A.SEARCH_WIDGET_CREATE[An()(se).replace(/ /g,"_")],{app_pathname:(0,b.av)(U.pathname),app_section:"search-widget"});const Ze=(0,Pn.Z)(),je=Se({view:R}).toBuilder().id(Ze).build();return B((0,Ro.w6)(je,_))};return t.createElement(ur,{type:"button",title:`Create ${se} Widget`,onClick:Ee},t.createElement(Xs,null,t.createElement(Ae,null)),se)}),[A,B,U.pathname,_,F,R]);return t.createElement(xe.Modal,{onHide:m,show:!0},t.createElement(xe.Modal.Header,{closeButton:!0},t.createElement(xe.Modal.Title,null,fs)),t.createElement(xe.Modal.Body,null,t.createElement(hs,null,V)),t.createElement(xe.Modal.Footer,null,t.createElement(xe.Button,{type:"button",onClick:m},"Cancel")))};var dr=e("SwOo9/Yp"),ca=e("liHGlRT1");const Pr=c.default.div` z-index: auto; ${ca.M} margin-bottom: 0; `,Js=t.forwardRef(({children:m,className:_,isFocused:A,style:R,...B},U)=>{let F={...R,transition:"none"};return A&&(F={...F,height:"100%",width:"100%",zIndex:3,top:0,left:0}),t.createElement(Pr,{className:_,style:F,ref:U,...B},m)});Js.defaultProps={className:void 0,style:{}},Js.propTypes={children:a().element.isRequired,className:a().string,isFocused:a().bool.isRequired,style:a().object};const Fr=Js;var Kr=e("gSdhV+tG"),mo=e("S/tO1idZ");const ua=t.createContext({settings:{},setSettings:()=>{}}),El=(0,u.ri)("contexts.ExportSettingsContext",()=>ua),fl=({children:m})=>{const[_,A]=(0,t.useState)(),R=(0,t.useMemo)(()=>({settings:_,setSettings:A}),[_]);return t.createElement(El.Provider,{value:R},m)};var Zi=e("qhwXAFlw"),$r=e("i0LZga0C");const Ki=m=>(0,nt.Z)((0,et.Gn)(m)),hl=()=>(0,nt.Z)(et.Sq);var vs=e("O+BThgTi"),So=e("gFL+I+yc"),Da=e("64Qr82UM"),mr=e("Ii+QL2UH"),Ys=e("O/XpfGnR");const da=()=>(0,nt.Z)(Be.AS),vl=c.default.div(({theme:m})=>(0,c.css)` font-size: ${m.fonts.size.tiny}; color: ${m.colors.gray[30]}; width: max-content; `),yl=(m,_,A)=>{var R,B,U;return(U=(B=(R=m==null?void 0:m.results)==null?void 0:R[_])==null?void 0:B.searchTypes[A])==null?void 0:U.effective_timerange},_l=({className:m,widget:_,activeQuery:A,widgetId:R})=>{var B,U;const{formatTime:F}=(0,Ys.Z)(),{result:V,widgetMapping:se}=(B=da())!=null?B:{},Se=mt(),Ae=jt=>F(jt,"complete"),Ee=jt=>F(jt,"internal"),Ze=Se!=null&&Se.timerange?`Global Override: ${(0,mr.Z)(Se.timerange,Ae)}`:void 0,je=(0,mr.Z)(_.timerange||Ke.nn,Ae),ke=R?(U=se==null?void 0:se.get(R))==null?void 0:U.first():void 0,_t=A&&ke?yl(V,A,ke):void 0,Dt=_t?(0,mr.Z)(_t,Ee):"Effective widget time range is currently not available.";return t.createElement(vl,{className:m},t.createElement(H.iI,{titleOverride:Dt},Ze||je))};_l.defaultProps={className:void 0,activeQuery:void 0,widgetId:void 0};const Cl=_l,Ra=(m,_,A)=>{const{searchTypes:R}=A,U=(0,Es.FZ)(m.type).searchResultTransformer||(Ee=>Ee),F=_.get(m.id,ot.Set()),V=F.map(Ee=>R[Ee]).filter(Ee=>Ee!==void 0).toArray(),se=A.errors.filter(Ee=>F.includes(Ee.searchTypeId));let Se;const Ae=U(V);if(se&&se.length>0&&(Se=se),!V||V.length===0){const Ee=A.errors.filter(Ze=>Ze.type==="query");Ee.length>0&&(Se=Se?[].concat(Se,Ee):Ee)}return{widgetData:Ae,error:Se}},Gi=(m,_)=>{const A=_==null?void 0:_.find(R=>R.queryId===m);return{widgetData:void 0,error:A?[A]:[]}},pr=m=>(0,Oe.P1)(Be.AS,et.cE,(0,et.Gn)(m),(_,A,R)=>{var B;const{result:U,widgetMapping:F}=_!=null?_:{},V=(B=U==null?void 0:U.results)==null?void 0:B[A],se=U==null?void 0:U.errors;return V?Ra(R,F,V):Gi(A,se)}),br=m=>(0,nt.Z)(pr(m));var Tl=e("A2mY8G47");const Sl=c.default.div(({theme:m})=>(0,c.css)` height: inherit; margin: 0; padding: 7px 9px 6px; display: flex; flex-direction: column; overflow: hidden; .dc-chart { float: none; } .controls { display: none; position: relative; left: -3px; } .reloading { margin-right: 2px; font-weight: bold; color: ${m.colors.variant.dark.info}; display: none; } .loading-failed { color: ${m.colors.variant.danger} !important; } .widget-title { font-size: ${m.fonts.size.large}; height: 25px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .load-error { color: ${m.colors.variant.danger}; margin-right: 5px; } .widget-update-info { text-align: left; float: left; font-size: ${m.fonts.size.small}; position: absolute; bottom: 10px; width: 130px; } .configuration dt { text-transform: capitalize; } svg { overflow: hidden; } .quickvalues-graph { text-align: center; } .graph.scatterplot path.line { display: none; } .actions { position: absolute; right: 15px; bottom: 10px; div { display: inline-block; margin-left: 5px; } button { padding: 0 5px; } } `),Al=({children:m,widgetId:_})=>t.createElement(Sl,{"data-widget-id":_},m);var qs=e("FYGzXHJc");const ji=t.createContext("query"),Pl=(0,u.ri)("views.components.contexts.QueryEditModeContext",()=>ji);var Ia=e("ocYLQ/BD"),Ao=e("jAGDuYSC"),bl=e("0IW4P5Zs"),Dl=e("6KiaUlHf");const zi=({children:m,widget:_})=>{const{setDisabled:A}=(0,t.useContext)(bl.Z),R=(0,t.useCallback)(Ee=>A("widget-edit-apply-all-changes",Ee),[A]),B=(0,t.useRef)(null),U=(0,t.useRef)(null),F=(0,sn.Z)(),V=(0,t.useCallback)(Ee=>{B.current=Ee},[]),se=(0,t.useCallback)(Ee=>{U.current=Ee},[]),Se=(0,t.useCallback)(()=>{let Ee=_,Ze=!1;if(B.current){const je=B.current(Ee);je&&(Ee=je,Ze=Ze||!0)}if(U.current){const je=U.current(Ee.config);je&&(Ee=Ee.toBuilder().config(je).build(),Ze=Ze||!0)}return Ze?(R(!0),F((0,Ro.QB)(_.id,Ee)).catch(je=>(Ao.Z.error(`Applying widget changes failed with status: ${je}`),je)).finally(()=>R(!1))):Promise.resolve()},[_,R,F]),Ae=(0,t.useMemo)(()=>({applyAllWidgetChanges:Se,bindApplyElementConfigurationChanges:se,bindApplySearchControlsChanges:V}),[Se,se,V]);return t.createElement(Dl.Z.Provider,{value:Ae},m)};var er=e("9oVghaOd"),rs=e.n(er),tr=e("DUKaTDO2"),oo=e("Cd4wX32x"),as=e("CHWvwBKE"),Wo=e("PYFLluwn"),bs=e("QBkrNAIi"),ma=e("VgplIV7d"),Gr=e("knPiWeMO"),Ol=e.n(Gr),jr=e("TJOheZRu"),$o=e("baf4E2h0");const zr=t.createContext(void 0),Fs=(0,u.ri)("contexts.FormWarningsContext",()=>zr),Ma=c.default.div` margin-left: 5px; width: 25px; min-height: 34px; display: flex; align-items: center; justify-content: center; `,Vr=c.default.button(({$clickable:m})=>(0,c.css)` padding: 0; background: transparent; border: 0; display: flex; align-items: center; cursor: ${m?"pointer":"default"}; `),gr=(0,c.default)(x.Z)(({theme:m,$status:_})=>(0,c.css)` color: ${_==="ERROR"?m.colors.variant.danger:m.colors.variant.warning}; font-size: 22px; `),Rl=(0,c.default)(x.Z)` margin-left: 5px; `,Hr=c.default.div` display: flex; justify-content: space-between; `,Il=c.default.div` display: flex; justify-content: space-between; &:not(:last-child) { margin-bottom: 6px; } `,xa=(0,c.keyframes)` 10%, 90% { transform: translate3d(-1px, 0, 0); } 20%, 80% { transform: translate3d(2px, 0, 0); } 30%, 50%, 70% { transform: translate3d(-4px, 0, 0); } 40%, 60% { transform: translate3d(4px, 0, 0); } `,La=(0,c.default)(xe.Popover)(({$shaking:m})=>(0,c.css)` animation: ${m?(0,c.css)`${xa} 0.82s cubic-bezier(0.36, 0.07, 0.19, 0.97) both`:"none"}; `),Ba=({title:m})=>t.createElement(Hr,null,m),pa=()=>{const[m,_]=(0,t.useState)(!1),A=(0,t.useCallback)(()=>{m||(_(!0),Ol()(()=>_(!1),820))},[m]);return[m,A]},Ua=m=>{const[_,A]=(0,t.useState)(!1),R=(0,t.useCallback)(()=>A(B=>!B),[]);return(0,t.useEffect)(()=>{const B=$o.Z.displayValidationErrors.listen(()=>{_?m():R()});return()=>{B()}},[m,_,R]),[_,R]},wa=m=>{switch(m){case"UNKNOWN_FIELD":return Ps.Z.PAGES.SEARCH_QUERY_ERRORS.UNKNOWN_FIELD;case"QUERY_PARSING_ERROR":return Ps.Z.PAGES.SEARCH_QUERY_ERRORS.QUERY_PARSING_ERROR;case"INVALID_OPERATOR":return Ps.Z.PAGES.SEARCH_QUERY_ERRORS.INVALID_OPERATOR;case"UNDECLARED_PARAMETER":return Ps.Z.PAGES.SEARCH_QUERY_ERRORS.UNDECLARED_PARAMETER;default:return Ps.Z.PAGES.SEARCH_QUERY_LANGUAGE}},Wa=m=>{if(m===null||m.length===0)return[];const[_]=m.reduce(([A,R],B)=>B.errorType==="UNKNOWN_FIELD"?B.relatedProperty!==void 0&&!R.includes(B.relatedProperty)?[[...A,B],[...R,B.relatedProperty]]:[A,R]:[[...A,B],R],[[],[]]);return _},kr=()=>{const m=(0,Fn.Z)("views.elements.validationErrorExplanation"),[_,A]=pa(),[R,B]=Ua(A),U=(0,t.useRef)(void 0),{errors:{queryString:F}}=(0,yt.useFormikContext)(),{warnings:V}=(0,t.useContext)(Fs),se=F!=null?F:V==null?void 0:V.queryString,{status:Se,explanations:Ae=[]}=se!=null?se:{explanations:[]},Ee=(0,t.useMemo)(()=>Wa(Ae),[Ae]),Ze=se&&(se==null?void 0:se.status)!=="OK";return t.createElement(t.Fragment,null,t.createElement(Ma,{ref:U},Ze?t.createElement(Vr,{title:"Toggle validation error explanation",onClick:B,$clickable:!0,tabIndex:0,type:"button"},t.createElement(gr,{$status:Se,name:"exclamation-circle"})):t.createElement(Nr.Z,{page:Ps.Z.PAGES.SEARCH_QUERY_LANGUAGE,title:"Search query syntax documentation",text:t.createElement(x.Z,{name:"lightbulb"})})),Ze&&R&&t.createElement(ma.aV,{show:!0,containerPadding:10,placement:"bottom",target:U.current,shouldUpdatePosition:!0,transition:ma.uT},t.createElement(La,{id:"query-validation-error-explanation",title:t.createElement(Ba,{title:jr.Z.capitalizeFirstLetter(Se.toLocaleLowerCase())}),$shaking:_},t.createElement("div",{role:"alert"},Ee.map(({errorType:je,errorTitle:ke,errorMessage:_t,id:Dt})=>t.createElement(Il,{key:Dt},t.createElement("span",null,t.createElement("b",null,ke),": ",_t),t.createElement(Nr.Z,{page:wa(je),title:`${ke} documentation`,text:t.createElement(Rl,{name:"lightbulb"})}))),m==null?void 0:m.map((je,ke)=>t.createElement(je,{validationState:se,key:ke}))))))},Na=()=>{const m=(0,t.useRef)(!1);return(0,t.useEffect)(()=>(m.current=!0,()=>{m.current=!1}),[]),m},Qr=({children:m})=>{const _=Na(),[A,R]=(0,t.useState)({}),B=(0,t.useCallback)((F,V)=>{_.current===!0&&R(se=>({...se,[F]:V}))},[_]),U=(0,t.useMemo)(()=>({warnings:A,setFieldWarning:B}),[B,A]);return t.createElement(Fs.Provider,{value:U},m)},Fa=(0,Oe.P1)(Be.nK,et.IB,(m,_)=>({parameterBindings:m,parameters:_})),Dr=()=>(0,nt.Z)(Fa);var ls=e("eZ5nxjAy"),Xr=e("eFxcQyPT"),Ds=e("QV1daZoe");const is=m=>typeof m=="object"?!!m.query_string:!!m,Er=({queryString:m,timeRange:_,streams:A,filter:R,...B},U)=>{if(!is(m)&&!is(R))return Promise.resolve({status:"OK",explanations:[]});const F={query:m,timerange:_?(0,Ds.P3)(_,U):void 0,streams:A,filter:R,...B};return(0,Xr.ZP)("POST",(0,b.DC)("/search/validate"),F).then(V=>{var se;if(V){const Se=(se=V.explanations)==null?void 0:se.map(({error_type:Ae,error_title:Ee,error_message:Ze,begin_line:je,end_line:ke,begin_column:_t,end_column:Dt,related_property:jt})=>({id:(0,Pn.Z)(),errorMessage:Ze,errorType:Ae,errorTitle:Ee,beginLine:je?je-1:0,endLine:ke?ke-1:0,beginColumn:_t,endColumn:Dt,relatedProperty:jt}));return{status:V.status,explanations:Se}}}).catch(V=>(Ao.Z.error(`Validating search query failed with status: ${V}`),{status:"OK",explanations:[]}))},Ea=({parameters:m})=>{const{validateForm:_}=(0,yt.useFormikContext)(),A=(0,t.useRef)(!1);return(0,t.useEffect)(()=>{A.current?_():A.current=!0},[_,m]),null};var Ul=e("wXrUUKFq"),fa=e.n(Ul);const fr=(m,_,A)=>{try{return m()}catch(R){console.error(`${_}: ${R}`),Ao.Z.error(`${_}: ${R}`)}return A},wl=(m,_)=>{const A=_.map(R=>fr(()=>R(m),"An error occurred when collecting initial search bar form values from a plugin",{}));return fa()({},...A)},Ka=m=>{var _;const A=(_=(0,Fn.Z)("views.components.searchBar"))!=null?_:[],R=A==null?void 0:A.map(B=>{var U;return(U=B())==null?void 0:U.useInitialSearchValues}).filter(B=>!!B);return wl(m,R)},Wl=m=>{var _;const A=(_=(0,Fn.Z)("views.components.searchBar"))!=null?_:[],R=A==null?void 0:A.map(B=>{var U;return(U=B())==null?void 0:U.useInitialDashboardWidgetValues}).filter(B=>!!B);return wl(m,R)},Or=async(m,_,A,R)=>{let B=R;for(const U of A){const F=await U(_,m,B).catch(V=>{const se=`An error occurred when executing a submit handler from a plugin: ${V}`;return console.error(se),Ao.Z.error(se),B});F&&(B=F)}return B},$a=(m,_,A,R)=>{const B=A==null?void 0:A.map(U=>{var F;return(F=U())==null?void 0:F.onSearchSubmit}).filter(U=>!!U);return Or(m,_,B,R)},Nl=(m,_,A,R)=>{const B=A==null?void 0:A.map(U=>{var F;return(F=U())==null?void 0:F.onDashboardWidgetSubmit}).filter(U=>!!U);return Or(m,_,B,R)},ha=(m,_,A=[])=>{const B=A.map(U=>{var F;return(F=U())==null?void 0:F.validationPayload}).filter(U=>!!U).map(U=>fr(()=>U(m,_),"An error occurred when preparing search bar validation for a plugin",{}));return fa()({},...B)},va=(m,_,A=[])=>{const B=A.map(U=>{var F;return(F=U())==null?void 0:F.onValidate}).filter(U=>!!U).map(U=>fr(()=>U(m,_),"An error occurred when validating search bar values from a plugin",{}));return fa()({},...B)};var Po=e("2XdKdJGP");const Zl=m=>{const _=(0,Fn.Z)("views.queryInput.commandContextProviders");return{...Object.fromEntries(_.map(({key:R,provider:B})=>[R,B()])),usage:m}},Fl=m=>{const _=(0,Fn.Z)("views.queryInput.commands"),A=(0,t.useMemo)(()=>_.filter(({usages:B=[]})=>B.includes(m)),[_,m]),R=Zl(m);return(0,t.useMemo)(()=>A.map(({name:B,bindKey:U,exec:F})=>({name:B,bindKey:U,exec:V=>F(V,R)})),[A,R])},hr=({children:m,usage:_})=>{const A=Fl(_);return(0,t.useMemo)(()=>m(A),[m,A])};var qo=e("6/nLyfIT");const $l=(0,Oe.P1)(et.fv,Be.nR,(m,_)=>({view:m,executionState:_})),Os=()=>(0,nt.Z)($l);var Rs=e("qC/AOIKG");const ja=c.default.div` display: flex; align-items: center; `,Gl=c.default.div(({theme:m})=>` margin-left: 10px; border: 1px dashed ${m.colors.input.border}; width: 100%; border-radius: 4px; padding: 0 5px; min-height: 34px; `),za=c.default.div(({theme:m})=>` display: inline-block; margin-left: 0; margin-top: 5px; padding: 0 3px; border-radius: 4px; background-color: ${m.colors.variant.lightest.primary}; color: ${m.colors.variant.darker.primary}; font-size: ${m.fonts.size.body}; font-family: ${m.fonts.family.monospace}; `),jl=(0,c.default)(xe.Button)` margin-top: 5px; margin-bottom: 5px; margin-left: 5px; display: inline-block; float: right; `,ya=({value:m,onReset:_})=>{const{formatTime:A}=(0,Ys.Z)(),R=(0,mr.Z)(m,U=>A(U,"complete")),B=(0,mr.Z)(m,U=>A(U,"internal"));return t.createElement(ja,null,t.createElement(Rs.Z,{disabled:!0}),t.createElement(Gl,null,t.createElement(za,{title:B},R),t.createElement(jl,{bsSize:"xs",bsStyle:"primary",onClick:_,"data-testid":"reset-global-time-range"},"Reset Global Override")))};var vr=e("f2ImtPH2");const zl=c.default.div` flex: 1; grid-area: streams; `,Ha=({disabled:m,value:_,streams:A,onChange:R})=>{const B=(0,P.Z)(),U=_.join(","),F="Select streams the search should include. Searches in all streams if empty.",V=A.sort(({key:Se},{key:Ae})=>(0,Cn.S)(Se,Ae)),se=Se=>{B(O.A.SEARCH_STREAM_INPUT_CHANGED,{app_pathname:"search",app_section:"search-bar",app_action_value:"search-filter",event_details:{streamsCount:Se.split(",").length}}),R(Se===""?[]:Se.split(","))};return t.createElement(zl,{"data-testid":"streams-filter",title:F},t.createElement(hn.Z,{placeholder:F,disabled:m,inputProps:{"aria-label":F},displayKey:"key",inputId:"streams-filter",onChange:se,options:V,multi:!0,value:U}))};Ha.propTypes={disabled:a().bool,value:a().arrayOf(a().string),streams:a().arrayOf(a().shape({key:a().string.isRequired,value:a().string.isRequired})).isRequired,onChange:a().func.isRequired},Ha.defaultProps={disabled:!1,value:[]};const ka=Ha,Qa=(0,c.default)(xe.Button)(({theme:m,$dirty:_})=>(0,c.css)` position: relative; min-width: 63px; &&&.disabled { color: ${m.utils.contrastingColor(m.colors.variant.success)}; } ${_?(0,c.css)` &::after { position: absolute; content: ''; height: 16px; width: 16px; top: -5px; right: -6px; border-radius: 50%; background-color: ${m.colors.variant.warning}; } `:""} `),k=(m,_,A)=>{_&&(m.preventDefault(),$o.Z.displayValidationErrors()),A()},$=({dirty:m,disabled:_,glyph:A,displaySpinner:R})=>{const B=(0,P.Z)(),U=(0,L.Z)(),F=_?"disabled":"",V=m?"Perform search (changes were made after last search execution)":"Perform Search",se=()=>{B(O.A.SEARCH_BUTTON_CLICKED,{app_pathname:(0,b.av)(U.pathname),app_section:"search-bar",app_action_value:"search-button",event_details:{disabled:_}})};return t.createElement(Qa,{onClick:Se=>k(Se,_,se),title:V,className:F,type:"submit",bsStyle:"success",$dirty:m},R?t.createElement(H.$j,{delay:0,text:""}):t.createElement(H.JO,{name:A}))};$.defaultProps={disabled:!1,displaySpinner:!1,dirty:!1,glyph:"search"},$.propTypes={disabled:a().bool,displaySpinner:a().bool,dirty:a().bool,glyph:a().string};const q=$;var Ne=e("8jTixuP6");const tt=(0,Ne.Z)(()=>Promise.all([e.e("1255d548-3618"),e.e("1255d548-2679"),e.e("1255d548-5716")]).then(e.bind(e,"myDR0xOD")));var wt=e("87D/Fijl"),Un=e.n(wt),Tn=e("rKq6XZKM"),kn=e("tITy3x4L");const eo=async(m,_,A,R,B,U,F)=>{const{timerange:V}=m;let se={};const Se=(0,kn.Z)(V,_,U);Lt()(Se)||(se={...se,timerange:Se});const Ae=va(m,F,B);Lt()(Ae)||(se={...se,...Ae});const Ee=await R(m);return(Ee==null?void 0:Ee.status)==="OK"?(A("queryString",void 0),se):(Ee==null?void 0:Ee.status)==="WARNING"?(A("queryString",Ee),se):(Ee==null?void 0:Ee.status)==="ERROR"?(A("queryString",void 0),{...se,queryString:Ee}):se},fo=m=>Un()(m),to=({timerange:m,..._},A)=>({timerange:(0,Ds.P3)(m,A),..._}),cs=({initialValues:m,limitDuration:_,onSubmit:A,children:R,validateOnMount:B,formRef:U,validateQueryString:F})=>{const[V,se]=(0,t.useState)(!0),{formatTime:Se,userTimezone:Ae}=(0,Ys.Z)(),Ee=(0,Fn.Z)("views.components.searchBar"),{setFieldWarning:Ze}=(0,t.useContext)(Fs),je=(0,t.useCallback)(jt=>(se(!1),A(to(jt,Ae)).finally(()=>se(!0))),[A,Ae]),ke=(0,t.useMemo)(()=>{const{timerange:jt,...Pt}=m;return{...Pt,timerange:(0,Tn.h)(jt,Se)}},[Se,m]),_t=Os(),Dt=(0,t.useCallback)(jt=>eo(jt,_,Ze,F,Ee,Se,_t),[_,Ze,F,Ee,Se,_t]);return t.createElement(yt.Formik,{initialValues:ke,enableReinitialize:V,onSubmit:je,innerRef:U,validate:Dt,validateOnBlur:!1,validateOnMount:B},(...jt)=>t.createElement(yt.Form,null,fo(R)?R(...jt):R))};cs.propTypes={onSubmit:a().func.isRequired,limitDuration:a().number.isRequired,validateOnMount:a().bool},cs.defaultProps={validateOnMount:!0,formRef:void 0};const us=cs,nr=(0,Ne.Z)(()=>Promise.all([e.e("1255d548-3618"),e.e("1255d548-2679"),e.e("1255d548-1247")]).then(e.bind(e,"BaXPld/A"))),or=c.default.div` width: 25%; min-width: 300px; max-width: 500px; display: flex; align-items: center; &::before { box-shadow: 17px 0 16px -16px rgb(0 0 0 / 40%) inset; } `,po=c.default.div(({theme:m})=>(0,c.css)` margin-left: 10px; border: 1px dashed ${m.colors.input.border}; display: flex; align-items: center; width: 100%; border-top-right-radius: 4px; border-bottom-right-radius: 4px; padding: 0 5px; min-height: 34px; border-left: 0; .query { flex: 1; } `),Ks=(0,c.default)(nr)` &&.ace-queryinput { border: none; } `,ho=(0,c.default)(xe.Button)` margin-left: 5px; `,Jr=({value:m,onReset:_})=>t.createElement(or,null,t.createElement(po,null,t.createElement(Ks,{disabled:!0,value:m.query_string,height:34,wrapEnabled:!1,maxLines:1}),t.createElement(ho,{bsSize:"xs",bsStyle:"primary",onClick:_,"data-testid":"reset-global-query"},"Reset Global Filter"))),Vl=c.default.div` display: flex; align-items: center; `,Hl=(0,c.default)(xe.ButtonGroup)` margin-left: 5px; `,$s=c.default.div` display: flex; justify-content: flex-end; `,Gs=(0,c.default)(H.kF)` margin-left: 5px; `,js=()=>t.createElement(t.Fragment,null,t.createElement("p",null,t.createElement("i",null,"Search filters")," contain their own query and extend the main query using the ",t.createElement("b",null,"AND")," operator."),t.createElement("p",null,"Filters can be saved separately and reused in saved searches and dashboards. Updating a saved filter will automatically affect the search results of searches which include the filter.")),vu=({onHide:m,pluggableControls:_})=>_.find(R=>R.id==="search-filters")?null:t.createElement(Vl,null,"Filters",t.createElement(Gs,{title:"Search Filters",trigger:["click"]},t.createElement(js,null),t.createElement("p",null,"Search filters and parameters are available for the enterprise version."),t.createElement($s,null,t.createElement(xe.Button,{onClick:m,bsSize:"xs"},"Hide controls"))),t.createElement(Hl,null,t.createElement(xe.Button,{disabled:!0,bsSize:"small"},t.createElement(H.JO,{name:"plus"})),t.createElement(xe.Button,{disabled:!0,bsSize:"small"},t.createElement(H.JO,{name:"folder"}))));var Xa=e("7GNmVOX8"),yu=e("zJE5UjMB");const Hi="pluggableSearchBarControlsAreHidden",ki=c.default.div` display: flex; flex-wrap: wrap; justify-content: space-between; gap: ${Po.V}; `,_u=()=>{var m;const A=((m=(0,Fn.Z)("views.components.searchBar"))!=null?m:[]).map(U=>U()).filter(U=>!!U),R=A.filter(({placement:U})=>U==="left"),B=A.filter(({placement:U})=>U==="right");return{leftControls:R,rightControls:B}},Cu=m=>m==null?void 0:m.map(({component:_,id:A})=>t.createElement(_,{key:A})),Hm=({hidePluggableControlsPreview:m,showLeftControls:_,showRightControls:A,hasPluggableControls:R,hasSearchFilterFeatureFlag:B,hasLeftColFallback:U,hasRightColFallback:F})=>R?!0:m?!1:_&&U&&B||A&&!!F,_a=({showLeftControls:m,showRightControls:_})=>{const[A,R]=(0,t.useState)(()=>!!Xa.Z.get(Hi)),{leftControls:B,rightControls:U}=_u(),F=(0,yu.Z)("search_filter"),V=!!(B!=null&&B.length||U!=null&&U.length),se=(0,t.useCallback)(()=>{R(!0),Xa.Z.set(Hi,!0)},[]),Se=t.createElement(vu,{onHide:se,pluggableControls:B});return Hm({hidePluggableControlsPreview:A,showLeftControls:m,showRightControls:_,hasPluggableControls:V,hasSearchFilterFeatureFlag:F,hasLeftColFallback:!!Se})?t.createElement(ki,null,t.createElement("div",null,F&&m&&t.createElement(t.Fragment,null,Cu(B),Se)),t.createElement("div",null,_&&Cu(U))):null};_a.defaultProps={showLeftControls:!0,showRightControls:!0};const Ql=_a,Tu=c.default.div` display: flex; flex-direction: column; gap: ${Po.V}; `,Qi=c.default.div` display: flex; flex: 1; `,Xl=(m,{timerange:_,streams:A,queryString:R})=>m.toBuilder().timerange(_).query((0,as.Eg)(R)).streams(A).build(),Xi=async(m,_,A,R)=>{const{timerange:B,streams:U,queryString:F}=_,V=await Nl(m,_,A,R),se=Xl(V,{timerange:B,streams:U,queryString:F});return R.equals(se)?m((0,qo.ht)()):m((0,Ro.QB)(R.id,se))},Rr=m=>m((0,qo.A7)(void 0)).then(()=>m((0,qo.ht)())),Ji=m=>m((0,qo.B3)(void 0)).then(()=>m((0,qo.ht)())),Su=m=>{const{bindApplySearchControlsChanges:_}=(0,t.useContext)(Dl.Z),{userTimezone:A}=(0,Ys.Z)();(0,t.useEffect)(()=>{_(R=>{if(m.current){const{dirty:B,values:U,isValid:F}=m.current;if(B&&F){const V=to(U,A);return Xl(R,V)}}})},[m,_,A])},Yi=m=>{var _,A;const{streams:R}=m,B=(_=m.timerange)!=null?_:Ke.nn,{query_string:U}=(A=m.query)!=null?A:(0,as.Eg)(""),F=Wl(m);return(0,t.useMemo)(()=>({timerange:B,streams:R,queryString:U,...F}),[B,R,U,F])},Au=(0,ls.Z)(Er,350),Pu=(m,_,A,R,B)=>{const U={queryString:m==null?void 0:m.queryString,timeRange:Lt()(_==null?void 0:_.timerange)?m==null?void 0:m.timerange:_.timerange,filter:_!=null&&_.query?_.query:void 0,streams:m==null?void 0:m.streams,...ha(m,B,A)};return Au(U,R)},qi=({availableStreams:m})=>{var _;const A=mt(),R=(0,t.useContext)(mo.Z),{userTimezone:B}=(0,Ys.Z)(),U=(0,d.o)(Wo.s,({searchesClusterConfig:Ht})=>Ht),F=!!(0,tr.useIsFetching)(["validateSearchQuery"]),V=(0,Fn.Z)("views.components.searchBar"),se=(_=rs().duration(U==null?void 0:U.query_time_range_limit).asSeconds())!=null?_:0,Se=(A==null?void 0:A.timerange)!==void 0,Ae=(A==null?void 0:A.query)!==void 0,Ee=(0,t.useRef)(null),{parameters:Ze}=Dr(),je=Os(),ke=(0,t.useCallback)(Ht=>Pu(Ht,A,V,B,je),[A,V,B,je]),_t=Yi(R),Dt=(0,sn.Z)(),jt=(0,t.useCallback)(Ht=>Xi(Dt,Ht,V,R),[Dt,V,R]),Pt=(0,t.useCallback)(()=>Dt(Rr),[Dt]),Yt=(0,t.useCallback)(()=>Dt(Ji),[Dt]);return Su(Ee),t.createElement(Qr,null,t.createElement(us,{initialValues:_t,limitDuration:se,formRef:Ee,onSubmit:jt,validateQueryString:ke},({dirty:Ht,errors:qt,isValid:pn,isSubmitting:tn,handleSubmit:wn,values:on,setFieldValue:so,validateForm:yn})=>{const lo=tn||F||!pn;return t.createElement(Tu,null,t.createElement(bs.l,{formKey:"widget-query-controls",disableSubmission:lo}),t.createElement(Ea,{parameters:Ze}),t.createElement(Po.Fy,null,!Se&&t.createElement(vr.Z,{disabled:Se,limitDuration:se,onChange:Sn=>so("timerange",Sn),value:on==null?void 0:on.timerange,hasErrorOnMount:!!qt.timerange,position:"right"}),Se&&t.createElement(ya,{value:A==null?void 0:A.timerange,onReset:Pt}),t.createElement(yt.Field,{name:"streams"},({field:{name:Sn,value:ro,onChange:Io}})=>t.createElement(ka,{value:ro,streams:m,onChange:rr=>Io({target:{value:rr,name:Sn}})}))),t.createElement(Po.dD,null,t.createElement(q,{disabled:lo,dirty:Ht,displaySpinner:tn}),t.createElement(Qi,null,t.createElement(yt.Field,{name:"queryString"},({field:{name:Sn,value:ro,onChange:Io},meta:{error:rr}})=>t.createElement(Fs.Consumer,null,({warnings:Qo})=>t.createElement(hr,{usage:"widget_query"},ba=>t.createElement(tt,{value:ro,timeRange:Lt()(A==null?void 0:A.timerange)?on==null?void 0:on.timerange:A.timerange,streams:on==null?void 0:on.streams,placeholder:'Type your search query here and press enter. E.g.: ("not found" AND http) OR http_response_code:[400 TO 404]',error:rr,disableExecution:lo,isValidating:F,warning:Qo.queryString,validate:yn,name:Sn,onChange:Io,onExecute:wn,commands:ba})))),t.createElement(kr,null)),Ae&&t.createElement(Jr,{value:A==null?void 0:A.query,onReset:Yt})),t.createElement(Ql,null))}))};qi.propTypes={};const bu=(0,d.Z)(qi,{availableStreams:oo.h},({availableStreams:{streams:m=[]},..._})=>({..._,availableStreams:m.map(A=>({key:A.title,value:A.id}))})),Ir=({children:m})=>{const _=(0,Fn.Z)("views.overrides.widgetEdit"),[A,R]=(0,t.useState)(void 0),B=(0,t.useCallback)(()=>R(void 0),[]),U=(0,t.useCallback)(V=>R(()=>V),[]);if(A){if(A instanceof Error)throw A;return t.createElement(A,{retry:B})}const F=_.map((V,se)=>t.createElement(V,{key:se,override:U}));return t.createElement(t.Fragment,null,F,m)},Ja=({children:m})=>{const[_,A]=(0,t.useState)({}),R=(0,t.useCallback)((F,V)=>{!!_[F]!==V&&A({..._,[F]:V})},[_]),B=Object.values(_).includes(!0),U=(0,t.useMemo)(()=>({disabled:B,setDisabled:R}),[B,R]);return t.createElement(bl.Z.Provider,{value:U},m)},Mr=c.default.div` display: flex; flex-direction: column; height: 100%; flex: 1; overflow: hidden; `,km=c.default.div` margin-bottom: 10px; `,Yl=c.default.div` display: flex; flex: 1; overflow: hidden; `,ec=({children:m,onCancel:_,onSubmit:A,displaySubmitActions:R})=>{const B=(0,t.useContext)(mo.Z);return B?t.createElement(zi,{widget:B},t.createElement(Ja,null,t.createElement(Mr,null,t.createElement(Bo,null,t.createElement(km,null,t.createElement(Pl.Provider,{value:"widget"},t.createElement(bu,null)))),t.createElement(Yl,{role:"presentation"},t.createElement(Ir,null,m)),R&&t.createElement("div",null,t.createElement(Ia.Z,{onSubmit:A,onCancel:_}))))):t.createElement(ir.Z,{text:"Loading widget ..."})};ec.defaultProps={displaySubmitActions:!0};const Ou=ec,tc=()=>t.createElement(H.M5,null,t.createElement(ir.Z,{"data-testid":"loading-widget"}));tc.propTypes={};const Ru=tc;var Ya=e("9FNnmA1r"),Iu=e("oxGoxcS7");const qa=()=>(0,nt.Z)(et.RN);var Mu=e("4U1brrvO");const xu=m=>m&&"formattingSettings"in m,ql=()=>qa().valueSeq().toArray().flatMap(_=>{var A;const{config:R}=_,B=_.id;if(xu(R)){const{chartColors:U={}}=(A=R.formattingSettings)!=null?A:Mu.Z.empty();return Object.entries(U).map(([F,V])=>({widgetId:B,name:F,color:V}))}return[]}).filter(_=>_!==null);var Bu=e("G0W2UiZR");const ei=({children:m,id:_})=>{const A=ql(),R=(0,t.useMemo)(()=>{const F=Iu.Z.builder();return A.filter(({widgetId:se})=>se===_).reduce((se,{name:Se,color:Ae})=>se.set(Se,Ae),F).build()},[A,_]),B=(0,sn.Z)(),U=(0,t.useMemo)(()=>({colors:R,setColor:(V,se)=>(R.set(V,se),B((0,Ro.Yn)(_,V,se)))}),[R,B,_]);return t.createElement(Bu.Z.Provider,{value:U},m)};ei.propTypes={children:a().node.isRequired,id:a().string.isRequired};const Uu=ei;class wu extends t.Component{constructor(_){super(_),this.state={}}static getDerivedStateFromError(_){return{error:_}}render(){const{error:_}=this.state,{children:A,...R}=this.props,B=t.cloneElement(A,R);return _?t.createElement(Ya.Z,{title:"While rendering this widget, the following error occurred:",errors:[{description:_.toString()}]}):B}}var Wu=e("rp7UD7rK"),nc=e("gqVHlIxA");const Nu=m=>m.sort((_,A)=>(0,Cn.S)(_.label,A.label)),Ca=({selectWidget:m,widgets:_,view:A})=>{const R=U=>({label:A.getWidgetTitleByWidget(U),value:U}),B=Nu(_.map(U=>R(U)).toArray());return t.createElement(t.Fragment,null,t.createElement(xe.Row,null,t.createElement(ks.Z,null,"The export will contain all messages for your current search.",t.createElement("br",null),"Please select a message table to adopt its fields. You can adjust all settings in the next step."),t.createElement(Bo,null,"Please select the message table you want to export the search results for. You can adjust its fields in the next step.",t.createElement("br",null),'Selecting a message table equals using the option "Export to CSV" in a message table action menu.')),_.size!==0?t.createElement(xe.Row,null,t.createElement("label",{htmlFor:"widget-selection"},"Select message table"),t.createElement(hn.Z,{placeholder:"Select message table",onChange:m,options:B,inputId:"widget-selection"})):t.createElement(xe.Row,null,t.createElement(xe.Alert,{bsStyle:"warning"},"You need to create a message table widget to export its result.")))},Zu=()=>(0,nt.Z)(Be.nR),Fu=()=>{const m=(0,Fn.Z)("views.export.formats"),_=m.sort((A,R)=>(0,Cn.S)(A==null?void 0:A.displayName,R==null?void 0:R.displayName)).map(({type:A,displayName:R,disabled:B=()=>!1})=>{const U=B();return{label:R(),value:A,disabled:U}});return m.length>1?t.createElement(yt.Field,{name:"format"},({field:{name:A,value:R,onChange:B}})=>t.createElement(t.Fragment,null,t.createElement("label",{htmlFor:A},"Output Format"),t.createElement(hn.Z,{name:A,value:R,options:_,onChange:U=>B({target:{name:A,value:U}})}))):null};var Ku=e("GrokUsBg");const $u=({widget:m})=>{var _;const{exportComponent:A=()=>null}=(_=(0,t.useMemo)(()=>(m==null?void 0:m.type)&&(0,Es.FZ)(m.type),[m]))!=null?_:{};return t.createElement(A,{widget:m})},Gu=({selectedWidget:m,view:_})=>{const A=_.getWidgetTitleByWidget(m);return t.createElement(xe.Row,null,t.createElement("i",null,t.createElement(ks.Z,null,m&&`The following settings are based on the message table: ${A}`,t.createElement("br",null)),t.createElement(Bo,null,m&&`You are currently exporting the search results for the message table: ${A}`,t.createElement("br",null))))},oc=({selectedWidget:m,view:_})=>t.createElement(t.Fragment,null,t.createElement(xe.Row,null,t.createElement(Fu,null)),m&&t.createElement(Gu,{selectedWidget:m,view:_}),t.createElement(xe.Row,null,t.createElement("p",null,"Define the fields for your file.",t.createElement("br",null)),m&&t.createElement("p",null,"The export supports fields created by decorators which are part of the message table, but they currently do not appear in the field list. If you want to export a decorated field, just enter its name."),t.createElement("p",null,"When you've finished the configuration, click on ",t.createElement("q",null,"Start Download"),".")),t.createElement(xe.Row,null,t.createElement(yt.Field,{name:"selectedFields"},({field:{name:A,value:R,onChange:B}})=>t.createElement(t.Fragment,null,t.createElement("label",{htmlFor:A},"Fields to export"),t.createElement(Ku.Z,{onChange:U=>B({target:{name:A,value:U.map(F=>({field:F}))}}),selectSize:"normal",displaySortableListOverlayInPortal:!0,selectedFields:R.map(({field:U})=>U)})))),t.createElement(xe.Row,null,t.createElement(yt.Field,{name:"limit"},({field:{name:A,value:R,onChange:B}})=>t.createElement(t.Fragment,null,t.createElement("label",{htmlFor:A},"Messages limit"),t.createElement(xe.Input,{type:"number",id:A,name:A,onChange:B,min:1,step:1,value:R}),t.createElement(xe.HelpBlock,null,"Messages are loaded in chunks. If a limit is defined, all chunks up to the one where the limit is reached will be retrieved. Which means the total number of delivered messages can be higher than the defined limit.")))),t.createElement($u,{widget:m}));var Ta=e("U1Iufsob");const Yr=(m,_)=>{const A=document.createElement("a");A.download=_,A.href=(0,b.DC)(Ta.Z.MessagesController.jobResults(m,_).url),document.body.appendChild(A),A.click(),document.body.removeChild(A)},ju=(m,_,A,R)=>{const{url:B}=Ta.Z.ExportJobsController.exportSearch(_);return(0,Xr.dc)("POST",(0,b.DC)(B),m,A).then(U=>Yr(U,R)).catch(()=>{Ao.Z.error("Export failed")})},sc=(m,_,A,R,B)=>{const{url:U}=Ta.Z.ExportJobsController.exportSearchType(_,A);return(0,Xr.dc)("POST",(0,b.DC)(U),m,R).then(F=>Yr(F,B)).catch(()=>{Ao.Z.error("Export for widget failed")})},zs=(m,_)=>m.find(A=>A.id===_),ti=(m,_)=>_?zs(m,_):m.size===1?m.first():null,ni=m=>{const A=pt.G.exports("views.export.formats").find(({type:R})=>R===m);if(!A)throw new Error(`Unknown export format "${A}"`);return A},zu=(m,_,A,R,B)=>{if(!A)throw new Error("Exports on a dashboard require a selected widget!");const{mimeType:U,fileExtension:F}=ni(m),V=`${B}.${F}`;return sc(_,R,A.id,U,V)},oi=(m,_,A,R,B,U)=>{if(A.size!==1)throw new Error("Searches must only have a single query!");const{mimeType:F,fileExtension:V}=ni(m),se=`${U}.${V}`;return R?sc(_,B,R.id,F,se):ju(_,B,F,se)},Vu={title:"Export all search results",shouldEnableDownload:(m,_,A,R)=>!R&&!m&&!!A&&A.length>0,shouldAllowWidgetSelection:(m,_,A)=>!m&&!_&&A.size>1,shouldShowWidgetSelection:(m,_,A)=>!m&&!_&&A.size>1,initialWidget:ti,downloadFile:(m,_,A,R,B,U)=>oi(m,_,A,R,B,U)},Hu={title:"Export message table search results",shouldEnableDownload:(m,_,A,R)=>!R&&!!_&&!!A&&A.length>0,shouldAllowWidgetSelection:(m,_)=>!m&&!_,shouldShowWidgetSelection:(m,_)=>!m&&!_,initialWidget:(m,_)=>_?zs(m,_):null,downloadFile:(m,_,A,R,B,U)=>zu(m,_,R,B,U)},ku={createExportStrategy:m=>{switch(m){case Rt.Z.Type.Dashboard:return Hu;case Rt.Z.Type.Search:default:return Vu}}},Qu=(m,_)=>{let A="search-result";return _?A=`${m.getWidgetTitleByWidget(_)}-${A}`:A=`${m.title||`Untitled ${(0,fe.Z)({type:m.type,capitalize:!0})}`}-${A}`,jr.Z.replaceSpaces(A,"-")},Xu=(m,_,A,R,B,U,F,V)=>{const se={execution_state:R,fields_in_order:U.map(Ee=>Ee.field),limit:F,...V},Se=B?A.getSearchTypeByWidgetId(B.id):void 0,Ae=Qu(A,B);return _(m,se,A.search.queries,Se,A.search.id,Ae)},Ju=(0,ot.OrderedSet)([Ke.rg,Ke.N1,Ke.ZA]),Yu=c.default.div` margin-left: 15px; margin-right: 15px; `,qu=m=>m.config.showMessageRow?(0,ot.OrderedSet)(m.config.fields).add(Ke.ZA).toOrderedSet():(0,ot.OrderedSet)(m.config.fields),rc=m=>(m?qu(m):Ju).map(A=>({field:A})).toArray(),ac=({closeModal:m,view:_,directExportWidgetId:A})=>{const R=Zu(),B=(0,L.Z)(),U=(0,P.Z)(),{state:F}=_,{shouldEnableDownload:V,title:se,initialWidget:Se,shouldShowWidgetSelection:Ae,shouldAllowWidgetSelection:Ee,downloadFile:Ze}=ku.createExportStrategy(_.type),je=F.map(qt=>qt.widgets.filter(pn=>pn.isExportable).toList()).toList().flatten(!0),[ke,_t]=(0,t.useState)(!1),Dt=Se(je,A),jt=rc(Dt),Pt=!!A,Yt=({selectedWidget:qt,selectedFields:pn,limit:tn,customSettings:wn,format:on})=>(U(O.A.SEARCH_WIDGET_EXPORT_DOWNLOADED,{app_pathname:(0,b.av)(B.pathname),app_section:"widget"}),_t(!0),Xu(on,Ze,_,R,qt,pn,tn,wn).then(m).finally(()=>_t(!1))),Ht={selectedWidget:Dt,selectedFields:jt,limit:void 0,customSettings:{},format:"csv"};return t.createElement(yt.Formik,{onSubmit:Yt,initialValues:Ht},({values:{selectedWidget:qt,selectedFields:pn},setFieldValue:tn})=>{const wn=Ae(Pt,qt,je),on=Ee(Pt,wn,je),so=V(wn,qt,pn,ke),yn=()=>tn("selectedWidget",void 0),lo=Sn=>tn("selectedFields",Sn);return t.createElement(nc.Z,{showModal:!0,onHide:m},t.createElement(yt.Form,null,t.createElement(xe.Modal.Header,null,t.createElement(xe.Modal.Title,null,se)),t.createElement(xe.Modal.Body,null,t.createElement(Yu,null,wn&&t.createElement(yt.Field,{name:"selectedWidget"},({field:{name:Sn,onChange:ro}})=>{const Io=rr=>(lo(rc(rr)),ro({target:{name:Sn,value:rr}}));return t.createElement(Ca,{selectWidget:Io,view:_,widgets:je.toList()})}),!wn&&t.createElement(oc,{selectedWidget:Dt,view:_}))),t.createElement(xe.Modal.Footer,null,t.createElement(Wu.Z,{leftCol:on&&t.createElement(xe.Button,{bsStyle:"link",onClick:yn,className:"pull-left"},"Select different message table"),onCancel:m,disabledSubmit:!so,isSubmitting:ke,isAsyncSubmit:!0,submitLoadingText:"Downloading...",submitIcon:"cloud-download-alt",submitButtonText:"Start Download"}))))})};ac.propTypes={closeModal:a().func,directExportWidgetId:a().string},ac.defaultProps={closeModal:()=>{},directExportWidgetId:null};const si=ac;var ed=e("STGxpovz");const lc=(m,_)=>_.state.reduce((A,R,B)=>{if(A)return A;const U=R.widgets.find(F=>F.id===m);if(U)return[U,B]},void 0);var el=e("gbXdylj1"),ai=e("/vL3Sz6z");const td=(m,_)=>{const A=m.get("widget");if(!A)return m;const R=A.remove(_);return m.set("widget",R)},li=(m,_,A)=>{const R=A.state.get(_),B=R.widgets.findIndex(Ee=>Ee.id===m),{widgetPositions:U,titles:F}=R,V=td(F,m);delete U[m];const{widgetMapping:se}=R,Se=se.remove(m),Ae=R.toBuilder().widgets(R.widgets.delete(B)).widgetMapping(Se).titles(V).widgetPositions(U).build();return A.toBuilder().state(A.state.set(_,(0,ed.Z)(Ae))).build()},nd=(m,_,A)=>{if(!A)return m;const B=m.get("widget",ot.Map()).set(_,A);return m.set("widget",B)},od=(m,_,A,R,B)=>{const U=A.state.get(_),F=m!=null&&m.id?m:m.toBuilder().newId().build(),V=U.widgets.push(F),{widgetPositions:se}=U,Se=B?(0,ai.r)(ot.Map({[F.id]:B.toBuilder().row(1).col(1).build()}),ot.Map(se)):ot.Map(se),Ae=nd(U.titles,F.id,R),Ee=U.toBuilder().widgets(V).titles(Ae).widgetPositions(Se).build();return A.toBuilder().state(A.state.set(_,Ee)).build()},ic=(m,_,A)=>A.state.get(_).titles.getIn(["widget",m]),rd=(m,_,A,R=!1)=>{if(A.type!==Rt.Z.Type.Dashboard)throw new Error(`Unexpected type ${A.type} expected ${Rt.Z.Type.Dashboard}`);const B=lc(m,A);if(B){const[U,F]=B,V=ic(m,F,A),{widgetPositions:se}=A.state.get(F),Se=se[m],Ae=R?A:li(m,F,A),Ee=R?U.toBuilder().newId().build():U;return(0,el.Z)(od(Ee,_,Ae,V,Se))}};var sr=e("AEcypqf3"),qr=e("iSSis/Yq"),cc=e("/coHI+Jz");const ko=(m,_,A)=>m?(0,ai.r)(ot.Map({[A.id]:m.toBuilder().row(1).col(1).build()}),ot.Map(_)):ot.Map(_),ad=(m,_,A)=>{if(!A)return m;const B=m.get($r.Z.Widget,(0,ot.Map)()).set(_.id,A);return m.set($r.Z.Widget,B)},op=(m,_,A,R)=>{const B=_.search.queries.first().id,U=_.state.get(B),F=U.widgets.push(m),{widgetPositions:V}=U,se=ko(A,V,m),Se=U.titles,Ae=ad(Se,m,R),Ee=U.toBuilder().widgets(F).titles(Ae).widgetPositions(se).build();return _.toBuilder().state(_.state.set(B,Ee)).build()},ii=(m,_,A)=>{if(A.type!==Rt.Z.Type.Dashboard)return;const R=pt.G.exports("views.hooks.copyWidgetToDashboard"),B=(0,ot.Map)(_.search.queries.map(F=>[F.id,F])),U=lc(m,_);if(U){const[F,V]=U,{timerange:se,query:Se,filter:Ae=(0,ot.Map)(),filters:Ee}=B.get(V),{widgetPositions:Ze}=_.state.get(V),je=Ze[m],ke=_.state.get(V).titles.get($r.Z.Widget).get(m),_t=(Ae?Ae.get("filters",ot.List.of()):ot.List.of()).filter(Pt=>ot.Map.isMap(Pt)&&Pt.get("type")==="stream").map(Pt=>Pt.get("id")).toList().toArray(),Dt=F.toBuilder().newId().timerange(se).query(Se).streams(_t).filters(Ee).build(),jt=(0,el.Z)(op(Dt,A,je,ke));return R.reduce((Pt,Yt)=>Yt(_,Pt),jt)}};var uc=e("MXZnZFI9"),dc=e("4zkAw1kt"),ci=e("g2NQZb9A"),mc=e("Y/YOqMWf"),yr=e("/7OuCFNo"),pc=e("hfAjrXHN");const ui=()=>(0,Fn.Z)("views.widgets.actions"),ld=({onSelect:m,widget:_})=>{const A=(0,t.useContext)(Ie.Z),R=ui(),B=(0,sn.Z)(),U=(0,P.Z)(),{pathname:F}=(0,L.Z)(),V=(0,t.useMemo)(()=>R.filter(({isHidden:se=()=>!1})=>!se(_)).map(({title:se,action:Se,type:Ae,disabled:Ee=()=>!1})=>{const Ze=(je,ke)=>{U(O.A.SEARCH_WIDGET_ACTION.SEARCH_WIDGET_EXTRA_ACTION,{app_pathname:(0,b.av)(F),app_section:"search-widget",app_action_value:Ae}),B(Se(_,{widgetFocusContext:A})),m(je,ke)};return t.createElement(xe.MenuItem,{key:`${Ae}-${_.id}`,disabled:Ee(),onSelect:Ze},se(_))}),[B,m,F,R,U,_,A]);return V.length>0?t.createElement(t.Fragment,null,t.createElement(xe.MenuItem,{divider:!0}),V):null};var id=e("+gqrR506");const tl=({onCancel:m,onSubmit:_,submitButtonText:A,submitLoadingText:R,activeDashboardId:B})=>{const[U,F]=(0,t.useState)(!1),[V,se]=(0,t.useState)(null),Se=(0,t.useRef)();(0,t.useEffect)(()=>(Se.current=!0,()=>{Se.current=!1}),[]);const[Ae,Ee]=(0,t.useState)({page:1,pageSize:5,query:"",sort:{attributeId:"title",direction:"asc"}}),{data:Ze,isInitialLoading:je}=(0,id.Z)(Ae);(0,t.useEffect)(()=>{se(null)},[Ae]);const ke=(0,t.useCallback)(Pt=>Ee(Yt=>({...Yt,query:Pt,page:1})),[]),_t=(0,t.useCallback)(()=>ke(""),[ke]),Dt=(0,t.useCallback)((Pt,Yt)=>Ee(Ht=>({...Ht,page:Pt,pageSize:Yt})),[]),jt=()=>{F(!0),_(V).then(()=>{Se.current&&F(!1)})};return t.createElement(xe.Modal,{show:!0},t.createElement(xe.Modal.Body,null,je&&t.createElement(H.$j,null),!je&&t.createElement(H.l9,{onChange:Dt,activePage:Ae.page,totalItems:Ze.pagination.total,pageSize:Ae.pageSize,pageSizes:[5,10,15],useQueryParameter:!1},t.createElement("div",{style:{marginBottom:"5px"}},t.createElement(H.UI,{onSearch:ke,onReset:_t})),Ze.list.length?t.createElement(xe.ListGroup,null,Ze.list.map(Pt=>{const Yt=B===Pt.id;return t.createElement(xe.ListGroupItem,{active:V===Pt.id,onClick:Yt?void 0:()=>se(Pt.id),header:Pt.title,disabled:Yt,key:Pt.id},Pt.summary)})):t.createElement("span",null,"No dashboards found"))),t.createElement(xe.Modal.Footer,null,t.createElement(H.os,{submitButtonText:A,submitLoadingText:R,isAsyncSubmit:!0,isSubmitting:U,disabledSubmit:!V,submitButtonType:"button",onSubmit:jt,onCancel:m})))};tl.defaultProps={activeDashboardId:void 0};const gc=tl;var di=e("gTexEe+8"),ea=e("yDuYCNwc"),ta=e("pzHcYe8v");const Ec=(0,Oe.P1)(et.vz,m=>m.map(_=>_.id).toOrderedSet()),fc=()=>(0,nt.Z)(Ec),cd=(m,_)=>_.map(A=>{const R=(0,ta.Z)(m,A)||"Unknown Page title";return{id:A,name:R}}),hc=({view:m,onCancel:_,onSubmit:A,widgetId:R})=>{const[B,U]=(0,t.useState)(null),[F,V]=(0,t.useState)(!1),se=(0,T.Z)(),Se=fc(),Ae=(0,t.useCallback)(_t=>V(_t.target.checked),[V]),Ee=(0,t.useCallback)(()=>A(R,B,F),[A,R,B,F]),Ze=cd(m,Se.toArray()).filter(({id:_t})=>_t!==se),je=Ze.map(({id:_t,name:Dt})=>t.createElement(xe.ListGroupItem,{onClick:()=>U(_t),active:_t===B,key:_t},Dt)),ke=Ze&&Ze.length>0?t.createElement(xe.ListGroup,null,je):t.createElement("span",null,"No pages found");return t.createElement(di.Z,{show:!0,onCancel:_,submitButtonDisabled:!B,submitButtonText:`${F?"Copy":"Move"} widget`,onSubmitForm:Ee,title:"Choose Target Page"},ke,t.createElement(ea.Z,{type:"checkbox",id:"keepCopy",name:"keepCopy",label:"Keep Copy on this Page",onChange:Ae,help:"When 'Keep Copy on the Page' is enabled, the widget will be copied and not moved to another page",checked:F}))},vc=m=>{m.stopPropagation(),m.preventDefault()},yc=({children:m})=>t.createElement("span",{role:"presentation",onClick:vc,onMouseDown:vc},m),nl=({children:m,onClick:_,title:A})=>{const R=U=>{U.preventDefault(),U.stopPropagation(),_(U)},B=U=>{U.keyCode===32&&(U.preventDefault(),U.stopPropagation(),_(U))};return t.createElement("span",{onClick:R,onKeyDown:B,role:"presentation",title:A},m)};nl.propTypes={children:a().node.isRequired,onClick:a().func},nl.defaultProps={onClick:()=>{},bsRole:void 0};const mi=({children:m,style:_})=>t.createElement(t.Fragment,null,t.Children.map(m,A=>t.cloneElement(A,{style:{..._,...A.props.style}})));mi.defaultProps={style:{}};class pi extends t.Component{constructor(_){super(_),this._onToggle=A=>{A.preventDefault(),A.stopPropagation(),this.setState(({show:R})=>({show:!R}))},this.state={show:!1}}render(){const{children:_,container:A,element:R,title:B}=this.props,{show:U}=this.state;return t.createElement(yc,null,t.createElement(nl,{bsRole:"toggle",onClick:this._onToggle,title:B},t.createElement("span",{ref:F=>{this.target=F}},R)),t.createElement(ma.aV,{show:U,container:A,placement:"bottom",shouldUpdatePosition:!0,rootClose:!0,onHide:this._onToggle,target:()=>this.target},t.createElement(mi,null,t.createElement(H.h_,{show:U,onMenuItemSelect:this._onToggle},t.createElement(xe.MenuItem,{header:!0},"Actions"),_))))}}pi.defaultProps={container:void 0,title:"Actions"},pi.propTypes={children:a().node.isRequired,container:a().oneOfType([a().node,a().func]),element:a().node.isRequired};const _c=pi,dd=({children:m})=>{const _=t.createElement(H.hU,{"data-testid":"widgetActionDropDown",name:"chevron-down",title:"Open actions dropdown"});return t.createElement(_c,{element:_},m)},gi=({onStretch:m,position:_,widgetId:A,widgetType:R})=>{const B=(0,P.Z)(),{pathname:U}=(0,L.Z)(),F=(0,t.useCallback)(()=>{const{col:Ee,row:Ze,height:je,width:ke}=_,{defaultWidth:_t}=(0,Es.FZ)(R);m({id:A,col:Ee,row:Ze,height:je,width:ke===1/0?_t:1/0}),B(O.A.SEARCH_WIDGET_ACTION.SEARCH_WIDGET_HORIZONTAL_STRETCH,{app_pathname:(0,b.av)(U),app_section:"search-widget",app_action_value:"widget-stretch-button"})},[m,U,_,B,A,R]);if(!_)return t.createElement(ir.Z,null);const{width:V}=_,se=V===1/0,Se=se?"compress":"arrows-alt-h",Ae=se?"Compress width":"Stretch width";return t.createElement(H.hU,{onClick:F,name:Se,title:Ae})};gi.propTypes={widgetId:a().string.isRequired,widgetType:a().string.isRequired,position:a().shape(vs.Ly).isRequired,onStretch:a().func.isRequired};const md=gi;var ol=e("wfOnu0E0");const Cc=c.default.div` > *:not(:last-child) { margin-right: 2px; } `,pd=async(m,_,A,R,B)=>{if(!R)return;const U=await qr.T.get(R),F=Rt.Z.fromJSON(U),V=await(0,mc.Z)(U.search_id).then(Se=>cc.Z.fromJSON(Se)),se=ii(A,m,F.toBuilder().search(V).build());if(se&&se.search){const Se=await(0,ci.Z)(se.search),Ae=se.toBuilder().search(Se).build();await qr.T.update(Ae),(0,sr.o2)(B,Ae.id)}_(!1)},gd=async(m,_,A,R,B,U)=>{if(!B)return;const F=rd(R,B,_,U);if(F){const V=await(0,ci.Z)(F.search),se=F.toBuilder().search(V).build();await m((0,We.NK)(se,!0)),A(!1),await m((0,We.xM)(B))}},Ei=async(m,_,A)=>window.confirm(`Are you sure you want to remove the widget "${A}"?`),Ed=(m,_,A)=>async R=>{const B=pt.G.exports("views.hooks.confirmDeletingWidget");return await(0,uc.Z)([...B,Ei],m,_,A)===!0?R((0,Ro.tQ)(m.id)):Promise.resolve()},fd=(m,_,A)=>R=>R((0,Ro.W4)(m,A)).then(()=>_()),Tc=({isFocused:m,onPositionsChange:_,position:A,title:R,toggleEdit:B})=>{const U=(0,t.useContext)(mo.Z),F=(0,To.Z)(),{query:V,timerange:se,streams:Se}=(0,t.useContext)(dc.Z),{setWidgetFocusing:Ae,unsetWidgetFocusing:Ee}=(0,t.useContext)(Ie.Z),[Ze,je]=(0,t.useState)(!1),[ke,_t]=(0,t.useState)(!1),[Dt,jt]=(0,t.useState)(!1),Pt=(0,sn.Z)(),Yt=(0,yr.Z)(),{pathname:Ht}=(0,L.Z)(),qt=(0,P.Z)(),{parameters:pn,parameterBindings:tn}=Dr(),wn=(0,t.useCallback)(()=>(qt(O.A.SEARCH_WIDGET_ACTION.DUPLICATE,{app_pathname:(0,b.av)(Ht),app_section:"search-widget",app_action_value:"widget-duplicate-button"}),Pt(fd(U.id,Ee,R))),[qt,Ht,Pt,U.id,Ee,R]),on=(0,t.useCallback)((Sn,ro)=>(qt(O.A.SEARCH_WIDGET_ACTION.COPY_TO_DASHBOARD,{app_pathname:(0,b.av)(Ht),app_section:"search-widget",app_action_value:"widget-copy-to-dashboard-button"}),pd(F,je,Sn,ro,Yt)),[Yt,Ht,qt,F]),so=(0,t.useCallback)((Sn,ro,Io)=>(qt(O.A.SEARCH_WIDGET_ACTION.MOVE,{app_pathname:(0,b.av)(Ht),app_section:"search-widget",app_action_value:"widget-move-button"}),gd(Pt,F,jt,Sn,ro,Io)),[Pt,Ht,qt,F]),yn=(0,t.useCallback)(()=>(qt(O.A.SEARCH_WIDGET_ACTION.DELETED,{app_pathname:(0,b.av)(Ht),app_section:"search-widget",app_action_value:"widget-delete-button"}),Pt(Ed(U,F,R))),[Pt,Ht,qt,R,F,U]),lo=(0,t.useCallback)(()=>(qt(O.A.SEARCH_WIDGET_ACTION.FOCUSED,{app_pathname:(0,b.av)(Ht),app_section:"search-widget",app_action_value:"widget-focus-button"}),Ae(U.id)),[Ht,qt,Ae,U.id]);return t.createElement(Cc,null,t.createElement(ol.Z,null,t.createElement(Bo,null,t.createElement(pc.Z,{queryString:V.query_string,timerange:se,streams:Se,parameterBindings:tn,parameters:pn})),m&&t.createElement(H.hU,{name:"compress-arrows-alt",title:"Un-focus widget",onClick:Ee}),!m&&t.createElement(t.Fragment,null,t.createElement(md,{widgetId:U.id,widgetType:U.type,onStretch:_,position:A}),t.createElement(H.hU,{name:"expand-arrows-alt",title:"Focus this widget",onClick:lo})),t.createElement(H.hU,{name:"edit",title:"Edit",onClick:B}),t.createElement(dd,null,t.createElement(xe.MenuItem,{onSelect:wn},"Duplicate"),t.createElement(ks.Z,null,t.createElement(xe.MenuItem,{onSelect:()=>je(!0)},"Copy to Dashboard")),U.isExportable&&t.createElement(xe.MenuItem,{onSelect:()=>_t(!0)},"Export"),t.createElement(Bo,null,t.createElement(xe.MenuItem,{onSelect:()=>jt(!0)},"Move to Page")),t.createElement(ld,{widget:U,onSelect:()=>{}}),t.createElement(xe.MenuItem,{divider:!0}),t.createElement(xe.MenuItem,{onSelect:yn},"Delete")),Ze&&t.createElement(gc,{onSubmit:Sn=>on(U.id,Sn),onCancel:()=>je(!1),submitLoadingText:"Copying widget...",submitButtonText:"Copy widget"}),ke&&t.createElement(si,{view:F,directExportWidgetId:U.id,closeModal:()=>_t(!1)}),Dt&&t.createElement(hc,{view:F,widgetId:U.id,onCancel:()=>jt(!1),onSubmit:so})))},dp=m=>(0,Es.FZ)(m).visualizationComponent,hd=m=>(0,Es.FZ)(m).editComponent,Sc=m=>(0,Es.FZ)(m).hasEditSubmitButton,vd=()=>{const m=(0,t.useContext)(bn.Z),_=(0,T.Z)();return(0,t.useMemo)(()=>m.queryFields.get(_,m.all),[m.all,m.queryFields,_])},fi=c.default.div` width: 100%; display: flex; justify-content: flex-end; `,yd=({title:m,id:_,widget:A,fields:R,queryId:B,editing:U,setLoadingState:F,onToggleEdit:V,onWidgetConfigChange:se})=>{const Se=(0,t.useMemo)(()=>dp(A.type),[A.type]),{error:Ae,widgetData:Ee}=br(_);if(Ae&&Ae.length>0)return t.createElement(Ya.Z,{errors:Ae});if(Ee){const{config:Ze,filter:je}=A;return t.createElement(Se,{config:Ze,data:Ee,editing:U,fields:R,filter:je,queryId:B,onConfigChange:se,setLoadingState:F,title:m,toggleEdit:V,type:A.type,id:_})}return t.createElement(Ru,null)},_d=({children:m,config:_,editing:A,fields:R,id:B,onToggleEdit:U,onCancelEdit:F,onWidgetConfigChange:V,type:se})=>{const Se=(0,t.useMemo)(()=>hd(se),[se]),Ae=Sc(se);return A?t.createElement(Ou,{onSubmit:U,onCancel:F,displaySubmitActions:!Ae},t.createElement(Se,{config:_,fields:R,editing:A,id:B,type:se,onSubmit:U,onCancel:F,onChange:V},m)):m},hi=(m,_)=>async(A,R)=>{const B=(0,et.cE)(R());return A((0,Tl.T)(B,"widget",m,_))},S=({id:m,editing:_,widget:A,title:R,position:B,onPositionsChange:U})=>{const F=vd(),[V,se]=(0,t.useState)(!1),[Se,Ae]=(0,t.useState)(_?A:void 0),{focusedWidget:Ee,setWidgetEditing:Ze,unsetWidgetEditing:je}=(0,t.useContext)(Ie.Z),ke=(0,sn.Z)(),_t=(0,P.Z)(),{pathname:Dt}=(0,L.Z)(),jt=(0,t.useCallback)(()=>{_t(O.A.SEARCH_WIDGET_ACTION.WIDGET_EDIT_TOGGLED,{app_pathname:(0,b.av)(Dt),app_section:"search-widget",app_action_value:"widget-edit-button"}),_?(je(),Ae(void 0)):(So.e.disable(),Ze(A.id),Ae(A))},[_,Dt,_t,Ze,je,A]),Pt=(0,t.useCallback)(()=>{_t(O.A.SEARCH_WIDGET_ACTION.WIDGET_EDIT_CANCEL_CLICKED,{app_pathname:(0,b.av)(Dt),app_section:"search-widget",app_action_value:"widget-edit-cancel-button"}),Se&&ke((0,Ro.QB)(m,Se)),jt()},[ke,m,Se,jt,Dt,_t]),Yt=(0,t.useCallback)(wn=>ke(hi(m,wn)),[ke,m]),Ht=(0,t.useCallback)(async wn=>(_t(O.A.SEARCH_WIDGET_ACTION.WIDGET_CONFIG_UPDATED,{app_pathname:(0,b.av)(Dt),app_section:"search-widget",app_action_value:"widget-edit-update-button"}),ke((0,Ro.YS)(m,wn)).then(()=>{})),[ke,m,Dt,_t]),qt=(0,T.Z)(),{config:pn}=A,tn=(Ee==null?void 0:Ee.id)===m;return t.createElement(Uu,{id:m},t.createElement(Al,{widgetId:m},t.createElement(Qe.Z.Consumer,null,wn=>t.createElement(qs.Z,{title:R,hideDragHandle:!wn||tn,loading:V,onRename:Yt},_?null:t.createElement(Tc,{isFocused:tn,toggleEdit:jt,title:R,position:B,onPositionsChange:U}))),t.createElement(_d,{onToggleEdit:jt,onCancelEdit:Pt,onWidgetConfigChange:Ht,config:pn,editing:_,fields:F,id:m,type:A.type},t.createElement(wu,null,t.createElement(yd,{id:m,editing:_,queryId:qt,widget:A,fields:F,title:R,setLoadingState:se,onToggleEdit:jt,onWidgetConfigChange:Ht}))),t.createElement(fi,null,t.createElement(Bo,null,!_&&t.createElement(Cl,{widget:A,activeQuery:qt,widgetId:m})))))};S.propTypes={editing:a().bool,id:a().string.isRequired,onPositionsChange:a().func.isRequired,title:a().string.isRequired,widget:a().instanceOf(Da.Z).isRequired},S.defaultProps={editing:!1};const X=S;var qe=e("m7J9z16Z"),Bt=e("I4XORk+Y");const Wt=(m,_,A)=>{var R;if((0,Ce.Z)()===Rt.Z.Type.Dashboard){const{streams:U,timerange:F,query:V}=m,se=(R=_==null?void 0:_.query)!=null&&R.query_string?(0,Bt._5)([V==null?void 0:V.query_string,_.query.query_string]):V==null?void 0:V.query_string;return{streams:U,timerange:(_!=null&&_.timerange?_.timerange:F)||Ke.nn,query:(0,as.Eg)(se||"")}}if(A){const U=(0,as.Fp)(A.filter).toJS(),{timerange:F,query:V}=A;return{streams:U,timerange:F,query:V}}},go=({children:m,widget:_})=>{const A=(0,qe.Z)(),R=mt(),B=Wt(_,R,A);return B?t.createElement(dc.Z.Provider,{value:B},m):m};var No=e("9kZNWwre");const xr=({children:m})=>{const{timerange:_,streams:A}=(0,t.useContext)(mo.Z),R=(0,qe.Z)(),{data:B}=(0,No.Z)(A,_),U=(0,t.useMemo)(()=>{const F=ot.List(B);return{all:F,queryFields:ot.Map({[R.id]:F})}},[B,R.id]);return t.createElement(bn.Z.Provider,{value:U},m)},Sa=m=>{var _;const A=hl();return(_=A==null?void 0:A.titles)==null?void 0:_.getIn([$r.Z.Widget,m.id],(0,Zi.Z)(m))},yi=({editing:m,onPositionsChange:_=()=>{},position:A,widgetId:R})=>{const B=Ki(R),U=(0,Ce.Z)(),F=Sa(B),V=(0,t.useMemo)(()=>({widget:B}),[B]),se=U===Rt.Z.Type.Dashboard?xr:t.Fragment;return t.createElement(go,{widget:B},t.createElement(mo.Z.Provider,{value:B},t.createElement(Kr.v.Provider,{value:V},t.createElement(fl,null,t.createElement(se,null,t.createElement(X,{editing:m,id:B.id,onPositionsChange:_,position:A,title:F,widget:B}))))))};yi.propTypes={editing:a().bool.isRequired,onPositionsChange:a().func,position:a().shape(vs.Ly).isRequired},yi.defaultProps={onPositionsChange:()=>{}};const mp=yi,Cd={xxl:12,xl:12,lg:12,md:12,sm:12,xs:12},Td=(0,c.default)(bt.Z)(({theme:m})=>(0,c.css)` color: ${m.colors.global.textDefault}; margin: 0; width: 100%; height: 100%; `),pp=(0,c.default)(ia.Z)(({$hasFocusedWidget:m})=>(0,c.css)` height: ${m?"100% !important":"100%"}; max-height: ${m?"100%":"auto"}; overflow: ${m?"hidden":"visible"}; transition: none; `),gp=m=>{const _=(0,Es.FZ)(m);return new Ar.Z(1,1,_.defaultHeight,_.defaultWidth)},Sd=({onPositionsChange:m,positions:_,widgetId:A,focusedWidget:R})=>{const B=(R==null?void 0:R.id)===A&&(R==null?void 0:R.editing),U=_[A];return t.createElement(mp,{editing:B,onPositionsChange:m,position:U,widgetId:A})},Ep=(m,_)=>Object.fromEntries(m.toArray().map(({id:A,type:R})=>{var B;return[A,(B=_[A])!=null?B:gp(R)]})),Ad=(0,Oe.P1)(et.RM,m=>Object.fromEntries(m.toArray().flatMap(({widgetPositions:_})=>Object.entries(_)))),_i=()=>{const m=(0,nt.Z)(Ad),_=qa(),A=(0,t.useMemo)(()=>Ep(_,m),[_,m]);return[_,A]},Ci=({children:m,locked:_,onPositionsChange:A,onSyncLayout:R,positions:B,width:U})=>{const{focusedWidget:F}=(0,t.useContext)(Ie.Z);return t.createElement(pp,{$hasFocusedWidget:!!(F!=null&&F.id),columns:Cd,isResizable:!(F!=null&&F.id),locked:_,positions:B,measureBeforeMount:!0,onPositionsChange:A,onSyncLayout:R,width:U,draggableHandle:".widget-drag-handle"},m)};Ci.defaultProps={onSyncLayout:void 0};const Ti=12,Si=({col:m,row:_,height:A,width:R})=>new Ar.Z(m,_,A,R>=Ti?1/0:R),Pd=(m,_)=>{const{id:A}=_,R=Si(_);return m((0,Ro.OT)(A,R))},Ac=(m,_,A)=>{const R=Object.fromEntries(_.map(B=>[B.id,Si(B)]));return A((0,Pn.Z)()),m((0,Ro.lg)(R))},bd=(m,_)=>(A,R)=>{const B=(0,et.$o)(R()),U=Object.fromEntries(_.map(F=>[F.id,Si(F)]));(0,dr.Z)(m,U)||A((0,Ro.lg)(U)).then(()=>A((0,We.hU)(B)))},Pc=(m,_)=>{const A=Ko(m.map(U=>_[U.id])),R={..._};return[A.map(U=>{const F=`gap-${(0,Pn.Z)()}`,{col:V,row:se,height:Se,width:Ae}=U,Ee=Ar.Z.builder().col(V).row(se).height(Se).width(Ae).build();return R[F]=Ee,t.createElement(Qs,{key:F,position:Ee,component:Zr})}),R]},sl=()=>{const m=(0,t.useContext)(Qe.Z),{focusedWidget:_}=(0,t.useContext)(Ie.Z),[A,R]=(0,t.useState)(void 0),B=(0,t.useRef)(),U=(0,sn.Z)(),[F,V]=_i(),se=(0,t.useCallback)(je=>(B.current=je,Ac(U,je,R)),[U]),Se=(0,t.useCallback)(je=>Pd(U,je),[U]),Ae=(0,t.useCallback)(je=>{(0,dr.Z)(B.current,je)||U(bd(V,je))},[U,V]),[Ee,Ze]=(0,t.useMemo)(()=>{const je=F.toArray().filter(ke=>!!V[ke.id]).map(({id:ke})=>t.createElement(Fr,{key:ke,className:"widgetFrame","data-widget-id":ke,isFocused:(_==null?void 0:_.id)===ke&&(_==null?void 0:_.focusing)},t.createElement(Sd,{positions:V,widgetId:ke,focusedWidget:_,onPositionsChange:Se})));if(m){const[ke,_t]=Pc(F.toArray(),V);return[[...je,...ke],_t]}return[je,V]},[_,m,A,V,F]);return t.createElement(Td,null,({width:je})=>t.createElement(Ci,{locked:!m,positions:Ze,onPositionsChange:se,onSyncLayout:Ae,width:je},Ee))};sl.displayName="WidgetGrid";const bc=sl,Dd=(0,c.default)(xe.Jumbotron)(({theme:m})=>(0,c.css)` .container-fluid & { border: 1px solid ${m.colors.gray[80]}; border-top-left-radius: 0; border-top-right-radius: 0; margin-bottom: 0; } `),Od=()=>t.createElement(Dd,null,t.createElement("h2",null,t.createElement(Bo,null,"This dashboard has no widgets yet"),t.createElement(ks.Z,null,"There are no widgets defined to visualize the search result")),t.createElement("br",null),t.createElement("p",null,'Create a new widget by selecting a widget type in the left sidebar section "Create".',t.createElement("br",null)),t.createElement("p",null,"A few tips for creating searches and dashboards"),t.createElement("ul",null,t.createElement("li",null,t.createElement("p",null,"1. Start with a ",t.createElement("b",null,"question")," you want to answer. Define the problem you want to solve.")),t.createElement("li",null,t.createElement("p",null,"2. ",t.createElement("b",null,"Limit")," the data to only the data points you want to see.")),t.createElement("li",null,t.createElement("p",null,"3. ",t.createElement("b",null,"Visualize")," the data. Does it answer your question?")),t.createElement(Bo,null,t.createElement("li",null,t.createElement("p",null,"4. ",t.createElement("b",null,"Share")," the dashboard with your colleagues. Prepare it for ",t.createElement("b",null,"reuse")," by using parameters (contained in ",t.createElement("a",{href:"https://www.graylog.org/graylog-enterprise-edition",target:"_blank",rel:"noopener noreferrer"},"Graylog Enterprise"),").")))),t.createElement("p",null,"You can also have a look at the ",t.createElement(Nr.Z,{page:Ps.Z.PAGES.DASHBOARDS,text:"documentation"}),", to learn more about the widget creation.")),Rd=()=>{const m=qa();return(m==null?void 0:m.size)>0},fp=()=>Rd()?t.createElement(bc,null):t.createElement(Od,null),Id=t.memo(fp);Id.displayName="Query";const hp=Id;var vp=e("k7aCBAx/");const yp=()=>(0,nt.Z)(m=>m.searchExecution.isLoading),_p=(0,c.default)(xe.Row)(({$hasFocusedWidget:m})=>(0,c.css)` height: ${m?"100%":"auto"}; overflow: ${m?"auto":"visible"}; position: relative; `),Cp=(0,c.default)(xe.Col)` height: 100%; `,Tp=()=>yp()&&t.createElement(vp.Z,{text:"Updating search results..."}),Dc=t.memo(()=>{const m=(0,t.useContext)(bn.Z),{focusedWidget:_}=(0,t.useContext)(Ie.Z),A=!!(_!=null&&_.id);return m?t.createElement(_p,{$hasFocusedWidget:A},t.createElement(Cp,null,t.createElement(hp,null),t.createElement(Tp,null))):t.createElement(ir.Z,null)});Dc.displayName="SearchResult";const Sp=Dc,xd=()=>{const m=(0,Fn.Z)("views.elements.header");return t.createElement(t.Fragment,null,m.map((_,A)=>t.createElement(_,{key:A})))},Pp=()=>{const m=(0,Fn.Z)("views.elements.queryBar");return t.createElement(t.Fragment,null,m.map((_,A)=>t.createElement(_,{key:A})))};var bp=e("t7jeigEY");const Oc=()=>(0,nt.Z)(et.$o),Ld=()=>Oc()?t.createElement(bp.Z,{question:"Are you sure you want to leave the page? Any unsaved changes will be lost."}):null,Bd={dashboardPage:void 0,setDashboardPage:()=>{},unsetDashboardPage:()=>{}},Dp=t.createContext(Bd),Ai=(0,u.ri)("contexts.DashboardPage",()=>Dp),Op=async()=>window.confirm("Do you really want to delete this dashboard page?"),Ud=async(m,_,A)=>{const R=A.map(U=>U.toArray()).toObject(),B=pt.G.exports("views.hooks.confirmDeletingDashboardPage");return(0,uc.Z)([...B,Op],m,_,R)},Pi=(0,Oe.P1)(et.RM,m=>m.map(_=>_.titles.getIn(["tab","title"])).filter(_=>_!==void 0).toMap()),gf=()=>(0,nt.Z)(Pi),Rp=(0,Oe.P1)(et.RM,m=>m.map(_=>_.widgets.map(A=>A.id).toList()).toMap()),Rc=()=>(0,nt.Z)(Rp);var Mp=e("GaFHk8Qk"),wd=e.n(Mp);class xp extends t.Component{constructor(_){super(_),this.open=A=>{this.setState({titleDraft:A,showModal:!0})},this.close=()=>{this.setState({showModal:!1})},this._onDraftSave=()=>{const{titleDraft:A}=this.state,{onTitleChange:R}=this.props;R(A),this.close()},this._onDraftChange=A=>{this.setState({titleDraft:A.target.value})},this.state={showModal:!1,titleDraft:""}}render(){const{titleDraft:_,showModal:A}=this.state;return t.createElement(di.Z,{show:A,title:"Editing dashboard page title",onSubmitForm:this._onDraftSave,onCancel:this.close,submitButtonText:"Update title",bsSize:"large"},t.createElement(ea.Z,{autoFocus:!0,help:"Enter a helpful dashboard page title. It has a maximum length of 40 characters.",id:"title",label:"Title",name:"title",onChange:this._onDraftChange,maxLength:40,required:!0,type:"text",value:_}))}}xp.propTypes={onTitleChange:a().func.isRequired};const Lp=xp;var Bp=e("agK8h0L2");const Wd=({children:m})=>t.createElement(_c,{element:t.createElement(H.JO,{name:"chevron-down","data-testid":"query-action-dropdown",title:"Page Actions"})},m);Wd.propTypes={children:a().node.isRequired};const Ic=Wd,Up=c.default.span(({$active:m})=>(0,c.css)` padding-right: ${m?"6px":"0"}; `),Nd=({active:m,allowsClosing:_,id:A,onRemove:R,openEditModal:B,openCopyToDashboardModal:U,title:F})=>{const[V,se]=(0,t.useState)(F),{setDashboardPage:Se}=(0,t.useContext)(Ai),Ae=(0,sn.Z)();(0,t.useEffect)(()=>{se(F)},[F]);const Ee=(0,t.useCallback)(()=>Ae((0,We.xb)(A)).then(Ze=>Se(Ze)),[Ae,A,Se]);return t.createElement(t.Fragment,null,t.createElement(Up,{"aria-label":V,$active:m,"data-testid":"query-tab","data-active-query-tab":m},V),m&&t.createElement(Ic,null,t.createElement(xe.MenuItem,{onSelect:()=>B(V)},"Edit Title"),t.createElement(xe.MenuItem,{onSelect:Ee},"Duplicate"),t.createElement(xe.MenuItem,{onSelect:()=>U(!0)},"Copy to Dashboard"),t.createElement(xe.MenuItem,{divider:!0}),t.createElement(xe.MenuItem,{onSelect:R,disabled:!_},"Delete")))};Nd.propTypes={allowsClosing:a().bool,onRemove:a().func.isRequired,title:a().string.isRequired,openEditModal:a().func.isRequired},Nd.defaultProps={allowsClosing:!0};const wp=Nd;var Zd=e("PVMUg5WH"),Wp=e("5s1wXXQQ"),Np=e("2z9Zbpb8");const Zp=c.default.div` display: flex; justify-content: space-between; flex: 1; overflow: hidden; `,Fp=({item:{id:m,title:_},onRemove:A,onUpdateTitle:R,disableDelete:B})=>t.createElement(Zp,null,t.createElement(Wp.Z,{key:_,disabled:!R,value:_,onChange:U=>R(m,U)}),t.createElement("div",null,t.createElement(H.hU,{title:`Remove page ${_}`,name:"trash-alt",onClick:()=>A(m),disabled:B}))),Kp=({show:m,setShow:_,queriesList:A,activeQueryId:R,dashboardId:B})=>{const{setDashboardPage:U}=(0,t.useContext)(Ai),F=Rc(),[V,se]=(0,t.useState)(A),Se=V.size<=1,Ae=(0,sn.Z)(),Ee=(0,P.Z)(),Ze=(0,t.useCallback)(()=>{const Pt=!V.find(({id:Yt})=>Yt===R);if(Ee(O.A.DASHBOARD_ACTION.DASHBOARD_PAGE_CONFIGURATION_UPDATED,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-page-configuration"}),Pt){const Yt=A.map(({id:tn})=>tn).toList(),Ht=V.map(({id:tn})=>tn).toArray(),qt=Yt.filter(tn=>!Ht.includes(tn)).toList(),pn=(0,Np.Z)(Yt,R,qt);U(pn)}Ae((0,We.G3)(V.map(({id:Yt})=>Yt).toOrderedSet())).then(()=>{const Yt=V.map(({id:Ht,title:qt})=>{const pn=ot.Map({title:qt}),tn=ot.Map({[$r.Z.Tab]:pn});return{queryId:Ht,titlesMap:tn}}).toArray();Ae((0,We.oq)(Yt)),_(!1)})},[V,Ee,Ae,R,A,U,_]),je=(0,t.useCallback)(()=>{Ee(O.A.DASHBOARD_ACTION.DASHBOARD_PAGE_CONFIGURATION_CANCELED,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-page-configuration"}),_(!1)},[Ee,_]),ke=(0,t.useCallback)(Pt=>{Ee(O.A.DASHBOARD_ACTION.DASHBOARD_PAGE_CONFIGURATION_SORTING_UPDATED,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-page-configuration-sorting"}),se(ot.OrderedSet(Pt))},[Ee,se]),_t=(0,t.useCallback)((Pt,Yt)=>{se(Ht=>Ht.map(qt=>qt.id===Pt?{id:Pt,title:Yt}:qt).toOrderedSet())},[]),Dt=(0,t.useCallback)(async Pt=>(Se||await Ud(B,R,F)&&(Ee(O.A.DASHBOARD_ACTION.DASHBOARD_PAGE_CONFIGURATION_PAGE_REMOVED,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-page-configuration-remove-page"}),se(Yt=>Yt.filter(Ht=>Ht.id!==Pt).toOrderedSet())),Promise.resolve()),[R,B,Se,Ee,F]),jt=(0,t.useCallback)(({item:Pt})=>t.createElement(Fp,{item:Pt,onUpdateTitle:_t,onRemove:Dt,disableDelete:Se}),[Se,Dt,_t]);return t.createElement(Zd.Z,{showModal:m,title:"Update Dashboard Pages Configuration",onConfirm:Ze,onCancel:je,confirmButtonText:"Update configuration"},t.createElement(t.Fragment,null,t.createElement("h3",null,"Order"),t.createElement("p",null,"Use drag and drop to change the order of the dashboard pages. Double-click on a dashboard title to change it."),t.createElement(H.cm,{items:V.toArray(),onMoveItem:ke,displayOverlayInPortal:!0,alignItemContent:"center",customContentRender:jt})))},Fd=(m,_,A)=>{if(A.type!==Rt.Z.Type.Dashboard)return;const R=pt.G.exports("views.hooks.copyWidgetToDashboard"),B=_.state.get(m),F=_.search.queries.find(Ee=>Ee.id===m).toBuilder().newId().build(),V=A.state.set(F.id,B.duplicate()),se=A.search.queries.add(F),Se=A.search.toBuilder().queries(se).build(),Ae=(0,el.Z)(A.toBuilder().state(V).search(Se).build());return R.reduce((Ee,Ze)=>Ze(_,Ee),Ae)},na="hidden",Kd="locked",$p="active",Mc=15,xc=c.default.div` display: flex; justify-content: space-between; align-items: center; `,$d=(0,c.default)(xe.Nav)(({theme:m})=>(0,c.css)` &.nav.nav-tabs { border-bottom: 0; display: flex; white-space: nowrap; position: relative; padding-left: ${Mc}px; > li { > a { color: ${m.colors.variant.dark.default}; border: none; &:hover, &:active, &:focus { transition: color 150ms ease-in-out; background: transparent; color: ${m.colors.variant.dark.primary}; } } } > li.active { display: flex; flex-direction: column; align-items: center; margin-bottom: -3px; > a { padding: 9px 15px; border: 1px solid ${m.colors.variant.lighter.default}; border-bottom: none; background-color: ${m.colors.global.contentBackground}; color: ${m.colors.variant.darkest.primary}; &:hover, &:active, &:focus { border: 1px solid ${m.colors.variant.lighter.default}; border-bottom: none; color: ${m.colors.variant.darkest.primary}; } } } > li.query-tabs-more, > li.query-tabs-more a { cursor: pointer; } } `),Gp=(m,_,A)=>{const R=document.querySelector("#dashboard-tabs"),B=R.querySelectorAll(":scope > li:not(.dropdown):not(.query-tabs-new)"),U=R.querySelectorAll("li.dropdown .dropdown-menu li"),F=R.querySelector("li.query-tabs-more"),V=R.querySelector("li.query-tabs-new"),se=[];let Se=F.offsetWidth+V.offsetWidth+Mc,Ae=0;B.forEach(Ee=>{if(Ee.classList.remove(na),Ee.setAttribute("aria-hidden","false"),_){const Ze=Ee.querySelector("a"),{tabId:je}=Ze.dataset;je===_&&(Se+=Ee.offsetWidth)}}),B.forEach((Ee,Ze)=>{Ee.classList.contains(Kd)||(Ae+=Ee.offsetWidth,m>=Ae+Se?se.splice(Ze,1):(Ee.classList.add(na),Ee.setAttribute("aria-hidden","true"),se.push(Ze)))}),U.forEach((Ee,Ze)=>{if(Ee.classList.remove(na),Ee.setAttribute("aria-hidden","false"),!se.includes(Ze))Ee.classList.add(na),Ee.setAttribute("aria-hidden","true");else if(Ee.classList.contains($p)){const{tabId:je}=Ee.querySelector("a").dataset;A(je)}}),se.length&&F.classList.contains(na)?F.classList.remove(na):!se.length&&!F.classList.contains(na)&&F.classList.add(na)},al=(m,_)=>{const A=m.toBuilder().search(_).build();return qr.T.update(A)},jp=(m,_,A)=>async R=>{const B=cc.Z.fromJSON(R),U=Fd(A,_,m.toBuilder().search(B).build());if(!U||!U.search)throw Error("Copying the dashboard page failed.");const F=U.search.queries.last().id,V=await(0,ci.Z)(U.search);return await al(U,V),[U,F]},hf=m=>async(_,A)=>{const R=(0,et.fv)(A()),B=(0,et.cE)(A()),U=await qr.T.get(m),F=Rt.Z.fromJSON(U);return(0,mc.Z)(U.search_id).then(jp(F,R,B))},Gd=({maxWidth:m,queries:_,titles:A,activeQueryId:R,onRemove:B,onSelect:U,queryTitleEditModal:F,dashboardId:V})=>{const[se,Se]=(0,t.useState)(!1),[Ae,Ee]=(0,t.useState)(),[Ze,je]=(0,t.useState)(!1),[ke,_t]=(0,t.useState)(!1),Dt=(0,sn.Z)(),jt=(0,yr.Z)(),Pt=(0,P.Z)(),Yt=(0,t.useCallback)(()=>{_t(tn=>!tn)},[]),Ht=(0,t.useCallback)(tn=>Dt(hf(tn)).then(([wn,on])=>(0,sr.o2)(jt,wn.id,on)).catch(wn=>{Ao.Z.error(`Copying dashboard page failed with error ${wn}`)}),[Dt,jt]),qt=(0,t.useCallback)(tn=>{F&&F.current.open(tn)},[F]),pn=(0,t.useMemo)(()=>{let tn=(0,ot.OrderedSet)(),wn=(0,ot.OrderedSet)(),on=(0,ot.OrderedSet)(),so=(0,ot.OrderedSet)();return _.keySeq().forEach((yn,lo)=>{const Sn=A.get(yn,`Page#${lo+1}`),ro=t.createElement(wp,{active:yn===R,id:yn,onRemove:()=>B(yn),openEditModal:qt,openCopyToDashboardModal:Yt,allowsClosing:_.size>1,title:Sn});tn=tn.add(Ae===yn?null:t.createElement(xe.NavItem,{eventKey:yn,key:yn,"data-tab-id":yn,onClick:()=>{Ee(void 0),U(yn)}},ro)),wn=wn.add(Ae===yn?null:t.createElement(xe.MenuItem,{eventKey:yn,key:yn,"data-tab-id":yn,onClick:()=>{Ee(yn),U(yn)}},ro)),on=on.add(Ae!==yn?null:t.createElement(xe.NavItem,{eventKey:yn,key:yn,"data-tab-id":yn,onClick:()=>U(yn),className:Kd},ro)),so=so.add({id:yn,title:Sn})}),{navItems:tn,menuItems:wn,lockedItems:on,queriesList:so}},[_,A,R,qt,Yt,Ae,B,U]);return(0,t.useEffect)(()=>{Gp(m,Ae,Ee)},[m,Ae,R]),t.createElement(xc,null,t.createElement($d,{bsStyle:"tabs",activeKey:R,id:"dashboard-tabs"},pn.navItems,t.createElement(Bp.J,{eventKey:"more",title:t.createElement(H.JO,{name:"ellipsis-h"}),className:"query-tabs-more",id:"query-tabs-more","aria-label":"More Dashboard Pages",noCaret:!0,pullRight:!0,active:se,open:se,onToggle:tn=>Se(tn)},pn.menuItems),pn.lockedItems,t.createElement(xe.NavItem,{key:"new",eventKey:"new",title:"Create New Page",onClick:()=>{Pt(O.A.DASHBOARD_ACTION.DASHBOARD_CREATE_PAGE,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-create-page-button"}),U("new")},className:"query-tabs-new"},t.createElement(H.JO,{name:"plus"}))),t.createElement(H.hU,{title:"Open pages configuration",name:"cog",onClick:()=>{Pt(O.A.DASHBOARD_ACTION.DASHBOARD_PAGE_CONFIGURATION,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-page-configuration-button"}),je(!0)}}),Ze&&t.createElement(Kp,{show:Ze,setShow:je,dashboardId:V,queriesList:pn.queriesList,activeQueryId:R}),ke&&t.createElement(gc,{onSubmit:tn=>Ht(tn),onCancel:Yt,activeDashboardId:V,submitButtonText:"Copy page",submitLoadingText:"Copying page..."}))};Gd.propTypes={maxWidth:a().number.isRequired,queries:wd().orderedSetOf(a().string).isRequired,titles:a().object.isRequired,activeQueryId:a().string.isRequired,onRemove:a().func.isRequired,onSelect:a().func.isRequired,queryTitleEditModal:a().oneOfType([a().func,a().shape({current:a().object})]).isRequired};const zp=Gd,Vp=({onRemove:m,onSelect:_,onTitleChange:A,queries:R,activeQueryId:B,titles:U,dashboardId:F})=>{const V=(0,t.useRef)();return t.createElement(xe.Row,null,t.createElement(xe.Col,null,t.createElement(bt.Z,null,({width:se})=>se?t.createElement(zp,{maxWidth:se,queries:R,dashboardId:F,titles:U,activeQueryId:B,onRemove:m,onSelect:_,queryTitleEditModal:V,onTitleChange:A}):t.createElement("div",null)),t.createElement(Lp,{onTitleChange:se=>A(B,se),ref:V})))};Vp.propTypes={onRemove:a().func.isRequired,onSelect:a().func.isRequired,onTitleChange:a().func.isRequired,queries:wd().orderedSetOf(a().string).isRequired,activeQueryId:a().string.isRequired,titles:a().object.isRequired};const Hp=Vp,kp=async(m,_,A,R,B,U)=>(R.size===1||await Ud(m,A,B)===!0&&U((0,We.hj)(_)),Promise.resolve()),Qp=()=>{const m=fc(),_=gf(),{activeQuery:A,id:R}=$e(),{setDashboardPage:B}=(0,t.useContext)(Ai),U=Rc(),F=(0,sn.Z)(),V=(0,t.useCallback)(Ae=>{Ae==="new"?F((0,We.rP)()).then(Ee=>B(Ee)):(B(Ae),F((0,We.xM)(Ae)))},[F,B]),se=(0,t.useCallback)(Ae=>kp(R,Ae,A,m,U,F),[R,A,m,U,F]),Se=(0,t.useCallback)((Ae,Ee)=>F((0,Tl.T)(Ae,"tab","title",Ee)),[F]);return t.createElement(Hp,{queries:m,activeQueryId:A,titles:_,dashboardId:R,onSelect:V,onTitleChange:Se,onRemove:se})};var Xp=e("8RmZXjGq"),vf=e("InkdxEOv"),Jp=e("SnOQy/BL"),yf=e("i3LesQt8");const Yp=c.default.li(({theme:m})=>(0,c.css)` font-size: ${m.fonts.size.body}; display: table-row; white-space: nowrap; `),qp=({activeQueryFields:m,fieldType:_,selectedQuery:A,style:R})=>{const{name:B,type:U}=_,F=!m.find(V=>V.name===B);return t.createElement(Yp,{style:R},t.createElement(yf.Z,{type:U})," ",t.createElement(Jp.Z,{queryId:A,disabled:F,name:B,type:U},B))},eg=50,tg=(0,c.default)(bt.Z)` overflow: hidden; `,ng=(m,_,A="all")=>{const R=B=>!(0,vf.Z)(B.name);switch(A){case"all":return _.filter(R).toList();case"allreserved":return _;case"current":default:return m.filter(R).toList()}},og=({filter:m,activeQueryFields:_,allFields:A,currentGroup:R})=>{const B=(0,T.Z)();if(!_)return t.createElement("span",null,"No field information available.");const U=m?se=>se.name.toLocaleUpperCase().includes(m.toLocaleUpperCase()):()=>!0,V=ng(_,A,R).filter(U).sortBy(se=>se.name.toLocaleUpperCase());return V.isEmpty()?t.createElement("i",null,"No fields to show. Try changing your filter term or select a different field set above."):t.createElement(tg,null,({width:se,height:Se})=>t.createElement(Xp.t7,{height:Se||eg,width:se,itemCount:V.size,itemSize:20},({index:Ae,style:Ee})=>t.createElement(qp,{fieldType:V.get(Ae),selectedQuery:B,activeQueryFields:_,style:Ee})))},ll=({onSelect:m,selected:_,group:A,text:R,title:B})=>t.createElement("a",{onClick:()=>m(A),role:"button",style:{fontWeight:_?"bold":"normal"},tabIndex:0,title:B},R),jd=c.default.div` white-space: break-spaces; height: 100%; display: grid; display: -ms-grid; grid-template-columns: 1fr; grid-template-rows: max-content 1fr; -ms-grid-columns: 1fr; -ms-grid-rows: max-content 1fr; > *:nth-child(1) { grid-column: 1; -ms-grid-column: 1; grid-row: 1; -ms-grid-row: 1; } > *:nth-child(2) { grid-column: 1; -ms-grid-column: 1; grid-row: 2; -ms-grid-row: 2; } `,sg=c.default.form` display: flex; `,Tf=c.default.div` margin-right: 5px; `,rg=c.default.input` width: 100%; `,oa=c.default.div` margin-top: 5px; margin-bottom: 0; `,Bc=({allFields:m,activeQueryFields:_})=>{const[A,R]=(0,t.useState)("current"),[B,U]=(0,t.useState)(void 0),F=se=>U(se.target.value),V=()=>U(void 0);return t.createElement(jd,null,t.createElement("div",null,t.createElement(sg,{onSubmit:se=>se.preventDefault()},t.createElement(Tf,{className:"form-group has-feedback"},t.createElement(rg,{id:"common-search-form-query-input",className:"query form-control",onChange:F,value:B||"",placeholder:"Filter fields",type:"text",autoComplete:"off",spellCheck:"false"})),t.createElement("div",{className:"form-group"},t.createElement(xe.Button,{type:"reset",className:"reset-button",onClick:V},"Reset"))),t.createElement(oa,null,"List fields of"," ",t.createElement(ll,{selected:A==="current",group:"current",text:"current query",title:"This shows fields which occur in your current query.",onSelect:R}),", ",t.createElement(ll,{selected:A==="all",group:"all",text:"all",title:"This shows all fields, but no reserved (gl2_*) fields.",onSelect:R})," or ",t.createElement(ll,{onSelect:R,selected:A==="allreserved",group:"allreserved",text:"all including reserved",title:"This shows all fields, including reserved (gl2_*) fields."})," fields."),t.createElement("hr",null)),t.createElement(og,{filter:B,activeQueryFields:_,allFields:m,currentGroup:A}))},zd=m=>{const _=(0,T.Z)();return t.createElement(bn.Z.Consumer,null,A=>{const R=A==null?void 0:A.all,B=A==null?void 0:A.queryFields,U=B==null?void 0:B.get(_,R);return t.createElement(Bc,{...m,allFields:R,activeQueryFields:U})})},Hd=()=>(0,d.o)(So.V);var Af=e("d4iC/0eA");const ag=(0,c.default)(xe.ButtonGroup)` display: flex; justify-content: flex-end; > .btn-group { .btn:first-child { max-width: 100%; } } `,kd=({refreshConfigEnabled:m,naturalInterval:_})=>{const A=m?t.createElement(t.Fragment,null,"Every ",_):"Not updating";return t.createElement(t.Fragment,null,A)},Pf=()=>{const m=Hd(),{dirty:_,isSubmitting:A}=(0,yt.useFormikContext)();(0,t.useEffect)(()=>{m.enabled&&!A&&_&&So.e.disable()},[_,A,m.enabled])},lg=m=>rs().duration(m).asMilliseconds(),Qd=()=>{const{dirty:m,submitForm:_}=(0,yt.useFormikContext)(),A=Hd(),R=(0,L.Z)(),B=(0,P.Z)(),{config:{auto_refresh_timerange_options:U={}}}=(0,Af.Z)(),F=Ee=>{B(O.A.SEARCH_REFRESH_CONTROL_PRESET_SELECTED,{app_pathname:(0,b.av)(R.pathname),app_section:"search-bar",app_action_value:"refresh-search-control-dropdown",event_details:{interval:Ee}}),So.e.setInterval(Ee),m&&_()};(0,t.useEffect)(()=>()=>So.e.disable(),[]),Pf();const V=(0,t.useCallback)(()=>{B(O.A.SEARCH_REFRESH_CONTROL_TOGGLED,{app_pathname:"search",app_section:"search-bar",app_action_value:"refresh-search-control-enable",event_details:{enabled:!A.enabled}}),A.enabled?So.e.disable():(m&&_(),So.e.enable())},[m,A.enabled,B,_]),se=Object.entries(U).map(([Ee,Ze])=>t.createElement(xe.MenuItem,{key:`RefreshControls-${Ze}`,onClick:()=>F(lg(Ee))},Ze)),Se=rs().duration(A.interval),Ae=Se.asSeconds()<60?t.createElement("span",null,Se.asSeconds()," ",t.createElement(H.qX,{singular:"second",plural:"seconds",value:Se.asSeconds()})):t.createElement("span",null,Se.asMinutes()," ",t.createElement(H.qX,{singular:"minute",plural:"minutes",value:Se.asMinutes()}));return t.createElement(ag,{"aria-label":"Refresh Search Controls"},t.createElement(xe.Button,{onClick:V,title:A.enabled?"Pause Refresh":"Start Refresh"},A.enabled?t.createElement(H.JO,{name:"pause"}):t.createElement(H.JO,{name:"play"})),t.createElement(xe.DropdownButton,{title:t.createElement(kd,{refreshConfigEnabled:A.enabled,naturalInterval:Ae}),id:"refresh-options-dropdown"},se))};var ig=e("kqAR+wt5"),Xd=e.n(ig);const Df={NAVBAR_HEIGHT:55,scrollToHint(m){if(!this.isElementVisible(m)){const _=Xd()("#scroll-to-hint");_.fadeIn("fast").delay(1500).fadeOut("fast").on("click",A=>{A.preventDefault();const R=window.pageYOffset-this.NAVBAR_HEIGHT+m.getBoundingClientRect().top;Xd()("html, body").animate({scrollTop:R},"fast"),_.off("click")})}},isElementVisible(m){const _=m.getBoundingClientRect();return _.top>0&&_.bottom>0}},Uc=({children:m,value:_})=>{const A=(0,t.useRef)();return(0,t.useEffect)(()=>{Df.scrollToHint(A.current)},[_]),t.createElement("span",{ref:A},m)};Uc.propTypes={children:a().node.isRequired,value:a().any.isRequired};const cg=Uc;var wc=e("0TVxnHwi"),Of=e("RCNj0OY4");const Wc=({show:m,onClose:_})=>{const A=(0,nt.Z)(R=>R);return t.createElement(nc.Z,{showModal:m,onHide:_},t.createElement(xe.Modal.Header,{closeButton:!0},t.createElement(xe.Modal.Title,null,"Debug information")),t.createElement(xe.Modal.Body,null,t.createElement("textarea",{disabled:!0,style:{height:"80vh",width:"100%"},value:JSON.stringify(A,null,2)})),t.createElement(xe.Modal.Footer,null,t.createElement(xe.Button,{type:"button",onClick:()=>_()},"Close")))},Jd=(m,_)=>async A=>{try{const R=await qr.T.create(m);A((0,We.hU)(!1)),A((0,We.de)(!1)),(0,sr.o2)(_,R.id),Ao.Z.success(`Saving view "${m.title}" was successful!`,"Success!")}catch(R){Ao.Z.error(`Saving view failed: ${R}`,"Error!")}},Yd={Edit:m=>`view:edit:${m}`},ug={save:{isShown:!0},saveAs:{isShown:!0},share:{isShown:!0},actionsDropdown:{isShown:!0}},If={save:{isShown:!1},saveAs:{isShown:!0},share:{isShown:!1},actionsDropdown:{isShown:!1}},Mf={save:{isShown:!1},saveAs:{isShown:!1},share:{isShown:!1},actionsDropdown:{isShown:!1}},qd={sidebar:{isShown:!0},viewActions:ug},dg=t.createContext(qd),Nc=(0,u.ri)("contexts.SearchPageLayout",()=>dg);function em(){let m=(0,t.useContext)(Nc);return m===void 0&&(m=qd),m}var Aa=e("q2j1bVbz"),Zc=e("HqzDVmZB");const tm=async(m,_,A)=>{let R=m.toBuilder().build();for(const B of A){const U=await B(R,_).catch(F=>{const V=`An error occurred when executing a submit handler from a plugin: ${F}`;return console.error(V),Ao.Z.error(V),R});U&&(R=U)}return R},nm=(m,_,A)=>{const R=A==null?void 0:A.map(({onSearchDuplication:B})=>B).filter(B=>!!B);return tm(m,_,R)},xf=(m,_,A)=>{const R=A==null?void 0:A.map(({onDashboardDuplication:B})=>B).filter(B=>!!B);return tm(m,_,R)};var Fc=e("qZ8Wpsbl"),Kc=e("Gkq4qIYY"),om=e("tt0llszK");const Lf=(0,c.default)(H.JO)(({theme:m,$isDirty:_})=>(0,c.css)` color: ${_?m.colors.variant.dark.warning:"default"}; `),sm=(0,t.forwardRef)(({title:m,onClick:_,disabled:A},R)=>{const B=Oc();return t.createElement(xe.Button,{title:m,ref:R,onClick:_,disabled:A},t.createElement(Lf,{name:"floppy-disk",type:B?"solid":"regular",$isDirty:!A&&B})," Save")});sm.defaultProps={disabled:!1};const rm=sm,Lr=m=>m.searchMetadata,mg=(0,Oe.P1)(Lr,m=>m.metadata),bi=(0,Oe.P1)(mg,m=>{var _;return(_=m==null?void 0:m.undeclared)!=null?_:ot.Set()}),pg=(0,Oe.P1)(bi,m=>(m==null?void 0:m.size)>0),_r=()=>(0,nt.Z)(pg),lm=({userIsAllowedToEdit:m,openSaveAsModal:_})=>{const A=(0,To.Z)(),R=(0,Kc.Z)(),B=(0,P.Z)(),U=(0,sn.Z)(),F=_r(),V=(0,t.useCallback)(()=>(B(O.A.DASHBOARD_ACTION.DASHBOARD_SAVED,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-save"}),U((0,om.Z)(A))),[U,B,A]);return(0,dn.Z)({actionKey:"save",callback:()=>R?_():V(),scope:"dashboard",options:{enabled:!F&&m}}),t.createElement(rm,{title:"Save dashboard",onClick:V,disabled:F||R||!m})};var gg=e("utbMO9sg");const Di=({onClick:m,openSaveAsModal:_})=>{const A=_r();return(0,dn.Z)({actionKey:"save-as",callback:()=>_(),scope:"dashboard",options:{enabled:!A}}),t.createElement(gg.Z,{onClick:m,disabled:A,title:"Save as new dashboard"},t.createElement(H.JO,{name:"copy"})," Save as")};var Oi=e("B6TE4HBJ"),Eg=e("oCSEoDew"),Gc=e.n(Eg),im=e("d4kzUuQm");const fg=({onSave:m,view:_,show:A,onClose:R})=>{const B=_.search.queries.keySeq().map((ke,_t)=>[_t,(0,ta.Z)(_,ke.id)]).toJS(),[U,F]=(0,t.useState)(10),[V,se]=(0,t.useState)(B.map(([ke])=>ke)),[Se,Ae]=(0,t.useState)(30),Ee=(0,t.useCallback)(ke=>se([...V,ke]),[V,se]),Ze=(0,t.useCallback)(ke=>se(V.filter(_t=>_t!==ke)),[V,se]),je=(0,t.useCallback)(()=>m({refreshInterval:U,queryTabs:V,queryCycleInterval:Se}),[m,U,V,Se]);return t.createElement(di.Z,{bsSize:"large",onCancel:R,onSubmitForm:je,submitButtonText:"Start full screen view",title:"Configuring Full Screen",show:A},t.createElement(ea.Z,{autoFocus:!0,id:"refresh-interval",type:"number",min:"1",name:"refresh-interval",label:"Refresh Interval",help:"After how many seconds should the dashboard refresh?",onChange:({target:{value:ke}})=>F(ke&&Number.parseInt(ke,10)),required:!0,step:1,value:U}),t.createElement(xe.FormGroup,null,t.createElement(xe.ControlLabel,null,"Tabs"),t.createElement("ul",null,B.map(([ke,_t])=>t.createElement("li",{key:`${ke}-${_t}`},t.createElement(xe.Checkbox,{inline:!0,checked:V.includes(ke),onChange:Dt=>Dt.target.checked?Ee(ke):Ze(ke)},_t)))),t.createElement(xe.HelpBlock,null,"Select the query tabs to include in rotation.")),t.createElement(ea.Z,{id:"query-cycle-interval",type:"number",min:"1",name:"query-cycle-interval",label:"Tab cycle interval",help:"After how many seconds should the next tab be shown?",onChange:({target:{value:ke}})=>Ae(ke&&Number.parseInt(ke,10)),required:!0,step:"1",value:Se}))},Bf=(m,_,A,R)=>{R(),m.push(new(Gc())(im.ZP.pluginRoute("DASHBOARDS_TV_VIEWID")(_.id)).search(A).toString())},hg=({queryCycleInterval:m,queryTabs:_,refreshInterval:A},R)=>{const B={interval:Number(m).toString(),refresh:Number(A).toString()},U=R.search.queries.toIndexedSeq().map((F,V)=>V).toJS();return!_||U.join(",")===_.join(",")?B:{...B,tabs:_.join(",")}},cm=({disabled:m,show:_,view:A})=>{const[R,B]=(0,t.useState)(_),{unsetWidgetFocusing:U}=(0,t.useContext)(Ie.Z),F=(0,yr.Z)(),V=(0,P.Z)(),se=Se=>{V(O.A.DASHBOARD_FULL_SCREEN_MODE_STARTED,{app_pathname:"dashboard",app_section:"dashboard-menu"}),Bf(F,A,hg(Se,A),U)};return t.createElement(t.Fragment,null,R&&t.createElement(fg,{onClose:()=>B(!1),onSave:se,show:!0,view:A}),t.createElement(xe.MenuItem,{disabled:m,onSelect:()=>B(!0),icon:"desktop"},"Full Screen"))};cm.defaultProps={disabled:!1,show:!1};const vg=cm,yg=(m,_)=>(0,wc.rq)(_==null?void 0:_.permissions,[Yd.Edit(m.id)])||m.type===Rt.Z.Type.Dashboard&&(0,wc.rq)(_==null?void 0:_.permissions,[`dashboards:edit:${m.id}`]),_g=()=>{const m=(0,To.Z)(),_=(0,Kc.Z)(),A=(0,Aa.Z)(),{viewActions:{save:{isShown:R},saveAs:{isShown:B},share:{isShown:U},actionsDropdown:{isShown:F}}}=em(),V=(0,Fc.Z)(),[se,Se]=(0,t.useState)(!1),[Ae,Ee]=(0,t.useState)(!1),[Ze,je]=(0,t.useState)(!1),[ke,_t]=(0,t.useState)(!1),[Dt,jt]=(0,t.useState)(!1),Pt=(0,P.Z)(),Yt=yg(m,A),Ht=Of.Z.gl2DevMode()&&t.createElement(t.Fragment,null,t.createElement(xe.MenuItem,{divider:!0}),t.createElement(xe.MenuItem,{onSelect:()=>Ee(!0),icon:"code"},"Debug")),qt=(0,sn.Z)(),pn=(0,yr.Z)(),tn=(0,Fn.Z)("views.components.dashboardActions"),wn=(0,t.useRef)({}),on=(0,t.useMemo)(()=>tn.map(({component:Sn,key:ro})=>t.createElement(Sn,{key:`dashboard-action-${ro}`,dashboard:m,modalRef:()=>wn.current[ro]})),[tn,m]),so=(0,t.useMemo)(()=>tn.filter(({modal:Sn})=>!!Sn).map(({modal:Sn,key:ro})=>t.createElement(Sn,{key:`dashboard-action-modal-${ro}`,dashboard:m,ref:Io=>{wn.current[ro]=Io}})),[tn,m]),yn=(0,t.useCallback)(async Sn=>{if(Pt(O.A.DASHBOARD_ACTION.DASHBOARD_NEW_SAVED,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-save-new"}),!!m.id){const Io=await xf(Sn,A.permissions,V);return qt(Jd(Io,pn))}return qt(Jd(Sn,pn))},[A.permissions,qt,pn,V,Pt,m.id]),lo=(0,t.useCallback)(Sn=>(Pt(O.A.DASHBOARD_ACTION.DASHBOARD_UPDATED,{app_pathname:"dashboard",app_section:"dashboard",app_action_value:"dashboard-update"}),qt((0,We.NK)(Sn))),[qt,Pt]);return t.createElement(xe.ButtonGroup,null,R&&t.createElement(lm,{userIsAllowedToEdit:Yt,openSaveAsModal:()=>je(!0)}),B&&t.createElement(Di,{onClick:()=>je(!0),openSaveAsModal:()=>je(!0)}),U&&t.createElement(H.Tz,{entityType:"dashboard",entityId:m.id,onClick:()=>Se(!0),bsStyle:"default",disabledInfo:_&&"Only saved dashboards can be shared."}),F&&t.createElement(xe.DropdownButton,{title:t.createElement(H.JO,{name:"ellipsis-h",title:"More Actions"}),id:"query-tab-actions-dropdown",pullRight:!0,noCaret:!0},on.length>0&&t.createElement(t.Fragment,null,on,t.createElement(xe.MenuItem,{divider:!0})),t.createElement(xe.MenuItem,{onSelect:()=>_t(!0),disabled:_||!Yt,icon:"edit"},"Edit metadata"),t.createElement(xe.MenuItem,{onSelect:()=>jt(!0),icon:"cloud-download-alt"},"Export"),Ht,t.createElement(xe.MenuItem,{divider:!0}),t.createElement(vg,{view:m,disabled:_})),Ae&&t.createElement(Wc,{show:!0,onClose:()=>Ee(!1)}),Ze&&t.createElement(Oi.Z,{show:!0,view:m.toBuilder().newId().build(),title:"Save new dashboard",submitButtonText:"Create dashboard",onClose:()=>je(!1),onSave:Sn=>yn(Sn)}),ke&&t.createElement(Oi.Z,{show:!0,view:m,title:"Editing dashboard",submitButtonText:"Update dashboard",onClose:()=>_t(!1),onSave:lo}),se&&t.createElement(Zc.Z,{entityId:m.id,entityType:"dashboard",entityTitle:m.title,description:"Search for a User or Team to add as collaborator on this dashboard.",onClose:()=>Se(!1)}),Dt&&t.createElement(si,{view:m,closeModal:()=>jt(!1)}),so)};var Ri=e("PwTFiGSp");const Cg=m=>Un()(m),um=({initialValues:m,limitDuration:_,onSubmit:A,validateQueryString:R,children:B})=>{const{formatTime:U,userTimezone:F}=(0,Ys.Z)(),{setFieldWarning:V}=(0,t.useContext)(Fs),[se,Se]=(0,t.useState)(!0),Ae=(0,Fn.Z)("views.components.searchBar"),Ee=(0,t.useCallback)(({timerange:Pt,...Yt})=>(Se(!1),A({timerange:(0,Ri.j9)(Pt)?void 0:(0,Ds.P3)(Pt,F),...Yt}).then(()=>Se(!0))),[A,F]),{timerange:Ze,...je}=m,_t={timerange:Ze&&!(0,Ri.j9)(Ze)?(0,Tn.h)(Ze,U):{},...je},Dt=Os(),jt=(0,t.useCallback)(Pt=>eo(Pt,_,V,R,Ae,U,Dt),[_,V,R,Ae,U,Dt]);return t.createElement(yt.Formik,{initialValues:_t,enableReinitialize:se,onSubmit:Ee,validate:jt,validateOnMount:!0},(...Pt)=>t.createElement(yt.Form,null,Cg(B)?B(...Pt):B))};um.propTypes={initialValues:a().shape({timerange:a().object,queryString:a().string}).isRequired,limitDuration:a().number.isRequired,onSubmit:a().func.isRequired};const zc=um,Uf=c.default.div(({theme:m})=>(0,c.css)` display: flex; justify-content: space-between; gap: ${Po.V}; @media (max-width: ${m.breakpoints.max.sm}) { flex-direction: column; } `),Tg=(0,c.default)(vr.Z)(({theme:m})=>(0,c.css)` flex: 0.2; flex-basis: 380px; @media (max-width: ${m.breakpoints.max.sm}) { flex: 1; flex-basis: auto; } `),Sg=(0,ls.Z)(Er,350),Ag=(m,_,A,R)=>{const B={timeRange:(0,Ri.j9)(m==null?void 0:m.timerange)||m==null?void 0:m.timerange,queryString:m==null?void 0:m.queryString,...ha(m,R,_)};return Sg(B,A)},Pg=(m,_)=>{const A=Ka();return(0,t.useMemo)(()=>({timerange:m,queryString:_,...A}),[_,m,A])},bg=()=>{var m,_;const{userTimezone:A}=(0,Ys.Z)(),{searchesClusterConfig:R}=(0,d.o)(Wo.s),{timerange:B,query:{query_string:U=""}={}}=(m=mt())!=null?m:{},F=(0,Fn.Z)("views.components.searchBar"),V=(0,sn.Z)(),se=Os(),Se=(0,t.useCallback)(async je=>{const{timerange:ke,queryString:_t}=je;await $a(V,je,F),V((0,qo.YD)(_t,ke)),V((0,qo.ht)())},[V,F]),{parameters:Ae}=Dr(),Ee=Pg(B,U);if(!R)return t.createElement(H.$j,null);const Ze=(_=rs().duration(R.query_time_range_limit).asSeconds())!=null?_:0;return t.createElement(Ie.Z.Consumer,null,({focusedWidget:{editing:je}={editing:!1}})=>t.createElement(cg,{value:U},t.createElement(Qr,null,t.createElement(zc,{initialValues:Ee,limitDuration:Ze,onSubmit:Se,validateQueryString:ke=>Ag(ke,F,A,se)},({dirty:ke,errors:_t,isSubmitting:Dt,isValid:jt,isValidating:Pt,handleSubmit:Yt,values:Ht,setFieldValue:qt,validateForm:pn})=>{const tn=Dt||Pt||!jt;return t.createElement(Po.Vi,null,t.createElement(Ea,{parameters:Ae}),t.createElement(Uf,null,t.createElement(Tg,{onChange:wn=>qt("timerange",wn),value:Ht==null?void 0:Ht.timerange,limitDuration:Ze,hasErrorOnMount:!!_t.timerange,noOverride:!0}),t.createElement(Qd,null)),t.createElement(Po.dD,null,t.createElement(Po.hF,null,t.createElement(q,{disabled:tn,glyph:"filter",displaySpinner:Dt,dirty:ke}),t.createElement(Po.M8,null,t.createElement(yt.Field,{name:"queryString"},({field:{name:wn,value:on,onChange:so},meta:{error:yn}})=>t.createElement(Fs.Consumer,null,({warnings:lo})=>t.createElement(hr,{usage:"global_override_query"},Sn=>t.createElement(tt,{value:on,timeRange:Ht==null?void 0:Ht.timerange,placeholder:"Apply filter to all widgets",name:wn,onChange:so,disableExecution:tn,error:yn,isValidating:Pt,validate:pn,warning:lo.queryString,onExecute:Yt,commands:Sn})))),t.createElement(kr,null))),!je&&t.createElement(_g,null)),t.createElement(Ql,{showLeftControls:!1}))}))))};var Dg=e("rzOX6PZw"),Og=e("rlwexfKi"),Rg=e("fkNiwXiR"),Vc=e("crOrxG1u"),Hc=e("Dg3D5NJi"),kc=e("qO9czYNI"),Ig=e("ty2gyrHp"),Mg=e("YwMFjcSm"),xg=e("Q1zRxDOP");const Lg=(m,_,A)=>(!_||!A||(A(_),m()),!1),Bg=(m,_)=>{const A=(0,tr.useQueryClient)();return{attributes:{title:{renderCell:(R,B)=>t.createElement(o.Consumer,{key:B.id},U=>{const F=V=>{V.preventDefault(),Lg(m,B.id,U)};return t.createElement(Ig.r,{onClick:F,to:im.ZP.getPluginRoute("SEARCH_VIEWID")(B.id)},R)})},favorite:{renderCell:(R,B)=>t.createElement(Mg.Z,{isFavorite:R,grn:(0,xg.L)("search",B.id),onChange:U=>{A.setQueriesData(["saved-searches","overview",_],F=>({...F,list:F.list.map(V=>V.id===B.id?V.toBuilder().favorite(U).build():V)}))}})}}}},Ug=(m,_,A,R,B)=>{m.stopPropagation(),window.confirm(`You are about to delete saved search: "${_.title}". Are you sure?`)&&A(_).then(()=>{_.id!==R&&B()})},wg=({search:m,onDeleteSavedSearch:_,activeSavedSearchId:A,refetch:R})=>{const[B,U]=(0,t.useState)(!1),F=(0,t.useCallback)(()=>{U(V=>!V)},[]);return t.createElement(t.Fragment,null,t.createElement(H.Tz,{bsSize:"xsmall",entityId:m.id,entityType:"search",onClick:()=>U(!0)}),t.createElement(H.AE,{permissions:[`view:edit:${m.id}`,"view:edit"],anyPermissions:!0},t.createElement(xe.Button,{onClick:V=>Ug(V,m,_,A,R),role:"button",bsSize:"xsmall",bsStyle:"danger",title:`Delete search ${m.title}`,tabIndex:0},"Delete")),B&&t.createElement(Zc.Z,{entityId:m.id,entityType:"search",entityTitle:m.title,description:"Search for a User or Team to add as collaborator on this search.",onClose:F}))};var Zf=e("Z2BtcgLJ");const Wg="/views/bulk_delete",Ff=({selectedSavedSearchIds:m,setSelectedSavedSearchIds:_})=>{const A=(0,tr.useQueryClient)(),R=m==null?void 0:m.length,B=jr.Z.pluralize(R,"saved search","saved searches"),U=(0,t.useCallback)(()=>{window.confirm(`Do you really want to remove ${R} ${B}?`)&&(0,Xr.ZP)("POST",(0,b.DC)(Wg),{entity_ids:m}).then(({failures:F})=>{if(F!=null&&F.length){const V=F.map(({entity_id:se})=>se);_(V),Ao.Z.error(`${V.length} out of ${R} selected ${B} could not be deleted.`)}else _([]),Ao.Z.success(`${R} ${B} ${jr.Z.pluralize(R,"was","were")} deleted successfully.`,"Success")}).catch(F=>{Ao.Z.error(`An error occurred while deleting saved searches. ${F}`)}).finally(()=>{A.invalidateQueries(["saved-searches","overview"])})},[B,A,R,m,_]);return t.createElement(Zf.Z,{selectedEntities:m,setSelectedEntities:_},t.createElement(xe.MenuItem,{onSelect:U},"Delete"))},dm="saved-searches",Qc={pageSize:20,sort:{attributeId:"title",direction:"asc"},displayedColumns:["title","description","summary","favorite"],columnsOrder:["title","summary","description","owner","created_at","favorite"]},Zg=(m,_)=>t.createElement(Ff,{selectedSavedSearchIds:m,setSelectedSavedSearchIds:_}),il=({activeSavedSearchId:m,deleteSavedSearch:_,onLoadSavedSearch:A})=>{const[R,B]=(0,t.useState)(""),[U,F]=(0,t.useState)(1),{layoutConfig:V,isInitialLoading:se}=(0,Hc.Z)({entityTableId:dm,defaultPageSize:Qc.pageSize,defaultDisplayedAttributes:Qc.displayedColumns,defaultSort:Qc.sort}),Se=(0,t.useMemo)(()=>({query:R,page:U,pageSize:V.pageSize,sort:V.sort}),[U,V.pageSize,V.sort,R]),{data:Ae,isInitialLoading:Ee,refetch:Ze}=(0,Vc.Z)(Se,{enabled:!se}),{mutate:je}=(0,kc.Z)(dm),ke=(0,t.useCallback)((on,so)=>{on&&F(on),so&&je({perPage:so})},[je]),_t=(0,t.useCallback)(on=>{F(1),je({perPage:on})},[je]),Dt=(0,t.useCallback)(on=>{F(1),je({sort:on})},[je]),jt=(0,t.useCallback)(on=>{F(1),B(on)},[]),Pt=(0,t.useCallback)(()=>jt(""),[jt]),Yt=(0,t.useCallback)(on=>{je({displayedAttributes:on})},[je]),Ht=(0,t.useCallback)(on=>t.createElement(wg,{search:on,onDeleteSavedSearch:_,refetch:Ze,activeSavedSearchId:m}),[m,_,Ze]),qt=Bg(A,Se);if(Ee||se)return t.createElement(H.$j,null);const{list:pn,pagination:tn,attributes:wn}=Ae;return t.createElement(H.l9,{onChange:ke,totalItems:tn==null?void 0:tn.total,pageSize:V.pageSize,activePage:U,showPageSizeSelect:!1,useQueryParameter:!1},t.createElement("div",{style:{marginBottom:"5px"}},t.createElement(H.UI,{focusAfterMount:!0,onSearch:jt,queryHelpComponent:t.createElement(Og.Z,{entityName:"search",commonFields:["id","title"]}),topMargin:0,onReset:Pt})),(tn==null?void 0:tn.total)===0&&!Se.query&&t.createElement(H.dX,null,"No saved searches have been created yet."),(tn==null?void 0:tn.total)===0&&Se.query&&t.createElement(H.pJ,null,"No saved searches have been found."),!!(pn!=null&&pn.length)&&t.createElement(Rg.Z,{data:pn,visibleColumns:V.displayedAttributes,columnsOrder:Qc.columnsOrder,onColumnsChange:Yt,bulkSelection:{actions:Zg},onSortChange:Dt,activeSort:V.sort,pageSize:Se.pageSize,onPageSizeChange:_t,actionsCellWidth:120,rowActions:Ht,columnRenderers:qt,columnDefinitions:wn}))},mm=({toggleModal:m,deleteSavedSearch:_,activeSavedSearchId:A})=>t.createElement(xe.Modal,{show:!0,title:"Saved searches",bsSize:"large",onHide:m},t.createElement(xe.Modal.Header,{closeButton:!0},t.createElement(xe.Modal.Title,null,"Saved Searches")),t.createElement(xe.Modal.Body,null,t.createElement(il,{deleteSavedSearch:_,activeSavedSearchId:A,onLoadSavedSearch:m})),t.createElement(xe.Modal.Footer,null,t.createElement(xe.Button,{onClick:m},"Cancel")));mm.propTypes={toggleModal:a().func.isRequired,deleteSavedSearch:a().func.isRequired};const Gf=mm;var Fg=e("dFpwyWHg"),pm=e.n(Fg),Ii=e("C2ikvoS0"),Kg=e.n(Ii),$g=e("1IntWRSu"),Gg=e.n($g),jf=e("8nGWeFnd"),jg=e.n(jf),zg=e("TeAcaicX"),Vg=e.n(zg),Hg=e("eE3+5goe"),kg=e.n(Hg),Xc=e("V7bsrEHK"),Pa={};Pa.styleTagTransform=kg(),Pa.setAttributes=jg(),Pa.insert=Gg().bind(null,"head"),Pa.domAPI=Kg(),Pa.insertStyleElement=Vg();var zf=pm()(Xc.Z,Pa);const Jc=Xc.Z&&Xc.Z.locals?Xc.Z.locals:void 0,Vf=c.default.form` width: 210px; `,gm=m=>{m.preventDefault(),m.stopPropagation()},Qg=m=>{const{isCreateNew:_,saveSearch:A,saveAsSearch:R,toggleModal:B,value:U,target:F}=m,[V,se]=(0,t.useState)(U),Se=(0,t.useCallback)(Dt=>se(Dt.target.value),[]),Ae=(V!=null?V:"").trim(),Ee=Ae===""||!_&&Ae===U,Ze=_?"Create new":"Save as",je=(0,Fc.Z)(),ke=(0,t.useCallback)(()=>A(V),[A,V]),_t=(0,t.useCallback)(()=>R(V),[R,V]);return t.createElement(H.Uv,null,t.createElement(ma.Ly,{placement:"left",target:F},t.createElement(xe.Popover,{title:"Name of search",id:"saved-search-popover"},t.createElement(Vf,{onSubmit:gm},t.createElement(xe.FormGroup,null,t.createElement(xe.ControlLabel,{htmlFor:"title"},"Title"),t.createElement(xe.FormControl,{type:"text",value:V,id:"title",placeholder:"Enter title",onChange:Se})),je==null?void 0:je.map(({component:Dt,id:jt})=>Dt&&t.createElement(Dt,{key:jt,disabledViewCreation:Ee})),t.createElement(xe.ButtonToolbar,null,!_&&t.createElement(xe.Button,{bsStyle:"primary",className:Jc.button,type:"submit",bsSize:"sm",onClick:ke},"Save"),t.createElement(xe.Button,{disabled:Ee,bsStyle:"info",className:Jc.button,type:"submit",bsSize:"sm",onClick:_t},Ze),t.createElement(xe.Button,{className:Jc.button,onClick:B,bsSize:"sm"},"Cancel"))))))},kf=(0,c.default)(xe.ButtonGroup)` display: flex; justify-content: flex-end; `,Xg=(m,_)=>m.owner===(_==null?void 0:_.username)||(0,wc.rq)(_==null?void 0:_.permissions,[Yd.Edit(m.id)]),Em=m=>m&&m.additional&&m.additional.body&&m.additional.body.message?m.additional.body.message:m,Xf=()=>{var m;const _=Oc(),A=(0,To.Z)(),R=(0,Kc.Z)(),B=(0,t.useContext)(o),U=(0,Aa.Z)(),F=(0,t.useContext)(n),V=A&&A.id&&Xg(A,U),se=(0,t.useRef)(),[Se,Ae]=(0,t.useState)(!1),[Ee,Ze]=(0,t.useState)(!1),[je,ke]=(0,t.useState)(!1),[_t,Dt]=(0,t.useState)(!1),[jt,Pt]=(0,t.useState)(!1),Yt=(m=A==null?void 0:A.title)!=null?m:"",Ht=(0,sn.Z)(),qt=(0,t.useCallback)(io=>Ht((0,We.NK)(io)),[Ht]),pn=R===!1,tn=!(_||pn),on=_?"Unsaved changes":pn?"Saved search":"Save search",so=(0,Fc.Z)(),yn=(0,yr.Z)(),lo=(0,t.useCallback)(()=>Ae(io=>!io),[]),Sn=(0,t.useCallback)(()=>Ae(!1),[]),ro=(0,t.useCallback)(()=>Ae(!0),[]),Io=(0,t.useCallback)(()=>Ze(io=>!io),[]),rr=(0,t.useCallback)(()=>ke(io=>!io),[]),Qo=(0,t.useCallback)(()=>Dt(io=>!io),[]),ba=(0,t.useCallback)(()=>Pt(io=>!io),[]),BE=(0,Fn.Z)("views.components.searchActions"),lu=(0,t.useMemo)(()=>BE.map(({component:io,key:Cr})=>t.createElement(io,{key:Cr,loaded:pn,view:A})),[BE,pn,A]),Bi=(0,t.useCallback)(async io=>{if(!A.id)return;const Cr=A.toBuilder().title(io).type(Rt.Z.Type.Search).build();await Ht((0,om.Z)(Cr)),Sn(),await Ht((0,We.fV)(Cr))},[Sn,Ht,A]),sa=(0,t.useCallback)(async io=>{if(!io||io==="")return;const Ui=(await nm(A,U.permissions,so)).toBuilder().newId().title(io).type(Rt.Z.Type.Search).build();qr.T.create(Ui).then(es=>(lo(),es)).then(es=>{B(es.id)}).then(()=>Ao.Z.success(`Saving view "${Ui.title}" was successful!`,"Success!")).catch(es=>Ao.Z.error(`Saving view failed: ${Em(es)}`,"Error!"))},[U.permissions,so,lo,A,B]),Bm=(0,t.useCallback)(io=>qr.T.delete(io).then(()=>Ao.Z.success(`Deleting view "${io.title}" was successful!`,"Success!")).then(()=>(io.id===A.id&&(0,sr.OD)(yn),Promise.resolve())).catch(Cr=>Ao.Z.error(`Deleting view failed: ${Em(Cr)}`,"Error!")),[yn,A.id]),iu=(0,t.useCallback)(()=>{(0,sr._D)(yn,A)},[yn,A]);return(0,dn.Z)({actionKey:"save",callback:()=>pn?Bi(on):ro(),scope:"search",dependencies:[pn,Bi,on]}),(0,dn.Z)({actionKey:"save-as",callback:()=>ro(),scope:"search"}),t.createElement(kf,{"aria-label":"Search Meta Buttons"},t.createElement(rm,{title:on,ref:se,onClick:lo}),Se&&t.createElement(Qg,{target:se.current,saveSearch:Bi,saveAsSearch:sa,isCreateNew:R||!V,toggleModal:lo,value:Yt}),t.createElement(xe.Button,{title:"Load a previously saved search",onClick:Io},t.createElement(H.JO,{name:"folder",type:"regular"})," Load"),Ee&&t.createElement(Gf,{deleteSavedSearch:Bm,toggleModal:Io,activeSavedSearchId:A.id}),t.createElement(H.Tz,{entityType:"search",entityId:A.id,onClick:ba,bsStyle:"default",disabledInfo:R&&"Only saved searches can be shared."}),t.createElement(xe.DropdownButton,{title:t.createElement(H.JO,{name:"ellipsis-h"}),"aria-label":"Open search actions dropdown",id:"search-actions-dropdown",pullRight:!0,noCaret:!0},t.createElement(xe.MenuItem,{onSelect:Qo,disabled:!V,icon:"edit"},"Edit metadata"),t.createElement(Dg.Z,{permissions:"dashboards:create"},t.createElement(xe.MenuItem,{onSelect:iu,icon:"tachometer-alt"},"Export to dashboard")),t.createElement(xe.MenuItem,{onSelect:rr,icon:"cloud-download-alt"},"Export"),t.createElement(xe.MenuItem,{disabled:tn,onSelect:F,icon:"eraser"},"Reset search"),lu.length>0?t.createElement(t.Fragment,null,t.createElement(xe.MenuItem,{divider:!0}),lu):null),je&&t.createElement(si,{view:A,closeModal:rr}),_t&&t.createElement(Oi.Z,{show:!0,view:A,title:"Editing saved search",submitButtonText:"Update search",onClose:Qo,onSave:qt}),jt&&t.createElement(Zc.Z,{entityId:A.id,entityType:"search",entityTitle:A.title,description:"Search for a User or Team to add as collaborator on this saved search.",onClose:ba}))},Jg=(0,Oe.P1)(et.vz,m=>ot.OrderedMap(m.map(_=>[_.id,_]))),Yg=()=>(0,nt.Z)(Jg),qg=()=>{const m=Yg();return(0,t.useMemo)(()=>m.map(_=>_.filter).toMap(),[m])},eE=c.default.div` display: flex; gap: ${Po.V}; flex: 1.5; `,fm={onSubmit:async(m,_,A,R)=>{const{timerange:B,streams:U,queryString:F}=_,se=(await $a(m,_,A,R)).toBuilder().timerange(B).filter((0,as.en)(U)).query((0,as.Eg)(F)).build();return R.equals(se)?m((0,qo.ht)()):m((0,We.rh)(se.id,se))}},tE=(0,ls.Z)(Er,350),Yf=({currentQuery:m,queryFilters:_})=>{const{id:A,query:R,timerange:B}=m!=null?m:{},{query_string:U}=R!=null?R:{},F=Ka(m),V=(0,as.Fp)(_.get(A,ot.Map())).toJS();return{timerange:B,streams:V,queryString:U,...F}},nE=(m,_,A,R)=>{const B={timeRange:m==null?void 0:m.timerange,streams:m==null?void 0:m.streams,queryString:m==null?void 0:m.queryString,...ha(m,R,_)};return tE(B,A)},qc=({onSubmit:m=fm.onSubmit})=>{var _;const A=(0,d.o)(oo.h,({streams:_t})=>_t.map(Dt=>({key:Dt.title,value:Dt.id}))),{searchesClusterConfig:R}=(0,d.o)(Wo.s),{userTimezone:B}=(0,Ys.Z)(),{parameters:U}=Dr(),F=(0,qe.Z)(),V=qg(),se=(0,Fn.Z)("views.components.searchBar"),Se=Yf({queryFilters:V,currentQuery:F}),Ae=(0,sn.Z)(),Ee=(0,t.useCallback)(_t=>m(Ae,_t,se,F),[F,Ae,m,se]),Ze=Os();if(!F||!R)return t.createElement(H.$j,null);const{query:je}=F,ke=(_=rs().duration(R.query_time_range_limit).asSeconds())!=null?_:0;return t.createElement(Ie.Z.Consumer,null,({focusedWidget:{editing:_t}={editing:!1}})=>t.createElement(cg,{value:je.query_string},t.createElement(Qr,null,t.createElement(us,{initialValues:Se,limitDuration:ke,onSubmit:Ee,validateQueryString:Dt=>nE(Dt,se,B,Ze)},({dirty:Dt,errors:jt,isSubmitting:Pt,isValid:Yt,isValidating:Ht,handleSubmit:qt,values:pn,setFieldValue:tn,validateForm:wn})=>{const on=Pt||Ht||!Yt;return t.createElement(t.Fragment,null,t.createElement(Ea,{parameters:U}),t.createElement(Po.Vi,null,t.createElement(Po.Fy,null,t.createElement(vr.Z,{limitDuration:ke,onChange:so=>tn("timerange",so),value:pn==null?void 0:pn.timerange,hasErrorOnMount:!!jt.timerange}),t.createElement(eE,null,t.createElement(yt.Field,{name:"streams"},({field:{name:so,value:yn,onChange:lo}})=>t.createElement(ka,{value:yn,streams:A,onChange:Sn=>lo({target:{value:Sn,name:so}})})),t.createElement(Qd,null))),t.createElement(Po.dD,null,t.createElement(Po.hF,null,t.createElement(q,{disabled:on,dirty:Dt,displaySpinner:Pt}),t.createElement(Po.M8,null,t.createElement(yt.Field,{name:"queryString"},({field:{name:so,value:yn,onChange:lo},meta:{error:Sn}})=>t.createElement(Fs.Consumer,null,({warnings:ro})=>t.createElement(hr,{usage:"search_query"},Io=>t.createElement(tt,{value:yn,timeRange:pn.timerange,streams:pn.streams,name:so,onChange:lo,placeholder:'Type your search query here and press enter. E.g.: ("not found" AND http) OR http_response_code:[400 TO 404]',error:Sn,isValidating:Ht,warning:ro.queryString,disableExecution:on,validate:wn,onExecute:qt,commands:Io})))),t.createElement(kr,null))),!_t&&t.createElement(Xf,null)),t.createElement(Ql,null)))}))))};qc.propTypes={onSubmit:a().func},qc.defaultProps=fm;const oE=qc;var Mi=e("brbjQOmY"),hm=e("5CYElDLi");const eh=({children:m})=>{const _=(0,Mi.Z)(),{highlightMessage:A}=_!=null?_:{};return A?t.createElement(hm.Z.Provider,{value:A.toString()},m):m};var sE=e("cFn5u42x");const th="",vm={type:"relative",from:300},ym=({children:m})=>{const _=(0,qe.Z)(),A=(0,t.useMemo)(()=>(0,as.Fp)(_==null?void 0:_.filter).toArray(),[_==null?void 0:_.filter]),{data:R,refetch:B}=(0,No.Z)(A,(_==null?void 0:_.timerange)||vm),{data:U,refetch:F}=(0,No.Z)([],(_==null?void 0:_.timerange)||vm),V=(0,t.useMemo)(()=>ot.Map({[(_==null?void 0:_.id)||th]:ot.List(R)}),[R,_==null?void 0:_.id]),se=(0,t.useMemo)(()=>ot.List(U!=null?U:[]),[U]),Se=(0,t.useMemo)(()=>({all:se,queryFields:V}),[se,V]);return(0,sE.Z)(()=>{B(),F()}),t.createElement(bn.Z.Provider,{value:Se},m)};ym.propTypes={children:a().node.isRequired};const eu=ym;var rE=e("dogTzS57");const aE=()=>(0,nt.Z)(rE.e),_m=({children:m})=>{const _=aE();return _?t.createElement(dt.Z.Provider,{value:_},m):m};_m.propTypes={children:a().node.isRequired};const lE=_m;var tu=e("lN93Sbbu"),Cm=e("CXwqYNRt");const Tm={[Rt.Z.Type.Dashboard]:"dashboardSidebarIsPinned",[Rt.Z.Type.Search]:"searchSidebarIsPinned"},cl=m=>{const _=m&&Tm[m];if(!_)throw new Error(`User sidebar pinning preference key is missing for view type ${m!=null?m:"(type not provided)"}`);return _},xs=(m,_,A)=>{const R=cl(A);return m!=null&&m.readOnly?Xa.Z.get(R):_[R]},nu=(m,_,A,R)=>{const B=cl(A);if(m!=null&&m.readOnly)Xa.Z.set(B,R);else{const U={..._,[B]:R};Cm.p.saveUserPreferences(m==null?void 0:m.username,U,void 0,!1)}},iE=({children:m})=>{const _=(0,Aa.Z)(),A=(0,t.useContext)(tu.Z),R=(0,Ce.Z)(),[B,U]=(0,t.useState)({sidebarIsPinned:xs(_,A,R)}),F=(0,t.useCallback)(Se=>nu(_,A,R,Se),[_,A,R]),V=(0,t.useCallback)((Se,Ae)=>{var Ee;return(Ee=B[Se])!=null?Ee:Ae},[B]),se=(0,t.useCallback)((Se,Ae)=>{Se==="sidebarIsPinned"&&F(Ae),U({...B,[Se]:Ae})},[F,B]);return m({getPreference:V,setPreference:se})},cE=({getPreference:m,setPreference:_,children:A})=>{const R=(0,t.useMemo)(()=>{const B={sidebar:{isPinned:m("sidebarIsPinned",!1)}};return{config:B,actions:{toggleSidebarPinning:()=>_("sidebarIsPinned",!B.sidebar.isPinned)}}},[m,_]);return t.createElement(y.Provider,{value:R},A)},uE=({children:m})=>t.createElement(iE,null,({getPreference:_,setPreference:A})=>t.createElement(cE,{getPreference:_,setPreference:A},m));var dE=e("+KM7MH1U"),ul=e.n(dE);const Sm=m=>new(Gc())(m).removeSearch("focusing").removeSearch("editing").removeSearch("focusedId"),oh=(m,_)=>{let A=Sm(_);return m&&(m.id&&(m.focusing||m.editing)&&(A=A.setSearch("focusedId",m.id)),m.focusing&&(A=A.setSearch("focusing",String(!0))),m.editing&&(A=A.setSearch("editing",String(!0)))),A.toString()},Am={editing:!1,focusing:!1,id:void 0},ou=({focusedWidget:m,focusUriParams:_,setFocusedWidget:A,widgetIds:R})=>{const B=(0,sn.Z)();(0,t.useEffect)(()=>{const U={id:_.id,editing:_.editing,focusing:_.focusing||_.editing};if(!ul()(m!=null?m:Am,U)){if(_.id&&!R.includes(_.id))return;A(U);const F=U!=null&&U.id?[U.id]:void 0;B((0,qo.Gd)(F)),B((0,qo.ht)())}},[m,A,R,_,B])},sh=({focusUriParams:m,widgetIds:_,query:A,history:R})=>{(0,t.useEffect)(()=>{if(m!=null&&m.id&&!_.includes(m.id)&&m.isPageShown||(m==null?void 0:m.id)===void 0){const B=Sm(A);R.replace(B.toString())}},[m,_,A,R])},su=({children:m})=>{const{search:_,pathname:A}=(0,L.Z)(),R=A+_,B=(0,yr.Z)(),[U,F]=(0,t.useState)(),V=qa(),se=(0,t.useMemo)(()=>V.map(Pt=>Pt.id).toArray(),[V]),Se=(0,T.Z)(),Ae=(0,Mi.Z)(),Ee=(0,t.useMemo)(()=>({editing:Ae.editing==="true",focusing:Ae.focusing==="true",id:Ae.focusedId,isPageShown:!Ae.page||Ae.page===Se}),[Ae.editing,Ae.focusing,Ae.focusedId,Ae.page,Se]);ou({focusedWidget:U,setFocusedWidget:F,widgetIds:se,focusUriParams:Ee}),sh({focusUriParams:Ee,widgetIds:se,query:R,history:B});const Ze=(0,t.useCallback)(Pt=>{const Yt=oh(Pt,R);B.replace(Yt)},[B,R]),je=(0,t.useCallback)(Pt=>Ze({id:Pt,editing:!1,focusing:!0}),[Ze]),ke=(0,t.useCallback)(()=>Ze(void 0),[Ze]),_t=(0,t.useCallback)(Pt=>{Ze({id:Pt,editing:!0,focusing:Ee.focusing})},[Ee.focusing,Ze]),Dt=(0,t.useCallback)(()=>Ze({id:Ee.focusing&&Ee.id?Ee.id:void 0,editing:!1,focusing:Ee.focusing}),[Ee.focusing,Ee.id,Ze]),jt=(0,t.useMemo)(()=>({focusedWidget:U,setWidgetFocusing:je,setWidgetEditing:_t,unsetWidgetEditing:Dt,unsetWidgetFocusing:ke}),[U,je,_t,Dt,ke]);return t.createElement(Ie.Z.Provider,{value:jt},m)};su.propTypes={children:a().node.isRequired};const Pm=su,rh=m=>{const{type:_}=m,A={rangetype:_},R=B=>Object.entries(B);switch(m.type){case"relative":return(0,Ri.a_)(m)?R({...A,relative:m.range}):(0,Ri.SP)(m)?"to"in m?R({...A,from:m.from,to:m.to}):R({...A,from:m.from}):R(A);case"keyword":return R({...A,keyword:m.keyword});case"absolute":return R({...A,from:m.from,to:m.to});default:return Object.entries(A)}},bm=(m,_,A,R)=>{if(m===Rt.Z.Type.Search&&A){const{query:{query_string:B},timerange:U,filter:F=ot.Map()}=A,V=new(Gc())(_).setSearch("q",B).removeQuery("from").removeQuery("to").removeQuery("keyword").removeQuery("relative"),se=rh(U).reduce((Ee,[Ze,je])=>Ee.setSearch(Ze,String(je)),V),Se=(0,as.Fp)(F),Ae=Se.isEmpty()?se.removeSearch("streams").toString():se.setSearch("streams",Se.join(",")).toString();_!==Ae&&R(Ae)}},mE=m=>{const _=(0,Ce.Z)(),A=(0,qe.Z)(),R=(0,yr.Z)();(0,t.useEffect)(()=>bm(_,m,A,R.replace),[]),(0,t.useEffect)(()=>bm(_,m,A,R.push),[A,R.push,m,_])};var pE=e("2eB4xxdN");const dl=m=>(_,A)=>{const R=(0,et.fv)(A()),B=(0,Be.nR)(A());(0,pE.Z)({view:R,query:m,retry:()=>Promise.resolve(),executionState:B})},gE=m=>{const _=(0,sn.Z)();(0,t.useEffect)(()=>{_(dl(m))},[m])},EE=({location:m})=>{const{pathname:_,search:A}=m,R=`${_}${A}`;return gE(m.query),mE(R),null},fE=(0,Co.Z)(EE);var hE=e("Tqc935YZ");const vE=()=>{const m=(0,Fn.Z)("useExternalActions"),_=(0,t.useMemo)(()=>m&&typeof m[0]=="function"?m[0]:()=>hE.Q,[m]),{isLoading:A,externalValueActions:R,isError:B}=_();return(0,t.useMemo)(()=>({isLoading:A,isError:B,externalValueActions:R}),[R,B,A])},ru=({children:m})=>{const _=vE();return t.createElement(hE.Z.Provider,{value:_},m)};ru.propTypes={children:a().node.isRequired};const yE=ru,ah=c.default.div(({$interactive:m})=>m?(0,c.css)` display: flex; overflow: auto; height: 100%; > *:nth-child(2) { flex-grow: 1; } `:(0,c.css)` flex: 1; `),_E=(0,c.default)(v.Z)(()=>{const{focusedWidget:m}=(0,t.useContext)(Ie.Z);return(0,c.css)` ${(m==null?void 0:m.id)&&(0,c.css)` .page-content-grid { display: flex; flex-direction: column; height: 100%; width: 100%; /* overflow auto is required to display the message table widget height correctly */ overflow: ${m!=null&&m.id?"auto":"visible"}; } `} `}),lh=m=>{const _=(0,nt.Z)(et.Ln);return t.createElement(Sr,{results:_,...m})},Dm=({children:m})=>{var _;const A=(0,To.Z)(),{searchesClusterConfig:R}=(_=(0,d.o)(Wo.s))!=null?_:{},{parameters:B,parameterBindings:U}=Dr(),F=(0,Aa.Z)(),V=(0,t.useMemo)(()=>({view:A,analysisDisabledFields:R==null?void 0:R.analysis_disabled_fields,currentUser:F,parameters:B,parameterBindings:U}),[F,U,B,R==null?void 0:R.analysis_disabled_fields,A]);return t.createElement(Kr.v.Provider,{value:V},m)};Dm.displayName="ViewAdditionalContextProvider";const ih=m=>{(0,t.useEffect)(()=>So.e.refresh.listen(()=>{So.e.refresh.promise(m())}),[m])},Om=({InfoBarSlot:m,SearchAreaContainer:_})=>{const A=(0,sn.Z)(),R=(0,t.useCallback)(()=>A((0,qo.ht)()),[A]),{sidebar:{isShown:B}}=em();return(0,t.useEffect)(()=>{R()},[R]),ih(R),(0,t.useEffect)(()=>{Wo.q.refresh(),oo.s.refresh()},[]),t.createElement(t.Fragment,null,t.createElement(fE,null),t.createElement(yE,null,t.createElement(Pm,null,t.createElement(Ie.Z.Consumer,null,({focusedWidget:{focusing:U,editing:F}={focusing:!1,editing:!1}})=>t.createElement(t.Fragment,null,t.createElement(ol.Z,null,t.createElement(Bo,null,t.createElement(Ld,null))),t.createElement(Qe.Z.Consumer,null,V=>t.createElement(uE,null,t.createElement(eu,null,t.createElement(Dm,null,t.createElement(lE,null,t.createElement(ah,{id:"main-row",$interactive:V},t.createElement(ol.Z,null,B&&t.createElement(lh,null,t.createElement(zd,null))),t.createElement(_E,{as:_},t.createElement(ol.Z,null,t.createElement(xd,null),m&&t.createElement(m,null),t.createElement(Bo,null,!F&&t.createElement(bg,null)),t.createElement(ks.Z,null,t.createElement(oE,null)),t.createElement(Pp,null),t.createElement(Bo,null,!U&&t.createElement(Qp,null))),t.createElement(eh,null,t.createElement(Sp,null))))))))))))))};Om.defaultProps={InfoBarSlot:void 0,SearchAreaContainer:void 0};const ch=Om;var CE=e("gvNRgdyu"),uh=e("/W/x1zfW");const TE=()=>t.createElement(H.$4,{title:"No stream permissions."},t.createElement(v.Z,null,t.createElement(uh.Z,{title:"No stream permissions."}),t.createElement(xe.Row,{className:"content"},t.createElement(xe.Col,{md:12},t.createElement(xe.Alert,{bsStyle:"warning"},"We cannot start a search right now, because you are not allowed to access any stream. If you feel this is an error, please contact your administrator."))))),SE=({children:m})=>{const _=(0,t.useContext)(CE.Z);return _&&_.length>0?m:t.createElement(TE,null)};var Rm=e("yAXMqwrl");const au=m=>new(Gc())(m).removeSearch("page"),AE=(m,_)=>{const A=au(_);return m?A.setSearch("page",m).toString():A.toString()},Im=({dashboardPage:m,uriParams:_,setDashboardPage:A})=>{const R=(0,nt.Z)(et.RM),B=(0,sn.Z)();(0,t.useEffect)(()=>{const U=_.page;R!=null&&R.has(U)?U!==m&&(A(U),B((0,We.xM)(U))):A(void 0)},[_.page,m,A,R,B])},PE=({uriParams:m,query:_,navigate:A})=>{(0,t.useEffect)(()=>{if((m==null?void 0:m.page)===void 0){const R=au(_);A(R.toString(),{replace:!0})}},[_,A,m==null?void 0:m.page])},bE=({children:m})=>{const{search:_,pathname:A}=(0,Rm.useLocation)(),R=A+_,B=(0,Rm.useNavigate)(),[U,F]=(0,t.useState)(),V=(0,Mi.Z)(),se=(0,t.useMemo)(()=>({page:V.page}),[V]);Im({dashboardPage:U,uriParams:se,setDashboardPage:F}),PE({uriParams:se,query:R,navigate:B});const Se=(0,t.useMemo)(()=>{const Ae=je=>{const ke=AE(je,R);B(ke,{replace:!0})};return{setDashboardPage:je=>Ae(je),unsetDashboardPage:()=>Ae(void 0),dashboardPage:U}},[U,B,R]);return t.createElement(Ai.Provider,{value:Se},m)};var DE=e("m5sCWlWB");const Mm=m=>((!m||!(m instanceof Array)||m.length<2)&&console.error("Return value supplied by processing hook is not array with two elements. It is: ",JSON.stringify(m,null,2)),m),xi=(m,_)=>m.reduce((A,R)=>A.then(Mm).then(([B,U])=>R({..._,view:B,executionState:U})),Promise.resolve([_.view,_.executionState])),Li=(m,_,A,R,B)=>{let U;return m.length>0?U=xi(m,{view:_,retry:V=>{var se,Se;const Ae=(se=V.view)!=null?se:_,Ee=(Se=V.executionState)!=null?Se:R;return Li(m,Ae,A,Ee,B)},query:A,executionState:R}):U=Promise.resolve([_,R]),U.then(Mm).then(async([F,V])=>(await B(F,V),[F,V]))},OE=(m,_,A=[],R=[],B={},U=()=>{})=>m.then(F=>Li(A,F,B,_,U)).then(([F,V])=>Li(R,F,B,V,U)),RE=({error:m})=>((0,t.useEffect)(()=>{console.log(m)},[m]),t.createElement(DE.Z,{title:"Something went wrong",description:t.createElement("p",null,"An unknown error has occurred. Please have a look at the following message and the graylog server log for more information.")},t.createElement("pre",null,m==null?void 0:m.message))),xm=(m,_,A)=>{const R=(0,Fn.Z)("views.hooks.loadingView"),B=(0,Fn.Z)("views.hooks.executingView"),[U,F]=(0,t.useState)({status:"loading"});return(0,t.useEffect)(()=>{OE(m,_,R,B,A,(V,se)=>{F({status:"loaded",view:V,executionState:se})}).catch(V=>{V instanceof Error&&console.error(V);const se=V instanceof Error?t.createElement(RE,{error:V}):V;F({status:"interrupted",component:se})})},[B,R,m]),U};var IE=e("NqeDg39C"),ME=e("oMyijaIY");const xE=({children:m})=>{const _=(0,ye.Z)();return t.createElement(H.$4,{title:_},m)},Lm=({children:m,isNew:_,view:A,loadNewView:R=sr.Wf,loadView:B=sr.fV,executionState:U,SearchComponentSlots:F,SearchAreaContainer:V})=>{const se=(0,Mi.Z)(),Se=se==null?void 0:se.page,Ae=(0,yr.Z)(),Ee=(0,t.useCallback)(()=>R(Ae),[R,Ae]),Ze=(0,t.useCallback)(Dt=>B(Ae,Dt),[B,Ae]),je=xm(A,U,se);if(je.status==="loading")return t.createElement(H.$j,null);if(je.status==="interrupted")return je.component;const{view:ke,executionState:_t}=je;return ke?t.createElement(IE.Z,{view:ke,executionState:_t,isNew:_,initialQuery:Se},t.createElement(xE,null,t.createElement(bE,null,t.createElement(n.Provider,{value:Ee},t.createElement(o.Provider,{value:Ze},m,t.createElement(SE,null,t.createElement(ch,{InfoBarSlot:F.InfoBarSlot,SearchAreaContainer:V}))))))):t.createElement(H.$j,null)};Lm.defaultProps={loadNewView:sr.Wf,loadView:sr.fV,executionState:ME.ZP.empty(),SearchComponentSlots:{},SearchAreaContainer:void 0};const LE=t.memo(Lm)},r4MY1c4i:(M,C,e)=>{"use strict";e.r(C),e.d(C,{default:()=>f});var t=e("Z7aTuO5B"),s=e("6dLKCZdN"),o=e("62FDaRYn"),r=e("iSSis/Yq"),n=e("/coHI+Jz"),c=e("Y/YOqMWf"),v=e("UmnljV2q");function d(y){const T=v.Z.fromJSON(y);return(0,c.Z)(y.search_id).then(P=>n.Z.fromJSON(P)).then(P=>T.toBuilder().search(P).build())}var g=e("9tc+dS6Z");const E=y=>{const T=(0,t.useMemo)(()=>r.T.get(y),[y]);return(0,t.useMemo)(()=>T.then(P=>d(P),P=>{throw P.status===404&&o.Z.report((0,g.W6)(P)),P}),[T])};var a=e("VcneZdh2");const f=({children:y})=>{const{viewId:T}=(0,s.Z)();if(!T)throw new Error("No view id specified!");const P=E(T);return t.createElement(a.Z,{view:P,isNew:!1},y)}},"gFL+I+yc":(M,C,e)=>{"use strict";e.d(C,{V:()=>d,e:()=>v});var t=e("JnTtTRmZ"),s=e.n(t),o=e("9oVghaOd"),r=e.n(o),n=e("IA3Ku5lS"),c=e("PYFLluwn");const v=(0,n.ei)("views.Refresh",()=>s().createActions({enable:{asyncResult:!0},disable:{asyncResult:!0},setInterval:{asyncResult:!0},refresh:{asyncResult:!0}})),d=(0,n.dS)("views.Refresh",()=>s().createStore({listenables:[v],refreshConfig:{},defaultInterval:void 0,intervalId:void 0,init(){this.listenTo(c.s,this.onDefaultIntervalChange,this.onDefaultIntervalChange),this.refreshConfig={enabled:!1}},onDefaultIntervalChange(g){var p;((p=g==null?void 0:g.searchesClusterConfig)==null?void 0:p.default_auto_refresh_option)!==this.defaultInterval&&(this.defaultInterval=g.searchesClusterConfig.default_auto_refresh_option)},getInitialState(){return this.refreshConfig},_scheduleRefresh(){if(this.intervalId&&clearInterval(this.intervalId),this.refreshConfig.enabled){const{interval:g}=this.refreshConfig;return setTimeout(async()=>{await v.refresh(),this.intervalId=this._scheduleRefresh()},g)}},setInterval(g){this.refreshConfig={interval:g,enabled:!0},this.intervalId=this._scheduleRefresh(),this._trigger()},enable(){var g;this.refreshConfig={interval:(g=this.refreshConfig.interval)!=null?g:r().duration(this.defaultInterval).asMilliseconds(),enabled:!0},this.intervalId=this._scheduleRefresh(),this._trigger()},disable(){this.refreshConfig={...this.refreshConfig,enabled:!1},this.intervalId=this._scheduleRefresh(),this._trigger()},_trigger(){const{enabled:g,interval:p}=this.refreshConfig;this.trigger({enabled:g,interval:p})}}))},PYFLluwn:(M,C,e)=>{"use strict";e.d(C,{q:()=>n,s:()=>c});var t=e("JnTtTRmZ"),s=e.n(t),o=e("IA3Ku5lS"),r=e("ibdPvtmL");const n=(0,o.ei)("views.SearchConfig",()=>s().createActions({refresh:{asyncResult:!0}})),c=(0,o.dS)("views.SearchConfig",()=>s().createStore({listenables:[n],init(){this.refresh()},getInitialState(){return this._state()},refresh(){r.h.listSearchesClusterConfig().then(v=>{this.searchesClusterConfig=v,this._trigger()})},_state(){return{searchesClusterConfig:this.searchesClusterConfig}},_trigger(){this.trigger(this._state())}}))},Cd4wX32x:(M,C,e)=>{"use strict";e.d(C,{h:()=>v,s:()=>c});var t=e("JnTtTRmZ"),s=e.n(t),o=e("IA3Ku5lS"),r=e("pUKP3+Pg"),n=e("pc+thvZE");const c=(0,o.ei)("views.Streams",()=>s().createActions(["refresh"])),v=(0,o.dS)("views.Streams",()=>s().createStore({listenables:[c],streams:[],init(){this.refresh(),n.SessionActions.logout.completed.listen(()=>this.clear())},getInitialState(){return this._state()},refresh(){r.ZP.listStreams().then(d=>{this.streams=d,this._trigger()})},clear(){this.streams=[],this._trigger()},_state(){return{streams:this.streams}},_trigger(){this.trigger(this._state())}}))},i0LZga0C:(M,C,e)=>{"use strict";e.d(C,{Z:()=>s});const s={Tab:"tab",Widget:"widget"}},"iSSis/Yq":(M,C,e)=>{"use strict";e.d(C,{T:()=>d});var t=e("JnTtTRmZ"),s=e.n(t),o=e("eFxcQyPT"),r=e("jAGDuYSC"),n=e("MdYBRjRJ"),c=e("IA3Ku5lS"),v=e("J1ga+jW6");const d=(0,c.ei)("views.ViewManagement",()=>s().createActions({create:{asyncResult:!0},delete:{asyncResult:!0},forValue:{asyncResult:!0},get:{asyncResult:!0},search:{asyncResult:!0},update:{asyncResult:!0}})),g=(0,n.DC)("/views"),p=u=>(0,n.DC)(`/views/${u}`),E=()=>(0,n.DC)("/views/forValue"),a=(0,c.dS)("views.ViewManagement",()=>s().createStore({listenables:[d],views:void 0,pagination:{total:0,count:0,page:1,perPage:10},getInitialState(){return{pagination:this.pagination,list:this.views}},get(u){const f=(0,o.ZP)("GET",`${g}/${u}`);return d.get.promise(f),f},create(u){const f=(0,o.ZP)("POST",g,JSON.stringify(u));return d.create.promise(f),f},createCompleted(){return v.D.reload()},update(u){const f=(0,o.ZP)("PUT",p(u.id),JSON.stringify(u));return d.update.promise(f),f},search(u,f=1,y=10,T="title",P="asc"){const O=(0,o.ZP)("GET",`${g}?query=${u}&page=${f}&per_page=${y}&sort=${T}&order=${P}`).then(b=>(this.views=b.views,this.pagination={total:b.total,count:b.count,page:b.page,perPage:b.per_page},this.trigger({list:this.views,pagination:this.pagination}),b)).catch(b=>{r.Z.error(`Fetching views failed with status: ${b}`,"Could not retrieve views")});d.search.promise(O)},delete(u){const f=(0,o.ZP)("DELETE",p(u.id)).catch(y=>{r.Z.error(`Deleting view ${u.title} failed with status: ${y}`,"Could not delete view")});d.delete.promise(f)},forValue(){const u=(0,o.ZP)("POST",E()).catch(f=>r.Z.error(`Finding matching views for value failed with status: ${f}`,"Could not find matching views"));d.forValue.promise(u)}}))},zAtQmw72:(M,C,e)=>{"use strict";e.d(C,{Z:()=>E});var t=e("1twFHSbl"),s=e.n(t),o=e("87D/Fijl"),r=e.n(o);const n=(a,u)=>a&&a[u]&&r()(a[u]),c=a=>n(a,"equals"),v=a=>n(a,"equalsForSearch"),d=a=>n(a,"toJS"),g=(a,u)=>{if(v(a))return a.equalsForSearch(u);if(d(a)&&d(u))return s()(a.toJS(),u.toJS(),g);if(c(a))return a.equals(u)},E=(a,u)=>s()(a,u,g)},PwTFiGSp:(M,C,e)=>{"use strict";e.d(C,{SP:()=>c,a_:()=>n,j9:()=>d,je:()=>v,o0:()=>g,ow:()=>r,yH:()=>o});var t=e("+KM7MH1U"),s=e.n(t);const o=p=>"type"in p&&p.type==="absolute",r=p=>"type"in p&&p.type==="relative",n=p=>r(p)&&"range"in p,c=p=>r(p)&&"from"in p,v=p=>"type"in p&&p.type==="keyword",d=p=>p!==void 0&&s()(p,{}),g=p=>p&&"type"in p},gToK60tD:(M,C,e)=>{"use strict";e.d(C,{j7:()=>t,ContentStream:()=>s,Xj:()=>o,VE:()=>r,T8:()=>n,Cd:()=>c,bn:()=>v,M0:()=>d});var t={};e.r(t),e.d(t,{byNamespace:()=>mt,metricNames:()=>lt,multipleMetrics:()=>Be});var s={};e.r(s),e.d(s,{getContentStreamTags:()=>Gt,getContentStreamUserSettings:()=>de,setContentStreamUserSettings:()=>pt});var o={};e.r(o),e.d(o,{suggestFieldValue:()=>mr});var r={};e.r(r),e.d(r,{assignToIndexSet:()=>Za,bulkDelete:()=>Ml,bulkPause:()=>kr,bulkResume:()=>ga,cloneStream:()=>ls,create:()=>Wa,get:()=>wa,getBystreamId:()=>Fa,getEnabled:()=>Na,getPage:()=>Qr,pause:()=>Xr,remove:()=>Dr,resume:()=>Ds,testMatch:()=>is,update:()=>xl});var n={};e.r(n),e.d(n,{changeFieldType:()=>Gs,getAllFieldTypes:()=>js});var c={};e.r(c),e.d(c,{list:()=>Qi,rebuild:()=>Xi,rebuildIndex:()=>Rr,rebuildIndexSet:()=>Xl,show:()=>Ji});var v={};e.r(v),e.d(v,{fieldTypeSummaries:()=>Mr});var d={};e.r(d),e.d(d,{get:()=>ud,getTelemetryUserSettings:()=>yc,saveTelemetryUserSettings:()=>nl});var g=e("pjsNBHWI"),p=e.n(g),E=e("eFxcQyPT"),a=e("MdYBRjRJ");const f=(S,X,qe,Bt,Wt)=>{const Rn=Object.entries(Bt).length>0?`${X}?${p().stringify(Bt)}`:X,go=new E.Ib(S,a.DC(Rn)).json(qe);return Object.entries(Wt).reduce((vi,[xr,Sa])=>vi.setHeader(xr,Sa),go).build()};function y(){return __request__("GET","/aws/available_services",null,{},{Accept:["application/json"]})}function T(S){return __request__("POST","/aws/cloudwatch/log_groups",S,{},{Accept:["application/json"]})}function P(S){return __request__("POST","/aws/inputs",S,{},{Accept:["application/json"]})}function O(S){return __request__("POST","/aws/kinesis/health_check",S,{},{Accept:["application/json"]})}function b(S){return __request__("POST","/aws/kinesis/streams",S,{},{Accept:["application/json"]})}function L(){return __request__("GET","/aws/permissions",null,{},{Accept:["application/json"]})}function x(){return __request__("GET","/aws/regions",null,{},{Accept:["application/json"]})}function W(){return __request__("PUT","/config",null,{},{Accept:["application/json"]})}function N(S){return __request__("POST","/aws/kinesis/auto_setup/create_stream",S,{},{Accept:["application/json"]})}function Z(S){return __request__("POST","/aws/kinesis/auto_setup/create_subscription",S,{},{Accept:["application/json"]})}function j(S){return __request__("POST","/aws/kinesis/auto_setup/create_subscription_policy",S,{},{Accept:["application/json"]})}function z(){return __request__("GET","/authz/grants-overview",null,{},{Accept:["application/json"]})}function ne(S="name",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/authz/roles",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function Y(S="name",X,qe=1,Bt=50,Wt,Rn="asc"){return __request__("GET",`/authz/roles/user/${X}`,null,{page:qe,per_page:Bt,query:Wt,sort:S,order:Rn},{Accept:["application/json"]})}function ae(S){return __request__("GET",`/authz/roles/${S}`,null,{},{Accept:["application/json"]})}function ee(S){return __request__("DELETE",`/authz/roles/${S}`,null,{},{Accept:["application/json"]})}function ue(S,X){return __request__("DELETE",`/authz/roles/${S}/assignee/${X}`,null,{},{Accept:["application/json"]})}function H(S="name",X,qe=1,Bt=50,Wt,Rn="asc"){return __request__("GET",`/authz/roles/${X}/assignees`,null,{page:qe,per_page:Bt,query:Wt,sort:S,order:Rn},{Accept:["application/json"]})}function ye(S,X){return __request__("PUT",`/authz/roles/${S}/assignees`,X,{},{Accept:["application/json"]})}function we(S,X){return __request__("POST",`/authz/shares/entities/${S}`,X,{},{Accept:["application/json"]})}function ut(S,X){return __request__("POST",`/authz/shares/entities/${S}/prepare`,X,{},{Accept:["application/json"]})}function ht(S,X,qe,Bt){return __request__("GET",`/authz/shares/user/${S}`,X,{capability:qe,entity_type:Bt},{Accept:["application/json"]})}function Je(){return __request__("GET","/cluster",null,{},{Accept:["application/json"]})}function Re(){return __request__("GET","/cluster/processbufferdump",null,{},{Accept:["application/json"]})}function le(S){return __request__("GET",`/cluster/${S}/jvm`,null,{},{Accept:["application/json"]})}function me(S){return __request__("GET",`/cluster/${S}/processbufferdump`,null,{},{Accept:["application/json"]})}function re(S){return __request__("GET",`/cluster/${S}/threaddump`,null,{},{Accept:["application/json"]})}function ce(){return __request__("POST","/cluster/debug/support/bundle/build",null,{},{Accept:["application/json"]})}function Q(S){return __request__("GET",`/cluster/debug/support/bundle/download/${S}`,null,{},{Accept:["application/octet-stream"]})}function J(){return __request__("GET","/cluster/debug/support/bundle/list",null,{},{Accept:["application/json"]})}function ie(S){return __request__("DELETE",`/cluster/debug/support/bundle/${S}`,null,{},{Accept:["application/json"]})}function ge(){return __request__("GET","/cluster/debug/support/manifest",null,{},{Accept:["application/json"]})}function fe(){return __request__("POST","/cluster/deflector/cycle",null,{},{Accept:["application/json"]})}function Ce(S){return __request__("POST",`/cluster/deflector/${S}/cycle`,null,{},{Accept:["application/json"]})}function Oe(){return __request__("GET","/cluster/inputstates",null,{},{Accept:["application/json"]})}function nt(S){return __request__("PUT",`/cluster/inputstates/${S}`,null,{},{Accept:["application/json"]})}function et(S){return __request__("DELETE",`/cluster/inputstates/${S}`,null,{},{Accept:["application/json"]})}function Fe(){return __request__("GET","/cluster/jobs",null,{},{Accept:["application/json"]})}function Pe(S){return __request__("GET",`/cluster/jobs/${S}`,null,{},{Accept:["application/json"]})}function $e(S){return __request__("DELETE",`/cluster/jobs/${S}`,null,{},{Accept:["application/json"]})}function Ot(S){return __request__("GET",`/cluster/${S}/journal`,null,{},{Accept:["application/json"]})}function ft(S,X){return __request__("PUT",`/cluster/${S}/lbstatus/override/${X}`,null,{},{Accept:["application/json"]})}function Tt(S,X){return __request__("POST",`/cluster/system/lookup/tables/${S}/purge`,null,{key:X},{Accept:["application/json"]})}function Lt(S){return __request__("POST","/cluster/metrics/multiple",S,{},{Accept:["application/json"]})}function Be(S,X){return f("POST",`/cluster/${S}/metrics/multiple`,X,{},{Accept:["application/json"]})}function lt(S){return f("GET",`/cluster/${S}/metrics/names`,null,{},{Accept:["application/json"]})}function mt(S,X){return f("GET",`/cluster/${S}/metrics/namespace/${X}`,null,{},{Accept:["application/json"]})}function Rt(S){return __request__("GET",`/cluster/${S}/plugins`,null,{},{Accept:["application/json"]})}function zt(S){return __request__("POST",`/cluster/${S}/processing/pause`,null,{},{Accept:["application/json"]})}function xt(S){return __request__("POST",`/cluster/${S}/processing/resume`,null,{},{Accept:["application/json"]})}function nn(){return __request__("GET","/cluster/processing/status",null,{},{Accept:["application/json"]})}function Vt(){return __request__("GET","/cluster/processing/status/persisted",null,{},{Accept:["application/json"]})}function jn(){return __request__("GET","/cluster/system/loggers",null,{},{Accept:["application/json"]})}function Mt(S,X=1e3){return __request__("GET",`/cluster/system/loggers/messages/recent/${S}`,null,{limit:X},{Accept:["text/plain"]})}function On(){return __request__("GET","/cluster/system/loggers/subsystems",null,{},{Accept:["application/json"]})}function rt(S,X){return __request__("PUT",`/cluster/system/loggers/${S}/level/${X}`,null,{},{Accept:["application/json"]})}function Bn(S,X,qe){return __request__("PUT",`/cluster/system/loggers/${S}/subsystems/${X}/level/${qe}`,null,{},{Accept:[]})}function de(S){return f("GET",`/contentstream/settings/${S}`,null,{},{Accept:["application/json"]})}function pt(S,X){return f("PUT",`/contentstream/settings/${X}`,S,{},{Accept:["application/json"]})}function Gt(){return f("GET","/contentstream/tags",null,{},{Accept:["application/json"]})}function gn(S="title",X=1,qe=50,Bt="asc",Wt,Rn){return __request__("GET","/dashboards",null,{page:X,per_page:qe,sort:S,order:Bt,query:Wt,filters:Rn},{Accept:["application/json"]})}function Jt(S){return __request__("GET",`/datanodes/request/${S}`,null,{},{Accept:["application/json"]})}function An(S){return __request__("POST",`/datanodes/request/${S}`,null,{},{Accept:["application/json"]})}function xe(S){return __request__("PUT",`/datanodes/request/${S}`,null,{},{Accept:["application/json"]})}function Pn(S){return __request__("DELETE",`/datanodes/request/${S}`,null,{},{Accept:["application/json"]})}function sn(){return __request__("GET","/api-docs",null,{},{Accept:["application/json"]})}function no(){return __request__("GET","/api-docs/global",null,{},{Accept:["application/json"]})}function Co(S){return __request__("GET",`/api-docs/${S}`,null,{},{Accept:["application/json"]})}function Go(){return __request__("GET","/enterprise/license/info",null,{},{Accept:["application/json"]})}function Mo(S){return __request__("GET",`/entitylists/preferences/${S}`,null,{},{Accept:["application/json"]})}function jo(S,X){return __request__("POST",`/entitylists/preferences/${X}`,S,{},{Accept:[]})}function Zt(){return __request__("GET","/entity_scopes",null,{},{Accept:["application/json"]})}function Me(S,X="title",qe=1,Bt=10,Wt){return __request__("GET","/entity_suggestions",null,{collection:S,column:X,page:qe,per_page:Bt,query:Wt},{Accept:["application/json"]})}function Ye(S){return __request__("POST","/events/search",S,{},{Accept:["application/json"]})}function Ke(S){return __request__("GET",`/events/${S}`,null,{},{Accept:["application/json"]})}function dt(S=1,X=50,qe){return __request__("GET","/events/definitions",null,{page:S,per_page:X,query:qe},{Accept:["application/json"]})}function it(S=!0,X){return __request__("POST","/events/definitions",X,{schedule:S},{Accept:["application/json"]})}function gt(S){return __request__("POST","/events/definitions/bulk_delete",S,{},{Accept:["application/json"]})}function It(S){return __request__("POST","/events/definitions/bulk_schedule",S,{},{Accept:["application/json"]})}function ot(S){return __request__("POST","/events/definitions/bulk_unschedule",S,{},{Accept:["application/json"]})}function yt(S="title",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/events/definitions/paginated",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function Xt(S){return __request__("POST","/events/definitions/validate",S,{},{Accept:["application/json"]})}function rn(S){return __request__("GET",`/events/definitions/${S}`,null,{},{Accept:["application/json"]})}function Cn(S,X=!0,qe){return __request__("PUT",`/events/definitions/${S}`,qe,{schedule:X},{Accept:["application/json"]})}function bn(S){return __request__("DELETE",`/events/definitions/${S}`,null,{},{Accept:["application/json"]})}function hn(S){return __request__("PUT",`/events/definitions/${S}/clear-notification-queue`,null,{},{Accept:["application/json"]})}function ao(S){return __request__("POST",`/events/definitions/${S}/duplicate`,null,{},{Accept:["application/json"]})}function Xn(S,X){return __request__("POST",`/events/definitions/${X}/execute`,S,{},{Accept:["application/json"]})}function vo(S){return __request__("PUT",`/events/definitions/${S}/schedule`,null,{},{Accept:["application/json"]})}function Kn(S){return __request__("PUT",`/events/definitions/${S}/unschedule`,null,{},{Accept:["application/json"]})}function Jn(S){return __request__("GET",`/events/definitions/${S}/with-context`,null,{},{Accept:["application/json"]})}function Wn(){return __request__("GET","/events/entity_types",null,{},{Accept:["application/json"]})}function bo(S=1,X=50,qe){return __request__("GET","/events/notifications",null,{page:S,per_page:X,query:qe},{Accept:["application/json"]})}function ds(S){return __request__("POST","/events/notifications",S,{},{Accept:["application/json"]})}function zo(){return __request__("GET","/events/notifications/legacy/types",null,{},{Accept:["application/json"]})}function Xo(S="title",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/events/notifications/paginated",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function Do(S){return __request__("POST","/events/notifications/test",S,{},{Accept:["application/json"]})}function Jo(S){return __request__("GET",`/events/notifications/${S}`,null,{},{Accept:["application/json"]})}function Zo(S,X){return __request__("PUT",`/events/notifications/${S}`,X,{},{Accept:["application/json"]})}function yo(S){return __request__("DELETE",`/events/notifications/${S}`,null,{},{Accept:["application/json"]})}function Vo(S){return __request__("POST",`/events/notifications/${S}/test`,null,{},{Accept:["application/json"]})}function _s(S){return __request__("GET",`/system/inputs/${S}/extractors`,null,{},{Accept:["application/json"]})}function Cs(S,X){return __request__("POST",`/system/inputs/${S}/extractors`,X,{},{Accept:["application/json"]})}function ms(S,X){return __request__("POST",`/system/inputs/${S}/extractors/order`,X,{},{Accept:[]})}function Yn(S,X){return __request__("DELETE",`/system/inputs/${S}/extractors/${X}`,null,{},{Accept:["application/json"]})}function xo(S,X,qe){return __request__("PUT",`/system/inputs/${S}/extractors/${X}`,qe,{},{Accept:["application/json"]})}function Ls(S,X){return __request__("GET",`/system/inputs/${S}/extractors/${X}`,null,{},{Accept:["application/json"]})}function Vs(S=1,X=5,qe){return __request__("GET","/favorites",null,{page:S,per_page:X,type:qe},{Accept:["application/json"]})}function Bs(S){return __request__("PUT",`/favorites/${S}`,null,{},{Accept:["application/json"]})}function Ts(S){return __request__("DELETE",`/favorites/${S}`,null,{},{Accept:["application/json"]})}function Us(){return __request__("GET","/views/fields",null,{},{Accept:["application/json"]})}function ws(S){return __request__("POST","/views/fields",S,{},{Accept:["application/json"]})}function Lo(){return __request__("GET","/",null,{},{Accept:["application/json"]})}function co(){return __request__("GET","/system/indexer/cluster/health",null,{},{Accept:["application/json"]})}function ns(){return __request__("GET","/system/indexer/cluster/name",null,{},{Accept:["application/json"]})}function os(S,X){return __request__("GET","/system/indexer/failures",null,{limit:S,offset:X},{Accept:["application/json"]})}function Ws(S){return __request__("GET","/system/indexer/failures/count",null,{since:S},{Accept:["application/json"]})}function ps(){return __request__("GET","/system/indexer/indices",null,{},{Accept:["application/json"]})}function Tr(){return __request__("GET","/system/indexer/indices/closed",null,{},{Accept:["application/json"]})}function Ns(S){return __request__("POST","/system/indexer/indices/multiple",S,{},{Accept:["application/json"]})}function gs(){return __request__("GET","/system/indexer/indices/open",null,{},{Accept:["application/json"]})}function Ho(){return __request__("GET","/system/indexer/indices/reopened",null,{},{Accept:["application/json"]})}function Yo(S){return __request__("GET",`/system/indexer/indices/${S}/closed`,null,{},{Accept:["application/json"]})}function te(S){return __request__("GET",`/system/indexer/indices/${S}/list`,null,{},{Accept:["application/json"]})}function Te(S){return __request__("GET",`/system/indexer/indices/${S}/open`,null,{},{Accept:["application/json"]})}function Le(S){return __request__("GET",`/system/indexer/indices/${S}/reopened`,null,{},{Accept:["application/json"]})}function st(S){return __request__("GET",`/system/indexer/indices/${S}`,null,{},{Accept:["application/json"]})}function St(S){return __request__("DELETE",`/system/indexer/indices/${S}`,null,{},{Accept:["application/json"]})}function $t(S){return __request__("POST",`/system/indexer/indices/${S}/close`,null,{},{Accept:["application/json"]})}function cn(S){return __request__("POST",`/system/indexer/indices/${S}/reopen`,null,{},{Accept:["application/json"]})}function In(){return __request__("GET","/system/indexer/indices/templates",null,{},{Accept:["application/json"]})}function Mn(){return __request__("POST","/system/indexer/indices/templates/update",null,{},{Accept:["application/json"]})}function Zn(S){return __request__("GET",`/system/indexer/indices/templates/${S}`,null,{},{Accept:["application/json"]})}function qn(S){return __request__("POST",`/system/indexer/indices/templates/${S}/update`,null,{},{Accept:["application/json"]})}function be(){return __request__("GET","/system/indexer/overview",null,{},{Accept:["application/json"]})}function ze(S){return __request__("GET",`/system/indexer/overview/${S}`,null,{},{Accept:["application/json"]})}function Ve(S,X,qe,Bt,Wt,Rn,go=500,No){return __request__("GET","/search/universal/absolute",null,{query:S,from:X,to:qe,limit:Wt,offset:Rn,batch_size:go,filter:No,fields:Bt},{Accept:["text/csv"]})}function We(S,X,qe,Bt,Wt,Rn,go,No,vi=!0){return __request__("GET","/search/universal/absolute",null,{query:S,from:X,to:qe,limit:Bt,offset:Wt,filter:Rn,fields:go,sort:No,decorate:vi},{Accept:["application/json"]})}function vt(S,X,qe,Bt,Wt,Rn,go=500,No){return __request__("GET","/search/universal/absolute/export",null,{query:S,from:X,to:qe,limit:Wt,offset:Rn,batch_size:go,filter:No,fields:Bt},{Accept:["text/csv"]})}function Et(S,X,qe,Bt,Wt,Rn=500,go){return __request__("GET","/search/universal/keyword",null,{query:S,keyword:X,limit:Bt,offset:Wt,batch_size:Rn,filter:go,fields:qe},{Accept:["text/csv"]})}function At(S,X,qe,Bt,Wt,Rn,go,No=!0){return __request__("GET","/search/universal/keyword",null,{query:S,keyword:X,limit:qe,offset:Bt,filter:Wt,fields:Rn,sort:go,decorate:No},{Accept:["application/json"]})}function Ct(S,X,qe,Bt,Wt,Rn=500,go){return __request__("GET","/search/universal/keyword/export",null,{query:S,keyword:X,limit:Bt,offset:Wt,batch_size:Rn,filter:go,fields:qe},{Accept:["text/csv"]})}function Kt(S,X,qe,Bt,Wt,Rn=500,go){return __request__("GET","/search/universal/relative",null,{query:S,range:X,limit:Bt,offset:Wt,batch_size:Rn,filter:go,fields:qe},{Accept:["text/csv"]})}function en(S,X,qe,Bt,Wt,Rn,go,No=!0){return __request__("GET","/search/universal/relative",null,{query:S,range:X,limit:qe,offset:Bt,filter:Wt,fields:Rn,sort:go,decorate:No},{Accept:["application/json"]})}function dn(S,X,qe,Bt,Wt,Rn=500,go){return __request__("GET","/search/universal/relative/export",null,{query:S,range:X,limit:Bt,offset:Wt,batch_size:Rn,filter:go,fields:qe},{Accept:["text/csv"]})}function En(S){return __request__("POST","/messages/parse",S,{},{Accept:["application/json"]})}function xn(S,X,qe){return __request__("GET",`/messages/${S}/analyze`,null,{analyzer:qe,string:X},{Accept:["application/json"]})}function zn(S,X){return __request__("GET",`/messages/${S}/${X}`,null,{},{Accept:["application/json"]})}function fn(){return __request__("GET","/system/pipelines/connections",null,{},{Accept:["application/json"]})}function Dn(S){return __request__("POST","/system/pipelines/connections/to_pipeline",S,{},{Accept:["application/json"]})}function Hn(S){return __request__("POST","/system/pipelines/connections/to_stream",S,{},{Accept:["application/json"]})}function _o(S){return __request__("GET",`/system/pipelines/connections/${S}`,null,{},{Accept:["application/json"]})}function Ss(S){return __request__("POST","/system/pipelines/pipeline",S,{},{Accept:["application/json"]})}function As(){return __request__("GET","/system/pipelines/pipeline",null,{},{Accept:["application/json"]})}function Hs(S="title",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/system/pipelines/pipeline/paginated",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function Fo(S){return __request__("POST","/system/pipelines/pipeline/parse",S,{},{Accept:["application/json"]})}function uo(S){return __request__("GET",`/system/pipelines/pipeline/${S}`,null,{},{Accept:["application/json"]})}function De(S,X){return __request__("PUT",`/system/pipelines/pipeline/${X}`,S,{},{Accept:["application/json"]})}function ss(S){return __request__("DELETE",`/system/pipelines/pipeline/${S}`,null,{},{Accept:["application/json"]})}function Wr(S){return __request__("POST","/system/pipelines/rulebuilder",S,{},{Accept:["application/json"]})}function Sr(){return __request__("GET","/system/pipelines/rulebuilder/actions",null,{},{Accept:["application/json"]})}function ir(){return __request__("GET","/system/pipelines/rulebuilder/conditions",null,{},{Accept:["application/json"]})}function Ps(S){return __request__("POST","/system/pipelines/rulebuilder/simulate",S,{},{Accept:["application/json"]})}function Nr(S){return __request__("POST","/system/pipelines/rulebuilder/validate",S,{},{Accept:["application/json"]})}function cr(S,X){return __request__("PUT",`/system/pipelines/rulebuilder/${X}`,S,{},{Accept:["application/json"]})}function Bo(S){return __request__("POST","/system/pipelines/rule",S,{},{Accept:["application/json"]})}function ks(){return __request__("GET","/system/pipelines/rule",null,{},{Accept:["application/json"]})}function ia(){return __request__("GET","/system/pipelines/rule/config/metrics",null,{},{Accept:["application/json"]})}function Es(){return __request__("PUT","/system/pipelines/rule/config/metrics",null,{},{Accept:["application/json"]})}function Ar(){return __request__("GET","/system/pipelines/rule/functions",null,{},{Accept:["application/json"]})}function Ie(S){return __request__("POST","/system/pipelines/rule/multiple",S,{},{Accept:["application/json"]})}function Qe(S="title",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/system/pipelines/rule/paginated",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function bt(S){return __request__("POST","/system/pipelines/rule/parse",S,{},{Accept:["application/json"]})}function Ut(){return __request__("GET","/system/pipelines/rule/rulebuilder/conditions",null,{},{Accept:["application/json"]})}function Qt(){return __request__("GET","/system/pipelines/rule/rulebuilder/functions",null,{},{Accept:["application/json"]})}function un(S){return __request__("POST","/system/pipelines/rule/simulate",S,{},{Accept:["application/json"]})}function Ln(S){return __request__("GET",`/system/pipelines/rule/${S}`,null,{},{Accept:["application/json"]})}function Vn(S,X){return __request__("PUT",`/system/pipelines/rule/${X}`,S,{},{Accept:["application/json"]})}function vn(S){return __request__("DELETE",`/system/pipelines/rule/${S}`,null,{},{Accept:["application/json"]})}function Nn(S){return __request__("POST","/system/pipelines/simulate",S,{},{Accept:["application/json"]})}function Uo(){return __request__("GET","/roles",null,{},{Accept:["application/json"]})}function Ko(S){return __request__("POST","/roles",S,{},{Accept:["application/json"]})}function wo(S,X){return __request__("PUT",`/roles/${S}`,X,{},{Accept:["application/json"]})}function Oo(S){return __request__("GET",`/roles/${S}`,null,{},{Accept:["application/json"]})}function Zs(S){return __request__("DELETE",`/roles/${S}`,null,{},{Accept:["application/json"]})}function Qs(S){return __request__("GET",`/roles/${S}/members`,null,{},{Accept:["application/json"]})}function Fn(S,X){return __request__("DELETE",`/roles/${S}/members/${X}`,null,{},{Accept:["application/json"]})}function To(S,X,qe="{}"){return __request__("PUT",`/roles/${S}/members/${X}`,qe,{},{Accept:["application/json"]})}function Ro(S){return __request__("POST","/views/search",S,{},{Accept:["application/json","application/vnd.graylog.search.v1+json"]})}function fs(S){return __request__("POST","/views/search",S,{},{Accept:["application/vnd.graylog.search.v2+json"]})}function hs(){return __request__("GET","/views/search",null,{},{Accept:["application/json","application/vnd.graylog.search.v1+json"]})}function ur(S){return __request__("GET",`/views/search/status/${S}`,null,{},{Accept:["application/json","application/vnd.graylog.search.v1+json"]})}function Xs(S,X=6e4){return __request__("POST","/views/search/sync",S,{timeout:X},{Accept:["application/json","application/vnd.graylog.search.v1+json"]})}function gl(S,X=6e4){return __request__("POST","/views/search/sync",S,{timeout:X},{Accept:["application/vnd.graylog.search.v2+json"]})}function Zr(S){return __request__("GET",`/views/search/${S}`,null,{},{Accept:["application/json","application/vnd.graylog.search.v1+json"]})}function dr(S,X){return __request__("POST",`/views/search/${S}/execute`,X,{},{Accept:["application/json","application/vnd.graylog.search.v1+json"]})}function ca(){return __request__("GET","/search/decorators",null,{},{Accept:["application/json"]})}function Pr(S){return __request__("POST","/search/decorators",S,{},{Accept:["application/json"]})}function Js(){return __request__("GET","/search/decorators/available",null,{},{Accept:["application/json"]})}function Fr(S,X){return __request__("PUT",`/search/decorators/${S}`,X,{},{Accept:["application/json"]})}function Kr(S){return __request__("DELETE",`/search/decorators/${S}`,null,{},{Accept:["application/json"]})}function mo(S){return __request__("POST","/views/export",S,{},{Accept:[]})}function ua(S,X){return __request__("POST",`/views/export/${S}`,X,{},{Accept:[]})}function El(S,X,qe){return __request__("POST",`/views/export/${S}/${X}`,qe,{},{Accept:[]})}function Ni(S){return __request__("POST","/views/search/messages",S,{},{Accept:["text/csv"]})}function fl(S,X){return __request__("GET",`/views/search/messages/job/${S}/${X}`,null,{},{Accept:[]})}function Zi(S,X){return __request__("POST",`/views/search/messages/${S}`,X,{},{Accept:["text/csv"]})}function $r(S,X,qe){return __request__("POST",`/views/search/messages/${S}/${X}`,qe,{},{Accept:[]})}function Fi(S){return __request__("POST","/views/search/metadata",S,{},{Accept:["application/json"]})}function Ki(S){return __request__("GET",`/views/search/metadata/${S}`,null,{},{Accept:["application/json"]})}function $i(S="title",X=1,qe=50,Bt="asc",Wt,Rn){return __request__("GET","/search/saved",null,{page:X,per_page:qe,sort:S,order:Bt,query:Wt,filters:Rn},{Accept:["application/json"]})}function hl(S,X,qe,Bt,Wt){return __request__("GET","/search/aggregate",null,{query:S,streams:X,timerange:qe,groups:Bt,metrics:Wt},{Accept:[]})}function vs(S){return __request__("POST","/search/aggregate",S,{},{Accept:[]})}function So(S,X,qe,Bt,Wt,Rn,go,No){return __request__("GET","/search/messages",null,{query:S,streams:X,timerange:qe,fields:Bt,sort:Wt,sortOrder:Rn,from:go,size:No},{Accept:[]})}function Da(S){return __request__("POST","/search/messages",S,{},{Accept:[]})}function mr(S){return f("POST","/search/suggest",S,{},{Accept:["application/json"]})}function Ys(S){return __request__("POST","/search/validate",S,{},{Accept:["application/json"]})}function Oa(S="node_name",X=1,qe=50,Bt,Wt="asc",Rn=!1){return __request__("GET","/sidecars",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt,only_active:Rn},{Accept:["application/json"]})}function da(){return __request__("GET","/sidecars/all",null,{},{Accept:["application/json"]})}function vl(S){return __request__("PUT","/sidecars/configurations",S,{},{Accept:["application/json"]})}function yl(S){return __request__("GET",`/sidecars/${S}`,null,{},{Accept:["application/json"]})}function _l(S,X){return __request__("PUT",`/sidecars/${S}`,X,{},{Accept:["application/json"]})}function Cl(S){return __request__("POST","/sidecar/administration",S,{},{Accept:["application/json"]})}function Ra(S){return __request__("PUT","/sidecar/administration/action",S,{},{Accept:["application/json"]})}function Gi(S){return __request__("GET",`/sidecar/action/${S}`,null,{},{Accept:["application/json"]})}function pr(S,X){return __request__("PUT",`/sidecar/action/${S}`,X,{},{Accept:["application/json"]})}function Eu(){return __request__("GET","/sidecar/collectors",null,{},{Accept:["application/json"]})}function br(S){return __request__("POST","/sidecar/collectors",S,{},{Accept:["application/json"]})}function Tl(S="name",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/sidecar/collectors/summary",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function Sl(S){return __request__("POST","/sidecar/collectors/validate",S,{},{Accept:["application/json"]})}function fu(S){return __request__("GET",`/sidecar/collectors/${S}`,null,{},{Accept:["application/json"]})}function Al(S,X){return __request__("PUT",`/sidecar/collectors/${S}`,X,{},{Accept:["application/json"]})}function qs(S){return __request__("DELETE",`/sidecar/collectors/${S}`,null,{},{Accept:["application/json"]})}function ji(S,X){return __request__("POST",`/sidecar/collectors/${S}/${X}`,null,{},{Accept:["application/json"]})}function Pl(){return __request__("GET","/sidecar/configuration_variables",null,{},{Accept:["application/json"]})}function Ia(S){return __request__("POST","/sidecar/configuration_variables",S,{},{Accept:["application/json"]})}function Ao(S){return __request__("POST","/sidecar/configuration_variables/validate",S,{},{Accept:["application/json"]})}function bl(S,X){return __request__("PUT",`/sidecar/configuration_variables/${S}`,X,{},{Accept:["application/json"]})}function Dl(S){return __request__("DELETE",`/sidecar/configuration_variables/${S}`,null,{},{Accept:["application/json"]})}function hu(S){return __request__("GET",`/sidecar/configuration_variables/${S}/configurations`,null,{},{Accept:["application/json"]})}function zi(S="name",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/sidecar/configurations",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function er(S){return __request__("POST","/sidecar/configurations",S,{},{Accept:["application/json"]})}function rs(S){return __request__("POST","/sidecar/configurations/render/preview",S,{},{Accept:["application/json"]})}function tr(S,X){return __request__("GET",`/sidecar/configurations/render/${S}/${X}`,null,{},{Accept:["application/json"]})}function oo(S=1){return __request__("GET","/sidecar/configurations/uploads",null,{page:S},{Accept:["application/json"]})}function as(S){return __request__("POST","/sidecar/configurations/validate",S,{},{Accept:["application/json"]})}function Wo(S){return __request__("DELETE",`/sidecar/configurations/${S}`,null,{},{Accept:["application/json"]})}function bs(S,X){return __request__("PUT",`/sidecar/configurations/${S}`,X,{},{Accept:["application/json"]})}function ma(S){return __request__("GET",`/sidecar/configurations/${S}`,null,{},{Accept:["application/json"]})}function Gr(S){return __request__("GET",`/sidecar/configurations/${S}/sidecars`,null,{},{Accept:["application/json"]})}function Ol(S){return __request__("POST",`/sidecar/configurations/${S}/${name}`,null,{},{Accept:["application/json"]})}function jr(S=1,X=5){return __request__("GET","/startpage/lastOpened",null,{page:S,per_page:X},{Accept:["application/json"]})}function $o(S=1,X=5){return __request__("GET","/startpage/recentActivity",null,{page:S,per_page:X},{Accept:["application/json"]})}function zr(S,X){return __request__("POST",`/system/inputs/${S}/staticfields`,X,{},{Accept:["application/json"]})}function Fs(S,X){return __request__("DELETE",`/system/inputs/${X}/staticfields/${S}`,null,{},{Accept:["application/json"]})}function Ma(S,X){return __request__("POST",`/streams/${S}/outputs`,X,{},{Accept:["application/json"]})}function Vr(S){return __request__("GET",`/streams/${S}/outputs`,null,{},{Accept:["application/json"]})}function gr(S,X){return __request__("DELETE",`/streams/${S}/outputs/${X}`,null,{},{Accept:["application/json"]})}function Rl(S,X){return __request__("GET",`/streams/${S}/outputs/${X}`,null,{},{Accept:["application/json"]})}function Hr(S){return __request__("GET",`/streams/${S}/rules`,null,{},{Accept:["application/json"]})}function Il(S,X){return __request__("POST",`/streams/${S}/rules`,X,{},{Accept:["application/json"]})}function xa(S){return __request__("GET",`/streams/${S}/rules/types`,null,{},{Accept:["application/json"]})}function La(S,X){return __request__("GET",`/streams/${S}/rules/${X}`,null,{},{Accept:["application/json"]})}function Ba(S,X,qe){return __request__("PUT",`/streams/${S}/rules/${X}`,qe,{},{Accept:["application/json"]})}function pa(S,X){return __request__("DELETE",`/streams/${S}/rules/${X}`,null,{},{Accept:[]})}function Ua(){return __request__("GET","/streams/rules/inputs",null,{},{Accept:["application/json"]})}function wa(){return f("GET","/streams",null,{},{Accept:["application/json"]})}function Wa(S){return f("POST","/streams",S,{},{Accept:["application/json"]})}function Ml(S){return f("POST","/streams/bulk_delete",S,{},{Accept:[]})}function kr(S){return f("POST","/streams/bulk_pause",S,{},{Accept:[]})}function ga(S){return f("POST","/streams/bulk_resume",S,{},{Accept:[]})}function Na(){return f("GET","/streams/enabled",null,{},{Accept:["application/json"]})}function Za(S,X){return f("PUT",`/streams/indexSet/${S}`,X,{},{Accept:["application/json"]})}function Qr(S="title",X=1,qe=50,Bt,Wt,Rn="asc"){return f("GET","/streams/paginated",null,{page:X,per_page:qe,query:Bt,filters:Wt,sort:S,order:Rn},{Accept:["application/json"]})}function Fa(S){return f("GET",`/streams/${S}`,null,{},{Accept:["application/json"]})}function xl(S,X){return f("PUT",`/streams/${S}`,X,{},{Accept:["application/json"]})}function Dr(S){return f("DELETE",`/streams/${S}`,null,{},{Accept:[]})}function ls(S,X){return f("POST",`/streams/${S}/clone`,X,{},{Accept:["application/json"]})}function Xr(S){return f("POST",`/streams/${S}/pause`,null,{},{Accept:[]})}function Ds(S){return f("POST",`/streams/${S}/resume`,null,{},{Accept:[]})}function is(S,X){return f("POST",`/streams/${S}/testMatch`,X,{},{Accept:[]})}function Ll(){return __request__("GET","/system",null,{},{Accept:["application/json"]})}function Er(){return __request__("GET","/system/jvm",null,{},{Accept:["application/json"]})}function Bl(){return __request__("GET","/system/locales",null,{},{Accept:["application/json"]})}function Ea(){return __request__("GET","/system/processbufferdump",null,{},{Accept:["application/json"]})}function Ul(){return __request__("GET","/system/threaddump",null,{},{Accept:["application/json"]})}function fa(){return __request__("GET","/system/threaddump",null,{},{Accept:["text/plain"]})}function fr(){return __request__("PUT","/system/authentication/http-header-auth-config",null,{},{Accept:["application/json"]})}function wl(){return __request__("GET","/system/authentication/http-header-auth-config",null,{},{Accept:["application/json"]})}function Ka(){return __request__("GET","/system/authentication/services/active-backend",null,{},{Accept:["application/json"]})}function Wl(S){return __request__("GET","/system/authentication/services/backends",S,{},{Accept:["application/json"]})}function Or(S){return __request__("POST","/system/authentication/services/backends",S,{},{Accept:["application/json"]})}function $a(){return __request__("GET","/system/authentication/services/backends/active-backend/type",null,{},{Accept:["application/json"]})}function Nl(S){return __request__("GET",`/system/authentication/services/backends/${S}`,null,{},{Accept:["application/json"]})}function ha(S,X){return __request__("PUT",`/system/authentication/services/backends/${S}`,X,{},{Accept:["application/json"]})}function va(S){return __request__("DELETE",`/system/authentication/services/backends/${S}`,null,{},{Accept:["application/json"]})}function Po(S="full_name",X,qe=1,Bt=50,Wt,Rn="asc"){return __request__("GET",`/system/authentication/services/backends/${X}/users`,null,{page:qe,per_page:Bt,query:Wt,sort:S,order:Rn},{Accept:["application/json"]})}function Zl(){return __request__("GET","/system/authentication/services/configuration",null,{},{Accept:["application/json"]})}function Vi(S){return __request__("POST","/system/authentication/services/configuration",S,{},{Accept:["application/json"]})}function Fl(S){return __request__("POST","/system/authentication/services/test/backend/connection",S,{},{Accept:["application/json"]})}function Kl(S){return __request__("POST","/system/authentication/services/test/backend/login",S,{},{Accept:["application/json"]})}function hr(S){return __request__("POST","/system/catalog",S,{},{Accept:["application/json"]})}function qo(){return __request__("GET","/system/catalog",null,{},{Accept:["application/json"]})}function $l(S){return __request__("POST","/system/catalog/entities/titles",S,{},{Accept:["application/json"]})}function Ga(){return __request__("GET","/system/cluster/node",null,{},{Accept:["application/json"]})}function Os(){return __request__("GET","/system/cluster/nodes",null,{},{Accept:["application/json"]})}function Rs(S){return __request__("GET",`/system/cluster/nodes/${S}`,null,{},{Accept:["application/json"]})}function ja(){return __request__("GET","/system/cluster_config",null,{},{Accept:["application/json"]})}function Gl(S,X){return __request__("PUT",`/system/cluster_config/${S}`,X,{},{Accept:["application/json"]})}function za(S){return __request__("GET",`/system/cluster_config/${S}`,null,{},{Accept:["application/json"]})}function jl(S){return __request__("DELETE",`/system/cluster_config/${S}`,null,{},{Accept:["application/json"]})}function Va(S){return __request__("GET",`/system/cluster_config/${S}`,null,{},{Accept:["application/schema+json"]})}function ya(){return __request__("GET","/system/cluster/stats",null,{},{Accept:["application/json"]})}function vr(){return __request__("GET","/system/cluster/stats/elasticsearch",null,{},{Accept:["application/json"]})}function zl(){return __request__("GET","/system/cluster/stats/mongo",null,{},{Accept:["application/json"]})}function Ha(S=30,X=!1,qe=!0){return __request__("GET","/system/cluster/traffic",null,{days:S,daily:X,includeToday:qe},{Accept:["application/json"]})}function ka(){return __request__("GET","/system/codecs/types/all",null,{},{Accept:["application/json"]})}function Qa(){return __request__("GET","/system/configuration",null,{},{Accept:["application/json"]})}function k(S){return __request__("GET",`/system/configuration/${S}`,null,{},{Accept:["application/json"]})}function $(){return __request__("GET","/system/content_packs",null,{},{Accept:["application/json"]})}function q(S){return __request__("POST","/system/content_packs",S,{},{Accept:["application/json"]})}function Ne(){return __request__("GET","/system/content_packs/latest",null,{},{Accept:["application/json"]})}function Ge(S){return __request__("GET",`/system/content_packs/${S}`,null,{},{Accept:["application/json"]})}function tt(S){return __request__("DELETE",`/system/content_packs/${S}`,null,{},{Accept:["application/json"]})}function wt(S){return __request__("GET",`/system/content_packs/${S}/installations`,null,{},{Accept:["application/json"]})}function Un(S,X){return __request__("DELETE",`/system/content_packs/${S}/installations/${X}`,null,{},{Accept:["application/json"]})}function Tn(S,X){return __request__("GET",`/system/content_packs/${S}/installations/${X}/uninstall_details`,null,{},{Accept:["application/json"]})}function kn(S,X){return __request__("GET",`/system/content_packs/${S}/${X}`,null,{},{Accept:["application/json"]})}function Eo(S,X){return __request__("DELETE",`/system/content_packs/${S}/${X}`,null,{},{Accept:["application/json"]})}function eo(S,X){return __request__("GET",`/system/content_packs/${S}/${X}/download`,null,{},{Accept:["application/json"]})}function fo(S,X,qe){return __request__("POST",`/system/content_packs/${S}/${X}/installations`,qe,{},{Accept:["application/json"]})}function to(S="Cluster Test"){return __request__("POST","/system/debug/events/cluster",S,{},{Accept:["application/json"]})}function cs(){return __request__("GET","/system/debug/events/cluster",null,{},{Accept:["application/json"]})}function us(S="Local Test"){return __request__("POST","/system/debug/events/local",S,{},{Accept:["application/json"]})}function Is(){return __request__("GET","/system/debug/events/local",null,{},{Accept:["application/json"]})}function nr(){return __request__("GET","/system/debug/streams/router_engine_info",null,{},{Accept:["application/json"]})}function or(S){return __request__("GET",`/system/debug/support/bundle/download/${S}`,null,{},{Accept:["application/octet-stream"]})}function po(){return __request__("GET","/system/debug/support/bundle/list",null,{},{Accept:["application/json"]})}function Ks(S){return __request__("DELETE",`/system/debug/support/bundle/${S}`,null,{},{Accept:["application/json"]})}function ho(S){return __request__("GET",`/system/debug/support/logfile/${S}`,null,{},{Accept:["application/octet-stream"]})}function Ms(){return __request__("GET","/system/debug/support/manifest",null,{},{Accept:["application/json"]})}function Jr(){return __request__("GET","/system/deflector",null,{},{Accept:["application/json"]})}function Vl(){return __request__("POST","/system/deflector/cycle",null,{},{Accept:[]})}function Hl(S){return __request__("GET",`/system/deflector/${S}`,null,{},{Accept:["application/json"]})}function $s(S){return __request__("POST",`/system/deflector/${S}/cycle`,null,{},{Accept:[]})}function Gs(S){return f("PUT","/system/indices/mappings",S,{},{Accept:["application/json"]})}function js(){return f("GET","/system/indices/mappings/types",null,{},{Accept:["application/json"]})}function kl(S){return __request__("GET","/system/fields",null,{limit:S},{Accept:["application/json"]})}function vu(){return __request__("GET","/system/gettingstarted",null,{},{Accept:["application/json"]})}function Xa(){return __request__("POST","/system/gettingstarted/dismiss",null,{},{Accept:["application/json"]})}function yu(){return __request__("GET","/system/grok",null,{},{Accept:["application/json"]})}function Hi(S){return __request__("POST","/system/grok",S,{},{Accept:["application/json"]})}function ki(S,X){return __request__("PUT","/system/grok",S,{"import-strategy":X},{Accept:["application/json"]})}function _u(S,X){return __request__("POST","/system/grok",S,{"import-strategy":X},{Accept:["application/json"]})}function Cu(S="name",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/system/grok/paginated",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function Hm(S){return __request__("POST","/system/grok/test",S,{},{Accept:["application/json"]})}function _a(S){return __request__("GET",`/system/grok/${S}`,null,{},{Accept:["application/json"]})}function Ql(S,X){return __request__("PUT",`/system/grok/${S}`,X,{},{Accept:["application/json"]})}function Tu(S){return __request__("DELETE",`/system/grok/${S}`,null,{},{Accept:["application/json"]})}function Qi(){return f("GET","/system/indices/ranges",null,{},{Accept:["application/json"]})}function Xl(S){return f("POST",`/system/indices/ranges/index_set/${S}/rebuild`,null,{},{Accept:["application/json"]})}function Xi(){return f("POST","/system/indices/ranges/rebuild",null,{},{Accept:["application/json"]})}function Rr(S){return f("POST",`/system/indices/ranges/${S}/rebuild`,null,{},{Accept:["application/json"]})}function Ji(S){return f("GET",`/system/indices/ranges/${S}`,null,{},{Accept:["application/json"]})}function Su(S){return __request__("PUT","/system/indices/index_set_defaults",S,{},{Accept:["application/json"]})}function Yi(S=0,X=0,qe=!1){return __request__("GET","/system/indices/index_sets",null,{skip:S,limit:X,stats:qe},{Accept:["application/json"]})}function Au(S){return __request__("POST","/system/indices/index_sets",S,{},{Accept:["application/json"]})}function Pu(S=0,X=0,qe,Bt=!1){return __request__("GET","/system/indices/index_sets/search",null,{searchTitle:qe,skip:S,limit:X,stats:Bt},{Accept:["application/json"]})}function qi(){return __request__("GET","/system/indices/index_sets/stats",null,{},{Accept:["application/json"]})}function bu(S){return __request__("GET",`/system/indices/index_sets/${S}`,null,{},{Accept:["application/json"]})}function Du(S,X){return __request__("PUT",`/system/indices/index_sets/${S}`,X,{},{Accept:["application/json"]})}function Ir(S,X=!0){return __request__("DELETE",`/system/indices/index_sets/${S}`,null,{delete_indices:X},{Accept:["application/json"]})}function Jl(S){return __request__("PUT",`/system/indices/index_sets/${S}/default`,null,{},{Accept:["application/json"]})}function Ja(S){return __request__("GET",`/system/indices/index_sets/${S}/stats`,null,{},{Accept:["application/json"]})}function Mr(S,X="index_set_id",qe=1,Bt=50,Wt="asc"){return f("POST","/system/indices/index_sets/types",S,{page:qe,per_page:Bt,sort:X,order:Wt},{Accept:["application/json"]})}function km(){return __request__("GET","/system/indices/retention/strategies",null,{},{Accept:["application/json"]})}function Yl(S){return __request__("GET",`/system/indices/retention/strategies/${S}`,null,{},{Accept:["application/json"]})}function ec(){return __request__("GET","/system/indices/rotation/strategies",null,{},{Accept:["application/json"]})}function Ou(S){return __request__("GET",`/system/indices/rotation/strategies/${S}`,null,{},{Accept:["application/json"]})}function tc(){return __request__("GET","/system/inputstates",null,{},{Accept:["application/json"]})}function Ru(S){return __request__("GET",`/system/inputstates/${S}`,null,{},{Accept:["application/json"]})}function Ya(S){return __request__("PUT",`/system/inputstates/${S}`,null,{},{Accept:["application/json"]})}function Iu(S){return __request__("DELETE",`/system/inputstates/${S}`,null,{},{Accept:["application/json"]})}function Qm(){return __request__("GET","/system/inputs",null,{},{Accept:["application/json"]})}function qa(S){return __request__("POST","/system/inputs",S,{},{Accept:["application/json"]})}function Mu(S){return __request__("DELETE",`/system/inputs/${S}`,null,{},{Accept:["application/json"]})}function xu(S){return __request__("GET",`/system/inputs/${S}`,null,{},{Accept:["application/json"]})}function Lu(S,X){return __request__("PUT",`/system/inputs/${X}`,S,{},{Accept:["application/json"]})}function ql(){return __request__("GET","/system/inputs/types",null,{},{Accept:["application/json"]})}function Bu(){return __request__("GET","/system/inputs/types/all",null,{},{Accept:["application/json"]})}function ei(S){return __request__("GET",`/system/inputs/types/${S}`,null,{},{Accept:["application/json"]})}function Uu(S){return __request__("POST","/system/jobs",S,{},{Accept:["application/json"]})}function wu(){return __request__("GET","/system/jobs",null,{},{Accept:["application/json"]})}function Wu(S){return __request__("DELETE",`/system/jobs/acknowledge/${S}`,null,{},{Accept:[]})}function nc(S){return __request__("GET",`/system/jobs/${S}`,null,{},{Accept:["application/json"]})}function Nu(S){return __request__("DELETE",`/system/jobs/${S}`,null,{},{Accept:["application/json"]})}function Xm(){return __request__("GET","/system/journal",null,{},{Accept:["application/json"]})}function Ca(){return __request__("GET","/system/lbstatus",null,{},{Accept:["text/plain"]})}function Jm(S){return __request__("PUT",`/system/lbstatus/override/${S}`,null,{},{Accept:["application/json"]})}function Zu(){return __request__("GET","/system/loggers",null,{},{Accept:["application/json"]})}function Ym(S=1e3){return __request__("GET","/system/loggers/messages/recent",null,{limit:S},{Accept:["text/plain"]})}function Fu(){return __request__("GET","/system/loggers/subsystems",null,{},{Accept:["application/json"]})}function Ku(S,X){return __request__("PUT",`/system/loggers/subsystems/${S}/level/${X}`,null,{},{Accept:[]})}function qm(S,X){return __request__("PUT",`/system/loggers/${S}/level/${X}`,null,{},{Accept:[]})}function $u(S="title",X=1,qe=50,Bt="desc",Wt){return __request__("GET","/system/lookup/adapters",null,{page:X,per_page:qe,sort:S,order:Bt,query:Wt},{Accept:["application/json"]})}function Gu(S){return __request__("POST","/system/lookup/adapters",S,{},{Accept:["application/json"]})}function ep(S){return __request__("POST","/system/lookup/adapters/validate",S,{},{Accept:["application/json"]})}function oc(S){return __request__("DELETE",`/system/lookup/adapters/${S}`,null,{},{Accept:["application/json"]})}function Ta(S,X){return __request__("PUT",`/system/lookup/adapters/${S}`,X,{},{Accept:["application/json"]})}function Yr(S){return __request__("GET",`/system/lookup/adapters/${S}`,null,{},{Accept:["application/json"]})}function ju(S,X){return __request__("GET",`/system/lookup/adapters/${S}/query`,null,{key:X},{Accept:["application/json"]})}function sc(S="title",X=1,qe=50,Bt="desc",Wt){return __request__("GET","/system/lookup/caches",null,{page:X,per_page:qe,sort:S,order:Bt,query:Wt},{Accept:["application/json"]})}function zs(S){return __request__("POST","/system/lookup/caches",S,{},{Accept:["application/json"]})}function ti(S){return __request__("POST","/system/lookup/caches/validate",S,{},{Accept:["application/json"]})}function ni(S){return __request__("DELETE",`/system/lookup/caches/${S}`,null,{},{Accept:["application/json"]})}function zu(S,X){return __request__("PUT",`/system/lookup/caches/${S}`,X,{},{Accept:["application/json"]})}function oi(S){return __request__("GET",`/system/lookup/caches/${S}`,null,{},{Accept:["application/json"]})}function Vu(S){return __request__("POST","/system/lookup/errorstates",S,{},{Accept:["application/json"]})}function Hu(S="title",X=1,qe=50,Bt="desc",Wt,Rn=!1){return __request__("GET","/system/lookup/tables",null,{page:X,per_page:qe,sort:S,order:Bt,query:Wt,resolve:Rn},{Accept:["application/json"]})}function tp(S){return __request__("POST","/system/lookup/tables",S,{},{Accept:["application/json"]})}function ku(S){return __request__("POST","/system/lookup/tables/validate",S,{},{Accept:["application/json"]})}function Qu(S,X){return __request__("PUT",`/system/lookup/tables/${S}`,X,{},{Accept:["application/json"]})}function np(S){return __request__("DELETE",`/system/lookup/tables/${S}`,null,{},{Accept:["application/json"]})}function Xu(S,X=!1){return __request__("GET",`/system/lookup/tables/${S}`,null,{resolve:X},{Accept:["application/json"]})}function Ju(S,X){return __request__("POST",`/system/lookup/tables/${S}/purge`,null,{key:X},{Accept:["application/json"]})}function Yu(S,X){return __request__("GET",`/system/lookup/tables/${S}/query`,null,{key:X},{Accept:["application/json"]})}function qu(){return __request__("GET","/system/lookup/types/adapters",null,{},{Accept:["application/json"]})}function rc(){return __request__("GET","/system/lookup/types/caches",null,{},{Accept:["application/json"]})}function ac(S){return __request__("PUT","/system/messageprocessors/config",S,{},{Accept:["application/json"]})}function si(){return __request__("GET","/system/messageprocessors/config",null,{},{Accept:["application/json"]})}function ed(S){return __request__("GET","/system/messages",null,{page:S},{Accept:["application/json"]})}function ri(){return __request__("GET","/system/metrics",null,{},{Accept:["application/json"]})}function lc(S){return __request__("POST","/system/metrics/multiple",S,{},{Accept:[]})}function el(){return __request__("GET","/system/metrics/names",null,{},{Accept:["application/json"]})}function ai(S){return __request__("GET",`/system/metrics/namespace/${S}`,null,{},{Accept:["application/json"]})}function td(S){return __request__("GET",`/system/metrics/${S}`,null,{},{Accept:["application/json"]})}function li(S,X){return __request__("POST",`/system/notification/message/html/${S}`,X,{},{Accept:["application/json"]})}function nd(S,X,qe){return __request__("POST",`/system/notification/message/html/${S}/${X}`,qe,{},{Accept:["application/json"]})}function od(S,X){return __request__("POST",`/system/notification/message/plaintext/${S}`,X,{},{Accept:["application/json"]})}function ic(S,X,qe){return __request__("POST",`/system/notification/message/plaintext/${S}/${X}`,qe,{},{Accept:["application/json"]})}function sd(){return __request__("GET","/system/notifications",null,{},{Accept:["application/json"]})}function rd(S){return __request__("DELETE",`/system/notifications/${S}`,null,{},{Accept:["application/json"]})}function sr(S,X){return __request__("DELETE",`/system/notifications/${S}/${X}`,null,{},{Accept:["application/json"]})}function qr(){return __request__("GET","/system/outputs",null,{},{Accept:["application/json"]})}function cc(S){return __request__("POST","/system/outputs",S,{},{Accept:["application/json"]})}function ko(){return __request__("GET","/system/outputs/available",null,{},{Accept:["application/json"]})}function ad(S){return __request__("GET",`/system/outputs/${S}`,null,{},{Accept:["application/json"]})}function op(S,X){return __request__("PUT",`/system/outputs/${S}`,X,{},{Accept:["application/json"]})}function sp(S){return __request__("DELETE",`/system/outputs/${S}`,null,{},{Accept:["application/json"]})}function ii(){return __request__("GET","/system/permissions",null,{},{Accept:["application/json"]})}function uc(S){return __request__("GET",`/system/permissions/reader/${S}`,null,{},{Accept:["application/json"]})}function dc(){return __request__("GET","/system/plugins",null,{},{Accept:["application/json"]})}function ci(){return __request__("PUT","/system/processing/pause",null,{},{Accept:[]})}function mc(){return __request__("PUT","/system/processing/resume",null,{},{Accept:[]})}function yr(){return __request__("GET","/system/processing/status",null,{},{Accept:["application/json"]})}function pc(){return __request__("GET","/system/processing/status/persisted",null,{},{Accept:["application/json"]})}function rp(S,X){return __request__("GET",`/system/searchVersion/satisfiesVersion/${S}`,null,{version:X},{Accept:["application/json"]})}function ui(){return __request__("GET","/system/serviceManager",null,{},{Accept:["application/json"]})}function ap(){return __request__("DELETE","/system/sessions",null,{},{Accept:["application/json"]})}function ld(){return __request__("GET","/system/sessions",null,{},{Accept:["application/json"]})}function id(S){return __request__("POST","/system/sessions",S,{},{Accept:["application/json"]})}function tl(S){return __request__("DELETE",`/system/sessions/${S}`,null,{},{Accept:["application/json"]})}function gc(){return __request__("GET","/system/stats",null,{},{Accept:["application/json"]})}function di(){return __request__("GET","/system/stats/fs",null,{},{Accept:["application/json"]})}function ea(){return __request__("GET","/system/stats/jvm",null,{},{Accept:["application/json"]})}function ta(){return __request__("GET","/system/stats/network",null,{},{Accept:["application/json"]})}function Ec(){return __request__("GET","/system/stats/os",null,{},{Accept:["application/json"]})}function lp(){return __request__("GET","/system/stats/process",null,{},{Accept:["application/json"]})}function fc(){return __request__("GET","/system/throughput",null,{},{Accept:["application/json"]})}function cd(){return __request__("GET","/system/urlwhitelist",null,{},{Accept:["application/json"]})}function ip(S){return __request__("PUT","/system/urlwhitelist",S,{},{Accept:["application/json"]})}function hc(S){return __request__("POST","/system/urlwhitelist/check",S,{},{Accept:["application/json"]})}function vc(S){return __request__("POST","/system/urlwhitelist/generate_regex",S,{},{Accept:["application/json"]})}function ud(){return f("GET","/telemetry",null,{},{Accept:["application/json"]})}function yc(){return f("GET","/telemetry/user/settings",null,{},{Accept:["application/json"]})}function nl(S){return f("PUT","/telemetry/user/settings",S,{},{Accept:["application/json"]})}function mi(S=!0,X=!0){return __request__("GET","/users",null,{include_permissions:S,include_sessions:X},{Accept:["application/json"]})}function pi(S){return __request__("POST","/users",S,{},{Accept:["application/json"]})}function _c(S){return __request__("GET",`/users/id/${S}`,null,{},{Accept:["application/json"]})}function cp(S){return __request__("DELETE",`/users/id/${S}`,null,{},{Accept:["application/json"]})}function dd(S="full_name",X=1,qe=50,Bt,Wt="asc"){return __request__("GET","/users/paginated",null,{page:X,per_page:qe,query:Bt,sort:S,order:Wt},{Accept:["application/json"]})}function gi(S,X){return __request__("PUT",`/users/${S}`,X,{},{Accept:["application/json"]})}function md(S,X){return __request__("PUT",`/users/${S}/password`,X,{},{Accept:["application/json"]})}function ol(S,X="enabled"){return __request__("PUT",`/users/${S}/status/${X}`,null,{},{Accept:["application/json"]})}function Cc(S){return __request__("GET",`/users/${S}/tokens`,null,{},{Accept:["application/json"]})}function pd(S,X){return __request__("DELETE",`/users/${S}/tokens/${X}`,null,{},{Accept:["application/json"]})}function gd(S,X,qe="{}"){return __request__("POST",`/users/${S}/tokens/${X}`,qe,{},{Accept:["application/json"]})}function Ei(S){return __request__("DELETE",`/users/${S}`,null,{},{Accept:["application/json"]})}function Ed(S){return __request__("GET",`/users/${S}`,null,{},{Accept:["application/json"]})}function fd(S,X){return __request__("PUT",`/users/${S}/permissions`,X,{},{Accept:["application/json"]})}function up(S){return __request__("DELETE",`/users/${S}/permissions`,null,{},{Accept:["application/json"]})}function Tc(S,X){return __request__("PUT",`/users/${S}/preferences`,X,{},{Accept:["application/json"]})}function dp(S){return __request__("POST","/views",S,{},{Accept:["application/json"]})}function hd(S="title",X=1,qe=50,Bt="asc",Wt){return __request__("GET","/views",null,{page:X,per_page:qe,sort:S,order:Bt,query:Wt},{Accept:["application/json"]})}function Sc(S){return __request__("POST","/views/bulk_delete",S,{},{Accept:["application/json"]})}function vd(S){return __request__("GET",`/views/${S}`,null,{},{Accept:["application/json"]})}function fi(S,X){return __request__("PUT",`/views/${S}`,X,{},{Accept:["application/json"]})}function yd(S){return __request__("DELETE",`/views/${S}`,null,{},{Accept:["application/json"]})}function _d(S){return __request__("PUT",`/views/${S}/default`,null,{},{Accept:["application/json"]})}function hi(){return __request__("POST","/views/forValue",null,{},{Accept:["application/json"]})}},mSSPPdLK:(M,C,e)=>{"use strict";e.d(C,{Z:()=>T});var t=e("dFpwyWHg"),s=e.n(t),o=e("C2ikvoS0"),r=e.n(o),n=e("1IntWRSu"),c=e.n(n),v=e("8nGWeFnd"),d=e.n(v),g=e("TeAcaicX"),p=e.n(g),E=e("eE3+5goe"),a=e.n(E),u=e("zUghPtuB"),f={};f.styleTagTransform=a(),f.setAttributes=d(),f.insert=c().bind(null,"head"),f.domAPI=r(),f.insertStyleElement=p();var y=s()(u.Z,f);const T=u.Z&&u.Z.locals?u.Z.locals:void 0},rw5gWgKu:M=>{"use strict";M.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAADsSURBVEhLY2AYBfQMgf///3P8+/evAIgvA/FsIF+BavYDDWMBGroaSMMBiE8VC7AZDrIFaMFnii3AZTjUgsUUWUDA8OdAH6iQbQEhw4HyGsPEcKBXBIC4ARhex4G4BsjmweU1soIFaGg/WtoFZRIZdEvIMhxkCCjXIVsATV6gFGACs4Rsw0EGgIIH3QJYJgHSARQZDrWAB+jawzgs+Q2UO49D7jnRSRGoEFRILcdmEMWGI0cm0JJ2QpYA1RDvcmzJEWhABhD/pqrL0S0CWuABKgnRki9lLseS7g2AlqwHWQSKH4oKLrILpRGhEQCw2LiRUIa4lwAAAABJRU5ErkJggg=="},"2JwhIP0b":M=>{"use strict";M.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGYSURBVEhL5ZSvTsNQFMbXZGICMYGYmJhAQIJAICYQPAACiSDB8AiICQQJT4CqQEwgJvYASAQCiZiYmJhAIBATCARJy+9rTsldd8sKu1M0+dLb057v6/lbq/2rK0mS/TRNj9cWNAKPYIJII7gIxCcQ51cvqID+GIEX8ASG4B1bK5gIZFeQfoJdEXOfgX4QAQg7kH2A65yQ87lyxb27sggkAzAuFhbbg1K2kgCkB1bVwyIR9m2L7PRPIhDUIXgGtyKw575yz3lTNs6X4JXnjV+LKM/m3MydnTbtOKIjtz6VhCBq4vSm3ncdrD2lk0VgUXSVKjVDJXJzijW1RQdsU7F77He8u68koNZTz8Oz5yGa6J3H3lZ0xYgXBK2QymlWWA+RWnYhskLBv2vmE+hBMCtbA7KX5drWyRT/2JsqZ2IvfB9Y4bWDNMFbJRFmC9E74SoS0CqulwjkC0+5bpcV1CZ8NMej4pjy0U+doDQsGyo1hzVJttIjhQ7GnBtRFN1UarUlH8F3xict+HY07rEzoUGPlWcjRFRr4/gChZgc3ZL2d8oAAAAASUVORK5CYII="},KVH9cwQk:M=>{"use strict";M.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII="},"IX/Ens47":M=>{"use strict";M.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHOSURBVEhLrZa/SgNBEMZzh0WKCClSCKaIYOED+AAKeQQLG8HWztLCImBrYadgIdY+gIKNYkBFSwu7CAoqCgkkoGBI/E28PdbLZmeDLgzZzcx83/zZ2SSXC1j9fr+I1Hq93g2yxH4iwM1vkoBWAdxCmpzTxfkN2RcyZNaHFIkSo10+8kgxkXIURV5HGxTmFuc75B2RfQkpxHG8aAgaAFa0tAHqYFfQ7Iwe2yhODk8+J4C7yAoRTWI3w/4klGRgR4lO7Rpn9+gvMyWp+uxFh8+H+ARlgN1nJuJuQAYvNkEnwGFck18Er4q3egEc/oO+mhLdKgRyhdNFiacC0rlOCbhNVz4H9FnAYgDBvU3QIioZlJFLJtsoHYRDfiZoUyIxqCtRpVlANq0EU4dApjrtgezPFad5S19Wgjkc0hNVnuF4HjVA6C7QrSIbylB+oZe3aHgBsqlNqKYH48jXyJKMuAbiyVJ8KzaB3eRc0pg9VwQ4niFryI68qiOi3AbjwdsfnAtk0bCjTLJKr6mrD9g8iq/S/B81hguOMlQTnVyG40wAcjnmgsCNESDrjme7wfftP4P7SP4N3CJZdvzoNyGq2c/HWOXJGsvVg+RA/k2MC/wN6I2YA2Pt8GkAAAAASUVORK5CYII="},"WN+LQtRW":M=>{"use strict";M.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAwCAYAAAB5R9gVAAAABGdBTUEAALGPC/xhBQAAAVVJREFUWAnN2G0KgjAYwPHpGfRkaZeqvgQaK+hY3SUHrk1YzNLay/OiEFp92I+/Mp2F2Mh2lLISWnflFjzH263RQjzMZ19wgs73ez0o1WmtW+dgA01VxrE3p6l2GLsnBy1VYQOtVSEH/atCCgqpQgKKqYIOiq2CBkqtggLKqQIKgqgCBjpJ2Y5CdJ+zrT9A7HHSTA1dxUdHgzCqJIEwq0SDsKsEg6iqBIEoq/wEcVRZBXFV+QJxV5mBtlDFB5VjYTaGZ2sf4R9PM7U9ZU+lLuaetPP/5Die3ToO1+u+MKtHs06qODB2zBnI/jBd4MPQm1VkY79Tb18gB+C62FdBFsZR6yeIo1YQiLJWMIiqVjQIu1YSCLNWFgijVjYIuhYYCKoWKAiiFgoopxYaKLUWOii2FgkophYp6F3r42W5A9s9OcgNvva8xQaysKXlFytoqdYmQH6tF3toSUo0INq9AAAAAElFTkSuQmCC"},glNHDCWm:M=>{"use strict";M.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAwCAYAAAB5R9gVAAAABGdBTUEAALGPC/xhBQAAAXRJREFUWAnN119ugjAcwPHWzJ1gnmxzB/BBE0n24m4xfNkTaOL7wOtsl3AXMMb+Vjaa1BG00N8fSEibPpAP3xAKKs2yjzTPH9RAjhEo9WzPr/Vm8zgE0+gXATAxxuxtqeJ9t5tIwv5AtQAApsfT6TPdbp+kUBcgVwvO51KqVhMkXKsVJFXrOkigVhCIs1Y4iKlWZxB1rX4gwlpRIIpa8SDkWmggrFq4IIRaJKCYWnSgnrXIQV1r8YD+1Vrn+bReagysIFfLABRt31v8oBu1xEBttfRbltmfjgEcWh9snUS2kNdBK6WN1vrOWxObWsz+fjxevsxmB1GQDfINWiev83nhaoiB/CoOU438oPrhXS0WpQ9xc1ZQWxWHqUYe0I0qrKCQKjygDlXIQV2r0IF6ViEBxVTBBSFUQQNhVYkHIVeJAtkNsbQ7c1LtzP6FsObhb2rCKv7NBIGoq4SDmKoEgTirXAcJVGkFSVVpgoSrXICGUMUH/QBZNSUy5XWUhwAAAABJRU5ErkJggg=="},OUOTPsAr:M=>{"use strict";M.exports="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA2IDYiIHN0eWxlPSJiYWNrZ3JvdW5kLWNvbG9yOiNmZmZmZmYwMCIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSI2cHgiIGhlaWdodD0iNnB4Ij48ZyBvcGFjaXR5PSIwLjMwMiI+PHBhdGggZD0iTSA2IDYgTCAwIDYgTCAwIDQuMiBMIDQgNC4yIEwgNC4yIDQuMiBMIDQuMiAwIEwgNiAwIEwgNiA2IEwgNiA2IFoiIGZpbGw9IiMwMDAwMDAiLz48L2c+PC9zdmc+"},"J6y4/h8P":(M,C,e)=>{M.exports=e("5knLEQW+")(1893)},"U7y/BNwM":(M,C,e)=>{M.exports=e("5knLEQW+")(22558)},"D4SbLiE/":(M,C,e)=>{M.exports=e("5knLEQW+")(2555)},UiXZqrDE:(M,C,e)=>{M.exports=e("5knLEQW+")(2598)},JnTtTRmZ:(M,C,e)=>{M.exports=e("5knLEQW+")(3001)},DUKaTDO2:(M,C,e)=>{M.exports=e("5knLEQW+")(3109)},ZaccISJq:(M,C,e)=>{M.exports=e("5knLEQW+")(3156)},yAXMqwrl:(M,C,e)=>{M.exports=e("5knLEQW+")(335)},"9oVghaOd":(M,C,e)=>{M.exports=e("5knLEQW+")(381)},zKLlqmvB:(M,C,e)=>{M.exports=e("5knLEQW+")(3935)},JuypItPU:(M,C,e)=>{M.exports=e("5knLEQW+")(4890)},GLQsuA3c:(M,C,e)=>{M.exports=e("5knLEQW+")(5243)},lCPkTODq:(M,C,e)=>{M.exports=e("5knLEQW+")(533)},Z7aTuO5B:(M,C,e)=>{M.exports=e("5knLEQW+")(7294)},aKyEWaw1:(M,C,e)=>{M.exports=e("5knLEQW+")(7588)},"ASBo/Til":(M,C,e)=>{M.exports=e("5knLEQW+")(8)},rDmUG0Dk:(M,C,e)=>{M.exports=e("5knLEQW+")(917)},"ww+BtWnX":(M,C,e)=>{M.exports=e("5knLEQW+")(947)},"kqAR+wt5":(M,C,e)=>{M.exports=e("5knLEQW+")(9755)},"5knLEQW+":M=>{"use strict";M.exports=__vendor},CcxYZm76:()=>{}},lf={};function mn(M){var C=lf[M];if(C!==void 0)return C.exports;var e=lf[M]={id:M,loaded:!1,exports:{}};return af[M].call(e.exports,e,e.exports,mn),e.loaded=!0,e.exports}mn.m=af,mn.amdD=function(){throw new Error("define cannot be used indirect")},(()=>{var M=[];mn.O=(C,e,t,s)=>{if(e){s=s||0;for(var o=M.length;o>0&&M[o-1][2]>s;o--)M[o]=M[o-1];M[o]=[e,t,s];return}for(var r=1/0,o=0;o=s)&&Object.keys(mn.O).every(a=>mn.O[a](e[c]))?e.splice(c--,1):(n=!1,s{var C=M&&M.__esModule?()=>M.default:()=>M;return mn.d(C,{a:C}),C},(()=>{var M=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,C;mn.t=function(e,t){if(t&1&&(e=this(e)),t&8||typeof e=="object"&&e&&(t&4&&e.__esModule||t&16&&typeof e.then=="function"))return e;var s=Object.create(null);mn.r(s);var o={};C=C||[null,M({}),M([]),M(M)];for(var r=t&2&&e;typeof r=="object"&&!~C.indexOf(r);r=M(r))Object.getOwnPropertyNames(r).forEach(n=>o[n]=()=>e[n]);return o.default=()=>e,mn.d(s,o),s}})(),mn.d=(M,C)=>{for(var e in C)mn.o(C,e)&&!mn.o(M,e)&&Object.defineProperty(M,e,{enumerable:!0,get:C[e]})},mn.f={},mn.e=M=>Promise.all(Object.keys(mn.f).reduce((C,e)=>(mn.f[e](M,C),C),[])),mn.u=M=>""+({"1255d548-7789":"LoginPage","1255d548-7899":"LoadingPage","1255d548-6663":"LoggedInPage","1255d548-124":"NewSearchPage","1255d548-517":"StreamSearchPage","1255d548-6618":"NewDashboardPage","1255d548-7153":"ShowViewPage"}[M]||M)+"."+{"1255d548-7789":"7c0cf14b33527d0ae8ad","1255d548-7899":"f26135c1b5707bf7420a","1255d548-6663":"1dcea87d1e4af4cb73ee","1255d548-3703":"ff7339521a389b539c90","1255d548-2236":"8431176882f7c7fc6e9a","1255d548-3618":"de46add0db683483be9a","1255d548-2341":"3dfff8d095da7cfdf692","1255d548-3521":"d1b3693e3651623483d5","1255d548-626":"d00dda61ddd52684f587","1255d548-8601":"fe127be969906a072c31","1255d548-3488":"586fb2517683c35973bc","1255d548-124":"6e59d13725f9bca5dc9a","1255d548-517":"607140bad62f18c63627","1255d548-6618":"c82103dd5a5e1cb3fb9a","1255d548-9366":"f2d2f665ebf60d780bb9","1255d548-7153":"75b5bca6e699a5d7e0af","1255d548-2679":"2ea8b20315560758a922","1255d548-5716":"58343bcf97921e07b4ab","1255d548-1247":"27b1f8022611d1b94b4c","1255d548-2378":"7792b4e7b39cf93c02aa","1255d548-2951":"9362266dfebed4fc6124","1255d548-3495":"e9a4bb972868e3fc72bc","1255d548-9582":"70b9e481fe7e785ba0a4","1255d548-8440":"761d7b075cdd5266e24f","1255d548-1899":"03b849c2ae164739c73a","1255d548-832":"00643985ddc5dc9a3f27","1255d548-8461":"242393b3a6d3d54debda","1255d548-4376":"86d943ecc614c0b3fe7c","1255d548-1449":"842221ca2db17ab35e17","1255d548-3668":"525adc6179220a48b5b0","1255d548-9738":"948670dead7c9ae448a4","1255d548-5673":"b4781774fc5dd72f5293","1255d548-4440":"06b2d0345da5b9122a6d","1255d548-5843":"66b1420bce40c1dc2be0","1255d548-8905":"ec28249651141b909d18","1255d548-539":"e8e74e871af5eba82414","1255d548-8592":"3e82e3aef6f553a592e5","1255d548-5226":"894068cf0729ec9c720d","1255d548-7664":"68ab3f580b20c9d96409","1255d548-1235":"6bd7770e62146e59707a","1255d548-1917":"4b0284b9f6b10798094c","1255d548-2065":"e74b793f1df9b912dccc","1255d548-7246":"f200d699d40bd783cabe","1255d548-5205":"eb874416e0c79f4b6c72","1255d548-3486":"b431fb9741ed8c9604ee","1255d548-7947":"b2d8c79a6a1437a7a1a2","1255d548-5573":"dde1fd14d40070a42601","1255d548-7295":"efca724585bc3a7821f0","1255d548-1217":"788aaa75b9f21acf2140","1255d548-3848":"1148bc2aaad4f5308986","1255d548-6717":"b345b73af9e2e6c4b4ab","1255d548-9985":"82f1e6e34e3f4c54485c","1255d548-3945":"6950d0c146bc43e1fe4f","1255d548-4889":"343228dbff196c121d46","1255d548-7375":"0a62991cf0672754286c","1255d548-7516":"bb1c7fc78af343c07ba8","1255d548-6800":"29ab0d5405adc761e098","1255d548-64":"6c9be24a5a5126c4ce0e","1255d548-8373":"282dae638c3b2547cce7","1255d548-2507":"c880aec23359f5fe633d","1255d548-7644":"700d87c9dc4bd7b53225","1255d548-795":"d36fe8f7feac90546ff7","1255d548-8940":"7e6fcb6591bbbe2797bc","1255d548-2379":"ab95cb6e8f8fa7b88066","1255d548-2746":"e82e5a9a4a0ad4696a95","1255d548-4499":"9d933f584c94fdb917c7","1255d548-6490":"d5145b504fd07d1dc086","1255d548-5299":"82092a4c17aee48064a9","1255d548-3580":"a3aed76e2616a8df2e33","1255d548-6202":"4a3c04565c5925e2b39e","1255d548-5967":"db64ad8f30f8fbf32c94","1255d548-4349":"fdf67b80fb715647c1b2","1255d548-8966":"daefc2cac5580d047728","1255d548-9693":"a6bd68487a9043109537","1255d548-5372":"f7f1344cf6047ca9ae26","1255d548-1314":"d712f4432886402b48b3","1255d548-7691":"29f9482a4a76cf88fd19","1255d548-6303":"a4648ae0cbf568bb38b5","1255d548-2032":"eaea4d7ded536fdf945d","1255d548-9821":"88760b2430a04099d965","1255d548-6712":"23ecb7d70611713d3e76","1255d548-6436":"545040a42f5be81e2c58","1255d548-5199":"051923e3e75d70e8884e","1255d548-699":"9e70c6b87a61a632652a","1255d548-7466":"83a666d83924acd3032d","1255d548-3135":"cbef515305c208a331eb","1255d548-4126":"ae16095afd6da8fc577d","1255d548-8617":"7388ac4c5ecab44644f1","1255d548-7421":"a7412cee59c41a56812e","1255d548-9145":"98fcf4c8bd3691fe4ea7","1255d548-3913":"8cdac0c5f1edc0c8dd2a","1255d548-1727":"c8a9ffcdf2640e93737f","1255d548-1149":"5a24f2309d40a78fe7aa","1255d548-5210":"d5fe7cb305627a6a2ce0","1255d548-2801":"ce8662c163526f874c4a","1255d548-7195":"1a542e98eaacea2fce5d","1255d548-7892":"bbf0a3663e8e1e6ca414","1255d548-8988":"59d16c07ad7f68851e18","1255d548-6543":"ad6ebad8de325f6c260b","1255d548-224":"f21e495be0180a1afc78","1255d548-4594":"d318652867b40b12817c","1255d548-8579":"2bd546a7fe429ddf6da9","1255d548-5912":"39fbec2fb46ad33fb816","1255d548-5208":"fa6065c6e394611402c8","1255d548-7604":"afd18abb1d666472790c","1255d548-2501":"8ba161447f299d54ecdc","1255d548-5690":"bc6f74b3495f7d9e0527","1255d548-490":"ff63a7d8d92fde12534e","1255d548-5534":"890176091ac76b162587","1255d548-3245":"7aa5de1a03474ae7d7fa","1255d548-3519":"2239126c18006c8ef239","1255d548-6323":"479b9038e0016738a21b","1255d548-1258":"b179013e1fffe51a01dd","1255d548-2012":"0dde2e50340a6b6e45f7","1255d548-3601":"f0e8d7b3f57ded6a2ae6","1255d548-6087":"99bf497b1a941d7f6017","1255d548-8956":"1e63d766fb5fd3de4fbf","1255d548-8890":"3145c797c153dced9084","1255d548-6217":"581e5afb0549c8466e52","1255d548-5831":"f80a057b291c0327f16a","1255d548-7396":"8032138583552e555d34"}[M]+".js",mn.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch{if(typeof window=="object")return window}}(),mn.o=(M,C)=>Object.prototype.hasOwnProperty.call(M,C),(()=>{var M={},C="graylog-web-interface:";mn.l=(e,t,s,o)=>{if(M[e]){M[e].push(t);return}var r,n;if(s!==void 0)for(var c=document.getElementsByTagName("script"),v=0;v{r.onerror=r.onload=null,clearTimeout(p);var u=M[e];if(delete M[e],r.parentNode&&r.parentNode.removeChild(r),u&&u.forEach(f=>f(a)),E)return E(a)},p=setTimeout(g.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=g.bind(null,r.onerror),r.onload=g.bind(null,r.onload),n&&document.head.appendChild(r)}})(),mn.r=M=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(M,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(M,"__esModule",{value:!0})},mn.nmd=M=>(M.paths=[],M.children||(M.children=[]),M),(()=>{var M;mn.g.importScripts&&(M=mn.g.location+"");var C=mn.g.document;if(!M&&C&&(C.currentScript&&(M=C.currentScript.src),!M)){var e=C.getElementsByTagName("script");if(e.length)for(var t=e.length-1;t>-1&&!M;)M=e[t--].src}if(!M)throw new Error("Automatic publicPath is not supported in this browser");M=M.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),mn.p=M})(),(()=>{mn.b=document.baseURI||self.location.href;var M={"1255d548-2143":0};mn.f.j=(t,s)=>{var o=mn.o(M,t)?M[t]:void 0;if(o!==0)if(o)s.push(o[2]);else{var r=new Promise((d,g)=>o=M[t]=[d,g]);s.push(o[2]=r);var n=mn.p+mn.u(t),c=new Error,v=d=>{if(mn.o(M,t)&&(o=M[t],o!==0&&(M[t]=void 0),o)){var g=d&&(d.type==="load"?"missing":d.type),p=d&&d.target&&d.target.src;c.message="Loading chunk "+t+` failed. (`+g+": "+p+")",c.name="ChunkLoadError",c.type=g,c.request=p,o[1](c)}};mn.l(n,v,"chunk-"+t,t)}},mn.O.j=t=>M[t]===0;var C=(t,s)=>{var[o,r,n]=s,c,v,d=0;if(o.some(p=>M[p]!==0)){for(c in r)mn.o(r,c)&&(mn.m[c]=r[c]);if(n)var g=n(mn)}for(t&&t(s);dmn("ajPaUdvr"));cf=mn.O(cf)})();})(); //# sourceMappingURL=app.a0efe310c8d25ed40c76.js.map




© 2015 - 2024 Weber Informatics LLC | Privacy Policy