Skip to content

Commit

Permalink
Editor, menu item, missing argument, formalize, upload text
Browse files Browse the repository at this point in the history
  • Loading branch information
schtr4jh committed Jan 10, 2020
1 parent 7ea999f commit 064aaa9
Show file tree
Hide file tree
Showing 6 changed files with 38 additions and 6 deletions.
27 changes: 24 additions & 3 deletions src/Pckg/Dynamic/public/js/editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,14 +82,16 @@ let tinyMceConfig = {
link_class_list: [
{title: 'Link', value: ''},
{title: 'Button', value: 'button'},
{title: 'Bordered button', value: 'button button-bordered'},
{title: 'Bordered button', value: 'button btn-bordered'},
{title: 'No shadow button', value: 'button no-shadow'},
{title: 'Shadow button', value: 'button shadow'},
{title: 'Primary color', value: 'button color-primary'},
{title: 'Secondary color', value: 'button color-secondary'},
{title: 'Dark button', value: 'button color-dark'},
{title: 'Light button', value: 'button color-light'}
{title: 'Light button', value: 'button color-light'},
{title: 'Small button', value: 'button size-xs'}
],
link_context_toolbar: true,
style_formats: [
{
title: 'Headings',
Expand Down Expand Up @@ -172,9 +174,28 @@ let tinyMceConfig = {
title: 'Secondary (system)', format: 'font-family-secondary-system',
}
]
}
},
{
title: 'Buttons',
items: [
{title: 'Button', format: 'buttonelement'},
{title: 'Bordered', format: 'buttonborderedelement'},
]
},
],
formats: {
buttonelement: {
selector: 'a', classes: 'button',
},
buttonborderedelement: {
selector: 'a', classes: 'button',
},
/*buttonsizexs: {
selector: 'a', classes: 'button size-xs',
},
buttonsizesm: {
selector: 'a', classes: 'button size-m',
},*/
font_size_xxs: {
selector: 'a,p,h1,h2,h3,h4,h5,h6,span,td,th,div,ul,ol,li,table', classes: 'font-size-xxs'
},
Expand Down
9 changes: 9 additions & 0 deletions src/Pckg/Generic/Record/MenuItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,15 @@ class MenuItem extends Record

protected $entity = MenuItems::class;

public function getAdditionalClass()
{
if (strpos($this->url, '#') !== 0) {
return;
}

return 'clicknscroll';
}

public function getRealUrl()
{
if (strpos($this->url, '://')) {
Expand Down
2 changes: 1 addition & 1 deletion src/Pckg/Generic/public/vue/pckg-generic-app-top.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ export const pckgFormValidator = {

export const pckgSync = {
methods: {
single: function (name, request) {
single: function (name, request, object) {
if (typeof object == 'undefined') {
object = this;
}
Expand Down
2 changes: 2 additions & 0 deletions src/Pckg/Maestro/Service/Formalize.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ public function __toString()
{
vueManager()->addView('Pckg/Maestro:_formalize', ['formalize' => $this, 'form' => $this->form]);

return '<pckg-maestro-formalize ref="formalize"></pckg-maestro-formalize>';

return (string)view(
'Pckg/Maestro:formalize',
[
Expand Down
2 changes: 1 addition & 1 deletion src/Pckg/Maestro/View/_table_actions.vue
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@

<div class="form-group">
<label>Row delimiter</label>
<div v-html="meta.newline"></div>
<div v-text="meta.newline"></div>
<div class="help">Automatically detected newline delimiter.</div>
</div>

Expand Down
2 changes: 1 addition & 1 deletion src/Pckg/Maestro/public/vue/pckg-htmlbuilder-dropzone.vue
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@
return file;
}
return 'Drop a file to upload';
return 'Select a file or drop it here to upload';
}
},
methods: {
Expand Down

0 comments on commit 064aaa9

Please sign in to comment.