فهرست منبع

fix radio input and label

yusuketk 5 سال پیش
والد
کامیت
524555cdd7
1فایلهای تغییر یافته به همراه7 افزوده شده و 7 حذف شده
  1. 7 7
      src/client/js/components/PageEditor/LinkEditModal.jsx

+ 7 - 7
src/client/js/components/PageEditor/LinkEditModal.jsx

@@ -268,7 +268,7 @@ class LinkEditModal extends React.PureComponent {
 
 
   render() {
   render() {
     return (
     return (
-      <Modal isOpen={this.state.show} toggle={this.cancel} size="lg">
+      <Modal isOpen={this.state.show} toggle={this.cancel}>
         <ModalHeader tag="h4" toggle={this.cancel} className="bg-primary text-light">
         <ModalHeader tag="h4" toggle={this.cancel} className="bg-primary text-light">
           Edit Links
           Edit Links
         </ModalHeader>
         </ModalHeader>
@@ -347,10 +347,10 @@ class LinkEditModal extends React.PureComponent {
                           type="radio"
                           type="radio"
                           className="custom-control-input"
                           className="custom-control-input"
                           id="markdownType"
                           id="markdownType"
-                          name={Linker.types.markdownLink}
                           checked={this.state.linkerType === Linker.types.markdownLink}
                           checked={this.state.linkerType === Linker.types.markdownLink}
+                          onClick={() => this.handleSelecteLinkerType(Linker.types.markdownLink)}
                         />
                         />
-                        <label className="custom-control-label" htmlFor="markdownType" onClick={e => this.handleSelecteLinkerType(e.target.name)}>
+                        <label className="custom-control-label" htmlFor="markdownType">
                           Markdown
                           Markdown
                         </label>
                         </label>
                       </div>
                       </div>
@@ -359,10 +359,10 @@ class LinkEditModal extends React.PureComponent {
                           type="radio"
                           type="radio"
                           className="custom-control-input"
                           className="custom-control-input"
                           id="growiType"
                           id="growiType"
-                          name={Linker.types.growiLink}
                           checked={this.state.linkerType === Linker.types.growiLink}
                           checked={this.state.linkerType === Linker.types.growiLink}
+                          onClick={() => this.handleSelecteLinkerType(Linker.types.growiLink)}
                         />
                         />
-                        <label className="custom-control-label" htmlFor="growiType" onClick={e => this.handleSelecteLinkerType(e.target.name)}>
+                        <label className="custom-control-label" htmlFor="growiType">
                           Growi original
                           Growi original
                         </label>
                         </label>
                       </div>
                       </div>
@@ -371,10 +371,10 @@ class LinkEditModal extends React.PureComponent {
                           type="radio"
                           type="radio"
                           className="custom-control-input"
                           className="custom-control-input"
                           id="pukiwikiType"
                           id="pukiwikiType"
-                          name={Linker.types.pukiwikiLink}
                           checked={this.state.linkerType === Linker.types.pukiwikiLink}
                           checked={this.state.linkerType === Linker.types.pukiwikiLink}
+                          onClick={() => this.handleSelecteLinkerType(Linker.types.pukiwikiLink)}
                         />
                         />
-                        <label className="custom-control-label" htmlFor="pukiwikiType" onClick={e => this.handleSelecteLinkerType(e.target.name)}>
+                        <label className="custom-control-label" htmlFor="pukiwikiType">
                           Pukiwiki
                           Pukiwiki
                         </label>
                         </label>
                       </div>
                       </div>