Skip to content

feat(VCol): syntax for overriding row size#22572

Merged
KaelWD merged 3 commits intonextfrom
feat/grid-even-more-dynamic
Feb 4, 2026
Merged

feat(VCol): syntax for overriding row size#22572
KaelWD merged 3 commits intonextfrom
feat/grid-even-more-dynamic

Conversation

@J-Sek
Copy link
Copy Markdown
Contributor

@J-Sek J-Sek commented Jan 31, 2026

  • adds size prop to VRow (that is pretty much nothing and can be merged separately if we are not sure about VCol changes)
  • adds syntax to override columns count for VCol size and offset
  • additional examples in the docs
  • minor adjustment to the migration guide

Markup:

<template>
  <v-app theme="dark">
    <v-container class="pa-4">
      <h5 class="mb-2">7 columns</h5>
      <v-row :size="5" class="mb-6">
        <v-col v-for="n in 5" :key="n" cols="1">
          <v-sheet class="pa-2 text-center" color="primary">{{ n }}</v-sheet>
        </v-col>
      </v-row>

      <h5 class="mb-2">VCol overriding row size with cols="n/size" syntax</h5>
      <v-row :size="12" class="mb-6 pa-3 border-dashed" gap="12">
        <v-col cols="2/5">
          <v-sheet class="pa-2 text-center" color="purple-accent-4">2/5</v-sheet>
        </v-col>
        <v-col cols="1/2">
          <v-sheet class="pa-2 text-center" color="brown-darken-1">1/2</v-sheet>
        </v-col>
        <v-col cols="1/10">
          <v-sheet class="pa-2 text-center" color="teal-darken-1">1/10</v-sheet>
        </v-col>
      </v-row>

      <h5 class="mb-2">Responsive overrides and offset</h5>
      <v-row :size="12" class="mb-6 pa-3 border-dashed" gap="12">
        <v-col
          offset="1/2"
          offset-lg="0"
          offset-md="1/3"
        >
          <v-sheet class="pa-2" color="blue-darken-2">grow | offset:1/2<br>grow | offset-md:1/3<br>grow | offset-lg:0</v-sheet>
        </v-col>

        <v-col
          cols="1/2"
          lg="1/4"
          md="1/3"
        >
          <v-sheet class="pa-2" color="yellow-darken-3">1/2<br>md:1/3<br>lg:1/4</v-sheet>
        </v-col>

        <v-col
          cols="1/4"
          lg="1/2"
          md="1/3"
          offset="1/8"
          offset-lg="0"
          offset-md="1/6"
        >
          <v-sheet class="pa-2" color="green-darken-1">1/4 | offset:1/8<br>md:1/3 | offset-md:1/6<br>lg:1/2 | offset-lg:0</v-sheet>
        </v-col>
      </v-row>
    </v-container>
  </v-app>
</template>

@J-Sek J-Sek self-assigned this Jan 31, 2026
@J-Sek J-Sek added T: feature A new feature C: VGrid Covers issues involving VContainer, VLayout, VFlex labels Jan 31, 2026
@J-Sek J-Sek marked this pull request as ready for review January 31, 2026 21:56
@J-Sek J-Sek requested a review from a team February 3, 2026 14:26
@KaelWD KaelWD self-requested a review February 4, 2026 05:59
@KaelWD KaelWD added this to the v4.0.0 (Revisionist) milestone Feb 4, 2026
@KaelWD KaelWD merged commit 43e8736 into next Feb 4, 2026
4 checks passed
@KaelWD KaelWD deleted the feat/grid-even-more-dynamic branch February 4, 2026 06:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C: VGrid Covers issues involving VContainer, VLayout, VFlex T: feature A new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants