1414 {{ stack.title }}
1515 </h3 >
1616 <h3 v-else-if =" !editing"
17- title =" stack.title"
1817 dir =" auto"
1918 tabindex =" 0"
2019 :aria-label =" stack.title"
20+ :title =" stack.title"
2121 class =" stack__title"
2222 @click =" startEditing(stack)"
2323 @keydown.enter =" startEditing(stack)" >
108108 </Container >
109109
110110 <transition name =" slide-bottom" appear >
111- <div v-show =" showAddCard" class =" stack__card-add" >
111+ <div v-if =" showAddCard" class =" stack__card-add" >
112112 <form :class =" { 'icon-loading-small': stateCardCreating }"
113113 @submit.prevent.stop =" clickAddCard()" >
114114 <label for =" new-stack-input-main" class =" hidden-visually" >{{ t('deck', 'Add a new card') }}</label >
@@ -365,37 +365,31 @@ export default {
365365 @import ' ./../../css/variables' ;
366366
367367 .stack {
368- width : $stack-width + $stack-spacing * 3 ;
368+ width : 100 % ;
369369 }
370370
371371 .stack__header {
372372 display : flex ;
373373 position : sticky ;
374374 top : 0 ;
375+ height : var (--default-clickable-area );
375376 z-index : 100 ;
376- padding-left : $card-spacing ;
377- padding-right : $card-spacing ;
378- margin : 6px ;
379377 margin-top : 0 ;
380378 cursor : grab ;
381379 background-color : var (--color-main-background );
382380
383381 // Smooth fade out of the cards at the top
384382 & :before {
385- content : ' ' ;
383+ content : ' ' ;
386384 display : block ;
387385 position : absolute ;
388- width : calc (100% - 16px );
389- height : 20px ;
390- top : 30px ;
391- left : 0px ;
386+ width : 100% ;
387+ height : $stack-gap ;
388+ bottom : 0 ;
392389 z-index : 99 ;
393390 transition : top var (--animation-slow );
394-
395- background-image : linear-gradient (180deg , var (--color-main-background ) 3px , rgba (255 , 255 , 255 , 0 ) 100% );
396- body .theme--dark & {
397- background-image : linear-gradient (180deg , var (--color-main-background ) 3px , rgba (0 , 0 , 0 , 0 ) 100% );
398- }
391+ background-image : linear-gradient (180deg , var (--color-main-background ) 0% , transparent 100% );
392+ transform : translateY (100% );
399393 }
400394
401395 & > * {
@@ -404,8 +398,10 @@ export default {
404398 }
405399
406400 h3 , form {
407- flex-grow : 1 ;
401+ flex : 1 1 auto ;
402+ min-width : 0 ;
408403 display : flex ;
404+ align-items : center ;
409405 cursor : inherit ;
410406 margin : 0 ;
411407
@@ -418,9 +414,8 @@ export default {
418414 white-space : nowrap ;
419415 overflow : hidden ;
420416 text-overflow : ellipsis ;
421- max-width : calc ($stack-width - 60px );
422417 border-radius : 3px ;
423- padding : 4 px 4 px ;
418+ padding : $card-padding ;
424419 font-size : var (--default-font-size );
425420
426421 & :focus-visible {
@@ -430,7 +425,6 @@ export default {
430425 }
431426
432427 form {
433- margin : -4px ;
434428 input {
435429 font-weight : bold ;
436430 padding : 0 6px ;
@@ -453,14 +447,25 @@ export default {
453447 flex-shrink : 0 ;
454448 z-index : 100 ;
455449 display : flex ;
456- margin-bottom : 5px ;
457- padding-top : var (--default-grid-baseline );
450+ padding-bottom : $stack-gap ;
458451 background-color : var (--color-main-background );
452+ position : relative ;
453+
454+ // Smooth fade out of the cards at the top
455+ & :before {
456+ content : ' ' ;
457+ display : block ;
458+ position : absolute ;
459+ width : 100% ;
460+ height : $stack-gap ;
461+ z-index : 99 ;
462+ transition : bottom var (--animation-slow );
463+ background-image : linear-gradient (0deg , var (--color-main-background ) 0% , transparent 100% );
464+ transform : translateY (-100% );
465+ }
459466
460467 form {
461468 display : flex ;
462- margin-left : $stack-spacing ;
463- margin-right : $stack-spacing ;
464469 width : 100% ;
465470 border : 2px solid var (--color-border-maxcontrast );
466471 border-radius : var (--border-radius-large );
@@ -481,7 +486,6 @@ export default {
481486 input {
482487 border : none ;
483488 margin : 0 ;
484- padding : 4px ;
485489 }
486490 }
487491
0 commit comments