Merge branch 'forms2_DB_conflicts' into forms2

pull/1/head
yflory 3 years ago
commit b5fd885035

@ -527,6 +527,7 @@ define([
var sframeChan = common.getSframeChannel(); var sframeChan = common.getSframeChannel();
var appType = (common.getMetadataMgr().getMetadata().type || 'pad').toUpperCase(); var appType = (common.getMetadataMgr().getMetadata().type || 'pad').toUpperCase();
data = data || {}; data = data || {};
Messages.toolbar_preview = "Preview"; // XXX
switch (type) { switch (type) {
case 'export': case 'export':
button = $('<button>', { button = $('<button>', {
@ -753,7 +754,7 @@ define([
//title: Messages.previewButtonTitle, // TODO display if the label text is collapsed //title: Messages.previewButtonTitle, // TODO display if the label text is collapsed
}, [ }, [
h('i.fa.fa-eye'), h('i.fa.fa-eye'),
h('span.cp-toolbar-name', Messages.share_linkOpen) h('span.cp-toolbar-name', Messages.toolbar_preview)
])).click(common.prepareFeedback(type)); ])).click(common.prepareFeedback(type));
break; break;
case 'print': case 'print':

@ -420,12 +420,12 @@ define([
embed: Util.isChecked($link.find('#cp-share-embed')) embed: Util.isChecked($link.find('#cp-share-embed'))
})); }));
}); });
Messages.share_linkOpen = "Open link"; // XXX
var linkButtons = [ var linkButtons = [
makeCancelButton(), makeCancelButton(),
!opts.sharedFolder && { !opts.sharedFolder && {
className: 'secondary cp-nobar', className: 'secondary cp-nobar',
name: Messages.share_linkOpen, name: Messages.share_linkOpen, // XXX add fa-eye icon
onClick: function () { onClick: function () {
opts.saveValue(); opts.saveValue();
var v = opts.getLinkValue({ var v = opts.getLinkValue({
@ -441,7 +441,7 @@ define([
keys: [[13, 'ctrl']] keys: [[13, 'ctrl']]
}, { }, {
className: 'primary cp-nobar', className: 'primary cp-nobar',
name: Messages.share_linkCopy, name: Messages.share_linkCopy, // XXX add fa-link icon
onClick: function () { onClick: function () {
opts.saveValue(); opts.saveValue();
var v = opts.getLinkValue({ var v = opts.getLinkValue({

@ -725,6 +725,7 @@
font-weight: bold; font-weight: bold;
padding: 5px 10px; padding: 5px 10px;
.cp-form-results-cell(); .cp-form-results-cell();
background: transparent;
} }
&:not(:first-child) { &:not(:first-child) {
.cp-mr-q { .cp-mr-q {

@ -3306,10 +3306,13 @@ define([
return; return;
} }
Messages.form_required = "Required"; // XXX // XXX
Messages.form_required_answer = "Answer: ";
Messages.form_required_on = "Required";
Messages.form_required_off = "Optional";
var requiredTag; var requiredTag;
if (block.opts && block.opts.required) { if (block.opts && block.opts.required) {
requiredTag = h('span.cp-form-required-tag', Messages.form_required); requiredTag = h('span.cp-form-required-tag', Messages.form_required_on);
} }
var dragHandle; var dragHandle;

@ -1,7 +1,7 @@
define([ define([
'/customize/messages.js' '/customize/messages.js'
], function (Messages) { ], function (Messages) {
Messages.form_type_poll = "Quick poll"; // XXX update key Messages.form_template_poll = "Quick poll"; // XXX update key
var pollValues = []; var pollValues = [];
var d8 = new Date(); var d8 = new Date();
d8.setDate(d8.getDate() - d8.getDay() + 7); // set sunday d8.setDate(d8.getDate() - d8.getDay() + 7); // set sunday
@ -24,7 +24,7 @@ define([
return [{ return [{
id: 'a', id: 'a',
used: 1, used: 1,
name: Messages.form_type_poll, name: Messages.form_template_poll,
content: { content: {
answers: { answers: {
anonymous: true, anonymous: true,

Loading…
Cancel
Save