@@ -30,6 +30,7 @@ const CModal = props => {
|
30 | 30 | addContentClass,
|
31 | 31 | onClose,
|
32 | 32 | className,
|
| 33 | +scrollable, |
33 | 34 | ...attributes
|
34 | 35 | } = props
|
35 | 36 |
|
@@ -73,6 +74,7 @@ const CModal = props => {
|
73 | 74 |
|
74 | 75 | const dialogClasses = classNames(
|
75 | 76 | 'modal-dialog', {
|
| 77 | +'modal-dialog-scrollable': scrollable, |
76 | 78 | 'modal-dialog-centered': centered,
|
77 | 79 | [`modal-${size}`]: size
|
78 | 80 | }
|
@@ -117,8 +119,8 @@ const CModal = props => {
|
117 | 119 | >
|
118 | 120 | <div className={dialogClasses} role="document">
|
119 | 121 | <div
|
120 |
| -{...attributes} |
121 |
| -className={contentClasses} |
| 122 | +{...attributes} |
| 123 | +className={contentClasses} |
122 | 124 | ref={innerRef}
|
123 | 125 | >
|
124 | 126 | <Context.Provider value={{close}}>
|
@@ -129,7 +131,7 @@ const CModal = props => {
|
129 | 131 | </div>
|
130 | 132 | )
|
131 | 133 | }}
|
132 |
| -
|
| 134 | + |
133 | 135 | </Transition>
|
134 | 136 | { backdrop && isOpen && <div className={backdropClasses}></div> }
|
135 | 137 | </div>
|
@@ -144,14 +146,15 @@ CModal.propTypes = {
|
144 | 146 | centered: PropTypes.bool,
|
145 | 147 | size: PropTypes.oneOf(['', 'sm', 'lg', 'xl']),
|
146 | 148 | backdrop: PropTypes.bool,
|
147 |
| -color: PropTypes.string, |
| 149 | +color: PropTypes.string, |
148 | 150 | borderColor: PropTypes.string,
|
149 | 151 | onOpened: PropTypes.func,
|
150 | 152 | onClosed: PropTypes.func,
|
151 | 153 | fade: PropTypes.bool,
|
152 | 154 | closeOnBackdrop: PropTypes.bool,
|
153 | 155 | onClose: PropTypes.func,
|
154 |
| -addContentClass: PropTypes.string |
| 156 | +addContentClass: PropTypes.string, |
| 157 | +scrollable: PropTypes.bool, |
155 | 158 | }
|
156 | 159 |
|
157 | 160 | CModal.defaultProps = {
|
|
0 commit comments