File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -340,8 +340,9 @@ div.ProseMirror {
340340
341341 table {
342342 border-spacing : 0 ;
343- // Needs to be sync with `.table-add-row` button width in `TableView.vue`
344- width : calc (100% - (2 * var (--clickable-area-small )) - 8px );
343+ // Needs to be in sync with `.table-add-row` button width in `TableView.vue`
344+ --table-width-offset : calc (var (--clickable-area-small ) + 4px );
345+ width : calc (100% - var (--table-width-offset ));
345346 table-layout : auto ;
346347 white-space : normal ; // force text to wrapping
347348 margin-bottom : calc (var (--clickable-area-small ) + 8px );
Original file line number Diff line number Diff line change 2727 {{ t('text', 'Delete this table') }}
2828 </NcActionButton >
2929 </NcActions >
30- <NodeViewContent class =" content" as =" table" />
30+ <div class =" table-scroll" >
31+ <NodeViewContent class =" content" as =" table" />
32+ </div >
3133 <NcButton
3234 v-if =" isEditable"
3335 class =" table-add-column"
5052 <TableAddRowAfter />
5153 </template >
5254 </NcButton >
53- <div class =" clearfix" />
5455 </NodeViewWrapper >
5556</template >
5657
@@ -143,7 +144,6 @@ export default {
143144<style scoped lang="scss">
144145.table-wrapper {
145146 position : relative ;
146- overflow-x : auto ;
147147
148148 & .focused ,
149149 & :hover {
@@ -153,7 +153,13 @@ export default {
153153 }
154154 }
155155
156+ .table-scroll {
157+ overflow-x : auto ;
158+ width : calc (100% - var (--clickable-area-small ) - 4px );
159+ }
160+
156161 .table-settings {
162+ z-index : 3 ;
157163 padding-left : 3px ;
158164 opacity : 0.5 ;
159165 position : absolute ;
@@ -187,20 +193,13 @@ export default {
187193 position : absolute ;
188194 left : 0 ;
189195 bottom : 4px ;
190- // Needs to be in sync with table width in `prosemirror.css`
191- width : calc (100% - (2 * var (--clickable-area-small )) - 8px ) !important ;
196+ // Needs to be in sync with `table` in `prosemirror.scss`
197+ --table-width-offset : calc (var (--clickable-area-small ) + 4px );
198+ width : calc (100% - (2 * var (--table-width-offset ))) !important ;
192199
193200 & :hover {
194201 opacity : 1 ;
195202 }
196203 }
197204}
198-
199- .clearfix {
200- clear : both ;
201- }
202-
203- table {
204- float : left ;
205- }
206205 </style >
You can’t perform that action at this time.
0 commit comments