@@ -65,8 +65,9 @@ const LeftColExpansionPanel = (props: LeftColExpPanPropsInt) => {
65
65
container
66
66
spacing = { 16 }
67
67
direction = "row"
68
- justify = "flex-start "
68
+ justify = "center "
69
69
alignItems = "center"
70
+ style = { { minWidth : '320px' } }
70
71
>
71
72
< Grid item xs = { 9 } >
72
73
< div
@@ -90,6 +91,7 @@ const LeftColExpansionPanel = (props: LeftColExpPanPropsInt) => {
90
91
color : 'red' ,
91
92
backgroundColor : color ,
92
93
borderRadius : '10px' ,
94
+ minWidth : '320px' ,
93
95
} }
94
96
>
95
97
< List style = { { color : 'red' } } >
@@ -122,42 +124,33 @@ const LeftColExpansionPanel = (props: LeftColExpPanPropsInt) => {
122
124
*/ }
123
125
124
126
{ /* LABEL AND TOGGLE(SWITCH) FOR STATEFULNESS */ }
125
- { focusedToggle ? (
126
- < InputLabel
127
- htmlFor = "stateful"
128
- style = { {
129
- color : '#fff' ,
130
- marginBottom : '10px' ,
131
- marginTop : '0px' ,
132
- marginLeft : '11px' ,
133
- padding : '0px' ,
134
- fontSize : '18px' ,
135
- textShadow : '1px 1px 2px rgba(0, 0, 0, 0.7)' ,
136
- } }
137
- >
138
- State?
139
- </ InputLabel >
140
- ) : (
141
- ''
142
- ) }
143
127
144
128
{ focusedToggle ? (
145
- < Switch
146
- checked = { stateful }
147
- onChange = { e => {
148
- toggleComponentState ( id ) ;
149
- changeFocusComponent ( { title } ) ;
150
- } }
151
- value = "stateful"
152
- color = "primary"
153
- // id={props.id.toString()}
154
- />
155
- ) : (
156
- ''
157
- ) }
158
- < div >
159
- { /* LABEL/TOGGLE(SWITCH) FOR CLASS BASED */ }
160
- { focusedToggle ? (
129
+ < span >
130
+ < InputLabel
131
+ htmlFor = "stateful"
132
+ style = { {
133
+ color : '#fff' ,
134
+ marginBottom : '10px' ,
135
+ marginTop : '0px' ,
136
+ marginLeft : '11px' ,
137
+ padding : '0px' ,
138
+ fontSize : '18px' ,
139
+ textShadow : '1px 1px 2px rgba(0, 0, 0, 0.7)' ,
140
+ } }
141
+ >
142
+ State?
143
+ </ InputLabel >
144
+ < Switch
145
+ checked = { stateful }
146
+ onChange = { e => {
147
+ toggleComponentState ( id ) ;
148
+ changeFocusComponent ( { title } ) ;
149
+ } }
150
+ value = "stateful"
151
+ color = "primary"
152
+ // id={props.id.toString()}
153
+ />
161
154
< InputLabel
162
155
htmlFor = "classBased"
163
156
style = { {
@@ -171,11 +164,8 @@ const LeftColExpansionPanel = (props: LeftColExpPanPropsInt) => {
171
164
} }
172
165
>
173
166
Class?
174
- </ InputLabel >
175
- ) : (
176
- ''
177
- ) }
178
- { focusedToggle ? (
167
+ </ InputLabel > { ' ' }
168
+ (
179
169
< Switch
180
170
checked = { classBased }
181
171
onChange = { e => {
@@ -185,48 +175,49 @@ const LeftColExpansionPanel = (props: LeftColExpPanPropsInt) => {
185
175
value = "classBased"
186
176
color = "primary"
187
177
/>
188
- ) : (
189
- ''
190
- ) }
191
- { focusedToggle && component . id !== 1 ? (
192
- < Button
193
- variant = "text"
194
- size = "small"
195
- color = "default"
196
- aria-label = "Delete"
197
- className = { classes . margin }
198
- onClick = { ( ) =>
199
- deleteComponent ( {
200
- componentId : id ,
201
- stateComponents : components ,
202
- } )
203
- }
178
+ </ span >
179
+ ) : (
180
+ ''
181
+ ) }
182
+
183
+ { focusedToggle && component . id !== 1 ? (
184
+ < Button
185
+ variant = "text"
186
+ size = "small"
187
+ color = "default"
188
+ aria-label = "Delete"
189
+ className = { classes . margin }
190
+ onClick = { ( ) =>
191
+ deleteComponent ( {
192
+ componentId : id ,
193
+ stateComponents : components ,
194
+ } )
195
+ }
196
+ style = { {
197
+ color : 'white' ,
198
+ marginBottom : '0px' ,
199
+ marginTop : '4px' ,
200
+ } }
201
+ >
202
+ < DeleteIcon
203
+ style = { {
204
+ color : '#b30000' ,
205
+ textShadow : '1px 1px 2px rgba(0, 0, 0, 0.5)' ,
206
+ } }
207
+ />
208
+ < div
204
209
style = { {
205
- color : 'white ' ,
206
- marginBottom : '0px ' ,
207
- marginTop : '4px ' ,
210
+ marginTop : '3px ' ,
211
+ fontSize : '15px ' ,
212
+ textShadow : '1px 1px 2px rgba(0, 0, 0, 0.8) ' ,
208
213
} }
209
214
>
210
- < DeleteIcon
211
- style = { {
212
- color : '#b30000' ,
213
- textShadow : '1px 1px 2px rgba(0, 0, 0, 0.5)' ,
214
- } }
215
- />
216
- < span
217
- style = { {
218
- marginTop : '3px' ,
219
- fontSize : '15px' ,
220
- textShadow : '1px 1px 2px rgba(0, 0, 0, 0.8)' ,
221
- } }
222
- >
223
- Delete Component
224
- </ span >
225
- </ Button >
226
- ) : (
227
- ''
228
- ) }
229
- </ div >
215
+ Delete Component
216
+ </ div >
217
+ </ Button >
218
+ ) : (
219
+ ''
220
+ ) }
230
221
</ div >
231
222
}
232
223
style = { { color } }
0 commit comments