@splunk/visualizations 26.1.2 → 26.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (159) hide show
  1. package/Area.config.js +2 -1
  2. package/Area.config.js.map +1 -1
  3. package/Area.js +1562 -433
  4. package/Area.js.map +1 -1
  5. package/Bar.config.js +1 -0
  6. package/Bar.config.js.map +1 -1
  7. package/Bar.js +1555 -430
  8. package/Bar.js.map +1 -1
  9. package/Bubble.config.js +1 -0
  10. package/Bubble.config.js.map +1 -1
  11. package/Bubble.js +1580 -455
  12. package/Bubble.js.map +1 -1
  13. package/ChoroplethSvg.config.js +1 -0
  14. package/ChoroplethSvg.config.js.map +1 -1
  15. package/ChoroplethSvg.js +1418 -351
  16. package/ChoroplethSvg.js.map +1 -1
  17. package/Column.config.js +2 -1
  18. package/Column.config.js.map +1 -1
  19. package/Column.js +1564 -435
  20. package/Column.js.map +1 -1
  21. package/Ellipse.config.js +1 -0
  22. package/Ellipse.config.js.map +1 -1
  23. package/Ellipse.js +1342 -297
  24. package/Ellipse.js.map +1 -1
  25. package/Events.config.js +4 -0
  26. package/Events.config.js.map +1 -1
  27. package/Events.js +1503 -489
  28. package/Events.js.map +1 -1
  29. package/FEATUREFLAGS.md +3 -0
  30. package/FillerGauge.config.js +1 -0
  31. package/FillerGauge.config.js.map +1 -1
  32. package/FillerGauge.js +1406 -345
  33. package/FillerGauge.js.map +1 -1
  34. package/Image.config.js +1 -0
  35. package/Image.config.js.map +1 -1
  36. package/Image.js +2355 -1183
  37. package/Image.js.map +1 -1
  38. package/Line.config.js +2 -1
  39. package/Line.config.js.map +1 -1
  40. package/Line.js +1562 -433
  41. package/Line.js.map +1 -1
  42. package/LinkGraph.config.js +1 -0
  43. package/LinkGraph.config.js.map +1 -1
  44. package/LinkGraph.js +2013 -968
  45. package/LinkGraph.js.map +1 -1
  46. package/Map.config.js +1 -0
  47. package/Map.config.js.map +1 -1
  48. package/Map.js +2556 -1527
  49. package/Map.js.map +1 -1
  50. package/Markdown.config.js +1 -0
  51. package/Markdown.config.js.map +1 -1
  52. package/Markdown.js +1952 -883
  53. package/Markdown.js.map +1 -1
  54. package/MarkerGauge.config.js +1 -0
  55. package/MarkerGauge.config.js.map +1 -1
  56. package/MarkerGauge.js +4049 -2965
  57. package/MarkerGauge.js.map +1 -1
  58. package/ParallelCoordinates.config.js +1 -0
  59. package/ParallelCoordinates.config.js.map +1 -1
  60. package/ParallelCoordinates.js +3286 -2215
  61. package/ParallelCoordinates.js.map +1 -1
  62. package/Pie.config.js +1 -0
  63. package/Pie.config.js.map +1 -1
  64. package/Pie.js +2187 -1036
  65. package/Pie.js.map +1 -1
  66. package/Punchcard.config.js +1 -0
  67. package/Punchcard.config.js.map +1 -1
  68. package/Punchcard.js +3397 -2299
  69. package/Punchcard.js.map +1 -1
  70. package/Rectangle.config.js +1 -0
  71. package/Rectangle.config.js.map +1 -1
  72. package/Rectangle.js +2181 -1112
  73. package/Rectangle.js.map +1 -1
  74. package/Sankey.config.js +1 -0
  75. package/Sankey.config.js.map +1 -1
  76. package/Sankey.js +3275 -2199
  77. package/Sankey.js.map +1 -1
  78. package/Scatter.config.js +1 -0
  79. package/Scatter.config.js.map +1 -1
  80. package/Scatter.js +3551 -2400
  81. package/Scatter.js.map +1 -1
  82. package/SingleValue.config.js +27 -0
  83. package/SingleValue.config.js.map +1 -1
  84. package/SingleValue.js +5551 -4397
  85. package/SingleValue.js.map +1 -1
  86. package/SingleValueBasic.js +1227 -1209
  87. package/SingleValueBasic.js.map +1 -1
  88. package/SingleValueIcon.config.js +27 -0
  89. package/SingleValueIcon.config.js.map +1 -1
  90. package/SingleValueIcon.js +2850 -1696
  91. package/SingleValueIcon.js.map +1 -1
  92. package/SingleValueRadial.config.js +1 -0
  93. package/SingleValueRadial.config.js.map +1 -1
  94. package/SingleValueRadial.js +6334 -5215
  95. package/SingleValueRadial.js.map +1 -1
  96. package/SparkLine.js +96 -96
  97. package/SparkLine.js.map +1 -1
  98. package/Table.config.js +172 -7
  99. package/Table.config.js.map +1 -1
  100. package/Table.js +3500 -2195
  101. package/Table.js.map +1 -1
  102. package/common/Charting.js +1009 -82
  103. package/common/Charting.js.map +1 -1
  104. package/common/ChartingApi.js +4 -4
  105. package/common/ChartingApi.js.map +1 -1
  106. package/common/DocExampleWithVizSandbox.js +54 -57
  107. package/common/DocExampleWithVizSandbox.js.map +1 -1
  108. package/common/EventsDoc.js +40 -40
  109. package/common/EventsDoc.js.map +1 -1
  110. package/common/GaugeMajorTicks.js +15 -13
  111. package/common/GaugeMajorTicks.js.map +1 -1
  112. package/common/GaugeValueMarker.js +12 -12
  113. package/common/GaugeValueMarker.js.map +1 -1
  114. package/common/OptionsDoc.js +34 -34
  115. package/common/OptionsDoc.js.map +1 -1
  116. package/common/OverviewDoc.js +124 -103
  117. package/common/OverviewDoc.js.map +1 -1
  118. package/common/SplunkVisualization.js +49 -49
  119. package/common/SplunkVisualization.js.map +1 -1
  120. package/common/SplunkVisualizationApi.js +4 -4
  121. package/common/SplunkVisualizationApi.js.map +1 -1
  122. package/common/ThemesDoc.js +31 -31
  123. package/common/ThemesDoc.js.map +1 -1
  124. package/common/chartingUtils.js +24 -8
  125. package/common/chartingUtils.js.map +1 -1
  126. package/common/docUtils.js +4 -4
  127. package/common/docUtils.js.map +1 -1
  128. package/common/gaugeUtils.js +16 -16
  129. package/common/gaugeUtils.js.map +1 -1
  130. package/common/shapeUtils.js +36 -36
  131. package/common/shapeUtils.js.map +1 -1
  132. package/common/utils/configUtils.js +48 -47
  133. package/common/utils/configUtils.js.map +1 -1
  134. package/common/utils/dataUtils.js +832 -6
  135. package/common/utils/dataUtils.js.map +1 -1
  136. package/common/utils/featureFlagUtils.js +139 -0
  137. package/common/utils/featureFlagUtils.js.map +1 -0
  138. package/common/utils/hocUtils.js +2 -2
  139. package/common/utils/hocUtils.js.map +1 -1
  140. package/common/utils/layoutUtils.js +2 -2
  141. package/common/utils/layoutUtils.js.map +1 -1
  142. package/common/utils/mapUtils.js +77 -54
  143. package/common/utils/mapUtils.js.map +1 -1
  144. package/common/utils/singleValueUtils.js +28 -19
  145. package/common/utils/singleValueUtils.js.map +1 -1
  146. package/common/utils/testHelper.js +10 -10
  147. package/common/utils/testHelper.js.map +1 -1
  148. package/common/utils/trellisUtils.js +6 -6
  149. package/common/utils/trellisUtils.js.map +1 -1
  150. package/common/utils/urlUtils.js +2 -2
  151. package/common/utils/urlUtils.js.map +1 -1
  152. package/common/withDashboardViz.js +1313 -235
  153. package/common/withDashboardViz.js.map +1 -1
  154. package/package.json +13 -12
  155. package/__mocks__/fileMock.js +0 -2
  156. package/__mocks__/styleMock.js +0 -2
  157. package/babel.config.js +0 -11
  158. package/jest.config.js +0 -8
  159. package/loki.config.js +0 -14
