Issue #852Opened February 9, 2018by JulyanoF0 reactions

[QUESTION] How to change <a> content in traits?

Question

I'm re-declaring a link type like this:

domComps.addType('link', {
    model: linkType.model.extend({
        defaults: Object.assign({}, linkType.model.prototype.defaults, {
        traits: [
            {
                label: 'Título',
                name: 'title',
                placeholder: 'Título'
            },
            {
                label: 'Link',
                name: 'href',
                placeholder: 'http://meusite.com.br'
            },
            {
                label: 'Descrição',
                name: 'content',
                placeholder: 'Botão'
            }
        ],
      }),
    })
});

When my button (<a>) is created, it is creating like this: <a class="btn botao-roxo">Botão</a> I would like to know how can I change the content of this (Botão) in traits.

Answers (2)

lock[bot]September 18, 20190 reactions

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.