Update cms-widget-fields footer image reference.
This commit is contained in:
parent
3951dfcf86
commit
8455534ef0
3 changed files with 21 additions and 15 deletions
|
|
@ -37,8 +37,8 @@ const widgetFields = Object.freeze({
|
|||
NAME: 'Name',
|
||||
BACK_BUTTON_TEXT: 'BackButtonText',
|
||||
FORWARD_BUTTON_TEXT: 'ForwardButtonText',
|
||||
FOOTER_IMAGE: 'FooterImage',
|
||||
ALT_TEXT: 'AltText'
|
||||
ALT_TEXT: 'AltText',
|
||||
FOOTER_IMAGE_URL: 'FooterImageURL'
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -4,26 +4,32 @@
|
|||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import widgetFields from '@/constants/cms-widget-fields.js';
|
||||
|
||||
export default {
|
||||
name: 'footer-image',
|
||||
props: {
|
||||
cmsWidgetName: String
|
||||
data() {
|
||||
return {
|
||||
widget: {
|
||||
footer: 'SiteFooterWidget'
|
||||
}
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
footerImageURL() {
|
||||
return this.getCmsContent(this.cmsWidgetName, 'FooterImageURL');
|
||||
return this.getCmsContent(this.widget.footer, widgetFields.FOOTER_WIDGET.FOOTER_IMAGE_URL);
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.footerImage {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin-top: auto;
|
||||
img {
|
||||
max-width: 375px;
|
||||
}
|
||||
<style lang="scss" scoped>
|
||||
.footerImage {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin-top: auto;
|
||||
img {
|
||||
max-width: 23.4375rem;
|
||||
}
|
||||
</style>
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -141,7 +141,7 @@ class="row">
|
|||
</div>
|
||||
<!-- Footer image component must have parent (usually container-fluid)
|
||||
set to display: flex and height 100dvh or height 100% -->
|
||||
<footerImage cmsWidgetName="SiteFooterWidget" />
|
||||
<footerImage />
|
||||
</div>
|
||||
</Form>
|
||||
</template>
|
||||
|
|
|
|||
Loading…
Reference in a new issue