@@ -1 +1 @@
1
- {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///external \"react\"","webpack:///external \"prop-types\"","webpack:///external \"@splunk/ui-utils/i18n\"","webpack:///external \"@babel/runtime/helpers/slicedToArray\"","webpack:///./src/common/docUtils.tsx","webpack:///external \"@splunk/react-docs/UtilPage\"","webpack:///./src/common/DocExampleWithVizSandbox.tsx","webpack:///external \"@splunk/react-docs/DocExample\"","webpack:///external \"@splunk/react-ui/Button\"","webpack:///external \"@splunk/react-ui/Code\"","webpack:///external \"@splunk/react-ui/TransitionOpen\"","webpack:///external \"@splunk/react-icons/SquaresLayered\"","webpack:///external \"@splunk/react-icons/Checkmark\"","webpack:///external \"@splunk/react-icons/EyeSlashed\"","webpack:///external \"@splunk/react-icons/WindowChevronsSlash\""],"names":[],"mappings":";;;;;;;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA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oBAAC,wBAAD,EAAe;AACX,aAAS,EAAC,cADC;AAEX,QAAI,EAAE,QAFK;AAGX,eAAW,EAAE,KAHF;AAIX,aAAS,EAAE,KAJA;AAKX,+BAA2B,EAAE,KALlB;AAMX,kBAAc,EAAE;AANL,GAAf,EAQI;AAAK,SAAK,EAAE;AAAE,aAAO,EAAE,MAAX;AAAmB,oBAAc,EAAE;AAAnC;AAAZ,KACI,oBAAC,cAAD,EAAK;AAAC,SAAK,EAAE,UAAR;AAAoB,YAAQ,EAAC;AAA7B,GAAL,CADJ,EAEI,oBAAC,gBAAD,EAAO;AACH,WAAO,EAAE,eADN;AAEH,QAAI,EAAE,QAAQ,GAAG,oBAAC,mBAAD,EAAU,IAAV,CAAH,GAAmB,oBAAC,wBAAD,EAAe,IAAf,CAF9B;AAGH,SAAK,EAAE,QAAQ,GAAG,cAAE,QAAF,CAAH,GAAiB,cAAE,mBAAF,CAH7B;AAIH,SAAK,EAAE;AAAE,YAAM,EAAE,MAAV;AAAkB,cAAQ,EAAE;AAA5B;AAJJ,GAAP,CAFJ,CARJ,CAPJ,CADJ;AA4BH,CA1ED;;AA4EA,wBAAwB,CAAC,SAAzB,GAAqC;AACjC,MAAI,EAAE,CAAC,CAAC,MADyB;AAEjC,OAAK,EAAE,CAAC,CAAC,MAFwB;AAGjC,MAAI,EAAE,CAAC,CAAC,MAHyB;AAIjC,SAAO,EAAE,CAAC,CAAC,IAJsB;AAKjC,aAAW,EAAE,CAAC,CAAC;AALkB,CAArC;AAQA,kBAAe,wBAAf,C;;;;;;AC1GA,0D;;;;;;ACAA,oD;;;;;;ACAA,kD;;;;;;ACAA,4D;;;;;;ACAA,+D;;;;;;ACAA,0D;;;;;;ACAA,2D;;;;;;ACAA,oE","file":"DocExampleWithVizSandbox.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 25);\n","module.exports = require(\"react\");","module.exports = require(\"prop-types\");","module.exports = require(\"@splunk/ui-utils/i18n\");","module.exports = require(\"@babel/runtime/helpers/slicedToArray\");","import * as React from 'react';\nimport UtilPage from '@splunk/react-docs/UtilPage';\n\n// https://github.com/jsdoc2md/jsdoc-api#synopsis\ninterface JsDoc {\n access?: string;\n classdesc?: string;\n comment: string;\n kind: string;\n longname: string;\n meta: Record<string, unknown>;\n member: string;\n name: string;\n scope: string;\n}\n\nconst sharedSelectors = ['getField', 'getType', 'min', 'max'];\n\nconst formatSidebarItemName = (name: string, className: string): string => {\n return sharedSelectors.find(sharedSelector => name === sharedSelector) ? `${className}#${name}` : name;\n};\n\nconst removePrependedClassName = (longname = ''): string => longname.slice(longname.indexOf('#') + 1);\n\nconst formatDSLSelectorDocs = (docs: JsDoc[]): JsDoc[] =>\n docs.map(doc => ({\n ...doc,\n longname: removePrependedClassName(doc.longname),\n }));\n\nexport const getFormatterClassdesc = (\n formatterDocs: JsDoc[],\n name: string\n): { name: string; markdown: string } => ({\n name,\n markdown: `# ${name}\\n ${formatterDocs.find(doc => doc.name === name && doc.kind === 'class').classdesc}`,\n});\n\nexport const extractDocItems = (\n docs: JsDoc[],\n className: string\n): { name: string; component: (...args: any[]) => any }[] => {\n const classHeaderDoc = docs[0];\n const fileDoc = docs[docs.length - 1];\n const filteredDocs = formatDSLSelectorDocs(docs).filter(\n ({ access, comment }) => access === 'public' && comment\n );\n\n return filteredDocs\n .map(doc => ({\n name: formatSidebarItemName(doc.name, className),\n component: function UtilDoc() {\n // named function so linter doesnt raise react/display-name error\n return (\n <UtilPage\n title={`${className}#${doc.name}`}\n status={1}\n docs={[classHeaderDoc, doc, fileDoc]}\n />\n );\n },\n }))\n .sort((a, b) => a.name.localeCompare(b.name));\n};\n\nexport const formatCodeStringToObject = (codeString: string, regexMatch: RegExp): any => {\n const match = regexMatch.exec(codeString);\n if (!match) return null;\n\n const stringToParse = `{${match[1]}}`;\n\n // remove trailing commas\n const removedCommas = stringToParse.replace(/,(?!\\s*?[-{[\"'\\w])/g, '');\n\n // convert double quotes (which only occur inside strings) to back quotes\n const backQuotes = removedCommas.replace(/\"/g, '`');\n // replace single quotes with double quotes\n const doubleQuotes = backQuotes.replace(/'/g, '\"');\n // replace back quotes with single quotes\n const singleQuotes = doubleQuotes.replace(/`/g, \"'\");\n\n // add quotes around keys\n const quotesAroundKeys = singleQuotes.replace(/\\b(\\w+)\\s*:(?=\\s)/g, '\"$1\":');\n\n let retval = null;\n try {\n retval = JSON.parse(quotesAroundKeys);\n } catch (e) {\n // eslint-disable-next-line no-console\n console.error(e);\n }\n return retval;\n};\n\nexport const extractDataFromReactCode = (codeString: string): any => {\n const primaryRegex = /dataSources={{([\\s\\S]*?primary:[\\s\\S]*?)}}/;\n const { primary } = formatCodeStringToObject(codeString, primaryRegex) ?? {};\n\n const optionsRegex = /options={{([\\s\\S]*?)}}/;\n const options = formatCodeStringToObject(codeString, optionsRegex);\n\n const contextRegex = /context={{([\\s\\S]*?)}}/;\n const context = formatCodeStringToObject(codeString, contextRegex);\n\n return { primary, options, context };\n};\n\n// Takes a stringified react viz example and a viz type\n// Returns a dashboard definition object.\n// e.g. codeString: '<Area dataSources={{}} options={{}} />'\n// type: 'splunk.area'\nexport const convertToDashboardJSON = (codeString: string, type: string): any => {\n const { options, primary, context } = extractDataFromReactCode(codeString);\n\n return {\n visualizations: {\n test_viz: {\n type,\n ...(options ? { options } : {}),\n ...(primary ? { dataSources: { primary: 'primary' } } : {}),\n ...(context ? { context } : {}),\n },\n },\n ...(primary ? { dataSources: { primary: { type: 'ds.test', options: primary } } } : {}),\n defaults: {\n dataSources: {\n global: {\n options: {\n queryParameters: {\n latest: '$global_time.latest$',\n earliest: '$global_time.earliest$',\n },\n },\n },\n },\n },\n inputs: {\n input_global_trp: {\n type: 'input.timerange',\n options: {\n token: 'global_time',\n defaultValue: '-24h@h,now',\n },\n title: 'Global Time Range',\n },\n },\n layout: {\n type: 'absolute',\n options: {},\n structure: [\n {\n item: 'test_viz',\n type: 'block',\n position: {\n x: 0,\n y: 0,\n w: 800,\n h: 500,\n },\n },\n ],\n globalInputs: ['input_global_trp'],\n },\n };\n};\n","module.exports = require(\"@splunk/react-docs/UtilPage\");","import * as React from 'react';\nimport DocExample from '@splunk/react-docs/DocExample';\nimport Button from '@splunk/react-ui/Button';\nimport Code from '@splunk/react-ui/Code';\nimport TransitionOpen from '@splunk/react-ui/TransitionOpen';\nimport SquaresLayered from '@splunk/react-icons/SquaresLayered';\nimport Checkmark from '@splunk/react-icons/Checkmark';\nimport EyeSlashed from '@splunk/react-icons/EyeSlashed';\nimport WindowChevronsSlash from '@splunk/react-icons/WindowChevronsSlash';\nimport { _ } from '@splunk/ui-utils/i18n';\nimport * as T from 'prop-types';\nimport { convertToDashboardJSON } from './docUtils';\n\ninterface DocExampleWithVizSandboxProps {\n type: string;\n title: string;\n code: string;\n example: () => React.ReactElement;\n hideSandbox?: boolean;\n description?: string;\n}\n\nconst DocExampleWithVizSandbox = (props: DocExampleWithVizSandboxProps): React.ReactElement => {\n const { type, title, code, example, hideSandbox = false, description } = props;\n const [isCopied, setIsCopied] = React.useState(false);\n const [showCode, setShowCode] = React.useState(false);\n const isMounted = React.useRef(true);\n\n const toggleShowCode = React.useCallback(() => {\n setShowCode(state => !state);\n }, []);\n\n React.useEffect((): (() => void) => {\n return () => {\n isMounted.current = false;\n setIsCopied(false);\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n if (hideSandbox) return <DocExample title={title} code={code} example={example} />;\n\n const objDefn = convertToDashboardJSON(code, type);\n // set spacing level to 4\n const prettyJson = JSON.stringify(objDefn, null, 4);\n\n const copyToClipBoard = () => {\n if ('clipboard' in navigator) {\n navigator.clipboard.writeText(prettyJson);\n setIsCopied(true);\n }\n setTimeout(() => {\n if (isMounted.current) {\n setIsCopied(false);\n }\n }, 5000);\n };\n\n const renderAdditionalActions = () => [\n <Button\n key=\"show-dashboard-definition\"\n appearance=\"toggle\"\n onClick={toggleShowCode}\n icon={showCode ? <EyeSlashed /> : <WindowChevronsSlash />}\n label={showCode ? _('Hide dashboard definition') : _('Show dashboard definition')}\n />,\n ];\n\n return (\n <DocExample\n renderAdditionalActions={renderAdditionalActions}\n title={title}\n code={code}\n example={example}\n description={description}\n >\n <TransitionOpen\n animation=\"slideFromTop\"\n open={showCode}\n retainFocus={false}\n takeFocus={false}\n renderChildrenWhenCollapsed={false}\n animateOnMount={false}\n >\n <div style={{ display: 'flex', justifyContent: 'space-between' }}>\n <Code value={prettyJson} language=\"json\" />\n <Button\n onClick={copyToClipBoard}\n icon={isCopied ? <Checkmark /> : <SquaresLayered />}\n label={isCopied ? _('Copied') : _('Copy to clipboard')}\n style={{ height: '30px', maxWidth: '164px' }}\n />\n </div>\n </TransitionOpen>\n </DocExample>\n );\n};\n\nDocExampleWithVizSandbox.propTypes = {\n type: T.string,\n title: T.string,\n code: T.string,\n example: T.func,\n hideSandbox: T.bool,\n};\n\nexport default DocExampleWithVizSandbox;\n","module.exports = require(\"@splunk/react-docs/DocExample\");","module.exports = require(\"@splunk/react-ui/Button\");","module.exports = require(\"@splunk/react-ui/Code\");","module.exports = require(\"@splunk/react-ui/TransitionOpen\");","module.exports = require(\"@splunk/react-icons/SquaresLayered\");","module.exports = require(\"@splunk/react-icons/Checkmark\");","module.exports = require(\"@splunk/react-icons/EyeSlashed\");","module.exports = require(\"@splunk/react-icons/WindowChevronsSlash\");"],"sourceRoot":""}
1
+ {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///external \"react\"","webpack:///external \"prop-types\"","webpack:///./src/common/docUtils.tsx","webpack:///external \"@splunk/react-docs/UtilPage\"","webpack:///./src/common/DocExampleWithVizSandbox.tsx","webpack:///external \"@splunk/react-docs/DocExample\"","webpack:///external \"@splunk/ui-utils/i18n\"","webpack:///external \"@splunk/react-ui/Button\"","webpack:///external \"@splunk/react-ui/Code\"","webpack:///external \"@splunk/react-ui/TransitionOpen\"","webpack:///external \"@splunk/react-icons/SquaresLayered\"","webpack:///external \"@splunk/react-icons/Checkmark\"","webpack:///external \"@splunk/react-icons/EyeSlashed\"","webpack:///external \"@splunk/react-icons/WindowChevronsSlash\"","webpack:///external \"@babel/runtime/helpers/slicedToArray\""],"names":[],"mappings":";;;;;;;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;AClFA,kC;;;;;;;ACAA,uC;;;;;;;;;;;;;;;ACAA;;AACA;;AAeA,IAAM,eAAe,GAAG,CAAC,UAAD,EAAa,SAAb,EAAwB,KAAxB,EAA+B,KAA/B,CAAxB;;AAEA,IAAM,qBAAqB,GAAG,SAAxB,qBAAwB,CAAC,IAAD,EAAe,SAAf,EAA4C;AACtE,SAAO,eAAe,CAAC,IAAhB,CAAqB,wBAAc;AAAA,WAAI,IAAI,KAAK,cAAb;AAAA,GAAnC,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A5B;AAJJ,GAAP,CAFJ,CARJ,CAPJ,CADJ;AA4BH,CA1ED;;AA4EA,wBAAwB,CAAC,SAAzB,GAAqC;AACjC,MAAI,EAAE,CAAC,CAAC,MADyB;AAEjC,OAAK,EAAE,CAAC,CAAC,MAFwB;AAGjC,MAAI,EAAE,CAAC,CAAC,MAHyB;AAIjC,SAAO,EAAE,CAAC,CAAC,IAJsB;AAKjC,aAAW,EAAE,CAAC,CAAC;AALkB,CAArC;AAQA,kBAAe,wBAAf,C;;;;;;;AC1GA,0D;;;;;;;ACAA,kD;;;;;;;ACAA,oD;;;;;;;ACAA,kD;;;;;;;ACAA,4D;;;;;;;ACAA,+D;;;;;;;ACAA,0D;;;;;;;ACAA,2D;;;;;;;ACAA,oE;;;;;;;ACAA,iE","file":"DocExampleWithVizSandbox.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 48);\n","module.exports = require(\"react\");","module.exports = require(\"prop-types\");","import * as React from 'react';\nimport UtilPage from '@splunk/react-docs/UtilPage';\n\n// https://github.com/jsdoc2md/jsdoc-api#synopsis\ninterface JsDoc {\n access?: string;\n classdesc?: string;\n comment: string;\n kind: string;\n longname: string;\n meta: Record<string, unknown>;\n member: string;\n name: string;\n scope: string;\n}\n\nconst sharedSelectors = ['getField', 'getType', 'min', 'max'];\n\nconst formatSidebarItemName = (name: string, className: string): string => {\n return sharedSelectors.find(sharedSelector => name === sharedSelector) ? `${className}#${name}` : name;\n};\n\nconst removePrependedClassName = (longname = ''): string => longname.slice(longname.indexOf('#') + 1);\n\nconst formatDSLSelectorDocs = (docs: JsDoc[]): JsDoc[] =>\n docs.map(doc => ({\n ...doc,\n longname: removePrependedClassName(doc.longname),\n }));\n\nexport const getFormatterClassdesc = (\n formatterDocs: JsDoc[],\n name: string\n): { name: string; markdown: string } => ({\n name,\n markdown: `# ${name}\\n ${formatterDocs.find(doc => doc.name === name && doc.kind === 'class').classdesc}`,\n});\n\nexport const extractDocItems = (\n docs: JsDoc[],\n className: string\n): { name: string; component: (...args: any[]) => any }[] => {\n const classHeaderDoc = docs[0];\n const fileDoc = docs[docs.length - 1];\n const filteredDocs = formatDSLSelectorDocs(docs).filter(\n ({ access, comment }) => access === 'public' && comment\n );\n\n return filteredDocs\n .map(doc => ({\n name: formatSidebarItemName(doc.name, className),\n component: function UtilDoc() {\n // named function so linter doesnt raise react/display-name error\n return (\n <UtilPage\n title={`${className}#${doc.name}`}\n status={1}\n docs={[classHeaderDoc, doc, fileDoc]}\n />\n );\n },\n }))\n .sort((a, b) => a.name.localeCompare(b.name));\n};\n\nexport const formatCodeStringToObject = (codeString: string, regexMatch: RegExp): any => {\n const match = regexMatch.exec(codeString);\n if (!match) return null;\n\n const stringToParse = `{${match[1]}}`;\n\n // remove trailing commas\n const removedCommas = stringToParse.replace(/,(?!\\s*?[-{[\"'\\w])/g, '');\n\n // convert double quotes (which only occur inside strings) to back quotes\n const backQuotes = removedCommas.replace(/\"/g, '`');\n // replace single quotes with double quotes\n const doubleQuotes = backQuotes.replace(/'/g, '\"');\n // replace back quotes with single quotes\n const singleQuotes = doubleQuotes.replace(/`/g, \"'\");\n\n // add quotes around keys\n const quotesAroundKeys = singleQuotes.replace(/\\b(\\w+)\\s*:(?=\\s)/g, '\"$1\":');\n\n let retval = null;\n try {\n retval = JSON.parse(quotesAroundKeys);\n } catch (e) {\n // eslint-disable-next-line no-console\n console.error(e);\n }\n return retval;\n};\n\nexport const extractDataFromReactCode = (codeString: string): any => {\n const primaryRegex = /dataSources={{([\\s\\S]*?primary:[\\s\\S]*?)}}/;\n const { primary } = formatCodeStringToObject(codeString, primaryRegex) ?? {};\n\n const optionsRegex = /options={{([\\s\\S]*?)}}/;\n const options = formatCodeStringToObject(codeString, optionsRegex);\n\n const contextRegex = /context={{([\\s\\S]*?)}}/;\n const context = formatCodeStringToObject(codeString, contextRegex);\n\n return { primary, options, context };\n};\n\n// Takes a stringified react viz example and a viz type\n// Returns a dashboard definition object.\n// e.g. codeString: '<Area dataSources={{}} options={{}} />'\n// type: 'splunk.area'\nexport const convertToDashboardJSON = (codeString: string, type: string): any => {\n const { options, primary, context } = extractDataFromReactCode(codeString);\n\n return {\n visualizations: {\n test_viz: {\n type,\n ...(options ? { options } : {}),\n ...(primary ? { dataSources: { primary: 'primary' } } : {}),\n ...(context ? { context } : {}),\n },\n },\n ...(primary ? { dataSources: { primary: { type: 'ds.test', options: primary } } } : {}),\n defaults: {\n dataSources: {\n global: {\n options: {\n queryParameters: {\n latest: '$global_time.latest$',\n earliest: '$global_time.earliest$',\n },\n },\n },\n },\n },\n inputs: {\n input_global_trp: {\n type: 'input.timerange',\n options: {\n token: 'global_time',\n defaultValue: '-24h@h,now',\n },\n title: 'Global Time Range',\n },\n },\n layout: {\n type: 'absolute',\n options: {},\n structure: [\n {\n item: 'test_viz',\n type: 'block',\n position: {\n x: 0,\n y: 0,\n w: 800,\n h: 500,\n },\n },\n ],\n globalInputs: ['input_global_trp'],\n },\n };\n};\n","module.exports = require(\"@splunk/react-docs/UtilPage\");","import * as React from 'react';\nimport DocExample from '@splunk/react-docs/DocExample';\nimport Button from '@splunk/react-ui/Button';\nimport Code from '@splunk/react-ui/Code';\nimport TransitionOpen from '@splunk/react-ui/TransitionOpen';\nimport SquaresLayered from '@splunk/react-icons/SquaresLayered';\nimport Checkmark from '@splunk/react-icons/Checkmark';\nimport EyeSlashed from '@splunk/react-icons/EyeSlashed';\nimport WindowChevronsSlash from '@splunk/react-icons/WindowChevronsSlash';\nimport { _ } from '@splunk/ui-utils/i18n';\nimport * as T from 'prop-types';\nimport { convertToDashboardJSON } from './docUtils';\n\ninterface DocExampleWithVizSandboxProps {\n type: string;\n title: string;\n code: string;\n example: () => React.ReactElement;\n hideSandbox?: boolean;\n description?: string;\n}\n\nconst DocExampleWithVizSandbox = (props: DocExampleWithVizSandboxProps): React.ReactElement => {\n const { type, title, code, example, hideSandbox = false, description } = props;\n const [isCopied, setIsCopied] = React.useState(false);\n const [showCode, setShowCode] = React.useState(false);\n const isMounted = React.useRef(true);\n\n const toggleShowCode = React.useCallback(() => {\n setShowCode(state => !state);\n }, []);\n\n React.useEffect((): (() => void) => {\n return () => {\n isMounted.current = false;\n setIsCopied(false);\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n if (hideSandbox) return <DocExample title={title} code={code} example={example} />;\n\n const objDefn = convertToDashboardJSON(code, type);\n // set spacing level to 4\n const prettyJson = JSON.stringify(objDefn, null, 4);\n\n const copyToClipBoard = () => {\n if ('clipboard' in navigator) {\n navigator.clipboard.writeText(prettyJson);\n setIsCopied(true);\n }\n setTimeout(() => {\n if (isMounted.current) {\n setIsCopied(false);\n }\n }, 5000);\n };\n\n const renderAdditionalActions = () => [\n <Button\n key=\"show-dashboard-definition\"\n appearance=\"toggle\"\n onClick={toggleShowCode}\n icon={showCode ? <EyeSlashed /> : <WindowChevronsSlash />}\n label={showCode ? _('Hide dashboard definition') : _('Show dashboard definition')}\n />,\n ];\n\n return (\n <DocExample\n renderAdditionalActions={renderAdditionalActions}\n title={title}\n code={code}\n example={example}\n description={description}\n >\n <TransitionOpen\n animation=\"slideFromTop\"\n open={showCode}\n retainFocus={false}\n takeFocus={false}\n renderChildrenWhenCollapsed={false}\n animateOnMount={false}\n >\n <div style={{ display: 'flex', justifyContent: 'space-between' }}>\n <Code value={prettyJson} language=\"json\" />\n <Button\n onClick={copyToClipBoard}\n icon={isCopied ? <Checkmark /> : <SquaresLayered />}\n label={isCopied ? _('Copied') : _('Copy to clipboard')}\n style={{ height: '30px', maxWidth: '164px' }}\n />\n </div>\n </TransitionOpen>\n </DocExample>\n );\n};\n\nDocExampleWithVizSandbox.propTypes = {\n type: T.string,\n title: T.string,\n code: T.string,\n example: T.func,\n hideSandbox: T.bool,\n};\n\nexport default DocExampleWithVizSandbox;\n","module.exports = require(\"@splunk/react-docs/DocExample\");","module.exports = require(\"@splunk/ui-utils/i18n\");","module.exports = require(\"@splunk/react-ui/Button\");","module.exports = require(\"@splunk/react-ui/Code\");","module.exports = require(\"@splunk/react-ui/TransitionOpen\");","module.exports = require(\"@splunk/react-icons/SquaresLayered\");","module.exports = require(\"@splunk/react-icons/Checkmark\");","module.exports = require(\"@splunk/react-icons/EyeSlashed\");","module.exports = require(\"@splunk/react-icons/WindowChevronsSlash\");","module.exports = require(\"@babel/runtime/helpers/slicedToArray\");"],"sourceRoot":""}
@@ -87,7 +87,7 @@ module.exports =
87
87
  /******/
88
88
  /******/
89
89
  /******/ // Load entry module and return exports
90
- /******/ return __webpack_require__(__webpack_require__.s = 60);
90
+ /******/ return __webpack_require__(__webpack_require__.s = 82);
91
91
  /******/ })
