Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: test the filesize before downloading it #1095

Closed
wants to merge 106 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
106 commits
Select commit Hold shift + click to select a range
36d3d22
chore: reformat composer.json files
Davidmattei Sep 17, 2024
cf82165
Merge branch '5.21' into 5.x
Davidmattei Sep 17, 2024
a99ccff
Merge branch '5.21' into 5.x
Davidmattei Sep 19, 2024
5761edf
feat(admin/mapping): add synonym filter and implement into demo (#1016)
theus77 Sep 24, 2024
1e28cbf
fix(admin/filter): remove btn with a2lix_lib (#1017)
theus77 Sep 24, 2024
1d48c1d
chore(demo): remove double 'french_stop' from backup. (#1018)
theus77 Sep 24, 2024
0e91fcf
Merge branch '5.21' into 5.x
Davidmattei Sep 24, 2024
1cf2740
docs(admin): describe type of field (content types) (#1019)
theus77 Sep 25, 2024
373792d
feat(admin/tasks): rename task manager to task admin (#1021)
Davidmattei Sep 25, 2024
bf76315
refactor(admin/cli): replace EmsCommand.php by AbstractCommand from c…
Davidmattei Sep 27, 2024
f7df812
Merge branch '5.21' into 5.x
Davidmattei Sep 27, 2024
70d6caf
Merge branch '5.21' into 5.x
Davidmattei Sep 30, 2024
7e596c7
feat(admin/user): new get user language and sort tabs (#1026)
Davidmattei Sep 30, 2024
b3cd0f8
feat(common/twig): add new filter ems_link (#1028)
Davidmattei Oct 3, 2024
78e2312
Merge branch '5.21' into 5.x
Davidmattei Oct 4, 2024
4999341
feat(admin/wysiwyg): add data attributes in iframe preview (#1029)
Davidmattei Oct 7, 2024
831f14a
feat(admin/contentType): dataLinks support display expression (#1032)
Davidmattei Oct 7, 2024
178412e
fix(xliff): drop ZWSP or SHY characters (#1014)
theus77 Oct 7, 2024
7bb722c
feat(admin/twig): json menu nested copy/paste functionality (#1033)
Davidmattei Oct 8, 2024
b24f515
build: 5.22.0 composer update monorepo
Davidmattei Oct 8, 2024
1eff4bc
build: require 5.22.*
Davidmattei Oct 8, 2024
669f49b
build: 5.22.0
Davidmattei Oct 8, 2024
67c21f1
fix(admin/cli): reindex skip lock and with_warnings false (#1035)
Davidmattei Oct 10, 2024
6091702
fix(admin/document): display external content (#1037)
Davidmattei Oct 11, 2024
e97dfed
Merge branch '5.21' into 5.22
Davidmattei Oct 11, 2024
3bc6345
Merge branch '5.21' into 5.22
Davidmattei Oct 11, 2024
5e2d5a3
build: 5.22.1
Davidmattei Oct 11, 2024
5d75156
feat(admin-web/assets): new archive ems (#1041)
theus77 Oct 13, 2024
689688e
refactor(common/cli): file structure use new ems archive (#1043)
theus77 Oct 14, 2024
cbcfc52
fix(common/storage): s3 upload key bucket aware (#1044)
Davidmattei Oct 15, 2024
fcfb575
Merge branch '5.22' into 5.x
Davidmattei Oct 15, 2024
e372ec2
feat(common/cli): file structure api or storage manager (#1045)
Davidmattei Oct 16, 2024
189ebf4
fix(common/storage): log error on register services (#1046)
Davidmattei Oct 17, 2024
3c6a89f
chore(doc): add example ems_dom_crawler twig filter (#1047)
Davidmattei Oct 18, 2024
e4bed29
refactor(asset): deprecated emsch proxy routes (#1050)
theus77 Oct 21, 2024
106149d
fix(admin/contentType): locale default null not 'en' (#1049)
Davidmattei Oct 21, 2024
f7954de
Merge branch '5.22' into 5.x
Davidmattei Oct 21, 2024
7fe7184
feat(common/twig): new filter ems_valid_email (#1051)
Davidmattei Oct 24, 2024
14ae11a
feat(admin/release): unpublish revision table use es query (#1052)
Davidmattei Oct 24, 2024
c292e81
Merge branch '5.21' into 5.22
Davidmattei Oct 24, 2024
45d74e3
Merge branch '5.22' into 5.x
Davidmattei Oct 24, 2024
915cc60
feat(contentType/version): new not blank version option (#1054)
Davidmattei Oct 25, 2024
84662f9
feat(contentType/field): asset field type add label field (#1055)
theus77 Oct 25, 2024
88b7ec5
refactor(admin): useless security access control since PR#1039 (#1057)
theus77 Oct 28, 2024
4080c73
Merge branch '5.21' into 5.22
Davidmattei Oct 28, 2024
12da9c6
build: 5.22.2
Davidmattei Oct 28, 2024
d41b05f
Merge branch '5.22' into 5.x
Davidmattei Oct 28, 2024
b60bced
build: require 5.23.*
Davidmattei Oct 28, 2024
aae2132
build: 5.23.0
Davidmattei Oct 28, 2024
6dfd3e8
build: fix cli needs validator
Davidmattei Oct 28, 2024
8573d01
fix(admin/dataTable): ajaxData is in export format (links are just te…
Davidmattei Oct 31, 2024
b850c75
fix(admin/contentType): locale option array on dateRange (#1059)
Davidmattei Oct 31, 2024
c7a9614
Merge branch '5.22' into 5.23
Davidmattei Oct 31, 2024
aa5dc50
fix(common/log): add channel_ouuid_idx for performance (#1060)
theus77 Oct 31, 2024
94c3613
fix(admin/submission): non required in submisssion (#1061)
theus77 Nov 2, 2024
8f374fb
fix(cli/file-import): improvements and config(s) hashes or files (#1056)
Davidmattei Nov 4, 2024
1105390
build: 5.22.3
Davidmattei Nov 4, 2024
0ef36e8
Merge branch '5.22' into 5.23
Davidmattei Nov 4, 2024
afcdf25
build: 5.23.1
Davidmattei Nov 4, 2024
cd4170f
Merge branch '5.23' into 5.x
Davidmattei Nov 4, 2024
58a3909
fix(cli/command): file import config normal merge (for overwritting) …
Davidmattei Nov 5, 2024
19c31db
feat(helper/uuid): generate uuid from value (#1064)
Davidmattei Nov 5, 2024
d87e289
fix(admin/revision): finalize draft setMetaFields (#1065)
Davidmattei Nov 6, 2024
8061b3d
fix(cli/command): file reader import generate version uuid (#1067)
Davidmattei Nov 6, 2024
092f66f
fix(admin/revision): data not consumed error on publishing new versio…
Davidmattei Nov 6, 2024
d107800
chore: update MakeFile
Davidmattei Nov 6, 2024
17c6522
fix(admin/revision): no 'data_not_consumed' warning for private field…
Davidmattei Nov 6, 2024
0b6d58c
fix(admin/revision): add ouuid_idx for better performance (#1068)
theus77 Nov 6, 2024
0711657
Merge branch '5.23' into 5.x
Davidmattei Nov 6, 2024
a4e6b4c
feat(admin/cli): forward form submissions (#1070)
theus77 Nov 8, 2024
582bb52
fix(admin/cli): reindex command doctrine paginate with bulkSize (#1071)
Davidmattei Nov 8, 2024
baf3646
refactor(web): routing and templating match the content type name (#1…
theus77 Nov 10, 2024
3dc0344
fix(admin/form-submission): remove file fields (which are saved as em…
theus77 Nov 10, 2024
3200177
Merge branch '5.23' into 5.x
Davidmattei Nov 10, 2024
478e23c
build: 5.23.2
Davidmattei Nov 12, 2024
d356a28
chore: rollback change release command
Davidmattei Nov 12, 2024
eaf472c
Merge branch '5.23' into 5.x
Davidmattei Nov 12, 2024
dc4d7fe
fix(admin/field): multiple asset must use the id of the children (not…
theus77 Nov 25, 2024
beb6334
fix(admin/cli): activate content type command fix configure (#1074)
Davidmattei Nov 25, 2024
7078ea4
Merge branch '5.23' into 5.x
Davidmattei Nov 25, 2024
c3acac0
fix(cli/file-structure): improve push command (save_hash_file, chunk …
theus77 Nov 25, 2024
9155e9a
fix(common/storage): If 404 the file is missing (otherwise throws an …
theus77 Nov 25, 2024
5dcf3c6
Merge branch '5.23' into 5.x
Davidmattei Nov 25, 2024
883d42d
feat(cli): preload archive in cache (#1079)
theus77 Nov 26, 2024
bf294aa
feat(common/api): publish api (client/server)+ command (#1080)
theus77 Nov 26, 2024
92980f9
build: 5.23.3
Davidmattei Nov 26, 2024
20b0c35
Merge branch '5.23' into 5.x
Davidmattei Nov 26, 2024
a5b3be5
build: 5.24.0
Davidmattei Nov 26, 2024
9f5fcc0
build: 5.24.0
Davidmattei Nov 26, 2024
215393b
feat(common/file-reader): correct trimming white spaces and keep "0" …
Davidmattei Nov 27, 2024
98dc5c0
fix(common/helper): the mimetype guesser is not good at recognize tex…
theus77 Nov 28, 2024
473c43f
fix(common): perf issues with etag behoind apache with deflate mod (#…
theus77 Nov 29, 2024
9279d8a
build: 5.24.1
Davidmattei Dec 2, 2024
895350b
fix(common/pdf): allow domPDF to use TempFile (in the system dir) (#1…
theus77 Dec 4, 2024
ee3fb8d
Merge branch '5.21' into 5.22
Davidmattei Dec 4, 2024
da7339c
Merge branch '5.22' into 5.23
Davidmattei Dec 4, 2024
346b247
Merge branch '5.23' into 5.24
Davidmattei Dec 4, 2024
ef50753
fix(cli/import): import miss formated excel (#1090)
theus77 Dec 4, 2024
756e711
Merge branch '5.23' into 5.24
Davidmattei Dec 4, 2024
b281529
fix(cli/file-reader): get file from api (#1091)
theus77 Dec 5, 2024
02fe9f0
fix(cli/file-reader): not found config fallback get config from api (…
theus77 Dec 5, 2024
0ccb281
fix(cli/file-reader): correct fallback with $fileIdentifier (#1093)
theus77 Dec 5, 2024
f3224d0
Merge branch '5.21' into 5.22
Davidmattei Dec 5, 2024
1f5f4c6
Merge branch '5.22' into 5.23
Davidmattei Dec 5, 2024
fe4102a
Merge branch '5.23' into 5.24
Davidmattei Dec 5, 2024
0d7fa63
fix: test the filesize before downloading it (otherwise we face timeo…
theus77 Dec 7, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
98 changes: 98 additions & 0 deletions CHANGELOG-5.x.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,103 @@
# Changelog 5.x

## 5.24.1 (2024-12-02)
### Features
* feat(common/file-reader): correct trimming white spaces and keep "0" values by @Davidmattei in https://github.com/ems-project/elasticms/pull/1082
### Bug Fixes
* fix(common): perf issues with etag behoind apache with deflate mod by @theus77 in https://github.com/ems-project/elasticms/pull/1084
* fix(common/helper): the mimetype guesser is not good at recognize text file by @theus77 in https://github.com/ems-project/elasticms/pull/1083

## 5.24.0 (2024-11-26)
### Features
* feat(admin/cli): forward form submissions by @theus77 in https://github.com/ems-project/elasticms/pull/1070
* feat(cli): preload archive in cache by @theus77 in https://github.com/ems-project/elasticms/pull/1079
* feat(common/api): publish api (client/server)+ command by @theus77 in https://github.com/ems-project/elasticms/pull/1080
* feat(helper/uuid): generate uuid from value by @Davidmattei in https://github.com/ems-project/elasticms/pull/1064
### Bug Fixes
* fix(admin/cli): activate content type command fix configure by @Davidmattei in https://github.com/ems-project/elasticms/pull/1074
* fix(admin/cli): reindex command doctrine paginate with bulkSize by @Davidmattei in https://github.com/ems-project/elasticms/pull/1071
* fix(admin/revision): data not consumed error on publishing new version by @Davidmattei in https://github.com/ems-project/elasticms/pull/1066
* fix(admin/revision): finalize draft setMetaFields by @Davidmattei in https://github.com/ems-project/elasticms/pull/1065
* fix(admin/revision): no 'data_not_consumed' warning for private fields by @Davidmattei in https://github.com/ems-project/elasticms/pull/1069
* fix(cli/command): file import config normal merge (for overwritting) by @Davidmattei in https://github.com/ems-project/elasticms/pull/1063
* fix(cli/command): file reader import generate version uuid by @Davidmattei in https://github.com/ems-project/elasticms/pull/1067
* fix(cli/file-import): improvements and config(s) hashes or files by @Davidmattei in https://github.com/ems-project/elasticms/pull/1056
* fix(cli/file-structure): improve push command (save_hash_file, chunk size) by @theus77 in https://github.com/ems-project/elasticms/pull/1076
### Code Refactoring
* refactor(web): routing and templating match the content type name by @theus77 in https://github.com/ems-project/elasticms/pull/1073

## 5.23.3 (2024-11-26)
### Bug Fixes
* fix(admin/field): multiple asset must use the id of the children (not the parent) by @theus77 in https://github.com/ems-project/elasticms/pull/1075
* fix(common/storage): If 404 the file is missing (otherwise throws an error) in HTTP storage service by @theus77 in https://github.com/ems-project/elasticms/pull/1077

## 5.23.2 (2024-11-12)
### Bug Fixes
* fix(admin/form-submission): remove file fields (which are saved as empty array) by @theus77 in https://github.com/ems-project/elasticms/pull/1072
* fix(admin/revision): add ouuid_idx for better performance by @theus77 in https://github.com/ems-project/elasticms/pull/1068

## 5.23.1 (2024-11-04)
### Bug Fixes
* fix(admin/contentType): locale option array on dateRange by @Davidmattei in https://github.com/ems-project/elasticms/pull/1059
* fix(admin/dataTable): ajaxData is in export format (links are just text) by @Davidmattei in https://github.com/ems-project/elasticms/pull/1058
* fix(admin/submission): non required in submisssion by @theus77 in https://github.com/ems-project/elasticms/pull/1061
* fix(common/log): add channel_ouuid_idx for performance by @theus77 in https://github.com/ems-project/elasticms/pull/1060

## 5.23.0 (2024-10-28)
### Features
* feat(admin-web/assets): new archive ems by @theus77 in https://github.com/ems-project/elasticms/pull/1041
* feat(admin/release): unpublish revision table use es query by @Davidmattei in https://github.com/ems-project/elasticms/pull/1052
* feat(common/cli): file structure api or storage manager by @Davidmattei in https://github.com/ems-project/elasticms/pull/1045
* feat(common/twig): new filter ems_valid_email by @Davidmattei in https://github.com/ems-project/elasticms/pull/1051
* feat(contentType/field): asset field type add label field by @theus77 in https://github.com/ems-project/elasticms/pull/1055
* feat(contentType/version): new not blank version option by @Davidmattei in https://github.com/ems-project/elasticms/pull/1054
### Bug Fixes
* fix(common/storage): log error on register services by @Davidmattei in https://github.com/ems-project/elasticms/pull/1046
### Code Refactoring
* refactor(admin): useless security access control since PR#1039 by @theus77 in https://github.com/ems-project/elasticms/pull/1057
* refactor(asset): deprecated emsch proxy routes by @theus77 in https://github.com/ems-project/elasticms/pull/1050
* refactor(common/cli): file structure use new ems archive by @theus77 in https://github.com/ems-project/elasticms/pull/1043
### Chores
* chore(doc): add example ems_dom_crawler twig filter by @Davidmattei in https://github.com/ems-project/elasticms/pull/1047

## 5.22.3 (2024-11-04)
### Bug Fixes
* fix(admin/contentType): locale option array on dateRange by @Davidmattei in https://github.com/ems-project/elasticms/pull/1059

## 5.22.2 (2024-10-28)
### Bug Fixes
* fix(admin/contentType): locale default null not 'en' by @Davidmattei in https://github.com/ems-project/elasticms/pull/1049
* fix(admin/security): give public access to route prefixed with /bundle by @theus77 in https://github.com/ems-project/elasticms/pull/1053
* fix(common/storage): s3 upload key bucket aware by @Davidmattei in https://github.com/ems-project/elasticms/pull/1044

## 5.22.1 (2024-10-11)
### Bug Fixes
* fix(admin/cli): reindex skip lock and with_warnings false by @Davidmattei in https://github.com/ems-project/elasticms/pull/1035
* fix(admin/document): display external content by @Davidmattei in https://github.com/ems-project/elasticms/pull/1037
* fix(ems/asset): unzip assets in admin (both in edit and view revision) by @theus77 in https://github.com/ems-project/elasticms/pull/1039

## 5.22.0 (2024-10-08)
### Features
* feat(admin/contentType): dataLinks support display expression by @Davidmattei in https://github.com/ems-project/elasticms/pull/1032
* feat(admin/mapping): add synonym filter and implement into demo by @theus77 in https://github.com/ems-project/elasticms/pull/1016
* feat(admin/tasks): rename task manager to task admin by @Davidmattei in https://github.com/ems-project/elasticms/pull/1021
* feat(admin/twig): json menu nested copy/paste functionality by @Davidmattei in https://github.com/ems-project/elasticms/pull/1033
* feat(admin/user): new get user language and sort tabs by @Davidmattei in https://github.com/ems-project/elasticms/pull/1026
* feat(admin/wysiwyg): add data attributes in iframe preview by @Davidmattei in https://github.com/ems-project/elasticms/pull/1029
* feat(common/twig): add new filter ems_link by @Davidmattei in https://github.com/ems-project/elasticms/pull/1028
### Bug Fixes
* fix(admin/datatable): revert remove table-responsive by @Davidmattei in https://github.com/ems-project/elasticms/pull/1023
* fix(admin/filter): remove btn with a2lix_lib by @theus77 in https://github.com/ems-project/elasticms/pull/1017
* fix(admin/revision): trash view only working for super user (sorting) by @Davidmattei in https://github.com/ems-project/elasticms/pull/1031
* fix(admin/twig-component): update json menu nested template by @Davidmattei in https://github.com/ems-project/elasticms/pull/1025
* fix(xliff): drop ZWSP or SHY characters by @theus77 in https://github.com/ems-project/elasticms/pull/1014
### Documentation
* docs(admin): describe type of field (content types) by @theus77 in https://github.com/ems-project/elasticms/pull/1019
### Code Refactoring
* refactor(admin/cli): replace EmsCommand.php by AbstractCommand from c… …ommon by @Davidmattei in https://github.com/ems-project/elasticms/pull/1022
### Chores
* chore(demo): remove double 'french_stop' from backup. by @theus77 in https://github.com/ems-project/elasticms/pull/1018

## 5.21.4 (2024-10-28)
### Bug Fixes
* fix(admin/security): give public access to route prefixed with /bundle by @theus77 in https://github.com/ems-project/elasticms/pull/1053
Expand Down
56 changes: 28 additions & 28 deletions EMS/admin-ui-bundle/composer.json
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
{
"name" : "elasticms/admin-ui-bundle",
"description" : "Admin ui bundle for elasticms",
"type" : "symfony-bundle",
"keywords" : [
"elasticms",
"admin",
"ui"
],
"license" : "MIT",
"authors" : [
{
"name" : "EMS Community",
"homepage" : "https://github.com/ems-project/EMSAdminUIBundle/contributors"
}
],
"require" : {
"php": "^8.1",
"elasticms/core-bundle": "5.21.*"
},
"autoload" : {
"psr-4" : {
"EMS\\AdminUIBundle\\" : "src/"
}
},
"config": {
"lock": false,
"sort-packages": true
}
"name": "elasticms/admin-ui-bundle",
"description": "Admin ui bundle for elasticms",
"type": "symfony-bundle",
"keywords": [
"elasticms",
"admin",
"ui"
],
"license": "MIT",
"authors": [
{
"name": "EMS Community",
"homepage": "https://github.com/ems-project/EMSAdminUIBundle/contributors"
}
],
"require": {
"php": "^8.1",
"elasticms/core-bundle": "5.24.*"
},
"autoload": {
"psr-4": {
"EMS\\AdminUIBundle\\": "src/"
}
},
"config": {
"lock": false,
"sort-packages": true
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@

<div class="json-menu-nested-component" id="{{ id }}" data-hash="{{ hash }}" {% if config.activeItemId %}data-active-item-id="{{ config.activeItemId }}"{% endif %}>
<div class="jmn-node-loading"><i class="fa fa-cog fa-spin fa-3x fa-fw"></i></div>
{{ template.block('jmn_layout_top', _context)|raw }}
<div class="jmn-top"></div>
<div class="jmn-wrapper">
{{ template.block('_jmn_columns', _context)|raw }}
<div class="jmn-header">{{ template.block('jmn_columns', _context)|raw }}</div>
<div id="{{- "tree-#{id}" -}}" class="jmn-tree jmn-node jmn-sortable" data-id="{{ config.jsonMenuNested.id }}" data-types="{{ config.nodes.types('_root')|json_encode|e('html_attr') }}"></div>
</div>
{{ template.block('jmn_layout_footer', _context)|raw }}
</div>
<div class="jmn-footer"></div>
</div>
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% trans_default_domain 'EMSCoreBundle' %}
{%- trans_default_domain 'EMSCoreBundle' -%}
{# @var config \EMS\CoreBundle\Core\Component\JsonMenuNested\Config\JsonMenuNestedConfig #}
{# @var column \EMS\CoreBundle\Core\Component\JsonMenuNested\Config\JsonMenuNestedColumn #}
{# @var template \EMS\CoreBundle\Core\Component\JsonMenuNested\Template\JsonMenuNestedTemplate #}
Expand All @@ -8,32 +8,30 @@
{# @var node \EMS\CoreBundle\Core\Component\JsonMenuNested\Config\JsonMenuNestedNode #}

{%- block jmn_layout_top -%}
<div class="jmn-top">
{{ template.block('jmn_title', _context)|raw }}
{{ template.block('jmn_actions', _context)|raw }}
</div>
<div>{{ template.block('jmn_title', _context)|raw }}</div>
<div>{{ template.block('jmn_actions', _context)|raw }}</div>
{%- endblock jmn_layout_top -%}

{%- block jmn_layout_footer -%}{% endblock jmn_layout_footer %}

{%- block jmn_title -%}{%- endblock jmn_title -%}

{%- block jmn_actions -%}
{% set dropDown = 'left' %}
{%- set dropDown = dropDown|default('right') -%}
{%- set node = config.nodes.root -%}
{{ template.block('jmn_button_add', _context)|raw }}
{{ template.block('jmn_button_more', _context)|raw }}
{%- endblock jmn_actions -%}

{%- block _jmn_columns -%}
<div class="jmn-header">
{% for column in config.columns %}
<div class="jmn-column {{ "jmn-column-#{column.name}" }}" style="{{ column.width ? "width:#{column.width}px;" }}" >
{%- if template.hasBlock("jmn_column_#{column.name}") -%}
{{ template.block("jmn_column_#{column.name}", _context)|raw }}
{%- endif -%}
</div>
{% endfor %}
</div>
{%- endblock _jmn_columns -%}
{%- block jmn_columns -%}
{% for column in config.columns %}
<div class="jmn-column {{ "jmn-column-#{column.name}" }}" style="{{ column.width ? "width:#{column.width}px;" }}" >
{%- if template.hasBlock("jmn_column_#{column.name}") -%}
{{ template.block("jmn_column_#{column.name}", _context)|raw }}
{%- endif -%}
</div>
{% endfor %}
{%- endblock jmn_columns -%}

{% block jmn_render %}
{% with { 'menu': menu } %}{{ template.block('jmn_items', _context)|raw }}{% endwith %}
Expand Down Expand Up @@ -112,33 +110,25 @@
<button class="jmn-btn-view" data-modal-size="{{- buttonModalSize|default('md') -}}">{{- buttonLabel|default('View') -}}</button>
{%- endblock jmn_button_item_view -%}

{%- block jmn_button_item_more -%}
{%- set menuMoreItems = menuMoreItems|default([
'jmn_button_item_view',
'jmn_button_item_edit',
'jmn_button_copy',
'jmn_button_paste',
'jmn_button_item_delete'
]) -%}
{{ template.block('jmn_button_more', _context)|raw }}
{%- endblock jmn_button_item_more -%}

{%- block jmn_button_item_add -%}
<button class="jmn-btn-add" data-add="{{ addNode.id }}" data-modal-size="{{- buttonModalSize|default('md') -}}">
{% if addNode.icon %}<i class="{{ addNode.icon }}"></i>{% endif %}
{{- buttonLabel|default("New #{addNode.label}") -}}
</button>
{%- endblock jmn_button_item_add -%}

{%- block jmn_button_item_more -%}
{% set menuMore = template.block('jmn_button_item_more_menu', _context)|raw %}
{% if menuMore|length > 0 %}
<div class="btn-group btn-group-sm">
<button type="button" class="btn btn-sm btn-default dropdown-toggle jmn-dropdown-more" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></button>
<ul class="dropdown-menu pull-right">
{{ menuMore|raw }}
</ul>
</div>
{% endif %}
{%- endblock jmn_button_item_more -%}

{%- block jmn_button_item_more_menu -%}
<li>{{ template.block('jmn_button_item_view', _context)|raw }}</li>
<li>{{ template.block('jmn_button_item_edit', _context)|raw }}</li>
<li>{{ template.block('jmn_button_item_delete', _context)|raw }}</li>
{%- endblock jmn_button_item_more_menu -%}

{%- block jmn_button_add -%}
{% set node = node|default(config.nodes.root) %}
{% set addNodes = config.nodes.children(node) %}
{% set addMenu = template.block('jmn_button_add_menu', _context)|raw %}
{% if addNodes|length > 0 and addMenu|length > 0 %}
Expand All @@ -154,11 +144,53 @@
{%- endblock jmn_button_add -%}

{%- block jmn_button_add_menu -%}
{% for addNode in addNodes|default([]) %}
<li>{{ template.block('jmn_button_item_add', _context)|raw }}</li>
{% endfor %}
{%- for addNode in addNodes|default([]) -%}
{%- set blockButtonItemAdd = template.block('jmn_button_item_add', _context)|raw -%}
{%- if blockButtonItemAdd|length > 0 -%}
<li>{{ template.block('jmn_button_item_add', _context)|raw }}</li>
{%- endif -%}
{%- endfor -%}
{%- endblock jmn_button_add_menu -%}

{%- block jmn_button_more -%}
{%- set menuMoreItems = menuMoreItems|default([
'jmn_button_copy',
'jmn_button_paste',
]) -%}
{% set menuMore = template.block('jmn_button_more_menu', _context)|raw %}
{% if menuMore|length > 0 %}
<div class="btn-group btn-group-sm">
<button type="button" class="btn btn-sm btn-default dropdown-toggle jmn-dropdown-more" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></button>
<ul class="{{ html_classes('dropdown-menu', { 'pull-right': (dropDown|default('right') == 'right') }) }}">
{{ menuMore|raw }}
</ul>
</div>
{% endif %}
{%- endblock jmn_button_more -%}

{%- block jmn_button_more_menu -%}
{%- for menuMoreItem in menuMoreItems -%}
{%- set blockMenuMoreItem = template.block(menuMoreItem, _context)|raw -%}
{%- if blockMenuMoreItem|length > 0 -%}
<li>{{ blockMenuMoreItem|raw }}</li>
{%- endif -%}
{%- endfor -%}
{%- endblock jmn_button_more_menu -%}

{%- block jmn_button_copy -%}
<button class="jmn-btn-copy">{{- buttonLabel|default(node == config.nodes.root ? 'Copy all' : 'Copy') -}}</button>
{%- endblock jmn_button_copy -%}

{%- block jmn_button_paste -%}
{%- if render.copyItem -%}
{%- set rootPaste = node == config.nodes.root and render.copyItem.type == config.nodes.root.type -%}
{%- set itemPaste = render.copyItem.type in config.nodes.children(node)|keys -%}
{%- if rootPaste or itemPaste -%}
<button class="jmn-btn-paste">{{- buttonLabel|default('Paste') -}}</button>
{%- endif -%}
{%- endif -%}
{%- endblock jmn_button_paste -%}

{%- block jmn_modal_title -%}
{% set modalTitle = modalTitle|default("#{action|capitalize} #{node.label|default}") %}
{% if node.icon|default(false) %}<i class="{{ node.icon }}"></i>&nbsp;{% endif %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,9 @@
{% if revision.hasVersionTags %}
<strong><i class="fa fa-tags margin-r-5"></i> Version</strong>
<p class="text-muted">
{% if newVersionTag|default(false) %}<span class="label label-success">New version {{ newVersionTag }}</span>{% endif %}
{% if newVersionTag is not null and newVersionTag != 'silent' %}
<span class="label label-success">New version {{ newVersionTag }}</span>
{% endif %}
{{ revision.versionTag|default('') }}
</p>
<hr/>
Expand Down Expand Up @@ -219,7 +221,7 @@

{% block revisionBody %}
<div class="box revision-view">
{% if revision.hasVersionTags and newVersionTag|default(false) %}
{% if revision.hasVersionTags and newVersionTag is not null and newVersionTag != 'silent' %}
<div class="box-header with-border bg-green color-palette">
<h3 class="box-title">New version <strong>{{ newVersionTag }}</strong></h3>
</div>
Expand Down

This file was deleted.

Loading
Loading