No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Cards display inline when is desktop and one above another when is mobile

    Help
    1
    1
    97
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • E
      Ewa last edited by

      Hi I need to change card direction depend on screen size. What is the best method to do it? Card have to have specific width, margins, paddings and grid

      <div :class="panelDitection">
         <div class="col" v-for=...>
           <Card class="cardClass" />
      
      ......
      
      <script>
        get panelDitection (): string {
          return this.$q.screen.lt.sm ? 'column' : 'row'
        }
      
      

      or maybe

      <div :class="panelDitection">
         <Class class="col cardClas" v-for=...>
      
      ......
      
      <script>
        get panelDitection (): string {
          return this.$q.screen.lt.sm ? 'column' : 'row'
        }
      
      

      But non of this method seems be good. I don’t thing adding class col here is good idea, but I don’t know what different I can to do.

      1 Reply Last reply Reply Quote 0
      • First post
        Last post