92
92
  /************************************************************************/
93
93
  /******/ ({
@@ -109,11 +109,18 @@ module.exports = require("prop-types");
109
109
  /***/ 10:
110
110
  /***/ (function(module, exports) {
111
111
 
112
+ module.exports = require("@babel/runtime/helpers/defineProperty");
113
+
114
+ /***/ }),
115
+
116
+ /***/ 11:
117
+ /***/ (function(module, exports) {
118
+
112
119
  module.exports = require("@babel/runtime/helpers/extends");
113
120
 
114
121
  /***/ }),
115
122
 
116
- /***/ 15:
123
+ /***/ 17:
117
124
  /***/ (function(module, exports) {
118
125
 
119
126
  module.exports = require("@splunk/react-ui/Markdown");
@@ -127,75 +134,82 @@ module.exports = require("styled-components");
127
134
 
128
135
  /***/ }),
129
136
 
130
- /***/ 39:
137
+ /***/ 4:
131
138
  /***/ (function(module, exports) {
132
139
 
133
- module.exports = require("@babel/runtime/helpers/inherits");
140
+ module.exports = require("@babel/runtime/helpers/classCallCheck");
134
141
 
135
142
  /***/ }),
136
143
 
137
- /***/ 40:
144
+ /***/ 6:
138
145
  /***/ (function(module, exports) {
139
146
 
140
- module.exports = require("@babel/runtime/helpers/getPrototypeOf");
147
+ module.exports = require("@splunk/react-ui/Heading");
141
148
 
142
149
  /***/ }),
143
150
 
144
- /***/ 45:
151
+ /***/ 60:
145
152
  /***/ (function(module, exports) {
146
153
 
147
- module.exports = require("@babel/runtime/helpers/assertThisInitialized");
154
+ module.exports = require("@babel/runtime/helpers/inherits");
148
155
 
149
156
  /***/ }),
150
157
 
151
- /***/ 46:
158
+ /***/ 61:
152
159
  /***/ (function(module, exports) {
153
160
 
154
- module.exports = require("@babel/runtime/helpers/possibleConstructorReturn");
161
+ module.exports = require("@babel/runtime/helpers/getPrototypeOf");
155
162
 
156
163
  /***/ }),
157
164
 
158
- /***/ 47:
165
+ /***/ 66:
159
166
  /***/ (function(module, exports) {
160
167
 
161
- module.exports = require("@splunk/react-ui/JSONTree");
168
+ module.exports = require("@babel/runtime/helpers/assertThisInitialized");
162
169
 
163
170
  /***/ }),
164
171
 
165
- /***/ 5:
172
+ /***/ 67:
166
173
  /***/ (function(module, exports) {
167
174
 
168
- module.exports = require("@babel/runtime/helpers/classCallCheck");
175
+ module.exports = require("@babel/runtime/helpers/possibleConstructorReturn");
169
176
 
170
177
  /***/ }),
171
178
 
172
- /***/ 6:
179
+ /***/ 68:
173
180
  /***/ (function(module, exports) {
174
181
 
175
- module.exports = require("@splunk/react-ui/Heading");
182
+ module.exports = require("@splunk/react-ui/JSONTree");
176
183
 
177
184
  /***/ }),
178
185
 
179
- /***/ 60:
186
+ /***/ 7:
187
+ /***/ (function(module, exports) {
188
+
189
+ module.exports = require("@babel/runtime/helpers/createClass");
190
+
191
+ /***/ }),
192
+
193
+ /***/ 82:
180
194
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
181
195
 
182
196
  "use strict";
183
197
  __webpack_require__.r(__webpack_exports__);
184
- /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(10);
198
+ /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
185
199
  /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__);
186
- /* harmony import */ var _babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(45);
200
+ /* harmony import */ var _babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(66);
187
201
  /* harmony import */ var _babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_1__);
