瀏覽代碼

Make the checkbox id more unique.

If the swagger.json defines more than one oauth2 Security scheme with
matching scopes, the id of the scope checkboxes were not unique.
As a result the scope for a second security scheme could not be
selected.

By adding the security scheme name to the id, it becomes more unique.
bubble
Stefan Grootscholten 7 年之前
父節點
當前提交
073eff4e10
共有 4 個文件被更改,包括 39 次插入39 次删除
  1. +34
    -34
      dist/swagger-ui-bundle.js
  2. +1
    -1
      dist/swagger-ui-bundle.js.map
  3. +2
    -2
      dist/swagger-ui.js
  4. +2
    -2
      src/core/components/auth/oauth2.jsx

+ 34
- 34
dist/swagger-ui-bundle.js
文件差異過大導致無法顯示
查看文件


+ 1
- 1
dist/swagger-ui-bundle.js.map 查看文件

@@ -1 +1 @@
{"version":3,"file":"swagger-ui-bundle.js","sources":["webpack:///swagger-ui-bundle.js"],"mappings":"AAAA;AAu/FA;AA6+FA;;;;;;;;;;;;;;;;;;;;;;;;;;AAoTA;;;;;;AAoIA;AAi7FA;AAmtCA;AAi0IA;AA2pJA;AA+uFA;AA2rGA;AAgiFA;AA0rFA;AAk9CA;AA2hDA;AA4rCA;AAi6EA;;;;;AA2gCA;AA02JA;;;;;;;;;;;;;;AAuyEA;AA4mIA;AAquJA;AAwsHA;AA2mGA;AAiiEA;AAq4DA;AA+2DA;AAqlBA;;;;;;AAilFA;AAs1FA;;;;;AAy3CA;AA2qFA;AAw2CA;AAwkCA;AAs/CA;AA4kFA;AAy1FA;;;;;;;;;AAm5CA;AA2zIA;AAk4DA;AAolDA","sourceRoot":""}
{"version":3,"file":"swagger-ui-bundle.js","sources":["webpack:///swagger-ui-bundle.js"],"mappings":"AAAA;AAu/FA;AA6+FA;;;;;;;;;;;;;;;;;;;;;;;;;;AAieA;;;;;;AAoIA;AAi7FA;AAmtCA;AAi0IA;AA2pJA;AA86FA;AA89FA;AAslFA;AAkjFA;AA48CA;AA+jDA;AAwrCA;AAm/EA;;;;;AAi1BA;AA02JA;;;;;;;;;;;;;;AAuyEA;AA4mIA;AAquJA;AAwsHA;AAinGA;AAmiEA;AAy4DA;AAm2DA;AAylBA;;;;;;AA6kFA;AAs1FA;;;;;AAy3CA;AA2qFA;AAw2CA;AAqkCA;AAi/CA;AAukFA;AAw1FA;;;;;;;;;AAi6CA;AA2zIA;AAk4DA;AAolDA","sourceRoot":""}

+ 2
- 2
dist/swagger-ui.js
文件差異過大導致無法顯示
查看文件


+ 2
- 2
src/core/components/auth/oauth2.jsx 查看文件

@@ -182,11 +182,11 @@ export default class Oauth2 extends React.Component {
<Row key={ name }>
<div className="checkbox">
<Input data-value={ name }
id={`${name}-checkbox`}
id={`${name}-checkbox-${this.state.name}`}
disabled={ isAuthorized }
type="checkbox"
onChange={ this.onScopeChange }/>
<label htmlFor={`${name}-checkbox`}>
<label htmlFor={`${name}-checkbox-${this.state.name}`}>
<span className="item"></span>
<div className="text">
<p className="name">{name}</p>


Loading…
取消
儲存