Skip to content

Commit

Permalink
added props title
Browse files Browse the repository at this point in the history
  • Loading branch information
Zh3nyaZh3nya committed Oct 4, 2023
1 parent af7323b commit a4a5c17
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/runtime/components/Parts/News.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<v-container class="d-flex flex-column align-center justify-center">
<div class="parts__news-title mb-5">
<h2 class="text-32 font-weight-regular">Новости</h2>
<h2 class="text-32 font-weight-regular" :class="`justify-${positionTitle}`">{{ title }}</h2>
</div>
<v-row>
<v-col
Expand Down Expand Up @@ -101,6 +101,8 @@ const props = defineProps({
xl: 4,
xxl: 4
})
}
},
title: { type: String, default: 'Новости' },
positionTitle: { type: String, default: 'center' },
})
</script>
3 changes: 3 additions & 0 deletions src/stories/partsNews.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ export default {
settingsCol: { type: 'object' },
settingsButton: { type: 'object'},
cards: { control: 'array' },
title: { control: 'text' }
},
};

Expand All @@ -26,6 +27,8 @@ export const First = {
</partsNews>`
}),
args: {
text: "Новости о нас",
positionTitle: "start",
cards: [
{
id: 1,
Expand Down

0 comments on commit a4a5c17

Please sign in to comment.