188
- /* harmony import */ var _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9);
202
+ /* harmony import */ var _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(10);
189
203
  /* harmony import */ var _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_2__);
190
- /* harmony import */ var _babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5);
204
+ /* harmony import */ var _babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4);
191
205
  /* harmony import */ var _babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_3__);
192
206
  /* harmony import */ var _babel_runtime_helpers_createClass__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7);
193
207
  /* harmony import */ var _babel_runtime_helpers_createClass__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_createClass__WEBPACK_IMPORTED_MODULE_4__);
194
- /* harmony import */ var _babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(39);
208
+ /* harmony import */ var _babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(60);
195
209
  /* harmony import */ var _babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_5__);
196
- /* harmony import */ var _babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(46);
210
+ /* harmony import */ var _babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(67);
197
211
  /* harmony import */ var _babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_6__);
198
- /* harmony import */ var _babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(40);
212
+ /* harmony import */ var _babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(61);
199
213
  /* harmony import */ var _babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_7__);
200
214
  /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(0);
201
215
  /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_8__);
@@ -203,9 +217,9 @@ __webpack_require__.r(__webpack_exports__);
203
217
  /* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_9__);
204
218
  /* harmony import */ var _splunk_react_ui_Heading__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(6);
205
219
  /* harmony import */ var _splunk_react_ui_Heading__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(_splunk_react_ui_Heading__WEBPACK_IMPORTED_MODULE_10__);
206
- /* harmony import */ var _splunk_react_ui_Markdown__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(15);
220
+ /* harmony import */ var _splunk_react_ui_Markdown__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(17);
207
221
  /* harmony import */ var _splunk_react_ui_Markdown__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(_splunk_react_ui_Markdown__WEBPACK_IMPORTED_MODULE_11__);
208
- /* harmony import */ var _splunk_react_ui_JSONTree__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(47);
222
+ /* harmony import */ var _splunk_react_ui_JSONTree__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(68);
209
223
  /* harmony import */ var _splunk_react_ui_JSONTree__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(_splunk_react_ui_JSONTree__WEBPACK_IMPORTED_MODULE_12__);
210
224
  /* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(2);
211
225
  /* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(styled_components__WEBPACK_IMPORTED_MODULE_13__);
@@ -467,20 +481,6 @@ EventsDoc.propTypes = {
467
481
  };
468
482
  /* harmony default export */ __webpack_exports__["default"] = (EventsDoc);
469
483
 
470
- /***/ }),
471
-
472
- /***/ 7:
473
- /***/ (function(module, exports) {
474
-
475
- module.exports = require("@babel/runtime/helpers/createClass");
476
-
477
- /***/ }),
478
-
479
- /***/ 9:
480
- /***/ (function(module, exports) {
481
-
482
- module.exports = require("@babel/runtime/helpers/defineProperty");
483
-
484
484
  /***/ })
485
485
 
486
486
  /******/ });
@@ -1 +1 @@
1
- {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///external \"react\"","webpack:///external \"prop-types\"","webpack:///external \"@babel/runtime/helpers/extends\"","webpack:///external \"@splunk/react-ui/Markdown\"","webpack:///external \"styled-components\"","webpack:///external \"@babel/runtime/helpers/inherits\"","webpack:///external \"@babel/runtime/helpers/getPrototypeOf\"","webpack:///external \"@babel/runtime/helpers/assertThisInitialized\"","webpack:///external \"@babel/runtime/helpers/possibleConstructorReturn\"","webpack:///external \"@splunk/react-ui/JSONTree\"","webpack:///external \"@babel/runtime/helpers/classCallCheck\"","webpack:///external \"@splunk/react-ui/Heading\"","webpack:///./src/common/EventsDoc.jsx","webpack:///external \"@babel/runtime/helpers/createClass\"","webpack:///external \"@babel/runtime/helpers/defineProperty\""],"names":["EventTester","styled","Event","EventName","EventItem","name","desc","marginLeft","T","string","EventsDesc","events","vizType","Object","description","VisExample","options","Visualization","dsState","onEventTrigger","height","width","PureComponent","number","EventExample","event","eventToDisplay","content","useMemo","JSON","object","EventsDoc","e","key","handleEvent","Component","any"],"mappings":";;;;;;;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;Q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tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 60);\n","module.exports = require(\"react\");","module.exports = require(\"prop-types\");","module.exports = require(\"@babel/runtime/helpers/extends\");","module.exports = require(\"@splunk/react-ui/Markdown\");","module.exports = require(\"styled-components\");","module.exports = require(\"@babel/runtime/helpers/inherits\");","module.exports = require(\"@babel/runtime/helpers/getPrototypeOf\");","module.exports = require(\"@babel/runtime/helpers/assertThisInitialized\");","module.exports = require(\"@babel/runtime/helpers/possibleConstructorReturn\");","module.exports = require(\"@splunk/react-ui/JSONTree\");","module.exports = require(\"@babel/runtime/helpers/classCallCheck\");","module.exports = require(\"@splunk/react-ui/Heading\");","/* eslint-disable react/no-multi-comp */\n/* eslint-disable max-classes-per-file */\nimport React, { Component, PureComponent, useMemo } from 'react';\nimport T from 'prop-types';\nimport Heading from '@splunk/react-ui/Heading';\nimport Markdown from '@splunk/react-ui/Markdown';\nimport JSONTree from '@splunk/react-ui/JSONTree';\nimport styled from 'styled-components';\n\nconst EventTester = styled.div`\n margin-top: 50px;\n`;\n\nconst Event = styled.div`\n margin-top: 20px;\n`;\nconst EventName = styled.div`\n color: #5ca300;\n padding-bottom: 5px;\n`;\n\nconst EventItem = ({ name, desc }) => (\n <Event>\n <EventName>{name}</EventName>\n <Markdown style={{ marginLeft: 40 }} text={desc} />\n </Event>\n);\n\nEventItem.propTypes = {\n name: T.string,\n desc: T.string,\n};\n\nconst EventsDesc = ({ events, vizType }) => (\n <div>\n <Heading level={4}>\n {Object.keys(events).length !== 0 || vizType === 'splunk.events' ? 'Events' : 'No Events'}\n </Heading>\n {vizType === 'splunk.events' && (\n <Markdown text=\"Events are dynamically added via the `eventActions` and `fieldActions` options for the Events visualization.\" />\n )}\n {Object.keys(events).map(eventName => (\n <EventItem key={eventName} name={eventName} desc={events[eventName].description} />\n ))}\n </div>\n);\n\nEventsDesc.propTypes = {\n events: T.object.isRequired,\n vizType: T.string,\n};\n\nclass VisExample extends PureComponent {\n render() {\n const { options = {}, Visualization, dsState, onEventTrigger, height, width } = this.props;\n return (\n <EventTester>\n <Heading level={4}>Test Visualization</Heading>\n <Visualization\n options={options}\n dataSources={dsState}\n onEventTrigger={onEventTrigger}\n hasEventHandlers\n height={height}\n width={width}\n />\n </EventTester>\n );\n }\n}\n\nVisExample.propTypes = {\n options: T.object,\n Visualization: T.any,\n dsState: T.object,\n onEventTrigger: T.func,\n height: T.number,\n width: T.number,\n};\n\nconst EventExample = ({ event }) => {\n const eventToDisplay = {\n ...event,\n };\n if (eventToDisplay.originalEvent != null) {\n eventToDisplay.originalEvent = '...Original Event instance...';\n }\n\n const content = useMemo(\n () => <JSONTree key={JSON.stringify(eventToDisplay)} json={eventToDisplay} expandChildren />,\n [eventToDisplay]\n );\n\n return (\n <React.Fragment>\n <Heading level={4}>Event Monitor</Heading>\n {content}\n </React.Fragment>\n );\n};\n\nEventExample.propTypes = {\n event: T.object,\n};\n\nclass EventsDoc extends Component {\n constructor(props, context) {\n super(props, context);\n this.state = {\n e: null,\n };\n }\n\n handleEvent = e => {\n this.setState({\n e,\n });\n };\n\n render() {\n return (\n <div>\n <EventsDesc events={this.props.events} vizType={this.props?.Visualization?.config?.key} />\n <VisExample {...this.props} onEventTrigger={this.handleEvent} />\n <EventExample event={this.state.e} />\n </div>\n );\n }\n}\n\nEventsDoc.propTypes = {\n options: T.object,\n events: T.object,\n dsState: T.object,\n Visualization: T.any,\n};\n\nexport default EventsDoc;\n","module.exports = require(\"@babel/runtime/helpers/createClass\");","module.exports = require(\"@babel/runtime/helpers/defineProperty\");"],"sourceRoot":""}
1
+ {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///external \"react\"","webpack:///external \"prop-types\"","webpack:///external \"@babel/runtime/helpers/defineProperty\"","webpack:///external \"@babel/runtime/helpers/extends\"","webpack:///external \"@splunk/react-ui/Markdown\"","webpack:///external \"styled-components\"","webpack:///external \"@babel/runtime/helpers/classCallCheck\"","webpack:///external \"@splunk/react-ui/Heading\"","webpack:///external \"@babel/runtime/helpers/inherits\"","webpack:///external \"@babel/runtime/helpers/getPrototypeOf\"","webpack:///external \"@babel/runtime/helpers/assertThisInitialized\"","webpack:///external \"@babel/runtime/helpers/possibleConstructorReturn\"","webpack:///external \"@splunk/react-ui/JSONTree\"","webpack:///external \"@babel/runtime/helpers/createClass\"","webpack:///./src/common/EventsDoc.jsx"],"names":["EventTester","styled","Event","EventName","EventItem","name","desc","marginLeft","T","string","EventsDesc","events","vizType","Object","description","VisExample","options","Visualization","dsState","onEventTrigger","height","width","PureComponent","number","EventExample","event","eventToDisplay","content","useMemo","JSON","object","EventsDoc","e","key","handleEvent","Component","any"],"mappings":";;;;;;;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;AClFA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dA;AACH;;AAED,MAAMC,OAAO,GAAGC,qDAAO,CACnB;AAAA,wBAAM;AAAU,SAAG,EAAEC,IAAI,CAAJA,UAAf,cAAeA,CAAf;AAA+C,UAAI,EAAnD;AAAqE,oBAAc;AAAnF,MAAN;AADmB,KAEnB,CAFJ,cAEI,CAFmB,CAAvB;AAKA,sBACI,2DAAC,4CAAD,8BACI;AAAS,SAAK,EAAE;AAAhB,KADJ,eACI,CADJ,EADJ,OACI,CADJ;AAbJ;;AAqBAL,YAAY,CAAZA,YAAyB;AACrBC,OAAK,EAAEjB,iDAAC,CAACsB;AADY,CAAzBN;;IAIMO,S;;;;;AACF,qCAA4B;AAAA;;AAAA;;AACxB;;AADwB,4LAOd,aAAK;AACf,qBAAc;AACVC,SAAC,EAADA;AADU,OAAd;AARwB;;AAExB,kBAAa;AACTA,OAAC,EAAE;AADM,KAAb;AAFwB;AAK3B;;;;WAQD,kBAAS;AAAA;;AACL,0BACI,qFACI;AAAY,cAAM,EAAE,WAApB;AAAuC,eAAO,kBAAE,KAAF,+EAAE,aAAF,iGAAE,sBAAF,iEAAE,uBAAmCC;AAAnF,QADJ,eAEI,iJAAgB,KAAhB;AAA4B,sBAAc,EAAE,KAAKC;AAAjD,SAFJ,eAGI;AAAc,aAAK,EAAE,WAAWF;AAAhC,QAHJ,CADJ;AAOH;;;;EAtBmBG,+C;;AAyBxBJ,SAAS,CAATA,YAAsB;AAClBf,SAAO,EAAER,iDAAC,CADQ;AAElBG,QAAM,EAAEH,iDAAC,CAFS;AAGlBU,SAAO,EAAEV,iDAAC,CAHQ;AAIlBS,eAAa,EAAET,iDAAC,CAAC4B;AAJC,CAAtBL;AAOA,0E","file":"EventsDoc.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 82);\n","module.exports = require(\"react\");","module.exports = require(\"prop-types\");","module.exports = require(\"@babel/runtime/helpers/defineProperty\");","module.exports = require(\"@babel/runtime/helpers/extends\");","module.exports = require(\"@splunk/react-ui/Markdown\");","module.exports = require(\"styled-components\");","module.exports = require(\"@babel/runtime/helpers/classCallCheck\");","module.exports = require(\"@splunk/react-ui/Heading\");","module.exports = require(\"@babel/runtime/helpers/inherits\");","module.exports = require(\"@babel/runtime/helpers/getPrototypeOf\");","module.exports = require(\"@babel/runtime/helpers/assertThisInitialized\");","module.exports = require(\"@babel/runtime/helpers/possibleConstructorReturn\");","module.exports = require(\"@splunk/react-ui/JSONTree\");","module.exports = require(\"@babel/runtime/helpers/createClass\");","/* eslint-disable react/no-multi-comp */\n/* eslint-disable max-classes-per-file */\nimport React, { Component, PureComponent, useMemo } from 'react';\nimport T from 'prop-types';\nimport Heading from '@splunk/react-ui/Heading';\nimport Markdown from '@splunk/react-ui/Markdown';\nimport JSONTree from '@splunk/react-ui/JSONTree';\nimport styled from 'styled-components';\n\nconst EventTester = styled.div`\n margin-top: 50px;\n`;\n\nconst Event = styled.div`\n margin-top: 20px;\n`;\nconst EventName = styled.div`\n color: #5ca300;\n padding-bottom: 5px;\n`;\n\nconst EventItem = ({ name, desc }) => (\n <Event>\n <EventName>{name}</EventName>\n <Markdown style={{ marginLeft: 40 }} text={desc} />\n </Event>\n);\n\nEventItem.propTypes = {\n name: T.string,\n desc: T.string,\n};\n\nconst EventsDesc = ({ events, vizType }) => (\n <div>\n <Heading level={4}>\n {Object.keys(events).length !== 0 || vizType === 'splunk.events' ? 'Events' : 'No Events'}\n </Heading>\n {vizType === 'splunk.events' && (\n <Markdown text=\"Events are dynamically added via the `eventActions` and `fieldActions` options for the Events visualization.\" />\n )}\n {Object.keys(events).map(eventName => (\n <EventItem key={eventName} name={eventName} desc={events[eventName].description} />\n ))}\n </div>\n);\n\nEventsDesc.propTypes = {\n events: T.object.isRequired,\n vizType: T.string,\n};\n\nclass VisExample extends PureComponent {\n render() {\n const { options = {}, Visualization, dsState, onEventTrigger, height, width } = this.props;\n return (\n <EventTester>\n <Heading level={4}>Test Visualization</Heading>\n <Visualization\n options={options}\n dataSources={dsState}\n onEventTrigger={onEventTrigger}\n hasEventHandlers\n height={height}\n width={width}\n />\n </EventTester>\n );\n }\n}\n\nVisExample.propTypes = {\n options: T.object,\n Visualization: T.any,\n dsState: T.object,\n onEventTrigger: T.func,\n height: T.number,\n width: T.number,\n};\n\nconst EventExample = ({ event }) => {\n const eventToDisplay = {\n ...event,\n };\n if (eventToDisplay.originalEvent != null) {\n eventToDisplay.originalEvent = '...Original Event instance...';\n }\n\n const content = useMemo(\n () => <JSONTree key={JSON.stringify(eventToDisplay)} json={eventToDisplay} expandChildren />,\n [eventToDisplay]\n );\n\n return (\n <React.Fragment>\n <Heading level={4}>Event Monitor</Heading>\n {content}\n </React.Fragment>\n );\n};\n\nEventExample.propTypes = {\n event: T.object,\n};\n\nclass EventsDoc extends Component {\n constructor(props, context) {\n super(props, context);\n this.state = {\n e: null,\n };\n }\n\n handleEvent = e => {\n this.setState({\n e,\n });\n };\n\n render() {\n return (\n <div>\n <EventsDesc events={this.props.events} vizType={this.props?.Visualization?.config?.key} />\n <VisExample {...this.props} onEventTrigger={this.handleEvent} />\n <EventExample event={this.state.e} />\n </div>\n );\n }\n}\n\nEventsDoc.propTypes = {\n options: T.object,\n events: T.object,\n dsState: T.object,\n Visualization: T.any,\n};\n\nexport default EventsDoc;\n"],"sourceRoot":""}
@@ -87,7 +87,7 @@ module.exports =
87
87
  /******/
88
88
  /******/
89
89
  /******/ // Load entry module and return exports
90
- /******/ return __webpack_require__(__webpack_require__.s = 61);
90
+ /******/ return __webpack_require__(__webpack_require__.s = 83);
91
91
  /******/ })
