Commit Graph

2321 Commits

Author SHA1 Message Date
Vladimir Slesarev
c63737d574 fix(auth): client_secret may appear in non-authcode flows while also using PKCE (#8146) 2022-08-10 09:28:37 -07:00
yzhe819
c36f240e47 fix(ux): responsive ui display (#8132)
* fix: responsive operation

* fix: responsive tag display

* fix: responsive content type selector

* fix: input display

* fix: width of server selector
2022-08-01 14:11:47 -07:00
Tim Lai
d68b7485b1 fix(lint): upcoming eslint@8 reported errors (#8105)
* fix: duplicate propTypes

* chore(lint): fix extra semicolon
2022-07-19 14:46:43 -07:00
Tim Lai
80cffc2544 fix: audio src cache change (#8102)
* #8057 Fix audio src change issue caused by reconciliation algorithm and that is why audio file load is not starting.


Co-authored-by: Roman Melnyk <r.melnyk@smartrockstars.com>
2022-07-19 11:10:28 -07:00
Mahtis Michel
878e848b9b feat: provide Topbar Logo as a wrappable component (#7521)
* docs(logo): added logo replace docs

Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-07-18 13:55:26 -07:00
Tomas Bruckner
0d5227bb5d feat(ux): add copy to clipboard to operation summary (#8094) 2022-07-18 10:48:57 -07:00
twjasa
a7e23b5a55 fix: remove dead code and format document (#8048) 2022-06-03 09:40:13 -07:00
Tim Lai
41f84aad05 fix: set yaml parser load option to JSON_SCHEMA (#8023) 2022-05-12 15:51:38 -07:00
Maciej Matyjas
abeb168696 fix(ui): avoid empty div when there are no externalDocs (#7997)
* fix(ui): avoid empty div when there are no externalDocs

* test(ui): existence of externalDocs div when present/absent from spec
2022-05-12 15:45:14 -07:00
Tim Lai
3aef3bf2bf fix: remove leftover text in request snippets (#8011) 2022-05-05 09:26:00 -07:00
Tim Lai
ffeb678f86 Revert "fix(oas3): set markdown line breaks to true (#7942)" (#7967)
This reverts commit b1128d7649.
2022-04-01 10:26:53 -07:00
Steven James
b825e44077 fix(fn): RandExp error should not cause UI to completely fail (#7940)
* regexp syntax varies across languages
2022-03-28 16:29:01 -07:00
Tim Lai
ed344ff836 fix(css): alignment of authorization btn (#7955) 2022-03-28 11:26:43 -07:00
Tim Lai
10db26d4e8 refactor(live-response): move h4 to inside div class request-url (#7954) 2022-03-28 11:11:23 -07:00
Tim Lai
b1128d7649 fix(oas3): set markdown line breaks to true (#7942) 2022-03-24 15:47:11 -07:00
Tim Lai
9250e209d4 fix(request-snippets): prevent scrolling errors from missing function (#7941)
* fix(request-snippets): prevent scrolling errors from missing function

* refactor(request-snippets): migrate to functional component

* fix(curl): remove undefined prop and function

* test(live-response): fix import of RequestSnippets
2022-03-24 11:23:42 -07:00
Tim Lai
859b2e149a fix(auth): use aria-label instead of name field (#7930) 2022-03-22 17:17:03 -07:00
twjasa
77d0bb960b feat: add modelcollapse to primitive models (#7557)
* update: primitive-model test with modelcollapse

Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-03-21 14:50:14 -07:00
Raymond Berger
d064198c37 fix(auth): add name tag to bearer input field (#7743)
Co-authored-by: Vladimir Gorej <vladimir.gorej@gmail.com>
Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-03-15 11:42:18 -07:00
Maciej Kowalski
8f63462f9e feat(oauth2): authActions.authPopup plugin accessible wrapper (#7699)
* enables win.open to be extensible by plugins

Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-03-10 14:44:46 -08:00
GhBogdan97
a5aca55f58 fix(css): update flex and overflow properties on tags (#7566)
Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-03-10 12:40:26 -08:00
dewijones92
3d79c24949 fix(examples): allow string created by regex pattern (#7829)
Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-03-03 16:31:00 -08:00
Tim Lai
07d346b516 feat(build): webpack@5 and webpack-dev-server@4 (#7826)
SwaggerUI is now built using `webpack@5`, with dev support for `webpack-dev-server@4`
- ES Module output bundle path now points to `swagger-ui-es-bundle-core`, which does not include dependencies
- No change to CommonJS output bundle or path
- Now uses Asset Modules, which replaces `file-loader`, `raw-loader`, and `url-loader`
- Removed unused rules/loaders for `.woff | .woff2 | .ttf | .eot` fonts and html
- Node polyfills are no longer bundled with `webpack@5`, and must be loaded separately and/or use `resolve.fallback`. 
As an example, SwaggerUI loads `process`, `buffer`, and `stream-browserify` as `devDependencies` in order to build development and production bundles.

SwaggerUI-React
- Now imports `swagger-ui-es-bundle-core`, and similarly outputs `swagger-ui-es-bundle-core` to its `dist` directory

Dev notes:
- Order of execution matters for the production npm build scripts. `build-stylesheets` needs to get built first, 
then cleanup of any empty artifacts, before building the various production bundles
- `Dev-helpers` now relies on `HTMLWebpackPlugin` to inject css and bundle files
2022-03-01 12:08:50 -08:00
Vladimir Gorej
c73d7182b2 fix(build): do not pull whole highlight.js and refractor libs (#7852)
Refs #7851
2022-02-19 20:20:53 +01:00
Anne Stellingwerf
a89c90ec77 fix(oauth2): generate default oauth2RedirectUrl based on page location and path (#7476)
Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-02-01 16:25:52 -08:00
Tim Lai
a0e9923dd5 fix(serverVariables): refresh state on definition change (#7821)
* fix(serverVariables): refresh state on definition change

* test(serverVariables): urls with server variables assertions
2022-02-01 15:57:33 -08:00
Mahtis Michel
2b30a3478d feat(requestSnippets): handle type: string, format: binary or base64 file upload data (#7545)
* test(curlify): assert that data-binary is generated

Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2022-01-31 11:34:45 -08:00
Vladimir Gorej
6c10e4a070 fix(auth): compensate for uninitialized config
Refs #7814
2022-01-31 14:27:46 +01:00
Vladimir Gorej
3ce6477007 refactor(memoizeN): extract support code out of closure (#7805) 2022-01-27 08:57:50 +01:00
Vladimir Gorej
d638e58527 fix(view-plugin): provide resolvers for memoized functions (#7801)
Before this change, memoization happened only on first
argument provided to the functions. Now the memoization
properly handle all arguments.

Refs #7800
2022-01-27 08:46:03 +01:00
Vladimir Gorej
87ccc247e0 refactor(memoize): get rid of memoizee prod dependency (#7799)
The memoizee dependency was replaced with specialization
of lodash.memoize.

Refs #7694
2022-01-26 17:39:47 +01:00
John Bednarczyk
8ea3cfd00f fix(plugins): make swagger-js wrapActions overridable (#7753)
Co-authored-by: John Bednarczyk <john.bednarczyk@singlewire.com>
Co-authored-by: Vladimir Gorej <vladimir.gorej@gmail.com>

Refs #7730
2022-01-26 12:47:42 +01:00
Christian Egli
c6d8d779d0 feat: do not ask for client secret when using auth code with PKCE (#7438)
Co-authored-by: Ignacio Lozano <nacholozano@gmail.com>
Co-authored-by: Vladimir Gorej <vladimir.gorej@gmail.com>

Refs #6290
2022-01-26 10:56:09 +01:00
Vladimir Gorej
8b1c4a7c1a feat(error-handling): introduce unified and configurable error handling (#7761)
Refs #7778
2022-01-24 16:12:13 +01:00
Vladimir Gorej
01a3e55960 fix(security): disable reading config params from URL search params (#7697)
Reading configuration parameters from URL search params 
is by default no longer enabled. To re-enable it, set queryConfigEnabled
configuration parameter to true.

Functionally, this is a breaking change, but given we're just providing
a security vulnerability patch we're considering this a PATCH version bump
only.

Refs #4872
Refs https://github.com/swagger-api/swagger-ui/security/advisories/GHSA-qrmm-w75w-3wpx
2021-12-09 17:28:17 +01:00
Vladimir Gorej
f3d38987aa fix: request JumpToPath components always as container
Refs https://github.com/swagger-api/swagger-editor/issues/2099
2021-11-26 10:52:00 +01:00
Vladimir Gorej
b299be764f fix: introduce Error Boundaries to handle unexpected failures (#7671)
Two new components have been updated via plugin system: ErrorBoundary and Fallback.
These components can be overridden by user plugins.

Refs #7647
2021-11-25 13:47:22 +01:00
Vladimir Gorej
7cc2657699 fix(highlight-code): fix regression code highlight behavior
Refs #7603
2021-11-05 11:54:14 +01:00
Vladimir Gorej
fb7e98a431 fix(servers): prevent UI crash when chaning Server with variables
Closes #7525
2021-11-04 16:27:27 +01:00
Vladimir Gorej
e3640739a4 fix(root-inject): handle errors in functional components properly 2021-11-03 09:49:50 +01:00
Vladimir Gorej
46b4e5cf3f fix(highlight-code): handle mousewheel events properly
SyntaxHighlighter component doesn't support ref. We had
to use different approach to finds it's DOM Node using
ref of the root Node of the render tree for HighlightCode
component.

Refs #7497
2021-11-03 09:49:50 +01:00
Vladimir Gorej
c31cb3079a feat: allow using functional components with hooks 2021-11-03 09:49:50 +01:00
Mahtis Michel
5a5a27e9d5 fix(param-body): fix loosing focus in Try It when typing (#7548)
Originally reported as SWOS-418

Closes #7477
2021-11-03 09:49:50 +01:00
Vladimir Gorej
8553943875 refactor(highlight-code): add UNSAFE prefix for lifecycle methods
Refs #7497
2021-11-03 09:49:50 +01:00
Vladimir Gorej
1283f523e7 fix(servers): compensate when server list contains a null value
Refs https://github.com/swagger-api/swagger-editor/issues/2761
Refs https://github.com/swagger-api/swagger-editor/issues/2710
Refs #7341
2021-11-03 09:49:50 +01:00
Vladimir Gorej
8c79e2a375 refactor: prefix lifecycle methods with UNSAFE_
Refs #7341
2021-11-03 09:49:50 +01:00
Vladimir Gorej
cf9a3657cc chore(deps): replace @kyleshockey/* deps with originals
@kyleshockey/object-assign-deep - replaced by lodash/merge. If behavior
not be compatible well use lodash/mergeWith.

@kyleshockey/xml - by installing stream library directly, we can use origin
xml library without the fork.

Refs #7341
2021-11-03 09:49:50 +01:00
Vladimir Gorej
ef0255f742 chore(deps): replace react-motion library for obj. literal
Refs #7341
2021-11-03 09:49:50 +01:00
Vladimir Gorej
6441ef78a2 chore(deps): update react-inspector to v5.1.1
Refs #7341
2021-11-03 09:49:50 +01:00
Vladimir Gorej
5bfd2d8df1 test(e2e-cypress): fix all failing tests for this script
Problem was with an obsolete and no longer supported
Perf tool for React. Reference to it have been removed.

Refs #7341
2021-11-03 09:49:50 +01:00