mirror of
https://github.com/steedos/steedos-platform
synced 2024-11-22 17:06:42 +00:00
22 lines
466 B
JavaScript
22 lines
466 B
JavaScript
import './button.html';
|
|
import { Button } from '@steedos/design-system-react';
|
|
|
|
Template.steedos_button.helpers({
|
|
component: function () {
|
|
return Button;
|
|
},
|
|
data: function () {
|
|
let assistiveText;
|
|
if(this.assistiveText){
|
|
assistiveText = this.assistiveText;
|
|
}
|
|
else if(this.title){
|
|
assistiveText = { label: this.title }
|
|
}
|
|
return Object.assign({}, {...this}, {
|
|
title: this.title || this.label,
|
|
assistiveText
|
|
}, {component: Button})
|
|
}
|
|
});
|