92
92
  /************************************************************************/
93
93
  /******/ ({
@@ -106,20 +106,13 @@ module.exports = require("prop-types");
106
106
 
107
107
  /***/ }),
108
108
 
109
- /***/ 10:
109
+ /***/ 11:
110
110
  /***/ (function(module, exports) {
111
111
 
112
112
  module.exports = require("@babel/runtime/helpers/extends");
113
113
 
114
114
  /***/ }),
115
115
 
116
- /***/ 16:
117
- /***/ (function(module, exports) {
118
-
119
- module.exports = require("@splunk/visualizations-shared/numberUtils");
120
-
121
- /***/ }),
122
-
123
116
  /***/ 2:
124
117
  /***/ (function(module, exports) {
125
118
 
@@ -127,14 +120,14 @@ module.exports = require("styled-components");
127
120
 
128
121
  /***/ }),
129
122
 
130
- /***/ 61:
123
+ /***/ 83:
131
124
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
132
125
 
133
126
  "use strict";
134
127
  __webpack_require__.r(__webpack_exports__);
135
128
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MajorTick", function() { return MajorTick; });
136
129
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "positionMajorTick", function() { return positionMajorTick; });
137
- /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(10);
130
+ /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
138
131
  /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__);
139
132
  /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
140
133
  /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
@@ -142,7 +135,7 @@ __webpack_require__.r(__webpack_exports__);
142
135
  /* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_2__);
143
136
  /* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2);
144
137
  /* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(styled_components__WEBPACK_IMPORTED_MODULE_3__);
145
- /* harmony import */ var _splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(16);
138
+ /* harmony import */ var _splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9);
146
139
  /* harmony import */ var _splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__);
147
140
 
148
141
 
