Commit Graph

316 Commits

Author SHA1 Message Date
kyle
ecf688171f feat: lazy resolver (#4249)
* default to empty `ImmutableMap` when grabbing op metadata
* pass `errors` into JsonSchema components
* Account for Immutable data structure in JavaScriptonSchema...
    ...and create empty Lists instead of Maps by default.
* Pass ImmutableList through to JsonSchema child components
* Add lazy resolving spec state extensions
* TEMPORARY: disable conventional resolved spec
* WIP
* Use resolveSubtree in Operation display
* Freebie: short-circuit Markdown component if it is given plaintext
* NEW DEFAULT BEHAVIOR: `defaultModelsExpandDepth: 1` does not expand individual models
* Render faked Model expander to trigger resolution
* Baseline support for Editor lifecycles
* Display operation summaries before the operation is resolved
* Test migrations
* WIP
* Swagger2 TIO Body params
* a bit of cleanup
* Debounce string param inputs
* Reach into unresolved operation for deprecated flag, if available
* Fire subtree request outside of render
* Remove debugging flags
* Fix logical errors in spec statePlugins
* TODOs become TODONEs!
* Migrate deeplinking feature to non-resolved spec action
* ESLint fixes
2018-02-23 01:12:53 -08:00
kyle
1e1b7f6063 fix(try-it-out): pass Parameter validation messages around in props for OAS3 (#4162)
* default to empty `ImmutableMap` when grabbing op metadata

* pass `errors` into JsonSchema components

* Account for Immutable data structure in JavaScriptonSchema...

...and create empty Lists instead of Maps by default.

* Pass ImmutableList through to JsonSchema child components
2018-01-25 20:14:35 -08:00
kyle
bb84da4e1d fix(oas3-editor-rendering): default to first server if current server becomes invalid (#4139)
* Remove produces/consumes setter from OperationContainer

* Store consumes/produces information in `meta` key

* Migrate produces value state usage to `meta` key

* use meta consumes data for isXml check

* Fix failing tests

* normalize action name casing

* restore correct produces fallback value logic

* default to first server if current server is invalid
2018-01-19 21:38:12 -06:00
Drew Ballance
286c0e0f72 fix: execution error in IE (#4128) 2018-01-18 21:35:43 -06:00
kyle
7af7121e64 fix: streamline management of user-selected produces and consumes values (#4137)
* Remove produces/consumes setter from OperationContainer

* Store consumes/produces information in `meta` key

* Migrate produces value state usage to `meta` key

* use meta consumes data for isXml check

* Fix failing tests

* normalize action name casing

* restore correct produces fallback value logic
2018-01-18 20:37:44 -06:00
narutowyh
12a9fbc0ca fix: ignore prototype's keys in a handful of for...in loops 2018-01-05 21:57:17 -06:00
Juan J. Jimenez-Anca
bd41b736a8 feat: display last error when definition/config load fails
Contains a breaking internal API change to `errActions.newThrownErr`, which will require a MINOR version bump. Swagger-Editor does not depend on the old usage style.
2018-01-05 21:45:21 -06:00
Kyle Shockey
9bad35ed85 Refactor specPath to Im data structures to avoid waste renders 2017-12-28 18:04:12 -06:00
Kyle Shockey
9d48c4751a Refactor afterLoad interface to expose raw plugin context 2017-12-28 16:26:18 -06:00
kyle
10b4f5d8a7 Merge branch 'master' into support/editor-validation-refactor 2017-12-23 00:18:26 -06:00
kyle
7469705bef Merge branch 'master' into bug/4040-default-tag 2017-12-22 23:35:54 -06:00
Kyle Shockey
57db23ed1f Don't parse non-method path keys as operations 2017-12-22 23:30:38 -06:00
Kyle Shockey
ca0b248df2 Prevent non-object values from being dispatched as new JSON content 2017-12-22 23:19:10 -06:00
Kyle Shockey
27156bb79d Linter fixes 2017-12-22 22:58:37 -06:00
Kyle Shockey
68c689e491 Type-check errors before iterating over them 2017-12-20 13:59:22 -06:00
Kyle Shockey
022b660b8c Merge branch 'master' into support/editor-validation-refactor 2017-12-19 23:29:59 -06:00
Kyle Shockey
7faf79ae38 Fix deepLinking scroll behavior 2017-12-16 00:28:53 -08:00
Kyle Shockey
49333dfadc Merge branch 'master' of github.com:swagger-api/swagger-ui into feature/small-tweaks 2017-12-15 17:22:03 -08:00
Kyle Shockey
a2f8d289a0 Fix error transformer imports 2017-12-15 14:17:12 -08:00
Kyle Shockey
2dd25abbdd Move initOAuth attacher out of core constructor 2017-12-15 14:16:44 -08:00
Kyle Shockey
85c83931c4 Move configs plugin to core 2017-12-14 20:17:31 -08:00
Kyle Shockey
b5c713a72b Eliminate require.context usage 2017-12-14 20:17:31 -08:00
Kyle Shockey
ca7f7ea78b Stop using require.context in error transformers 2017-12-14 20:17:31 -08:00
kyle
a94c6c0e7f Merge branch 'master' into feature/deeplink-zenscroll 2017-12-11 19:05:16 -08:00
kyle
059520e819 Merge branch 'master' into oas-301-support 2017-12-07 17:43:33 -08:00
Kyle Shockey
3b35b0767e Accept OpenAPI 3.* 2017-12-07 17:42:49 -08:00
kyle
bfb4c7a8d7 Merge branch 'master' into feature/spec-path 2017-12-07 16:49:34 -08:00
kyle
70ba6a93ef Merge branch 'master' into bug/3982-oas3-trace-method 2017-12-07 14:03:11 -08:00
Kyle Shockey
328f02c463 Move method filtering logic to Operations component 2017-12-07 14:00:47 -08:00
keik
372b1c6a6a Fix case style 2017-12-06 15:29:34 +09:00
Josh Ponelat
c260263e4e fix issues with deeplink conflicts 2017-12-04 16:10:43 +02:00
Josh Ponelat
3893cb4396 deep linking for models, operations and tags 2017-12-04 16:10:42 +02:00
Josh Ponelat
f6b86d2d33 Refactor layout .show/.isShown to handle branch nodes 2017-12-04 16:09:24 +02:00
Kyle Shockey
bb57fd2406 Send server variables to Client as JS objects 2017-11-30 20:11:30 -08:00
Kyle Shockey
6f5649c6ba Only set the first server as current if we...
...don't already have a currentServer.

This avoids having the selected server reset each time the
operation is expanded, or the Try-It-Out mode is entered.
2017-11-30 17:28:35 -08:00
Kyle Shockey
d7d061b5af Provide operation server data to Swagger-Client 2017-11-30 17:26:49 -08:00
Kyle Shockey
0f86524514 Don't render if there are no servers defined 2017-11-30 17:11:49 -08:00
Kyle Shockey
ef3ccd7a23 Move server styles into its own scss file; add a little polish 2017-11-30 17:06:17 -08:00
Kyle Shockey
0c0c9a6519 LESS bugs 2017-11-30 16:49:26 -08:00
Kyle Shockey
945d7a3a0f Basic OperationServers wireup 2017-11-30 16:34:36 -08:00
Kyle Shockey
efd02106a2 Support namespaces in OAS3 server state 2017-11-30 15:57:37 -08:00
Kyle Shockey
7e9d8f0b37 Wire up OperationServers passthrough 2017-11-30 15:30:46 -08:00
Kyle Shockey
5d3efbb5f7 Display option level information in message, not header 2017-11-30 14:37:26 -08:00
Kyle Shockey
0997c5e5d4 Remove hardwired "Server" header, make global one prettier 2017-11-30 14:34:01 -08:00
Kyle Shockey
21ff236e43 Basic OperationServers display 2017-11-30 14:25:05 -08:00
Kyle Shockey
07a9410ee5 Create OperationServers component 2017-11-30 14:07:42 -08:00
Kyle Shockey
25b9fb28dc Move Server Variables header to a more sensible location 2017-11-30 13:50:39 -08:00
Kyle Shockey
2325118540 Add responseInterceptor as well 2017-11-29 15:55:15 -06:00
Kyle Shockey
ade47ca40e Add requestInterceptor to OAuth2 request authorization calls 2017-11-29 15:54:17 -06:00
Greg Thompson
8ff2d77398 Merge branch 'master' into ft/3052-extensions 2017-11-20 09:48:33 -06:00