|
99 | 99 | <Draggable |
100 | 100 | v-model="columns" |
101 | 101 | class="question__content" |
102 | | - animation="200" |
| 102 | + :animation="200" |
103 | 103 | direction="vertical" |
104 | 104 | handle=".option__drag-handle" |
105 | 105 | invertSwap |
106 | | - tag="ul" |
| 106 | + tag="transition-group" |
| 107 | + :componentData="{ |
| 108 | + name: isDragging |
| 109 | + ? 'no-external-transition-on-drag' |
| 110 | + : 'options-list-transition', |
| 111 | + }" |
107 | 112 | @change="saveOptionsOrder('column')" |
108 | 113 | @start="isDragging = true" |
109 | 114 | @end="isDragging = false"> |
110 | | - <TransitionGroup |
111 | | - :name=" |
112 | | - isDragging |
113 | | - ? 'no-external-transition-on-drag' |
114 | | - : 'options-list-transition' |
115 | | - "> |
116 | | - <!-- Column input edit --> |
117 | | - <AnswerInput |
118 | | - v-for="(answer, index) in columns" |
119 | | - :key="answer.local ? 'option-local' : answer.id" |
120 | | - ref="input" |
121 | | - :answer="answer" |
122 | | - :formId="formId" |
123 | | - :index="index" |
124 | | - :isUnique="isUnique" |
125 | | - :maxIndex="columns.length - 2" |
126 | | - :maxOptionLength="maxStringLengths.optionText" |
127 | | - optionType="column" |
128 | | - @createAnswer="onCreateAnswer" |
129 | | - @update:answer="updateAnswer" |
130 | | - @delete="deleteOption" |
131 | | - @focusNext="focusNextInput" |
132 | | - @moveUp="onOptionMoveUp(index, 'column')" |
133 | | - @moveDown="onOptionMoveDown(index, 'column')" |
134 | | - @tabbedOut="checkValidOption('column')" /> |
135 | | - </TransitionGroup> |
| 115 | + <!-- Column input edit --> |
| 116 | + <AnswerInput |
| 117 | + v-for="(answer, index) in columns" |
| 118 | + :key="answer.local ? 'option-local' : answer.id" |
| 119 | + ref="input" |
| 120 | + :answer="answer" |
| 121 | + :formId="formId" |
| 122 | + :index="index" |
| 123 | + :isUnique="isUnique" |
| 124 | + :maxIndex="columns.length - 2" |
| 125 | + :maxOptionLength="maxStringLengths.optionText" |
| 126 | + optionType="column" |
| 127 | + @createAnswer="onCreateAnswer" |
| 128 | + @update:answer="updateAnswer" |
| 129 | + @delete="deleteOption" |
| 130 | + @focusNext="focusNextInput" |
| 131 | + @moveUp="onOptionMoveUp(index, 'column')" |
| 132 | + @moveDown="onOptionMoveDown(index, 'column')" |
| 133 | + @tabbedOut="checkValidOption('column')" /> |
136 | 134 | </Draggable> |
137 | 135 |
|
138 | 136 | <div>{{ t('forms', 'Rows') }}</div> |
139 | 137 | <Draggable |
140 | 138 | v-model="rows" |
141 | 139 | class="question__content" |
142 | | - animation="200" |
| 140 | + :animation="200" |
143 | 141 | direction="vertical" |
144 | 142 | handle=".option__drag-handle" |
145 | 143 | invertSwap |
146 | | - tag="ul" |
| 144 | + tag="transition-group" |
| 145 | + :componentData="{ |
| 146 | + name: isDragging |
| 147 | + ? 'no-external-transition-on-drag' |
| 148 | + : 'options-list-transition', |
| 149 | + }" |
147 | 150 | @change="saveOptionsOrder('row')" |
148 | 151 | @start="isDragging = true" |
149 | 152 | @end="isDragging = false"> |
150 | | - <TransitionGroup |
151 | | - :name=" |
152 | | - isDragging |
153 | | - ? 'no-external-transition-on-drag' |
154 | | - : 'options-list-transition' |
155 | | - "> |
156 | | - <!-- Row input edit --> |
157 | | - <AnswerInput |
158 | | - v-for="(answer, index) in rows" |
159 | | - :key="answer.local ? 'option-local' : answer.id" |
160 | | - ref="input" |
161 | | - :answer="answer" |
162 | | - :formId="formId" |
163 | | - :index="index" |
164 | | - :isUnique="isUnique" |
165 | | - :maxIndex="rows.length - 2" |
166 | | - :maxOptionLength="maxStringLengths.optionText" |
167 | | - optionType="row" |
168 | | - @createAnswer="onCreateAnswer" |
169 | | - @update:answer="updateAnswer" |
170 | | - @delete="deleteOption" |
171 | | - @focusNext="focusNextInput" |
172 | | - @moveUp="onOptionMoveUp(index, 'row')" |
173 | | - @moveDown="onOptionMoveDown(index, 'row')" |
174 | | - @tabbedOut="checkValidOption('row')" /> |
175 | | - </TransitionGroup> |
| 153 | + <!-- Row input edit --> |
| 154 | + <AnswerInput |
| 155 | + v-for="(answer, index) in rows" |
| 156 | + :key="answer.local ? 'option-local' : answer.id" |
| 157 | + ref="input" |
| 158 | + :answer="answer" |
| 159 | + :formId="formId" |
| 160 | + :index="index" |
| 161 | + :isUnique="isUnique" |
| 162 | + :maxIndex="rows.length - 2" |
| 163 | + :maxOptionLength="maxStringLengths.optionText" |
| 164 | + optionType="row" |
| 165 | + @createAnswer="onCreateAnswer" |
| 166 | + @update:answer="updateAnswer" |
| 167 | + @delete="deleteOption" |
| 168 | + @focusNext="focusNextInput" |
| 169 | + @moveUp="onOptionMoveUp(index, 'row')" |
| 170 | + @moveDown="onOptionMoveDown(index, 'row')" |
| 171 | + @tabbedOut="checkValidOption('row')" /> |
176 | 172 | </Draggable> |
177 | 173 | </template> |
178 | 174 | </template> |
|
0 commit comments