@@ -179,6 +172,7 @@ var MajorTick = function MajorTick(_ref) {
179
172
  majorTickStrokeColor = _ref.majorTickStrokeColor,
180
173
  majorTickFillColor = _ref.majorTickFillColor;
181
174
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default.a.createElement("g", null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default.a.createElement(MajorTickLine, {
175
+ "data-test": "major-tick-line",
182
176
  index: index,
183
177
  x1: x1,
184
178
  y1: y1,
@@ -188,7 +182,8 @@ var MajorTick = function MajorTick(_ref) {
188
182
  }), showLabels && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default.a.createElement(MajorTickLabel, {
189
183
  x: labelX,
190
184
  y: labelY,
191
- majorTickFillColor: majorTickFillColor
185
+ majorTickFillColor: majorTickFillColor,
186
+ "data-test": "major-tick-label"
192
187
  }, Object(_splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__["isNumerial"])(label) ? Object(_splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__["formatNumber"])(label, 0, {
193
188
  useThousandSeparators: true,
194
189
  useTrendUnits: true
@@ -380,6 +375,13 @@ MajorTicks.defaultProps = {
380
375
  };
381
376
  /* harmony default export */ __webpack_exports__["default"] = (MajorTicks);
382
377
 
378
+ /***/ }),
379
+
380
+ /***/ 9:
381
+ /***/ (function(module, exports) {
382
+
383
+ module.exports = require("@splunk/visualizations-shared/numberUtils");
384
+
383
385
  /***/ })
384
386
 
385
387
  /******/ });
@@ -1 +1 @@
1
- {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///external \"react\"","webpack:///external \"prop-types\"","webpack:///external \"@babel/runtime/helpers/extends\"","webpack:///external \"@splunk/visualizations-shared/numberUtils\"","webpack:///external \"styled-components\"","webpack:///./src/common/GaugeMajorTicks.jsx"],"names":["DEFAULT_NUM_OF_TICKS","TICK_LENGTH_DELTA","TICK_LABEL_PADDING_FACTOR","MajorTickLine","styled","props","MajorTickLabel","MajorTick","index","x1","y1","x2","y2","showLabels","label","labelX","labelY","majorTickStrokeColor","majorTickFillColor","formatNumber","useThousandSeparators","useTrendUnits","T","string","positionMajorTick","width","height","startX","startY","orientation","numOfTicks","i","y","x","MajorTicks","min","max","majorUnit","usePercentageRange","range","Number","majorTicks","parseInt","extraNumOfTicks","Math"],"mappings":";;;;;;;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QACh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AAAA,QAEnBC,EAFmB;AAAA,QAEfC,GAFe;AAAA,QAEXC,GAFW;AAAA,QAEPG,OAFO;AAAA,QAECC,OAFD;;AAY/ByB,cAAU,CAAVA,mBACI;AACI,SAAG,EADP;AAEI,QAAE,EAFN;AAGI,QAAE,EAHN;AAII,QAAE,EAJN;AAKI,QAAE,EALN;AAMI,QAAE,EANN;AAOI,gBAAU,EAPd;AAQI,WAAK,EAAEH,kBAAkB,YAR7B;AASI,YAAM,EATV;AAUI,YAAM,EAVV;AAWI,wBAAkB,EAXtB;AAYI,0BAAoB,EAAErB;AAZ1B,MADJwB;AAgBH;;AAED,sBAAO,sEAAP,UAAO,CAAP;AAtFJ;;AAyFAP,UAAU,CAAVA,YAAuB;AACnBT,OAAK,EAAEH,iDAAC,CADW;AAEnBI,QAAM,EAAEJ,iDAAC,CAFU;AAGnBK,QAAM,EAAEL,iDAAC,CAHU;AAInBM,QAAM,EAAEN,iDAAC,CAJU;AAKnBa,KAAG,EAAEb,iDAAC,CALa;AAMnBc,KAAG,EAAEd,iDAAC,CANa;AAOnBe,WAAS,EAAEf,iDAAC,CAADA,UAAY,CAACA,iDAAC,CAAF,QAAWA,iDAAC,CAPhB,MAOI,CAAZA,CAPQ;AAQnBO,aAAW,EAAEP,iDAAC,CARK;AASnBT,YAAU,EAAES,iDAAC,CATM;AAUnBgB,oBAAkB,EAAEhB,iDAAC,CAVF;AAWnBJ,oBAAkB,EAAEI,iDAAC,CAXF;AAYnBL,sBAAoB,EAAEK,iDAAC,CAACC;AAZL,CAAvBW;AAeAA,UAAU,CAAVA,eAA0B;AACtBC,KAAG,EADmB;AAEtBC,KAAG,EAFmB;AAGtBC,WAAS,EAHa;AAItBR,aAAW,EAJW;AAKtBhB,YAAU,EALY;AAMtByB,oBAAkB,EAAE;AANE,CAA1BJ;AASA,2E","file":"GaugeMajorTicks.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 61);\n","module.exports = require(\"react\");","module.exports = require(\"prop-types\");","module.exports = require(\"@babel/runtime/helpers/extends\");","module.exports = require(\"@splunk/visualizations-shared/numberUtils\");","module.exports = require(\"styled-components\");","import React from 'react';\nimport T from 'prop-types';\nimport styled from 'styled-components';\nimport { isNumerial, formatNumber } from '@splunk/visualizations-shared/numberUtils';\n\nconst DEFAULT_NUM_OF_TICKS = 5;\nconst TICK_LENGTH_DELTA = 5;\nconst TICK_LABEL_PADDING_FACTOR = 3.2;\n\nconst MajorTickLine = styled.line`\n stroke: ${props => props.majorTickStrokeColor};\n stroke-width: 2px;\n stroke-dasharray: ${props => (props.index === 0 ? 0 : 3)};\n`;\n\nconst MajorTickLabel = styled.text`\n font-size: 12px;\n font-family: Splunk Platform Sans, sans-serif;\n line-height: 19px;\n fill: ${props => props.majorTickFillColor};\n text-anchor: middle;\n text-align: center;\n`;\n\nexport const MajorTick = ({\n index,\n x1,\n y1,\n x2,\n y2,\n showLabels,\n label,\n labelX,\n labelY,\n majorTickStrokeColor,\n majorTickFillColor,\n}) => (\n <g>\n <MajorTickLine\n index={index}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n majorTickStrokeColor={majorTickStrokeColor}\n />\n {showLabels && (\n <MajorTickLabel x={labelX} y={labelY} majorTickFillColor={majorTickFillColor}>\n {isNumerial(label)\n ? formatNumber(label, 0, {\n useThousandSeparators: true,\n useTrendUnits: true,\n })\n : label}\n </MajorTickLabel>\n )}\n </g>\n);\n\nMajorTick.propTypes = {\n index: T.number,\n x1: T.number,\n y1: T.number,\n x2: T.number,\n y2: T.number,\n showLabels: T.bool,\n label: T.oneOfType([T.string, T.number]),\n labelX: T.number,\n labelY: T.number,\n majorTickStrokeColor: T.string,\n majorTickFillColor: T.string,\n};\n\n/**\n * calculate position for each major tick\n * @method positionMajorTick\n * @param {Object} input\n * @param {Number} input.width\n * @param {Number} input.height\n * @param {Number} input.startX start x for rendering the first major tick\n * @param {Number} input.startY start y for rendering the first major tick\n * @param {String} input.orientation\n * @param {Number} input.numOfTicks how many ticks need to render\n * @param {Number} input.i index of major tick\n * @return {Object} MajorTick positions\n */\nexport const positionMajorTick = ({ width, height, startX, startY, orientation, numOfTicks, i }) => {\n let x1 = startX;\n let y1 = startY;\n let x2 = startX;\n let y2 = startY;\n let labelX = startX;\n let labelY;\n\n if (orientation === 'vertical') {\n const y = (height / numOfTicks) * (numOfTicks - i) + startY;\n x1 -= TICK_LENGTH_DELTA;\n y1 = y;\n x2 += width + TICK_LENGTH_DELTA;\n y2 = y;\n labelX += width + TICK_LENGTH_DELTA * TICK_LABEL_PADDING_FACTOR;\n labelY = y;\n } else {\n const x = (width / numOfTicks) * i + startX;\n x1 = x;\n y1 -= TICK_LENGTH_DELTA;\n x2 = x;\n y2 += height + TICK_LENGTH_DELTA;\n labelX = x;\n labelY = y2 + 16;\n }\n\n return { x1, y1, x2, y2, labelX, labelY };\n};\n\nconst MajorTicks = ({ ...props }) => {\n const {\n width,\n height,\n startX,\n startY,\n min,\n max,\n majorUnit,\n orientation,\n showLabels,\n usePercentageRange,\n majorTickFillColor,\n majorTickStrokeColor,\n } = props;\n\n const range = max - min;\n const numOfTicks =\n majorUnit === 'auto' || Number.isNaN(Number(majorUnit)) || majorUnit <= 0\n ? DEFAULT_NUM_OF_TICKS\n : range / majorUnit;\n const majorTicks = [];\n\n for (let i = 0; i <= numOfTicks; i += 1) {\n const { x1, y1, x2, y2, labelX, labelY } = positionMajorTick({\n width,\n height,\n startX,\n startY,\n orientation,\n numOfTicks,\n i,\n });\n const label = usePercentageRange\n ? `${parseInt((i / numOfTicks - min / range) * 100, 10)}%`\n : parseInt(min + (range / numOfTicks) * i, 10);\n\n majorTicks.push(\n <MajorTick\n key={i}\n index={i}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n showLabels={showLabels}\n label={label}\n labelX={labelX}\n labelY={labelY}\n majorTickFillColor={majorTickFillColor}\n majorTickStrokeColor={majorTickStrokeColor}\n />\n );\n }\n\n // if the gauge is not divided evenly, put the last tick at the end of the gauge\n if (!Number.isInteger(numOfTicks)) {\n const extraNumOfTicks = Math.ceil(numOfTicks);\n const { x1, y1, x2, y2, labelX, labelY } = positionMajorTick({\n width,\n height,\n startX,\n startY,\n orientation,\n numOfTicks: extraNumOfTicks,\n i: extraNumOfTicks,\n });\n\n majorTicks.push(\n <MajorTick\n key={extraNumOfTicks}\n id={extraNumOfTicks}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n showLabels={showLabels}\n label={usePercentageRange ? '100%' : max}\n labelX={labelX}\n labelY={labelY}\n majorTickFillColor={majorTickFillColor}\n majorTickStrokeColor={majorTickStrokeColor}\n />\n );\n }\n\n return <g>{majorTicks}</g>;\n};\n\nMajorTicks.propTypes = {\n width: T.number,\n height: T.number,\n startX: T.number,\n startY: T.number,\n min: T.number,\n max: T.number,\n majorUnit: T.oneOfType([T.string, T.number]),\n orientation: T.string,\n showLabels: T.bool,\n usePercentageRange: T.bool,\n majorTickFillColor: T.string,\n majorTickStrokeColor: T.string,\n};\n\nMajorTicks.defaultProps = {\n min: 0,\n max: 100,\n majorUnit: 'auto',\n orientation: 'horizontal',\n showLabels: true,\n usePercentageRange: false,\n};\n\nexport default MajorTicks;\n"],"sourceRoot":""}
1
+ {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///external \"react\"","webpack:///external \"prop-types\"","webpack:///external \"@babel/runtime/helpers/extends\"","webpack:///external \"styled-components\"","webpack:///./src/common/GaugeMajorTicks.jsx","webpack:///external \"@splunk/visualizations-shared/numberUtils\""],"names":["DEFAULT_NUM_OF_TICKS","TICK_LENGTH_DELTA","TICK_LABEL_PADDING_FACTOR","MajorTickLine","styled","props","MajorTickLabel","MajorTick","index","x1","y1","x2","y2","showLabels","label","labelX","labelY","majorTickStrokeColor","majorTickFillColor","formatNumber","useThousandSeparators","useTrendUnits","T","string","positionMajorTick","width","height","startX","startY","orientation","numOfTicks","i","y","x","MajorTicks","min","max","majorUnit","usePercentageRange","range","Number","majorTicks","parseInt","extraNumOfTicks","Math"],"mappings":";;;;;;;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;AClFA,kC;;;;;;;ACAA,uC;;;;;;;ACAA,2D;;;;;;;ACAA,8C;;;;;;;;;;;;;;;;;;;;;;ACAA;AACA;AACA;AACA;AAEA,IAAMA,oBAAoB,GAA1B;AACA,IAAMC,iBAAiB,GAAvB;AACA,IAAMC,yBAAyB,GAA/B;AAEA,IAAMC,aAAa,GAAGC,wDAAM,CAAT,IAAGA,CAAH,UAAGA,CAAH;AAAA;AAAA;AAAA,CAAGA,EAAH,uDAAGA,EACR,iBAAK;AAAA,SAAIC,KAAK,CAAT;AADA,CAAGD,EAGE,iBAAK;AAAA,SAAKC,KAAK,C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B;AACnBT,OAAK,EAAEH,iDAAC,CADW;AAEnBI,QAAM,EAAEJ,iDAAC,CAFU;AAGnBK,QAAM,EAAEL,iDAAC,CAHU;AAInBM,QAAM,EAAEN,iDAAC,CAJU;AAKnBa,KAAG,EAAEb,iDAAC,CALa;AAMnBc,KAAG,EAAEd,iDAAC,CANa;AAOnBe,WAAS,EAAEf,iDAAC,CAADA,UAAY,CAACA,iDAAC,CAAF,QAAWA,iDAAC,CAPhB,MAOI,CAAZA,CAPQ;AAQnBO,aAAW,EAAEP,iDAAC,CARK;AASnBT,YAAU,EAAES,iDAAC,CATM;AAUnBgB,oBAAkB,EAAEhB,iDAAC,CAVF;AAWnBJ,oBAAkB,EAAEI,iDAAC,CAXF;AAYnBL,sBAAoB,EAAEK,iDAAC,CAACC;AAZL,CAAvBW;AAeAA,UAAU,CAAVA,eAA0B;AACtBC,KAAG,EADmB;AAEtBC,KAAG,EAFmB;AAGtBC,WAAS,EAHa;AAItBR,aAAW,EAJW;AAKtBhB,YAAU,EALY;AAMtByB,oBAAkB,EAAE;AANE,CAA1BJ;AASA,2E;;;;;;;AC1OA,sE","file":"GaugeMajorTicks.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 83);\n","module.exports = require(\"react\");","module.exports = require(\"prop-types\");","module.exports = require(\"@babel/runtime/helpers/extends\");","module.exports = require(\"styled-components\");","import React from 'react';\nimport T from 'prop-types';\nimport styled from 'styled-components';\nimport { isNumerial, formatNumber } from '@splunk/visualizations-shared/numberUtils';\n\nconst DEFAULT_NUM_OF_TICKS = 5;\nconst TICK_LENGTH_DELTA = 5;\nconst TICK_LABEL_PADDING_FACTOR = 3.2;\n\nconst MajorTickLine = styled.line`\n stroke: ${props => props.majorTickStrokeColor};\n stroke-width: 2px;\n stroke-dasharray: ${props => (props.index === 0 ? 0 : 3)};\n`;\n\nconst MajorTickLabel = styled.text`\n font-size: 12px;\n font-family: Splunk Platform Sans, sans-serif;\n line-height: 19px;\n fill: ${props => props.majorTickFillColor};\n text-anchor: middle;\n text-align: center;\n`;\n\nexport const MajorTick = ({\n index,\n x1,\n y1,\n x2,\n y2,\n showLabels,\n label,\n labelX,\n labelY,\n majorTickStrokeColor,\n majorTickFillColor,\n}) => (\n <g>\n <MajorTickLine\n data-test=\"major-tick-line\"\n index={index}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n majorTickStrokeColor={majorTickStrokeColor}\n />\n {showLabels && (\n <MajorTickLabel\n x={labelX}\n y={labelY}\n majorTickFillColor={majorTickFillColor}\n data-test=\"major-tick-label\"\n >\n {isNumerial(label)\n ? formatNumber(label, 0, {\n useThousandSeparators: true,\n useTrendUnits: true,\n })\n : label}\n </MajorTickLabel>\n )}\n </g>\n);\n\nMajorTick.propTypes = {\n index: T.number,\n x1: T.number,\n y1: T.number,\n x2: T.number,\n y2: T.number,\n showLabels: T.bool,\n label: T.oneOfType([T.string, T.number]),\n labelX: T.number,\n labelY: T.number,\n majorTickStrokeColor: T.string,\n majorTickFillColor: T.string,\n};\n\n/**\n * calculate position for each major tick\n * @method positionMajorTick\n * @param {Object} input\n * @param {Number} input.width\n * @param {Number} input.height\n * @param {Number} input.startX start x for rendering the first major tick\n * @param {Number} input.startY start y for rendering the first major tick\n * @param {String} input.orientation\n * @param {Number} input.numOfTicks how many ticks need to render\n * @param {Number} input.i index of major tick\n * @return {Object} MajorTick positions\n */\nexport const positionMajorTick = ({ width, height, startX, startY, orientation, numOfTicks, i }) => {\n let x1 = startX;\n let y1 = startY;\n let x2 = startX;\n let y2 = startY;\n let labelX = startX;\n let labelY;\n\n if (orientation === 'vertical') {\n const y = (height / numOfTicks) * (numOfTicks - i) + startY;\n x1 -= TICK_LENGTH_DELTA;\n y1 = y;\n x2 += width + TICK_LENGTH_DELTA;\n y2 = y;\n labelX += width + TICK_LENGTH_DELTA * TICK_LABEL_PADDING_FACTOR;\n labelY = y;\n } else {\n const x = (width / numOfTicks) * i + startX;\n x1 = x;\n y1 -= TICK_LENGTH_DELTA;\n x2 = x;\n y2 += height + TICK_LENGTH_DELTA;\n labelX = x;\n labelY = y2 + 16;\n }\n\n return { x1, y1, x2, y2, labelX, labelY };\n};\n\nconst MajorTicks = ({ ...props }) => {\n const {\n width,\n height,\n startX,\n startY,\n min,\n max,\n majorUnit,\n orientation,\n showLabels,\n usePercentageRange,\n majorTickFillColor,\n majorTickStrokeColor,\n } = props;\n\n const range = max - min;\n const numOfTicks =\n majorUnit === 'auto' || Number.isNaN(Number(majorUnit)) || majorUnit <= 0\n ? DEFAULT_NUM_OF_TICKS\n : range / majorUnit;\n const majorTicks = [];\n\n for (let i = 0; i <= numOfTicks; i += 1) {\n const { x1, y1, x2, y2, labelX, labelY } = positionMajorTick({\n width,\n height,\n startX,\n startY,\n orientation,\n numOfTicks,\n i,\n });\n const label = usePercentageRange\n ? `${parseInt((i / numOfTicks - min / range) * 100, 10)}%`\n : parseInt(min + (range / numOfTicks) * i, 10);\n\n majorTicks.push(\n <MajorTick\n key={i}\n index={i}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n showLabels={showLabels}\n label={label}\n labelX={labelX}\n labelY={labelY}\n majorTickFillColor={majorTickFillColor}\n majorTickStrokeColor={majorTickStrokeColor}\n />\n );\n }\n\n // if the gauge is not divided evenly, put the last tick at the end of the gauge\n if (!Number.isInteger(numOfTicks)) {\n const extraNumOfTicks = Math.ceil(numOfTicks);\n const { x1, y1, x2, y2, labelX, labelY } = positionMajorTick({\n width,\n height,\n startX,\n startY,\n orientation,\n numOfTicks: extraNumOfTicks,\n i: extraNumOfTicks,\n });\n\n majorTicks.push(\n <MajorTick\n key={extraNumOfTicks}\n id={extraNumOfTicks}\n x1={x1}\n y1={y1}\n x2={x2}\n y2={y2}\n showLabels={showLabels}\n label={usePercentageRange ? '100%' : max}\n labelX={labelX}\n labelY={labelY}\n majorTickFillColor={majorTickFillColor}\n majorTickStrokeColor={majorTickStrokeColor}\n />\n );\n }\n\n return <g>{majorTicks}</g>;\n};\n\nMajorTicks.propTypes = {\n width: T.number,\n height: T.number,\n startX: T.number,\n startY: T.number,\n min: T.number,\n max: T.number,\n majorUnit: T.oneOfType([T.string, T.number]),\n orientation: T.string,\n showLabels: T.bool,\n usePercentageRange: T.bool,\n majorTickFillColor: T.string,\n majorTickStrokeColor: T.string,\n};\n\nMajorTicks.defaultProps = {\n min: 0,\n max: 100,\n majorUnit: 'auto',\n orientation: 'horizontal',\n showLabels: true,\n usePercentageRange: false,\n};\n\nexport default MajorTicks;\n","module.exports = require(\"@splunk/visualizations-shared/numberUtils\");"],"sourceRoot":""}
@@ -87,7 +87,7 @@ module.exports =
87
87
  /******/
88
88
  /******/
89
89
  /******/ // Load entry module and return exports
90
- /******/ return __webpack_require__(__webpack_require__.s = 62);
90
+ /******/ return __webpack_require__(__webpack_require__.s = 84);
91
91
  /******/ })
92
92
  /************************************************************************/
93
93
  /******/ ({
@@ -106,20 +106,13 @@ module.exports = require("prop-types");
106
106
 
107
107
  /***/ }),
108
108
 
109
- /***/ 10:
109
+ /***/ 11:
110
110
  /***/ (function(module, exports) {
111
111
 
112
112
  module.exports = require("@babel/runtime/helpers/extends");
113
113
 
114
114
  /***/ }),
115
115
 
116
- /***/ 16:
117
- /***/ (function(module, exports) {
118
-
119
- module.exports = require("@splunk/visualizations-shared/numberUtils");
120
-
121
- /***/ }),
122
-
123
116
  /***/ 2:
124
117
  /***/ (function(module, exports) {
125
118
 
@@ -127,14 +120,14 @@ module.exports = require("styled-components");
127
120
 
128
121
  /***/ }),
129
122
 
130
- /***/ 62:
123
+ /***/ 84:
131
124
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
132
125
 
133
126
  "use strict";
134
127
  __webpack_require__.r(__webpack_exports__);
135
128
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "positionValueMarkerRect", function() { return positionValueMarkerRect; });
136
129
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "positionLabel", function() { return positionLabel; });
137
- /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(10);
130
+ /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
138
131
  /* harmony import */ var _babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_extends__WEBPACK_IMPORTED_MODULE_0__);
139
132
  /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
140
133
  /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
@@ -142,7 +135,7 @@ __webpack_require__.r(__webpack_exports__);
142
135
  /* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_2__);
143
136
  /* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2);
144
137
  /* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(styled_components__WEBPACK_IMPORTED_MODULE_3__);
145
- /* harmony import */ var _splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(16);
138
+ /* harmony import */ var _splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9);
146
139
  /* harmony import */ var _splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_splunk_visualizations_shared_numberUtils__WEBPACK_IMPORTED_MODULE_4__);
147
140
 
148
141
 
@@ -337,6 +330,13 @@ ValueMarker.defaultProps = {
337
330
  };
338
331
  /* harmony default export */ __webpack_exports__["default"] = (ValueMarker);
339
332
 
333
+ /***/ }),
334
+
335
+ /***/ 9:
336
+ /***/ (function(module, exports) {
337
+
338
+ module.exports = require("@splunk/visualizations-shared/numberUtils");
339
+
340
340
  /***/ })
341
341
 
342
342
  /******/ });