@digi-frontend/dgate-api-documentation 1.0.1 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.editorconfig +12 -12
- package/.prettierignore +7 -7
- package/.prettierrc +15 -15
- package/dist/{2e10bbdb265df50e.svg → 43595976d1fdccbf.svg} +4 -4
- package/dist/{8789eb84283ea95b.svg → 56dc416b683db280.svg} +5 -5
- package/dist/{bb8b87cace25e052.svg → 64efc2716808c4a4.svg} +3 -3
- package/dist/{d32ce84bbd78babd.svg → 72db3b05a96dd600.svg} +3 -3
- package/dist/{d501922060662842.svg → 844eba3f2e42a9eb.svg} +3 -3
- package/dist/_virtual/index10.js +1 -1
- package/dist/_virtual/index21.js +2 -0
- package/dist/_virtual/index21.js.map +1 -0
- package/dist/_virtual/index3.js +1 -1
- package/dist/_virtual/index5.js +1 -1
- package/dist/_virtual/index6.js +1 -1
- package/dist/_virtual/index7.js +1 -1
- package/dist/_virtual/index8.js +1 -1
- package/dist/_virtual/index9.js +1 -1
- package/dist/_virtual/node2.js +2 -0
- package/dist/_virtual/node2.js.map +1 -0
- package/dist/_virtual/node3.js +2 -0
- package/dist/_virtual/node3.js.map +1 -0
- package/dist/{070dc6ecd197bc80.svg → a7568b270e175038.svg} +8 -8
- package/dist/{9bdff13f8d8fa48a.svg → af16a554be8c4d69.svg} +3 -3
- package/dist/{7f54eeb0bb2d1150.svg → b82c7612e73342f3.svg} +3 -3
- package/dist/node_modules/digitinary-ui/dist/index.js +1 -1
- package/dist/node_modules/digitinary-ui/dist/index.js.map +1 -1
- package/dist/node_modules/domelementtype/lib/index.js +1 -1
- package/dist/node_modules/formik/dist/formik.esm.js +1 -1
- package/dist/node_modules/html-dom-parser/lib/index.js +1 -1
- package/dist/node_modules/html-dom-parser/lib/server/html-to-dom.js +1 -1
- package/dist/node_modules/html-dom-parser/lib/server/html-to-dom.js.map +1 -1
- package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/index.js +2 -0
- package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/index.js.map +1 -0
- package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/node.js +2 -0
- package/dist/node_modules/html-dom-parser/node_modules/domhandler/lib/node.js.map +1 -0
- package/dist/node_modules/html-react-parser/esm/index.mjs.js +1 -1
- package/dist/node_modules/html-react-parser/esm/index.mjs.js.map +1 -1
- package/dist/node_modules/html-react-parser/lib/index.js +1 -1
- package/dist/node_modules/html-react-parser/lib/index.js.map +1 -1
- package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/index.js +2 -0
- package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/index.js.map +1 -0
- package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/node.js +2 -0
- package/dist/node_modules/html-react-parser/node_modules/domhandler/lib/node.js.map +1 -0
- package/dist/node_modules/htmlparser2/dist/commonjs/Parser.js +1 -1
- package/dist/node_modules/htmlparser2/dist/commonjs/Parser.js.map +1 -1
- package/dist/node_modules/htmlparser2/dist/commonjs/Tokenizer.js +1 -1
- package/dist/node_modules/htmlparser2/dist/commonjs/Tokenizer.js.map +1 -1
- package/dist/node_modules/htmlparser2/dist/commonjs/index.js +1 -1
- package/dist/node_modules/htmlparser2/dist/commonjs/index.js.map +1 -1
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/foreignNames.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/foreignNames.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/index.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/lib/index.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/encode.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/encode.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/escape.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/escape.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/index.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/dom-serializer/node_modules/entities/lib/index.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/index.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/index.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/node.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domhandler/lib/node.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/feeds.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/feeds.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/helpers.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/helpers.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/index.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/index.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/legacy.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/legacy.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/manipulation.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/manipulation.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/querying.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/querying.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/stringify.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/stringify.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/traversal.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/domutils/lib/traversal.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode-codepoint.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode-codepoint.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/decode.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-html.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-html.js.map +1 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +2 -0
- package/dist/node_modules/htmlparser2/node_modules/entities/dist/commonjs/generated/decode-data-xml.js.map +1 -0
- package/dist/node_modules/react/cjs/react-jsx-runtime.development.js +1 -1
- package/dist/node_modules/react/cjs/react-jsx-runtime.development.js.map +1 -1
- package/dist/node_modules/react-fast-compare/index.js +1 -1
- package/dist/node_modules/react-fast-compare/index.js.map +1 -1
- package/dist/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/react-property/lib/index.js +1 -1
- package/dist/node_modules/react-property/lib/index.js.map +1 -1
- package/dist/node_modules/style-to-object/cjs/index.js +1 -1
- package/dist/node_modules/toposort/index.js +1 -1
- package/dist/node_modules/yup/index.esm.js +1 -1
- package/dist/node_modules/yup/index.esm.js.map +1 -1
- package/dist/src/assets/icons/AddRow.svg.js +1 -1
- package/dist/src/assets/icons/AddRow.svg.js.map +1 -1
- package/dist/src/assets/icons/CheckMarkSquare.svg.js +2 -0
- package/dist/src/assets/icons/CheckMarkSquare.svg.js.map +1 -0
- package/dist/src/assets/icons/CloseIcon.svg.js +1 -1
- package/dist/src/assets/icons/CloseIcon.svg.js.map +1 -1
- package/dist/src/assets/icons/DeleteIcon.svg.js +1 -1
- package/dist/src/assets/icons/DeleteIcon.svg.js.map +1 -1
- package/dist/src/assets/icons/DownArrow.svg.js +1 -1
- package/dist/src/assets/icons/DownArrow.svg.js.map +1 -1
- package/dist/src/assets/icons/EditIcon.svg.js +1 -1
- package/dist/src/assets/icons/EditIcon.svg.js.map +1 -1
- package/dist/src/assets/icons/UpArrow.svg.js +1 -1
- package/dist/src/assets/icons/UpArrow.svg.js.map +1 -1
- package/dist/src/assets/icons/deleteOutlinedIcon.svg.js +2 -0
- package/dist/src/assets/icons/deleteOutlinedIcon.svg.js.map +1 -0
- package/dist/src/components/Chips/Chips.js +2 -0
- package/dist/src/components/Chips/Chips.js.map +1 -0
- package/dist/src/components/InfoForm/InfoForm.js +1 -1
- package/dist/src/components/InfoForm/InfoForm.js.map +1 -1
- package/dist/src/components/JsonInput/JsonInput.js +1 -1
- package/dist/src/components/JsonInput/JsonInput.js.map +1 -1
- package/dist/src/components/LivePreview/LivePreview.js +1 -1
- package/dist/src/components/LivePreview/LivePreview.js.map +1 -1
- package/dist/src/components/MethodAccordion/MethodAccordion.js +1 -1
- package/dist/src/components/MethodAccordion/MethodAccordion.js.map +1 -1
- package/dist/src/components/SVGLoader/SVGLoader.js.map +1 -1
- package/dist/src/components/SectionHead/SectionHead.js.map +1 -1
- package/dist/src/components/SimpleLabelValue/SimpleLabelValue.js.map +1 -1
- package/dist/src/components/Tooltip/Tooltip.js.map +1 -1
- package/dist/src/components/dialog/index.js +1 -1
- package/dist/src/components/dialog/index.js.map +1 -1
- package/dist/src/components/table/table.js +1 -1
- package/dist/src/components/table/table.js.map +1 -1
- package/dist/src/constants/index.js +1 -1
- package/dist/src/constants/index.js.map +1 -1
- package/dist/src/constants/regex.js +1 -1
- package/dist/src/constants/regex.js.map +1 -1
- package/dist/src/helpers/layout.helper.js +1 -1
- package/dist/src/helpers/layout.helper.js.map +1 -1
- package/dist/src/helpers/methodAccordion.helper.js.map +1 -1
- package/dist/src/index.js +1 -1
- package/dist/src/layout/layout.js +1 -1
- package/dist/src/layout/layout.js.map +1 -1
- package/dist/src/layout/layout.module.css.js +1 -1
- package/dist/src/validator/form.scheme.js +1 -1
- package/dist/src/validator/form.scheme.js.map +1 -1
- package/dist/styles.css +430 -1863
- package/dist/types/assets/icons/index.d.ts +1 -17
- package/dist/types/components/InfoForm/InfoForm.d.ts +1 -3
- package/dist/types/components/JsonInput/JsonInput.d.ts +1 -2
- package/dist/types/components/LivePreview/LivePreview.d.ts +0 -1
- package/dist/types/components/MethodAccordion/MethodAccordion.d.ts +2 -7
- package/dist/types/components/Tooltip/Tooltip.d.ts +2 -2
- package/dist/types/components/dialog/dialog.d.ts +0 -6
- package/dist/types/components/dialog/index.d.ts +1 -1
- package/dist/types/components/table/table.d.ts +1 -2
- package/dist/types/constants/index.d.ts +0 -11
- package/dist/types/constants/regex.d.ts +0 -2
- package/dist/types/index.d.ts +0 -1
- package/dist/types/layout/layout.d.ts +1 -4
- package/dist/types/types/layout.type.d.ts +1 -3
- package/dist/types/types/openApi.d.ts +4 -17
- package/dist/types/validator/form.scheme.d.ts +3 -12
- package/package.json +43 -47
- package/rollup.config.js +35 -37
- package/src/assets/icons/AddRow.svg +3 -3
- package/src/assets/icons/CheckMarkSquare.svg +5 -5
- package/src/assets/icons/CloseIcon.svg +4 -4
- package/src/assets/icons/DeleteIcon.svg +3 -3
- package/src/assets/icons/DownArrow.svg +3 -3
- package/src/assets/icons/EditIcon.svg +3 -3
- package/src/assets/icons/UpArrow.svg +3 -3
- package/src/assets/icons/deleteOutlinedIcon.svg +8 -8
- package/src/assets/icons/index.ts +8 -24
- package/src/components/Chips/Chips.tsx +87 -87
- package/src/components/Chips/style.scss +147 -147
- package/src/components/InfoForm/InfoForm.module.scss +15 -165
- package/src/components/InfoForm/InfoForm.tsx +124 -424
- package/src/components/JsonInput/JsonInput.tsx +124 -149
- package/src/components/JsonInput/style.module.scss +123 -133
- package/src/components/LivePreview/LivePreview.module.scss +5 -181
- package/src/components/LivePreview/LivePreview.tsx +80 -224
- package/src/components/MethodAccordion/MethodAccordion.module.scss +294 -399
- package/src/components/MethodAccordion/MethodAccordion.tsx +401 -1063
- package/src/components/SVGLoader/SVGLoader.tsx +94 -96
- package/src/components/SectionHead/SectionHead.scss +29 -29
- package/src/components/SectionHead/SectionHead.tsx +22 -22
- package/src/components/SimpleLabelValue/SimpleLabelValue.tsx +31 -31
- package/src/components/SimpleLabelValue/index.ts +1 -1
- package/src/components/SimpleLabelValue/style.scss +30 -30
- package/src/components/Tooltip/Tooltip.scss +130 -133
- package/src/components/Tooltip/Tooltip.tsx +86 -85
- package/src/components/_global.scss +337 -337
- package/src/components/dialog/dialog.ts +54 -61
- package/src/components/dialog/index.tsx +85 -88
- package/src/components/dialog/style.scss +104 -188
- package/src/components/table/style.scss +179 -223
- package/src/components/table/table.tsx +307 -490
- package/src/constants/index.ts +74 -95
- package/src/constants/regex.ts +5 -7
- package/src/global.d.ts +13 -13
- package/src/helpers/layout.helper.ts +147 -187
- package/src/helpers/methodAccordion.helper.ts +19 -19
- package/src/index.ts +1 -2
- package/src/layout/layout.module.css +56 -65
- package/src/layout/layout.tsx +99 -181
- package/src/types/index.ts +0 -28
- package/src/types/layout.type.ts +30 -32
- package/src/types/openApi.ts +95 -109
- package/src/types/transformedOpenApi.ts +52 -52
- package/src/validator/form.scheme.ts +70 -96
- package/tsconfig.json +33 -33
- package/dist/16702d92fd6d1730.svg +0 -6
- package/dist/2b546d6e9fdf604a.svg +0 -3
- package/dist/2c3c6c2c3b835504.svg +0 -5
- package/dist/55b5994c5781482b.svg +0 -5
- package/dist/60bef8083c55f46b.svg +0 -6
- package/dist/68c710e0583e19e6.svg +0 -5
- package/dist/731221b3f242672d.svg +0 -4
- package/dist/8520b6792278d9df.svg +0 -6
- package/dist/9506ef7a26a74147.svg +0 -12
- package/dist/9b7aee27757b5036.svg +0 -3
- package/dist/_virtual/core.js +0 -2
- package/dist/_virtual/core.js.map +0 -1
- package/dist/_virtual/core2.js +0 -2
- package/dist/_virtual/core2.js.map +0 -1
- package/dist/_virtual/format.js +0 -2
- package/dist/_virtual/format.js.map +0 -1
- package/dist/_virtual/json.js +0 -2
- package/dist/_virtual/json.js.map +0 -1
- package/dist/cceb1e5dc06b0b85.svg +0 -4
- package/dist/d140a601c85bac25.svg +0 -3
- package/dist/d6d0a98ec38e6b77.svg +0 -3
- package/dist/e04479ad425e7d58.svg +0 -4
- package/dist/f4452c3ebcf0d5da.svg +0 -4
- package/dist/f4a32992f02af522.svg +0 -5
- package/dist/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/defineProperty.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/defineProperty.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/extends.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/extends.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/iterableToArray.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/iterableToArray.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/toPrimitive.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/toPrimitive.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/typeof.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/typeof.js.map +0 -1
- package/dist/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js +0 -2
- package/dist/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js.map +0 -1
- package/dist/node_modules/dom-serializer/lib/foreignNames.js +0 -2
- package/dist/node_modules/dom-serializer/lib/foreignNames.js.map +0 -1
- package/dist/node_modules/dom-serializer/lib/index.js +0 -2
- package/dist/node_modules/dom-serializer/lib/index.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/decode_codepoint.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/encode.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/encode.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/escape.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/escape.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-html.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/decode-data-xml.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/generated/encode-html.js.map +0 -1
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/index.js +0 -2
- package/dist/node_modules/dom-serializer/node_modules/entities/lib/index.js.map +0 -1
- package/dist/node_modules/domhandler/lib/index.js +0 -2
- package/dist/node_modules/domhandler/lib/index.js.map +0 -1
- package/dist/node_modules/domhandler/lib/node.js +0 -2
- package/dist/node_modules/domhandler/lib/node.js.map +0 -1
- package/dist/node_modules/domutils/lib/feeds.js +0 -2
- package/dist/node_modules/domutils/lib/feeds.js.map +0 -1
- package/dist/node_modules/domutils/lib/helpers.js +0 -2
- package/dist/node_modules/domutils/lib/helpers.js.map +0 -1
- package/dist/node_modules/domutils/lib/index.js +0 -2
- package/dist/node_modules/domutils/lib/index.js.map +0 -1
- package/dist/node_modules/domutils/lib/legacy.js +0 -2
- package/dist/node_modules/domutils/lib/legacy.js.map +0 -1
- package/dist/node_modules/domutils/lib/manipulation.js +0 -2
- package/dist/node_modules/domutils/lib/manipulation.js.map +0 -1
- package/dist/node_modules/domutils/lib/querying.js +0 -2
- package/dist/node_modules/domutils/lib/querying.js.map +0 -1
- package/dist/node_modules/domutils/lib/stringify.js +0 -2
- package/dist/node_modules/domutils/lib/stringify.js.map +0 -1
- package/dist/node_modules/domutils/lib/traversal.js +0 -2
- package/dist/node_modules/domutils/lib/traversal.js.map +0 -1
- package/dist/node_modules/entities/dist/commonjs/decode-codepoint.js +0 -2
- package/dist/node_modules/entities/dist/commonjs/decode-codepoint.js.map +0 -1
- package/dist/node_modules/entities/dist/commonjs/decode.js +0 -2
- package/dist/node_modules/entities/dist/commonjs/decode.js.map +0 -1
- package/dist/node_modules/entities/dist/commonjs/generated/decode-data-html.js +0 -2
- package/dist/node_modules/entities/dist/commonjs/generated/decode-data-html.js.map +0 -1
- package/dist/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +0 -2
- package/dist/node_modules/entities/dist/commonjs/generated/decode-data-xml.js.map +0 -1
- package/dist/node_modules/fast-json-stable-stringify/index.js +0 -2
- package/dist/node_modules/fast-json-stable-stringify/index.js.map +0 -1
- package/dist/node_modules/fault/index.js +0 -2
- package/dist/node_modules/fault/index.js.map +0 -1
- package/dist/node_modules/format/format.js +0 -2
- package/dist/node_modules/format/format.js.map +0 -1
- package/dist/node_modules/highlight.js/lib/core.js +0 -2
- package/dist/node_modules/highlight.js/lib/core.js.map +0 -1
- package/dist/node_modules/highlight.js/lib/languages/json.js +0 -2
- package/dist/node_modules/highlight.js/lib/languages/json.js.map +0 -1
- package/dist/node_modules/lowlight/lib/core.js +0 -2
- package/dist/node_modules/lowlight/lib/core.js.map +0 -1
- package/dist/node_modules/nanoid/index.js +0 -2
- package/dist/node_modules/nanoid/index.js.map +0 -1
- package/dist/node_modules/nanoid/url-alphabet/index.js +0 -2
- package/dist/node_modules/nanoid/url-alphabet/index.js.map +0 -1
- package/dist/node_modules/react-syntax-highlighter/dist/esm/checkForListedLanguage.js +0 -2
- package/dist/node_modules/react-syntax-highlighter/dist/esm/checkForListedLanguage.js.map +0 -1
- package/dist/node_modules/react-syntax-highlighter/dist/esm/create-element.js +0 -2
- package/dist/node_modules/react-syntax-highlighter/dist/esm/create-element.js.map +0 -1
- package/dist/node_modules/react-syntax-highlighter/dist/esm/highlight.js +0 -2
- package/dist/node_modules/react-syntax-highlighter/dist/esm/highlight.js.map +0 -1
- package/dist/node_modules/react-syntax-highlighter/dist/esm/languages/hljs/json.js +0 -2
- package/dist/node_modules/react-syntax-highlighter/dist/esm/languages/hljs/json.js.map +0 -1
- package/dist/node_modules/react-syntax-highlighter/dist/esm/light.js +0 -2
- package/dist/node_modules/react-syntax-highlighter/dist/esm/light.js.map +0 -1
- package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-dark.js +0 -2
- package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-dark.js.map +0 -1
- package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-light.js +0 -2
- package/dist/node_modules/react-syntax-highlighter/dist/esm/styles/hljs/stackoverflow-light.js.map +0 -1
- package/dist/src/assets/icons/ApiIcon.svg.js +0 -2
- package/dist/src/assets/icons/ApiIcon.svg.js.map +0 -1
- package/dist/src/assets/icons/ArrowBack.svg.js +0 -2
- package/dist/src/assets/icons/ArrowBack.svg.js.map +0 -1
- package/dist/src/assets/icons/BookIcon.svg.js +0 -2
- package/dist/src/assets/icons/BookIcon.svg.js.map +0 -1
- package/dist/src/assets/icons/CopySticker.svg.js +0 -2
- package/dist/src/assets/icons/CopySticker.svg.js.map +0 -1
- package/dist/src/assets/icons/DeleteOutlinedIcon.svg.js +0 -2
- package/dist/src/assets/icons/DeleteOutlinedIcon.svg.js.map +0 -1
- package/dist/src/assets/icons/FilterIcon.svg.js +0 -2
- package/dist/src/assets/icons/FilterIcon.svg.js.map +0 -1
- package/dist/src/assets/icons/Plus.svg.js +0 -2
- package/dist/src/assets/icons/Plus.svg.js.map +0 -1
- package/dist/src/assets/icons/PlusSquare.svg.js +0 -2
- package/dist/src/assets/icons/PlusSquare.svg.js.map +0 -1
- package/dist/src/assets/icons/RequestOption.svg.js +0 -2
- package/dist/src/assets/icons/RequestOption.svg.js.map +0 -1
- package/dist/src/assets/icons/arrowDownGray.svg.js +0 -2
- package/dist/src/assets/icons/arrowDownGray.svg.js.map +0 -1
- package/dist/src/assets/icons/arrowRightGray.svg.js +0 -2
- package/dist/src/assets/icons/arrowRightGray.svg.js.map +0 -1
- package/dist/src/assets/icons/close-circle.svg.js +0 -2
- package/dist/src/assets/icons/close-circle.svg.js.map +0 -1
- package/dist/src/assets/icons/copy.svg.js +0 -2
- package/dist/src/assets/icons/copy.svg.js.map +0 -1
- package/dist/src/assets/icons/document.svg.js +0 -2
- package/dist/src/assets/icons/document.svg.js.map +0 -1
- package/dist/src/assets/icons/eye.svg.js +0 -2
- package/dist/src/assets/icons/eye.svg.js.map +0 -1
- package/dist/src/assets/icons/infoIcon.svg.js +0 -2
- package/dist/src/assets/icons/infoIcon.svg.js.map +0 -1
- package/dist/src/assets/icons/searchIcon.svg.js +0 -2
- package/dist/src/assets/icons/searchIcon.svg.js.map +0 -1
- package/dist/src/components/table/tags-table.js +0 -2
- package/dist/src/components/table/tags-table.js.map +0 -1
- package/dist/src/constants/methods.constant.js +0 -2
- package/dist/src/constants/methods.constant.js.map +0 -1
- package/dist/src/context/SectionToggleContext.js +0 -2
- package/dist/src/context/SectionToggleContext.js.map +0 -1
- package/dist/src/helpers/docs.helper.js +0 -2
- package/dist/src/helpers/docs.helper.js.map +0 -1
- package/dist/src/layout/docsComponents/Codebox/Codebox.js +0 -2
- package/dist/src/layout/docsComponents/Codebox/Codebox.js.map +0 -1
- package/dist/src/layout/docsComponents/Codebox/style.module.scss.js +0 -2
- package/dist/src/layout/docsComponents/Codebox/style.module.scss.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsAside/DocsAside.js +0 -2
- package/dist/src/layout/docsComponents/DocsAside/DocsAside.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsAside/style.module.scss.js +0 -2
- package/dist/src/layout/docsComponents/DocsAside/style.module.scss.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsContent/DocsContent.js +0 -2
- package/dist/src/layout/docsComponents/DocsContent/DocsContent.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsContent/EndpointPage/index.js +0 -2
- package/dist/src/layout/docsComponents/DocsContent/EndpointPage/index.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsContent/OverviewPage/index.js +0 -2
- package/dist/src/layout/docsComponents/DocsContent/OverviewPage/index.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.js +0 -2
- package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.module.scss.js +0 -2
- package/dist/src/layout/docsComponents/DocsHeader/DocsHeader.module.scss.js.map +0 -1
- package/dist/src/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.js +0 -2
- package/dist/src/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.js.map +0 -1
- package/dist/src/layout/docsComponents/index.js +0 -2
- package/dist/src/layout/docsComponents/index.js.map +0 -1
- package/dist/src/layout/docsLayout.js +0 -2
- package/dist/src/layout/docsLayout.js.map +0 -1
- package/dist/src/utils/index.js +0 -2
- package/dist/src/utils/index.js.map +0 -1
- package/dist/types/components/table/tags-table.d.ts +0 -11
- package/dist/types/constants/methods.constant.d.ts +0 -16
- package/dist/types/context/SectionToggleContext.d.ts +0 -37
- package/dist/types/helpers/docs.helper.d.ts +0 -3
- package/dist/types/layout/docsComponents/Codebox/Codebox.d.ts +0 -4
- package/dist/types/layout/docsComponents/DocsAside/DocsAside.d.ts +0 -5
- package/dist/types/layout/docsComponents/DocsContent/DocsContent.d.ts +0 -12
- package/dist/types/layout/docsComponents/DocsContent/EndpointPage/index.d.ts +0 -7
- package/dist/types/layout/docsComponents/DocsContent/OverviewPage/index.d.ts +0 -9
- package/dist/types/layout/docsComponents/DocsHeader/DocsHeader.d.ts +0 -6
- package/dist/types/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.d.ts +0 -18
- package/dist/types/layout/docsComponents/index.d.ts +0 -17
- package/dist/types/layout/docsLayout.d.ts +0 -31
- package/dist/types/types/docsLayout.type.d.ts +0 -7
- package/dist/types/types/index.d.ts +0 -27
- package/dist/types/utils/index.d.ts +0 -2
- package/src/assets/icons/ApiIcon.svg +0 -12
- package/src/assets/icons/ArrowBack.svg +0 -3
- package/src/assets/icons/BookIcon.svg +0 -6
- package/src/assets/icons/CopySticker.svg +0 -6
- package/src/assets/icons/DeleteOutlinedIcon.svg +0 -8
- package/src/assets/icons/FilterIcon.svg +0 -4
- package/src/assets/icons/Plus.svg +0 -5
- package/src/assets/icons/PlusSquare.svg +0 -3
- package/src/assets/icons/RequestOption.svg +0 -5
- package/src/assets/icons/arrowDownGray.svg +0 -3
- package/src/assets/icons/arrowRightGray.svg +0 -3
- package/src/assets/icons/close-circle.svg +0 -5
- package/src/assets/icons/copy.svg +0 -4
- package/src/assets/icons/document.svg +0 -6
- package/src/assets/icons/eye.svg +0 -4
- package/src/assets/icons/infoIcon.svg +0 -5
- package/src/assets/icons/searchIcon.svg +0 -4
- package/src/components/table/tags-table.tsx +0 -348
- package/src/constants/methods.constant.ts +0 -26
- package/src/context/SectionToggleContext.tsx +0 -121
- package/src/helpers/docs.helper.ts +0 -42
- package/src/layout/docsComponents/Codebox/Codebox.tsx +0 -61
- package/src/layout/docsComponents/Codebox/style.module.scss +0 -43
- package/src/layout/docsComponents/DocsAside/DocsAside.tsx +0 -93
- package/src/layout/docsComponents/DocsAside/style.module.scss +0 -113
- package/src/layout/docsComponents/DocsContent/DocsContent.tsx +0 -51
- package/src/layout/docsComponents/DocsContent/EndpointPage/index.tsx +0 -236
- package/src/layout/docsComponents/DocsContent/EndpointPage/style.scss +0 -309
- package/src/layout/docsComponents/DocsContent/OverviewPage/index.tsx +0 -192
- package/src/layout/docsComponents/DocsContent/OverviewPage/style.scss +0 -284
- package/src/layout/docsComponents/DocsContent/style.scss +0 -0
- package/src/layout/docsComponents/DocsHeader/DocsHeader.module.scss +0 -270
- package/src/layout/docsComponents/DocsHeader/DocsHeader.tsx +0 -187
- package/src/layout/docsComponents/DocsSideMenuTree/DocsSideMenuTree.tsx +0 -229
- package/src/layout/docsComponents/DocsSideMenuTree/style.scss +0 -195
- package/src/layout/docsComponents/index.scss +0 -49
- package/src/layout/docsComponents/index.tsx +0 -28
- package/src/layout/docsLayout.tsx +0 -120
- package/src/types/docsLayout.type.ts +0 -7
- package/src/utils/index.ts +0 -12
- package/the_npm_commands.sh +0 -12
- package/variables.txt +0 -4
|
@@ -1,424 +1,124 @@
|
|
|
1
|
-
import { useEffect, useState } from 'react'
|
|
2
|
-
// @ts-ignore
|
|
3
|
-
import { useFormikContext } from 'formik'
|
|
4
|
-
import {
|
|
5
|
-
import styles from './InfoForm.module.scss'
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
const
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
{
|
|
113
|
-
|
|
114
|
-
:
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
delay={[0, 0]}
|
|
126
|
-
onCreate={(instance) =>
|
|
127
|
-
setTooltipRefs((prev) => ({
|
|
128
|
-
...prev,
|
|
129
|
-
[index]: instance,
|
|
130
|
-
}))
|
|
131
|
-
}
|
|
132
|
-
content={
|
|
133
|
-
<div className={styles.editDescTooltipContent}>
|
|
134
|
-
<p className={styles.editDescTooltipContent_header}>Description</p>
|
|
135
|
-
<TextArea
|
|
136
|
-
placeholder="Describe tag..."
|
|
137
|
-
value={item.description}
|
|
138
|
-
disabled={readOnly}
|
|
139
|
-
onChange={(value) => {
|
|
140
|
-
if (value === '' || regex.ASCII.test(value))
|
|
141
|
-
onTableChange('description', value, index)
|
|
142
|
-
}}
|
|
143
|
-
maxLength={25}
|
|
144
|
-
/>
|
|
145
|
-
{!readOnly && (
|
|
146
|
-
<Button
|
|
147
|
-
className={styles.editDescTooltipContent_btn}
|
|
148
|
-
variant="outlined"
|
|
149
|
-
size="small"
|
|
150
|
-
onClick={() => {
|
|
151
|
-
setFieldValue(`tags[${index}].description`, item.description?.trim())
|
|
152
|
-
tooltipRefs[index]?.hide()
|
|
153
|
-
}}
|
|
154
|
-
disabled={!item.description?.trim()}
|
|
155
|
-
>
|
|
156
|
-
Apply
|
|
157
|
-
</Button>
|
|
158
|
-
)}
|
|
159
|
-
</div>
|
|
160
|
-
}
|
|
161
|
-
>
|
|
162
|
-
{readOnly || values.tags[index].description ? (
|
|
163
|
-
<Button
|
|
164
|
-
className={styles.editDescBtn}
|
|
165
|
-
variant="link"
|
|
166
|
-
color="action"
|
|
167
|
-
endIcon={<SVGLoader src={EditIcon} width="1.5rem" height="1.5rem" />}
|
|
168
|
-
></Button>
|
|
169
|
-
) : (
|
|
170
|
-
<Button
|
|
171
|
-
className={styles.editDescBtn}
|
|
172
|
-
variant="link"
|
|
173
|
-
color="action"
|
|
174
|
-
endIcon={<SVGLoader src={EditIcon} width="1.5rem" height="1.5rem" />}
|
|
175
|
-
>
|
|
176
|
-
{readOnly || values.tags[index].description
|
|
177
|
-
? 'View Description'
|
|
178
|
-
: 'Add Description'}
|
|
179
|
-
</Button>
|
|
180
|
-
)}
|
|
181
|
-
</Tooltip>
|
|
182
|
-
</div>
|
|
183
|
-
),
|
|
184
|
-
externalDocs: (
|
|
185
|
-
<div className={styles.paramDescContainer}>
|
|
186
|
-
{values.tags[index].externalDocs?.description && values.tags[index].externalDocs?.url && (
|
|
187
|
-
<a
|
|
188
|
-
className={styles.externalDocsLink}
|
|
189
|
-
href={
|
|
190
|
-
values.tags[index]?.externalDocs?.url &&
|
|
191
|
-
values.tags[index]?.externalDocs?.url?.indexOf('http') > -1
|
|
192
|
-
? values.tags[index]?.externalDocs?.url
|
|
193
|
-
: `https://${values.tags[index]?.externalDocs?.url}`
|
|
194
|
-
}
|
|
195
|
-
target="_blank"
|
|
196
|
-
style={
|
|
197
|
-
!values.tags[index].externalDocs?.description
|
|
198
|
-
? { textDecoration: 'none', pointerEvents: 'none' }
|
|
199
|
-
: {}
|
|
200
|
-
}
|
|
201
|
-
>
|
|
202
|
-
{values.tags[index].externalDocs?.description
|
|
203
|
-
? values.tags[index].externalDocs?.description?.substring(0, 12)
|
|
204
|
-
: readOnly && '-'}
|
|
205
|
-
{values.tags[index].externalDocs?.description &&
|
|
206
|
-
values.tags[index].externalDocs?.description?.length > 12
|
|
207
|
-
? '...'
|
|
208
|
-
: ''}
|
|
209
|
-
</a>
|
|
210
|
-
)}
|
|
211
|
-
|
|
212
|
-
<Tooltip
|
|
213
|
-
arrowWithBorder
|
|
214
|
-
placement="bottom-end"
|
|
215
|
-
type="function"
|
|
216
|
-
trigger="click"
|
|
217
|
-
delay={[0, 0]}
|
|
218
|
-
onCreate={(instance) =>
|
|
219
|
-
setExternalTooltipRefs((prev) => ({
|
|
220
|
-
...prev,
|
|
221
|
-
[index]: instance,
|
|
222
|
-
}))
|
|
223
|
-
}
|
|
224
|
-
content={
|
|
225
|
-
<div className={styles.editDescTooltipContent}>
|
|
226
|
-
<p className={styles.editDescTooltipContent_header}>External Docs Description</p>
|
|
227
|
-
<TextArea
|
|
228
|
-
placeholder="Describe External Doc..."
|
|
229
|
-
value={item.externalDocs?.description}
|
|
230
|
-
disabled={readOnly}
|
|
231
|
-
maxLength={25}
|
|
232
|
-
onChange={(value) => {
|
|
233
|
-
if (value === '' || regex.ASCII.test(value)) {
|
|
234
|
-
onTableChange(
|
|
235
|
-
'externalDocs',
|
|
236
|
-
{ ...item.externalDocs, description: value },
|
|
237
|
-
index
|
|
238
|
-
)
|
|
239
|
-
setDescription(value)
|
|
240
|
-
}
|
|
241
|
-
}}
|
|
242
|
-
/>
|
|
243
|
-
<p className={styles.editDescTooltipContent_header}>External Docs Link</p>
|
|
244
|
-
<TextArea
|
|
245
|
-
placeholder="External Docs Link..."
|
|
246
|
-
value={item.externalDocs?.url}
|
|
247
|
-
disabled={readOnly}
|
|
248
|
-
maxLength={200}
|
|
249
|
-
restrictedCharsRegex={regex.urlRegex}
|
|
250
|
-
onChange={(value) => {
|
|
251
|
-
if (value === '' || regex.ASCII.test(value)) {
|
|
252
|
-
onTableChange('externalDocs', { ...item.externalDocs, url: value }, index)
|
|
253
|
-
setURL(value)
|
|
254
|
-
}
|
|
255
|
-
}}
|
|
256
|
-
/>
|
|
257
|
-
{!readOnly && (
|
|
258
|
-
<Button
|
|
259
|
-
className={styles.editDescTooltipContent_btn}
|
|
260
|
-
variant="outlined"
|
|
261
|
-
size="small"
|
|
262
|
-
onClick={() => {
|
|
263
|
-
setFieldValue(`tags[${index}].externalDocs`, {
|
|
264
|
-
description: description?.trim(),
|
|
265
|
-
url: url?.trim(),
|
|
266
|
-
})
|
|
267
|
-
setDescription('')
|
|
268
|
-
setURL('')
|
|
269
|
-
externalTooltipRefs[index]?.hide()
|
|
270
|
-
}}
|
|
271
|
-
disabled={
|
|
272
|
-
!(
|
|
273
|
-
(values.tags[index].externalDocs?.url && !url?.trim()) ||
|
|
274
|
-
(url?.trim() && regex.urlRegex.test(url))
|
|
275
|
-
)
|
|
276
|
-
}
|
|
277
|
-
>
|
|
278
|
-
Apply
|
|
279
|
-
</Button>
|
|
280
|
-
)}
|
|
281
|
-
</div>
|
|
282
|
-
}
|
|
283
|
-
>
|
|
284
|
-
{readOnly || values.tags[index].externalDocs?.description ? (
|
|
285
|
-
<div className={styles.editExternalDocs}>
|
|
286
|
-
<SVGLoader
|
|
287
|
-
src={EditIcon}
|
|
288
|
-
width="1.5rem"
|
|
289
|
-
height="1.5rem"
|
|
290
|
-
onClick={(e) => {
|
|
291
|
-
e?.stopPropagation()
|
|
292
|
-
setDescription(item.externalDocs?.description)
|
|
293
|
-
setURL(item.externalDocs?.url)
|
|
294
|
-
}}
|
|
295
|
-
/>
|
|
296
|
-
</div>
|
|
297
|
-
) : (
|
|
298
|
-
<Button
|
|
299
|
-
className={styles.editDescBtn}
|
|
300
|
-
variant="link"
|
|
301
|
-
color="action"
|
|
302
|
-
endIcon={<SVGLoader src={EditIcon} width="1.5rem" height="1.5rem" />}
|
|
303
|
-
onClick={() => {
|
|
304
|
-
setDescription(item.externalDocs?.description)
|
|
305
|
-
setURL(item.externalDocs?.url)
|
|
306
|
-
}}
|
|
307
|
-
>
|
|
308
|
-
{readOnly ||
|
|
309
|
-
(values.tags[index]?.externalDocs &&
|
|
310
|
-
(values.tags[index]?.externalDocs?.url ||
|
|
311
|
-
values.tags[index].externalDocs?.description))
|
|
312
|
-
? 'View '
|
|
313
|
-
: 'Add '}{' '}
|
|
314
|
-
External Docs Link
|
|
315
|
-
</Button>
|
|
316
|
-
)}
|
|
317
|
-
</Tooltip>
|
|
318
|
-
|
|
319
|
-
{!readOnly && <div className={styles.paramDescContainer_separator}></div>}
|
|
320
|
-
|
|
321
|
-
{!readOnly && (
|
|
322
|
-
<Button
|
|
323
|
-
className={styles.deleteParamBtn}
|
|
324
|
-
variant="link"
|
|
325
|
-
color="error"
|
|
326
|
-
endIcon={<SVGLoader src={DeleteIcon} width="1.125rem" height="1.125rem" />}
|
|
327
|
-
onClick={() => handleDeleteClick(index, item.name)}
|
|
328
|
-
></Button>
|
|
329
|
-
)}
|
|
330
|
-
</div>
|
|
331
|
-
),
|
|
332
|
-
}))
|
|
333
|
-
}
|
|
334
|
-
|
|
335
|
-
return (
|
|
336
|
-
<form className={styles.apiInfoForm} onSubmit={(e) => e.preventDefault()}>
|
|
337
|
-
<div className={styles.apiDocRow}>
|
|
338
|
-
<Input
|
|
339
|
-
size="large"
|
|
340
|
-
placeholder="e.g. Payments"
|
|
341
|
-
label="API Name"
|
|
342
|
-
required
|
|
343
|
-
value={values?.info?.title}
|
|
344
|
-
maxLength={35}
|
|
345
|
-
onChange={(value) => {
|
|
346
|
-
setFieldValue('info.title', value)
|
|
347
|
-
}}
|
|
348
|
-
onClear={() => {
|
|
349
|
-
setFieldValue('info.title', '')
|
|
350
|
-
}}
|
|
351
|
-
errorMsg={errors?.info?.title}
|
|
352
|
-
restrictedCharactersRegex={regex.basic}
|
|
353
|
-
/>
|
|
354
|
-
<Input size="large" label="Version" required value={values?.info?.version} disabled />
|
|
355
|
-
</div>
|
|
356
|
-
<TextArea
|
|
357
|
-
size="large"
|
|
358
|
-
placeholder="Enter a description of the API's functionality..."
|
|
359
|
-
label="Description"
|
|
360
|
-
value={values?.info?.description}
|
|
361
|
-
maxLength={120}
|
|
362
|
-
required
|
|
363
|
-
onChange={(value: string) => {
|
|
364
|
-
if (value === '' || regex.ASCII.test(value)) {
|
|
365
|
-
setFieldValue('info.description', value)
|
|
366
|
-
}
|
|
367
|
-
}}
|
|
368
|
-
onClear={() => {
|
|
369
|
-
setFieldValue('info.description', '')
|
|
370
|
-
}}
|
|
371
|
-
errorMsg={errors?.info?.description}
|
|
372
|
-
/>
|
|
373
|
-
<div className={styles.paramsTable}>
|
|
374
|
-
<TagsTable
|
|
375
|
-
id="paramter-table"
|
|
376
|
-
data={tableRecords}
|
|
377
|
-
headCells={tagsTableHeaders}
|
|
378
|
-
isFormOpen={isFormOpen}
|
|
379
|
-
setIsFormOpen={setIsFormOpen}
|
|
380
|
-
saveNewRow={saveNewRow}
|
|
381
|
-
readOnly={readOnly}
|
|
382
|
-
/>
|
|
383
|
-
</div>
|
|
384
|
-
<CommonDialog
|
|
385
|
-
status="error"
|
|
386
|
-
content={
|
|
387
|
-
<p
|
|
388
|
-
style={{
|
|
389
|
-
textAlign: 'center',
|
|
390
|
-
fontWeight: 400,
|
|
391
|
-
fontSize: '1rem',
|
|
392
|
-
lineHeight: '1.4375rem',
|
|
393
|
-
}}
|
|
394
|
-
className="delete-msg-container"
|
|
395
|
-
>
|
|
396
|
-
Are you sure you want to delete
|
|
397
|
-
<span className="plan-name">
|
|
398
|
-
{' '}
|
|
399
|
-
Tag <strong>{selectedTagName}</strong>
|
|
400
|
-
</span>
|
|
401
|
-
?
|
|
402
|
-
</p>
|
|
403
|
-
}
|
|
404
|
-
onSubmit={{
|
|
405
|
-
onClick: confirmDeleteTag,
|
|
406
|
-
text: 'Delete',
|
|
407
|
-
color: 'error',
|
|
408
|
-
fullWidth: true,
|
|
409
|
-
}}
|
|
410
|
-
onCancel={{
|
|
411
|
-
text: 'Cancel',
|
|
412
|
-
color: 'action',
|
|
413
|
-
fullWidth: true,
|
|
414
|
-
variant: 'outlined',
|
|
415
|
-
}}
|
|
416
|
-
onClose={() => setOpenDeleteDialog(false)}
|
|
417
|
-
open={openDeleteDialog}
|
|
418
|
-
icon={<SVGLoader src={DeleteOutlinedIcon} width="4.0625rem" height="4.0625rem" />}
|
|
419
|
-
/>
|
|
420
|
-
</form>
|
|
421
|
-
)
|
|
422
|
-
}
|
|
423
|
-
|
|
424
|
-
export default InfoForm
|
|
1
|
+
import { useEffect, useState } from 'react'
|
|
2
|
+
// @ts-ignore
|
|
3
|
+
import { useFormikContext } from 'formik'
|
|
4
|
+
import { Input, SelectGroup, TextArea } from 'digitinary-ui'
|
|
5
|
+
import styles from './InfoForm.module.scss'
|
|
6
|
+
import Chips from '../../components/Chips/Chips'
|
|
7
|
+
import regex from '../../constants/regex'
|
|
8
|
+
import { TransformedOpenApi } from '../../types/transformedOpenApi'
|
|
9
|
+
|
|
10
|
+
const InfoForm = () => {
|
|
11
|
+
const [tagsList, setTagsList] = useState([])
|
|
12
|
+
const [authType, setAuthType] = useState('')
|
|
13
|
+
const { values, setFieldValue, errors } = useFormikContext<TransformedOpenApi>()
|
|
14
|
+
|
|
15
|
+
useEffect(() => {
|
|
16
|
+
if (values && values.tags) {
|
|
17
|
+
setTagsList(values.tags)
|
|
18
|
+
}
|
|
19
|
+
if (values && values.components && values.components.securitySchemes) {
|
|
20
|
+
const authenticatorKeys = Object.keys(values.components.securitySchemes)
|
|
21
|
+
if (authenticatorKeys.length) {
|
|
22
|
+
setAuthType(values.components.securitySchemes[authenticatorKeys[0]].scheme)
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}, [])
|
|
26
|
+
|
|
27
|
+
const capitalize = (str) => {
|
|
28
|
+
if (!str) return ''
|
|
29
|
+
return str.charAt(0).toUpperCase() + str.slice(1)
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
return (
|
|
33
|
+
<form className={styles.apiInfoForm} onSubmit={(e) => e.preventDefault()}>
|
|
34
|
+
<Input
|
|
35
|
+
size="large"
|
|
36
|
+
placeholder="e.g. Payments"
|
|
37
|
+
label="API Name"
|
|
38
|
+
required
|
|
39
|
+
value={values?.info?.title}
|
|
40
|
+
maxLength={25}
|
|
41
|
+
onChange={(value) => {
|
|
42
|
+
setFieldValue('info.title', value)
|
|
43
|
+
}}
|
|
44
|
+
onClear={() => {
|
|
45
|
+
setFieldValue('info.title', '')
|
|
46
|
+
}}
|
|
47
|
+
errorMsg={errors?.info?.title}
|
|
48
|
+
restrictedCharsRegex={regex.basic}
|
|
49
|
+
/>
|
|
50
|
+
<div className={styles.apiDocRow}>
|
|
51
|
+
<Input
|
|
52
|
+
size="large"
|
|
53
|
+
label="API Authentication Type"
|
|
54
|
+
required
|
|
55
|
+
value={capitalize(authType)}
|
|
56
|
+
disabled
|
|
57
|
+
/>
|
|
58
|
+
<Input size="large" label="Version" required value={values?.info?.version} disabled />
|
|
59
|
+
</div>
|
|
60
|
+
<TextArea
|
|
61
|
+
size="large"
|
|
62
|
+
placeholder="Enter a description of the API's functionality..."
|
|
63
|
+
label="Description"
|
|
64
|
+
value={values?.info?.description}
|
|
65
|
+
maxLength={120}
|
|
66
|
+
onChange={(value: string) => {
|
|
67
|
+
setFieldValue('info.description', value)
|
|
68
|
+
}}
|
|
69
|
+
onClear={() => {
|
|
70
|
+
setFieldValue('info.description', '')
|
|
71
|
+
}}
|
|
72
|
+
errorMessage={errors?.info?.description}
|
|
73
|
+
restrictedCharsRegex={regex.restrictNone}
|
|
74
|
+
/>
|
|
75
|
+
<SelectGroup
|
|
76
|
+
value={values.tags.map((item) => ({
|
|
77
|
+
label: item.name,
|
|
78
|
+
value: item.name,
|
|
79
|
+
description: item.description || '',
|
|
80
|
+
}))}
|
|
81
|
+
onChange={(items) =>
|
|
82
|
+
setFieldValue(
|
|
83
|
+
'tags',
|
|
84
|
+
items.map((item) => ({
|
|
85
|
+
name: item.label,
|
|
86
|
+
description: item.description || '',
|
|
87
|
+
}))
|
|
88
|
+
)
|
|
89
|
+
}
|
|
90
|
+
label="Tags"
|
|
91
|
+
options={[
|
|
92
|
+
{
|
|
93
|
+
list: tagsList?.map((item) => ({
|
|
94
|
+
label: item.name,
|
|
95
|
+
value: item.name,
|
|
96
|
+
description: item.description || '',
|
|
97
|
+
})),
|
|
98
|
+
},
|
|
99
|
+
]}
|
|
100
|
+
/>
|
|
101
|
+
{values.tags.length > 0 && (
|
|
102
|
+
<Chips
|
|
103
|
+
className={styles.apiInfoForm_tagsChips}
|
|
104
|
+
items={values.tags.map((t) => ({
|
|
105
|
+
id: t.name,
|
|
106
|
+
label: t.name,
|
|
107
|
+
description: t.description || '',
|
|
108
|
+
}))}
|
|
109
|
+
onDelete={(items) =>
|
|
110
|
+
setFieldValue(
|
|
111
|
+
'tags',
|
|
112
|
+
items.map((item) => ({
|
|
113
|
+
name: item.label,
|
|
114
|
+
description: item.description || '',
|
|
115
|
+
}))
|
|
116
|
+
)
|
|
117
|
+
}
|
|
118
|
+
/>
|
|
119
|
+
)}
|
|
120
|
+
</form>
|
|
121
|
+
)
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export default InfoForm
|