From 4bd722326d5173f6d9cad04d78d9c7502a67312d Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 13:59:13 +0200 Subject: [PATCH 01/44] refactor webpack_main into _bundler_main utility, in preparation for webpack re-use --- .../hqwebapp/templatetags/hq_shared_tags.py | 50 ++++++++++--------- 1 file changed, 27 insertions(+), 23 deletions(-) diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index cbeec9741b9e..90fd2a77d336 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -642,6 +642,32 @@ def analytics_ab_test(parser, token): return _create_page_data(parser, token, 'analytics_ab_test') +def _bundler_main(parser, token, flag, node_class): + bits = token.contents.split(None, 1) + if len(bits) == 1: + tag_name = bits[0] + value = None + else: + tag_name, value = bits + + # Treat requirejs_main_b5 identically to requirejs_main + # Some templates check for {% if requirejs_main %} + tag_name = tag_name.rstrip("_b5") + + if getattr(parser, flag, False): + raise TemplateSyntaxError( + "multiple '%s' tags not allowed (%s)" % tuple(bits)) + setattr(parser, flag, True) + + if value and (len(value) < 2 or value[0] not in '"\'' or value[0] != value[-1]): + raise TemplateSyntaxError("bad '%s' argument: %s" % tuple(bits)) + + # use a block to allow extension template to set _main for base + return loader_tags.BlockNode("__" + tag_name, NodeList([ + node_class(tag_name, value and value[1:-1]) + ])) + + @register.tag def requirejs_main_b5(parser, token): """ @@ -665,29 +691,7 @@ def requirejs_main(parser, token): will have a value of `None` unless an extending template has a `{% requirejs_main "..." %}` with a value. """ - bits = token.contents.split(None, 1) - if len(bits) == 1: - tag_name = bits[0] - value = None - else: - tag_name, value = bits - - # Treat requirejs_main_b5 identically to requirejs_main - # Some templates check for {% if requirejs_main %} - tag_name = tag_name.rstrip("_b5") - - if getattr(parser, "__saw_requirejs_main", False): - raise TemplateSyntaxError( - "multiple '%s' tags not allowed (%s)" % tuple(bits)) - parser.__saw_requirejs_main = True - - if value and (len(value) < 2 or value[0] not in '"\'' or value[0] != value[-1]): - raise TemplateSyntaxError("bad '%s' argument: %s" % tuple(bits)) - - # use a block to allow extension template to set requirejs_main for base - return loader_tags.BlockNode("__" + tag_name, NodeList([ - RequireJSMainNode(tag_name, value and value[1:-1]) - ])) + return _bundler_main(parser, token, "__saw_requirejs_main", RequireJSMainNode) class RequireJSMainNode(template.Node): From ed089608e6011413be6718a006ae90917292f455 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 14:04:15 +0200 Subject: [PATCH 02/44] add webpack_main and webpack_main_b3 tags, and introduce use_js_bundler as the new context var for determining if a page is using webpack or requirejs --- .../hqwebapp/templatetags/hq_shared_tags.py | 36 ++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index 90fd2a77d336..5f4ca634d12b 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -654,6 +654,9 @@ def _bundler_main(parser, token, flag, node_class): # Some templates check for {% if requirejs_main %} tag_name = tag_name.rstrip("_b5") + # likewise with webpack_main_b3, treat identically to webpack_main + tag_name = tag_name.rstrip("_b3") + if getattr(parser, flag, False): raise TemplateSyntaxError( "multiple '%s' tags not allowed (%s)" % tuple(bits)) @@ -694,6 +697,30 @@ def requirejs_main(parser, token): return _bundler_main(parser, token, "__saw_requirejs_main", RequireJSMainNode) +@register.tag +def webpack_main(parser, token): + """ + Indicate that a page should be using Webpack, by naming the + JavaScript module to be used as the page's main entry point. + + The base template need not specify a value in its `{% webpack_main %}` + tag, allowing it to be extended by templates that may or may not + use requirejs. In this case the `webpack_main` template variable + will have a value of `None` unless an extending template has a + `{% webpack_main "..." %}` with a value. + """ + return _bundler_main(parser, token, "__saw_webpack_main", WebpackMainNode) + + +@register.tag +def webpack_main_b3(parser, token): + """ + Alias for webpack_main. Use this to mark entry points that should be part of the + bootstrap 3 bundle of webpack. + """ + return webpack_main(parser, token) + + class RequireJSMainNode(template.Node): def __init__(self, name, value): @@ -704,12 +731,19 @@ def __repr__(self): return "" % (self.value,) def render(self, context): - if self.name not in context: + if self.name not in context and self.value: # set name in block parent context + context.dicts[-2]['use_js_bundler'] = True context.dicts[-2][self.name] = self.value return '' +class WebpackMainNode(RequireJSMainNode): + + def __repr__(self): + return "" % (self.value,) + + @register.inclusion_tag('hqwebapp/basic_errors.html') def bootstrap_form_errors(form): return {'form': form} From 76c5a7c1fc6ff5ced09c6451e66a336a93efa40c Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 14:38:10 +0200 Subject: [PATCH 03/44] update checks for requirejs_main in templates to new use_js_bundler flag --- .../hqadmin/hqadmin_base_report.html | 2 +- .../hqwebapp/templates/hqwebapp/base.html | 36 +++++++++---------- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/corehq/apps/hqadmin/templates/hqadmin/hqadmin_base_report.html b/corehq/apps/hqadmin/templates/hqadmin/hqadmin_base_report.html index a591d6dcd6f5..374241b4b965 100644 --- a/corehq/apps/hqadmin/templates/hqadmin/hqadmin_base_report.html +++ b/corehq/apps/hqadmin/templates/hqadmin/hqadmin_base_report.html @@ -5,7 +5,7 @@ {% block title %}{% if current_page and section %}{% if current_page.title %}{{ current_page.title }} : {% endif %}{{ section.page_name }} {% else %}{{ report.title }}{% endif %}: Admin Reports{% endblock %} {% block js %}{{ block.super }} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% if request.use_datatables %} {% endif %} diff --git a/corehq/apps/hqwebapp/templates/hqwebapp/base.html b/corehq/apps/hqwebapp/templates/hqwebapp/base.html index ce87bc4d9a7a..e619023c3095 100644 --- a/corehq/apps/hqwebapp/templates/hqwebapp/base.html +++ b/corehq/apps/hqwebapp/templates/hqwebapp/base.html @@ -149,13 +149,13 @@ window.USE_BOOTSTRAP5 = {{ use_bootstrap5|BOOL }}; - {% if not requirejs_main %} + {% if not use_js_bundler %} {% javascript_libraries use_bootstrap5=use_bootstrap5 underscore=True jquery_ui=request.use_jquery_ui ko=True hq=True analytics=True %} {% endif %} {# Up here because if daterangepicker is called from within a form widget, #} {# the javascript requiring the config file is run before js-inline #} - {% if request.use_daterangepicker and not requirejs_main and not use_bootstrap5 %} + {% if request.use_daterangepicker and not use_js_bundler and not use_bootstrap5 %} {% compress js %} @@ -163,7 +163,7 @@ {% endcompress %} {% endif %} - {% if request.use_tempusdominus and not requirejs_main and use_bootstrap5 %} + {% if request.use_tempusdominus and not use_js_bundler and use_bootstrap5 %} {% compress js %} @@ -319,7 +319,7 @@ {# DO NOT COMPRESS #} {# HQ Specific Libraries #} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% if use_bootstrap5 %} {% compress js %} @@ -347,7 +347,7 @@ {# JavaScript Display Logic Libaries #} - {% if request.couch_user and not requirejs_main %} + {% if request.couch_user and not use_js_bundler %} {% if use_bootstrap5 %} @@ -357,13 +357,13 @@ {% endif %} {% endif %} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% compress js %} {% endcompress %} {% endif %} - {% if request.use_nvd3 and not requirejs_main %} + {% if request.use_nvd3 and not use_js_bundler %} {% compress js %} @@ -372,7 +372,7 @@ {% endcompress %} {% endif %} - {% if request.use_nvd3_v3 and not requirejs_main %} + {% if request.use_nvd3_v3 and not use_js_bundler %} {% compress js %} @@ -380,7 +380,7 @@ {% endcompress %} {% endif %} - {% if request.use_datatables and not requirejs_main %} + {% if request.use_datatables and not use_js_bundler %} {% if use_bootstrap5 %} {% compress js %} @@ -397,20 +397,20 @@ {% endif %} {% endif %} - {% if request.use_typeahead and not requirejs_main and not use_bootstrap5 %} + {% if request.use_typeahead and not use_js_bundler and not use_bootstrap5 %} {% compress js %} {% endcompress %} {% endif %} - {% if request.use_timepicker and not requirejs_main and not use_bootstrap5 %} + {% if request.use_timepicker and not use_js_bundler and not use_bootstrap5 %} {% compress js %} {% endcompress %} {% endif %} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% if request.use_maps %} {% compress js %} @@ -419,17 +419,17 @@ {% endif %} {% endif %} - {% if request.use_maps and not requirejs_main %} + {% if request.use_maps and not use_js_bundler %} {% compress js %} {% endcompress %} {% endif %} - {% if request.use_timeago and not requirejs_main %} + {% if request.use_timeago and not use_js_bundler %} {% endif %} - {% if request.use_multiselect and not requirejs_main %} + {% if request.use_multiselect and not use_js_bundler %} {% compress js %} @@ -437,7 +437,7 @@ {% endcompress %} {% endif %} - {% if request.use_ko_validation and not requirejs_main %} + {% if request.use_ko_validation and not use_js_bundler %} {% if use_bootstrap5 %} @@ -469,7 +469,7 @@ {% include 'hqwebapp/partials/bootstrap3/ko_feedback.html' %} {% endif %} - {% if show_overdue_invoice_modal and not requirejs_main %} + {% if show_overdue_invoice_modal and not use_js_bundler %} {% if use_bootstrap5 %} {% else %} @@ -477,7 +477,7 @@ {% endif %} {% endif %} - {% if show_prepaid_modal and not requirejs_main %} + {% if show_prepaid_modal and not use_js_bundler %} {% if use_bootstrap5 %} {% else %} From 3af653aa3013facce29f96cfefd69bb30746bf23 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 14:38:48 +0200 Subject: [PATCH 04/44] update check for use_js_bundler flag in mocha test base template, with tbd note to figure out webpack for tests --- corehq/apps/mocha/templates/mocha/base.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/corehq/apps/mocha/templates/mocha/base.html b/corehq/apps/mocha/templates/mocha/base.html index 0eb30eff18d3..12ed3550b598 100644 --- a/corehq/apps/mocha/templates/mocha/base.html +++ b/corehq/apps/mocha/templates/mocha/base.html @@ -1,7 +1,7 @@ {% load compress %} {% load hq_shared_tags %} {% load statici18n %} -{% requirejs_main %} +{% requirejs_main %} {# todo, figure out webpack hooks for js tests #} @@ -21,14 +21,14 @@ {# DO NOT COMPRESS #} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% endif %} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% block core_libraries %} {% javascript_libraries underscore=True ko=True hq=True analytics=True %} {% endblock %} @@ -51,7 +51,7 @@
{% block mocha_tests %}{% endblock %} - {% if not requirejs_main %} + {% if not use_js_bundler %} From 15d683cd6ad239dcb9fc04b5cdfcd3a9aab01e4f Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 14:39:33 +0200 Subject: [PATCH 05/44] update usage of not requirejs_main check in test_bootstrap_changes to use_js_bundler for consistency --- .../apps/hqwebapp/tests/utils/test_bootstrap_changes.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/corehq/apps/hqwebapp/tests/utils/test_bootstrap_changes.py b/corehq/apps/hqwebapp/tests/utils/test_bootstrap_changes.py index fd3692fc1fc0..8b891810a86d 100644 --- a/corehq/apps/hqwebapp/tests/utils/test_bootstrap_changes.py +++ b/corehq/apps/hqwebapp/tests/utils/test_bootstrap_changes.py @@ -260,7 +260,7 @@ def test_flag_extended_changed_javascript_plugins_bootstrap5(): def test_file_contains_reference_to_path(): filedata = """ {# Our Libraries #} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% compress js %} @@ -274,7 +274,7 @@ def test_file_contains_reference_to_path(): def test_file_does_not_contain_reference_to_path(): filedata = """ {# Our Libraries #} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% compress js %} @@ -309,7 +309,7 @@ def test_javascript_file_does_not_contain_reference_to_path(): def test_replace_path_references(): filedata = """ {# Our Libraries #} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% compress js %} @@ -321,7 +321,7 @@ def test_replace_path_references(): result = replace_path_references(filedata, "foobarapp/js/bugz.js", "foobarapp/js/bootstrap3/bugz.js") expected_result = """ {# Our Libraries #} - {% if not requirejs_main %} + {% if not use_js_bundler %} {% compress js %} From 5f353ae8ada8d771b24d85ea421e867cf56197e5 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 14:40:16 +0200 Subject: [PATCH 06/44] update template tag tests for requirejs_main --- corehq/apps/hqwebapp/templatetags/tests/test_tag.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/corehq/apps/hqwebapp/templatetags/tests/test_tag.py b/corehq/apps/hqwebapp/templatetags/tests/test_tag.py index 8213b428b069..3d94c95b4036 100644 --- a/corehq/apps/hqwebapp/templatetags/tests/test_tag.py +++ b/corehq/apps/hqwebapp/templatetags/tests/test_tag.py @@ -101,7 +101,7 @@ def test_requirejs_main(self): {% extends "requirejs_base.html" %} {% load hq_shared_tags %} {% requirejs_main "requirejs/main" %} - {% block content %}{{requirejs_main}}{% endblock %} + {% block content %}{% if use_js_bundler %}{{requirejs_main}}{% endif %}{% endblock %} """).strip(), "requirejs/main after tag\nrequirejs/main", ) @@ -112,10 +112,10 @@ def test_requirejs_main_no_arg(self): self.render(""" {% load hq_shared_tags %} {% requirejs_main %} - {% if requirejs_main %}unexpected truth{% endif %} + {% if use_js_bundler %}unexpected truth{% endif %} {{requirejs_main}} """).strip(), - "None", + "", ) def test_requirejs_main_in_context(self): From 7e2697dea3f7c384f3bc77bcaebff57c68f6c346 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 14:54:01 +0200 Subject: [PATCH 07/44] continue to also check for requirejs_main in test --- corehq/apps/hqwebapp/templatetags/tests/test_tag.py | 1 + 1 file changed, 1 insertion(+) diff --git a/corehq/apps/hqwebapp/templatetags/tests/test_tag.py b/corehq/apps/hqwebapp/templatetags/tests/test_tag.py index 3d94c95b4036..c005799284f6 100644 --- a/corehq/apps/hqwebapp/templatetags/tests/test_tag.py +++ b/corehq/apps/hqwebapp/templatetags/tests/test_tag.py @@ -113,6 +113,7 @@ def test_requirejs_main_no_arg(self): {% load hq_shared_tags %} {% requirejs_main %} {% if use_js_bundler %}unexpected truth{% endif %} + {% if requirejs_main %}unexpected truth 2{% endif %} {{requirejs_main}} """).strip(), "", From 59b7d4bd4e86e584266547f7ceb661e4ac009982 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 14:55:02 +0200 Subject: [PATCH 08/44] add tests for webpack_main tag, mirroring requirejs_main --- .../tests/templates/webpack_base.html | 5 ++ .../hqwebapp/templatetags/tests/test_tag.py | 73 +++++++++++++++++++ 2 files changed, 78 insertions(+) create mode 100644 corehq/apps/hqwebapp/templatetags/tests/templates/webpack_base.html diff --git a/corehq/apps/hqwebapp/templatetags/tests/templates/webpack_base.html b/corehq/apps/hqwebapp/templatetags/tests/templates/webpack_base.html new file mode 100644 index 000000000000..2825998d2dc2 --- /dev/null +++ b/corehq/apps/hqwebapp/templatetags/tests/templates/webpack_base.html @@ -0,0 +1,5 @@ +{% load hq_shared_tags %} +{% if webpack_main %}{{ webpack_main }} before tag{% endif %} +{% webpack_main "webpack/base" %} +{% if webpack_main %}{{ webpack_main }} after tag{% endif %} +{% block content %}{% endblock %} diff --git a/corehq/apps/hqwebapp/templatetags/tests/test_tag.py b/corehq/apps/hqwebapp/templatetags/tests/test_tag.py index c005799284f6..4d028d16ede4 100644 --- a/corehq/apps/hqwebapp/templatetags/tests/test_tag.py +++ b/corehq/apps/hqwebapp/templatetags/tests/test_tag.py @@ -167,3 +167,76 @@ def test_requirejs_main_mismatched_delimiter(self): {% load hq_shared_tags %} {% requirejs_main 'x" %} """) + + def test_webpack_main(self): + self.assertEqual( + self.render(""" + {% extends "webpack_base.html" %} + {% load hq_shared_tags %} + {% webpack_main "webpack/main" %} + {% block content %}{% if use_js_bundler %}{{webpack_main}}{% endif %}{% endblock %} + """).strip(), + "webpack/main after tag\nwebpack/main", + ) + + def test_webpack_main_no_arg(self): + # this version can be used in a base template that may or may not use webpack + self.assertEqual( + self.render(""" + {% load hq_shared_tags %} + {% webpack_main %} + {% if use_js_bundler %}unexpected truth{% endif %} + {% if webpack_main %}unexpected truth 2{% endif %} + {{webpack_main}} + """).strip(), + "", + ) + + def test_webpack_main_in_context(self): + self.assertEqual( + self.render( + """ + {% extends "webpack_base.html" %} + {% load hq_shared_tags %} + {% webpack_main "webpack/main" %} + {% block content %}{{webpack_main}}{% endblock %} + """, + {"webpack_main": "webpack/context"} + ).strip(), + "webpack/context before tag\n\n" + "webpack/context after tag\n" + "webpack/context", + ) + + def test_webpack_main_multiple_tags(self): + msg = r"multiple 'webpack_main' tags not allowed \(\"webpack/two\"\)" + with self.assertRaisesRegex(TemplateSyntaxError, msg): + self.render(""" + {% load hq_shared_tags %} + {% webpack_main "webpack/one" %} + {% webpack_main "webpack/two" %} + """) + + def test_webpack_main_too_short(self): + msg = r"bad 'webpack_main' argument: '" + with self.assertRaisesRegex(TemplateSyntaxError, msg): + self.render(""" + {% load hq_shared_tags %} + {% webpack_main ' %} + """) + + def test_webpack_main_bad_string(self): + msg = r"bad 'webpack_main' argument: \.'" + with self.assertRaisesRegex(TemplateSyntaxError, msg): + self.render(""" + {% load hq_shared_tags %} + {% webpack_main .' %} + """) + + def test_webpack_main_mismatched_delimiter(self): + msg = r"bad 'webpack_main' argument: 'x\"" + with self.assertRaisesRegex(TemplateSyntaxError, msg): + self.render(""" + {% load hq_shared_tags %} + {% webpack_main 'x" %} + """) From 51108ee984dd6e81b09a00ea370611ceed40d3ee Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 18:43:57 +0200 Subject: [PATCH 09/44] add script for generating details / entries for webpack config --- .gitignore | 3 + webpack/appPaths.js | 63 ++++++++++++++++++++ webpack/generateDetails.js | 119 +++++++++++++++++++++++++++++++++++++ 3 files changed, 185 insertions(+) create mode 100644 webpack/appPaths.js create mode 100644 webpack/generateDetails.js diff --git a/.gitignore b/.gitignore index d3ae1d1011ed..61bfa61fb5a1 100644 --- a/.gitignore +++ b/.gitignore @@ -85,3 +85,6 @@ corehq/apps/hqwebapp/static/hqwebapp/js/lib/modernizr.js # direnv .envrc .direnv + +# webpack build related +/webpack/*.json diff --git a/webpack/appPaths.js b/webpack/appPaths.js new file mode 100644 index 000000000000..cef1388061c4 --- /dev/null +++ b/webpack/appPaths.js @@ -0,0 +1,63 @@ +'use strict'; + +const fs = require('fs'); +const path = require('path'); + +const __BASE = path.resolve(__dirname, '..'); +const TEMPLATES_DIR = 'templates'; +const APPS_PATH = path.resolve(__BASE, 'corehq', 'apps'); +const EX_SUBMODULES_PATH = path.resolve(__BASE, 'corehq', 'ex-submodules'); +const MOTECH_PATH = path.resolve(__BASE, 'corehq', 'motech'); +const CUSTOM_PATH = path.resolve(__BASE, 'custom'); + +const nonStandardAppPaths = { + "case": path.resolve(EX_SUBMODULES_PATH, 'casexml', 'apps', 'case'), + "soil": path.resolve(EX_SUBMODULES_PATH, 'soil'), + "motech": MOTECH_PATH, + // motech apps: + "dhis2": path.resolve(MOTECH_PATH, 'dhis2'), + "generic_inbound": path.resolve(MOTECH_PATH, 'generic_inbound'), + "openmrs": path.resolve(MOTECH_PATH, 'openmrs'), + "repeaters": path.resolve(MOTECH_PATH, 'repeaters'), + // custom apps: + "champ": path.resolve(CUSTOM_PATH, 'champ'), + "inddex": path.resolve(CUSTOM_PATH, 'inddex'), + "mc": path.resolve(CUSTOM_PATH, 'reports', 'mc'), + "up_nrhm": path.resolve(CUSTOM_PATH, 'up_nrhm'), +}; + +// workaround for apps that have different folder names in the static directory (rare) +const appRenames = { + "analytics": "analytix", +}; + +const hasTemplateFolder = function (dirEnt) { + const templatePath = path.resolve(APPS_PATH, dirEnt.name, TEMPLATES_DIR); + try { + return fs.readdirSync(templatePath); + } catch (e) { + // throws an error if the templates directory does not exist + return false; + } +}; + +const getStandardAppPaths = function () { + const paths = {}; + fs.readdirSync(APPS_PATH, {withFileTypes: true}) + .filter(dirEnt => dirEnt.isDirectory()) + .filter(hasTemplateFolder) + .forEach(dirEnt => { + let appName = appRenames[dirEnt.name] || dirEnt.name; + paths[appName] = path.resolve(APPS_PATH, dirEnt.name); + }); + return paths; +}; + +const getAllAppPaths = function () { + return Object.assign(getStandardAppPaths(), nonStandardAppPaths); +}; + +module.exports = { + getAllAppPaths: getAllAppPaths, + TEMPLATES_DIR: TEMPLATES_DIR, +}; diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js new file mode 100644 index 000000000000..2c176187aa61 --- /dev/null +++ b/webpack/generateDetails.js @@ -0,0 +1,119 @@ +'use strict'; + +const fs = require('fs'); +const path = require('path'); +const appPaths = require('./appPaths'); + +const scanTemplates = function (dir, entryRegex, allAppPaths, details, isProdMode) { + const files = fs.readdirSync(dir); + + files.forEach((file) => { + let fullPath = path.join(dir, file); + let stats = fs.statSync(fullPath); + + if (stats.isDirectory()) { + // Make sure we recursively scan subdirectories + scanTemplates(fullPath, entryRegex, allAppPaths, details, isProdMode); + } else if (stats.isFile() && fullPath.endsWith('.html')) { + let content = fs.readFileSync(fullPath, 'utf-8'); + let match; + + // Extract all matches of the {% webpack_main "path" %} tag + while ((match = entryRegex.exec(content)) !== null) { + let entryName = match[1]; + let folders = entryName.split('/'); + let appName = folders[0]; + let fullEntryPath = path.join(allAppPaths[appName], 'static', `${entryName}.js`); + + if (!fs.existsSync(fullEntryPath)) { + console.warn(`JavaScript file not found: ${fullEntryPath}`); + continue; + } + details.entries[entryName] = { + import: fullEntryPath, + // for cache-busting in production: + filename: isProdMode ? `${entryName}.[contenthash].js` : `${entryName}.js`, + }; + + let aliasName = folders.slice(0, 2).join('/'); + if (!(aliasName in details.aliases)) { + details.aliases[aliasName] = path.join(allAppPaths[appName], 'static', aliasName); + } + if (!details.appsWithEntries.includes(appName)) { + details.appsWithEntries.push(appName); + } + } + } + }); +}; + +const getDetails = function (entryRegex, allAppPaths, isProdMode) { + const details = { + entries: {}, + aliases: {}, + appsWithEntries: [], + }; + for (let appName in allAppPaths) { + scanTemplates( + path.join(allAppPaths[appName], appPaths.TEMPLATES_DIR), + entryRegex, + allAppPaths, + details, + isProdMode + ); + } + return details; +}; + +// When run from the command line: +if (require.main === module) { + const isProductionMode = process.argv.includes('--prod'); + const allAppPaths = appPaths.getAllAppPaths(); + + // guarantee that these aliases are always generated + const aliases = { + 'hqwebapp/js': path.join(allAppPaths.hqwebapp, 'static/hqwebapp/js'), + 'notifications/js': path.join(allAppPaths.notifications, 'static/notifications/js'), + }; + + // guarantee that these apps are always included + const appsWithEntries = [ + "hqwebapp", + "notifications", + ]; + + // This splits the builds into bootstrap 5 and bootstrap 3 versions + const defaultDetails = getDetails( + /{% webpack_main ["']([\/\w\-]+)["'] %}/g, + allAppPaths, + isProductionMode + ); + const b3Details = getDetails( + /{% webpack_main_b3 ["']([\/\w\-]+)["'] %}/g, + allAppPaths, + isProductionMode + ); + + fs.writeFileSync( + path.resolve(__dirname, 'details.json'), + JSON.stringify({ + entries: defaultDetails.entries, + b3Entries: b3Details.entries, + aliases: Object.assign( + aliases, + defaultDetails.aliases, + b3Details.aliases + ), + appsWithEntries: Object.assign( + appsWithEntries, + defaultDetails.appsWithEntries, + b3Details.appsWithEntries + ), + allAppPaths: allAppPaths, + }, null, 2) + ); +} + +module.exports = { + getDetails: getDetails, +}; From b8ed4ce138d022ade3466606d0fce7d8639e0457 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 18:46:27 +0200 Subject: [PATCH 10/44] add webpack_main usage to hqwebapp/base.html --- corehq/apps/hqwebapp/static/hqwebapp/js/hqModules.js | 4 ++-- corehq/apps/hqwebapp/templates/hqwebapp/base.html | 3 +++ .../hqwebapp/templates/hqwebapp/partials/webpack.html | 9 +++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html diff --git a/corehq/apps/hqwebapp/static/hqwebapp/js/hqModules.js b/corehq/apps/hqwebapp/static/hqwebapp/js/hqModules.js index 292d41083ace..ddb2fa88483f 100644 --- a/corehq/apps/hqwebapp/static/hqwebapp/js/hqModules.js +++ b/corehq/apps/hqwebapp/static/hqwebapp/js/hqModules.js @@ -57,7 +57,7 @@ function hqDefine(path, dependencies, moduleAccessor) { } (function (factory) { - if (typeof define === 'function' && define.amd && window.USE_REQUIREJS) { + if (typeof define === 'function' && define.amd && (window.USE_REQUIREJS || window.USE_WEBPACK)) { // HQ's requirejs build process (build_requirejs.py) replaces hqDefine calls with // define calls, so it's important that this do nothing but pass through to require define(path, dependencies, factory); @@ -117,7 +117,7 @@ function hqImport(path) { // at module definition time, but this function can be used when doing so would // introduce a circular dependency. function hqRequire(paths, callback) { // eslint-disable-line no-unused-vars - if (typeof define === 'function' && define.amd && window.USE_REQUIREJS) { + if (typeof define === 'function' && define.amd && (window.USE_REQUIREJS || window.USE_WEBPACK)) { // HQ's requirejs build process (build_requirejs.py) replaces hqRequire calls with // require calls, so it's important that this do nothing but pass through to require require(paths, callback); // eslint-disable-line no-undef diff --git a/corehq/apps/hqwebapp/templates/hqwebapp/base.html b/corehq/apps/hqwebapp/templates/hqwebapp/base.html index e619023c3095..774b5e82660b 100644 --- a/corehq/apps/hqwebapp/templates/hqwebapp/base.html +++ b/corehq/apps/hqwebapp/templates/hqwebapp/base.html @@ -1,6 +1,7 @@ {% load menu_tags %}{% load i18n %}{% load hq_shared_tags %}{% load cache %}{% load compress %}{% load statici18n %} {% get_current_language as LANGUAGE_CODE %} {% requirejs_main %} +{% webpack_main %} @@ -318,6 +319,8 @@ {# DO NOT COMPRESS #} + {% include "hqwebapp/partials/webpack.html" %} {# must come after statici18n above #} + {# HQ Specific Libraries #} {% if not use_js_bundler %} {% if use_bootstrap5 %} diff --git a/corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html b/corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html new file mode 100644 index 000000000000..fbb00679bb56 --- /dev/null +++ b/corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html @@ -0,0 +1,9 @@ +{% load hq_shared_tags %} + +{% if webpack_main %} + + +{% endif %} From 2345791601bdf4350ad6d869215aa90f365a031e Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 18:47:26 +0200 Subject: [PATCH 11/44] add management command to pass SATIC_ROOT settings from django to webpack config by generating webpack/settings.json --- .../commands/genereate_webpack_settings.py | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 corehq/apps/hqwebapp/management/commands/genereate_webpack_settings.py diff --git a/corehq/apps/hqwebapp/management/commands/genereate_webpack_settings.py b/corehq/apps/hqwebapp/management/commands/genereate_webpack_settings.py new file mode 100644 index 000000000000..2f3795748dbc --- /dev/null +++ b/corehq/apps/hqwebapp/management/commands/genereate_webpack_settings.py @@ -0,0 +1,21 @@ +import json +from pathlib import Path + +from django.conf import settings +from django.core.management.base import BaseCommand + +import corehq + +WEBPACK_BASE_DIR = Path(corehq.__file__).resolve().parent.parent / "webpack" + + +class Command(BaseCommand): + help = ("Generates a settings file for webpack so that the same staticfiles directory " + "that Django is using is passed to the Webpack build.") + + def handle(self, **options): + webpack_settings = { + 'staticfilesPath': settings.STATIC_ROOT, + } + with open(WEBPACK_BASE_DIR / "settings.json", "w") as f: + json.dump(webpack_settings, f) From 1a54bb20a479e692f741c6da3acd77eafb045643 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 19:27:01 +0200 Subject: [PATCH 12/44] add webpack configs for development and production, split across bootstrap5 and 3 --- package.json | 12 +- webpack/utils.js | 88 +++ webpack/webpack.b3.common.js | 24 + webpack/webpack.common.js | 95 +++ webpack/webpack.dev.js | 35 ++ webpack/webpack.prod.js | 43 ++ yarn.lock | 1062 ++++++++++++++++++++++++++++++++-- 7 files changed, 1316 insertions(+), 43 deletions(-) create mode 100644 webpack/utils.js create mode 100644 webpack/webpack.b3.common.js create mode 100644 webpack/webpack.common.js create mode 100644 webpack/webpack.dev.js create mode 100644 webpack/webpack.prod.js diff --git a/package.json b/package.json index af25524f87df..e36ab142778f 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,7 @@ "description": "CommCare HQ Javascript Libraries", "private": true, "dependencies": { + "@babel/core": "7.25.2", "@babel/standalone": "^7.21.4", "@ckeditor/ckeditor5-alignment": "^40.1.0", "@ckeditor/ckeditor5-build-classic": "^40.1.0", @@ -21,6 +22,7 @@ "Caret.js": "INTELOGIE/Caret.js#0.3.1", "DOMPurify": "npm:dompurify#2.3.6", "ace-builds": "1.5.0", + "babel-loader": "9.1.3", "babel-plugin-transform-modules-requirejs-babel": "^0.1.0", "backbone": "npm:backbone#~1.3.2", "backbone.marionette": "4.1.3", @@ -42,6 +44,7 @@ "datatables.net-fixedcolumns-bs5": "4.3.0", "detectrtc": "1.4.0", "eonasdan-bootstrap-datetimepicker": "4.17.49", + "exports-loader": "5.0.0", "fast-levenshtein": "2.0.6", "intl-tel-input": "9.0.7", "jquery": "3.5.1", @@ -79,11 +82,16 @@ "requirejs-babel7": "^1.3.2", "select2": "4.1.0-rc.0", "signature_pad": "^4.1.6", + "string-replace-loader": "3.1.0", "topojson": "3.0.2", "uglify-js": "3", "ui-select": "npm:ui-select#0.13.2", "underscore": "1.13.1", "url-polyfill": "1.1.10", + "webpack": "5.93.0", + "webpack-cli": "5.1.4", + "webpack-merge": "6.0.1", + "webpack-modernizr-loader": "5.0.0", "xpath": "dimagi/js-xpath#v0.0.8", "zxcvbn": "4.4.2" }, @@ -127,6 +135,8 @@ }, "scripts": { "postinstall": "yarn run -s build:modernizr", - "build:modernizr": "modernizr -c modernizr-conf.json -d corehq/apps/hqwebapp/static/hqwebapp/js/lib" + "build:modernizr": "modernizr -c modernizr-conf.json -d corehq/apps/hqwebapp/static/hqwebapp/js/lib", + "dev": "node webpack/generateDetails.js && webpack --mode development --config webpack/webpack.dev.js --watch", + "build": "node webpack/generateDetails.js --prod && webpack --config webpack/webpack.prod.js" } } diff --git a/webpack/utils.js b/webpack/utils.js new file mode 100644 index 000000000000..2dd8643af624 --- /dev/null +++ b/webpack/utils.js @@ -0,0 +1,88 @@ +'use strict'; + +const path = require("path"); +const fs = require("fs"); + +const __BASE = path.resolve(__dirname, '..'); +const SETTINGS_FILE = path.resolve(__dirname, 'settings.json'); +const DETAILS_FILE = path.resolve(__dirname, 'details.json'); + +const fetchJsonDataOrDefault = function (filePath, defaultData) { + let fetchedData = defaultData; + if (fs.existsSync(filePath)) { + const content = fs.readFileSync(filePath, 'utf-8'); + fetchedData = JSON.parse(content); + } + return fetchedData; +}; + +const DETAILS = fetchJsonDataOrDefault(DETAILS_FILE, {}); +const SETTINGS = fetchJsonDataOrDefault(SETTINGS_FILE, { + staticfilesPath: path.resolve(__BASE, 'staticfiles'), +}); +const WEBPACK_PATH = path.join(SETTINGS.staticfilesPath, 'webpack'); +const WEBPACK_B3_PATH = path.join(SETTINGS.staticfilesPath, 'webpack_b3'); + +const getStaticFolderForApp = function (appName) { + const appPath = DETAILS.allAppPaths[appName]; + if (!appPath) { + console.warn(`No path found for ${appName}`); + } + return path.join(appPath, 'static'); +}; + +const getStaticPathForApp = function (appName, directory) { + directory = directory || ""; + const staticFolder = getStaticFolderForApp(appName); + return path.resolve(staticFolder, appName, directory); +}; + +const getEntries = function (otherEntry) { + const otherEntries = { + 'b3': DETAILS.b3Entries, + }; + return otherEntries[otherEntry] || DETAILS.entries; +}; + +const getAllAliases = function (aliases) { + return Object.assign(aliases, DETAILS.aliases); +}; + +const getCacheGroups = function () { + const cacheGroups = { + common: { + name: 'common', + chunks: 'all', + minChunks: 2, + priority: 1, + }, + vendor: { + test: /[\\/]node_modules[\\/]/, + name: 'vendor', + chunks: 'all', + priority: 1, + }, + }; + + DETAILS.appsWithEntries.forEach(appName => { + const testExp = new RegExp("[\\\\/]" + appName + "[\\\\/]js[\\\\/]"); + cacheGroups[appName] = { + test: testExp, + name: `${appName}/${appName}.bundle`, + chunks: 'all', + minChunks: 1, + priority: 0, + }; + }); + return cacheGroups; +}; + +module.exports = { + WEBPACK_PATH: WEBPACK_PATH, + WEBPACK_B3_PATH: WEBPACK_B3_PATH, + getStaticFolderForApp: getStaticFolderForApp, + getStaticPathForApp: getStaticPathForApp, + getEntries: getEntries, + getAllAliases: getAllAliases, + getCacheGroups: getCacheGroups, +}; diff --git a/webpack/webpack.b3.common.js b/webpack/webpack.b3.common.js new file mode 100644 index 000000000000..73cc781fce6f --- /dev/null +++ b/webpack/webpack.b3.common.js @@ -0,0 +1,24 @@ +'use strict'; + +const commonDefault = require("./webpack.common"); +const webpack = require('webpack'); +const utils = require('./utils'); + +// bootstrap 3 builds off of the default common config, +// with some overrides specified below... +module.exports = Object.assign({}, commonDefault, { + entry: utils.getEntries('b3'), + + plugins: [ + new webpack.ProvidePlugin({ + '$': 'jquery', + 'jQuery': 'jquery', // needed for bootstrap 3 to work + }), + ], + + optimization: { + splitChunks: { + cacheGroups: utils.getCacheGroups('b3'), + }, + }, +}); diff --git a/webpack/webpack.common.js b/webpack/webpack.common.js new file mode 100644 index 000000000000..65e66d2800b6 --- /dev/null +++ b/webpack/webpack.common.js @@ -0,0 +1,95 @@ +'use strict'; + +const path = require('path'); +const webpack = require('webpack'); +const utils = require('./utils'); + +const aliases = { + "jquery": "jquery/dist/jquery.min", + + // todo after completing requirejs migration, + // remove this file and the yarn modernizr post-install step + "modernizr": "hqwebapp/js/lib/modernizr", + + "sentry_browser": path.resolve(utils.getStaticFolderForApp('hqwebapp'), + 'sentry/js/sentry.browser.7.28.0.min'), + "sentry_captureconsole": path.resolve(utils.getStaticFolderForApp('hqwebapp'), + 'sentry/js/sentry.captureconsole.7.28.0.min'), + "tempusDominus": "@eonasdan/tempus-dominus", + "ko.mapping": path.resolve(utils.getStaticPathForApp('hqwebapp', 'js/lib/knockout_plugins/'), + 'knockout_mapping.ko.min'), +}; + + +module.exports = { + entry: utils.getEntries(), + + module: { + rules: [ + { + test: /\.js$/, + loader: 'babel-loader', + }, + + // this rule ensures that hqDefine is renamed to define AMD module + // definition syntax that webpack understands + { + test: /\.js$/, + loader: 'string-replace-loader', + options: { + search: /\bhqDefine\b/g, + replace: 'define', + }, + }, + { + test: /\.js$/, + loader: 'string-replace-loader', + options: { + search: /\b(es6!)?hqwebapp\/js\/bootstrap5_loader\b/g, + replace: 'bootstrap5', + }, + }, + + { + test: /modernizr\.js$/, + loader: "webpack-modernizr-loader", + options: { + "options": [ + "setClasses", + ], + "feature-detects": [ + "test/svg/smil", + ], + }, + }, + + { + test: /sentry\.browser/, + loader: "exports-loader", + options: { + type: "commonjs", + exports: { + syntax: "single", + name: "Sentry", + }, + }, + }, + ], + }, + + plugins: [ + new webpack.ProvidePlugin({ + '$': 'jquery', + }), + ], + + optimization: { + splitChunks: { + cacheGroups: utils.getCacheGroups(), + }, + }, + + resolve: { + alias: utils.getAllAliases(aliases), + }, +}; diff --git a/webpack/webpack.dev.js b/webpack/webpack.dev.js new file mode 100644 index 000000000000..b58f4156ae26 --- /dev/null +++ b/webpack/webpack.dev.js @@ -0,0 +1,35 @@ +'use strict'; + +const { merge } = require('webpack-merge'); +const common = require('./webpack.common'); +const b3Common = require('./webpack.b3.common'); +const utils = require("./utils"); + +// after the Bootstrap 5 migration is complete, +// we can remove the list and just export one merged config +module.exports = [ + // this is the default webpack development config + merge( + common, { + mode: 'development', + devtool: 'inline-source-map', + output: { + filename: '[name].js', + path: utils.WEBPACK_PATH, + clean: true, + }, + }), + // this is the Bootstrap 3 development config, which + // builds to the webpack_b3 directory and outputs + // the manifest to manifest_b3.json + merge( + b3Common, { + mode: 'development', + devtool: 'inline-source-map', + output: { + filename: '[name].js', + path: utils.WEBPACK_B3_PATH, + clean: true, + }, + }), +]; diff --git a/webpack/webpack.prod.js b/webpack/webpack.prod.js new file mode 100644 index 000000000000..45f80a9f8fdb --- /dev/null +++ b/webpack/webpack.prod.js @@ -0,0 +1,43 @@ +'use strict'; + +const { merge } = require('webpack-merge'); +const common = require('./webpack.common'); +const b3Common = require('./webpack.b3.common'); +const utils = require("./utils"); + + +// After the Bootstrap 5 migration is complete, +// we can remove the list and just export one merged config +module.exports = [ + // this is the default webpack production config + merge( + common, { + mode: 'production', + devtool: 'source-map', + performance: { + // for now we'll disable bundle size warnings until we + // are ready to implement recommended optimizations + hints: false, + }, + output: { + filename: '[name].[contenthash].js', // cache-busting + path: utils.WEBPACK_PATH, + clean: true, + }, + }), + // this is the Bootstrap 3 production config, which + // builds to the webpack_b3 directory + merge( + b3Common, { + mode: 'production', + devtool: 'source-map', + performance: { + hints: false, + }, + output: { + filename: '[name].[contenthash].js', + path: utils.WEBPACK_B3_PATH, + clean: true, + }, + }), +]; diff --git a/yarn.lock b/yarn.lock index 06cace17d8ec..94c3d560cffe 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,14 @@ # yarn lockfile v1 +"@ampproject/remapping@^2.2.0": + version "2.3.0" + resolved "https://registry.yarnpkg.com/@ampproject/remapping/-/remapping-2.3.0.tgz#ed441b6fa600072520ce18b43d2c8cc8caecc7f4" + integrity sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw== + dependencies: + "@jridgewell/gen-mapping" "^0.3.5" + "@jridgewell/trace-mapping" "^0.3.24" + "@babel/code-frame@^7.0.0": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.10.4.tgz#168da1a36e90da68ae8d49c0f1b48c7c6249213a" @@ -9,11 +17,115 @@ dependencies: "@babel/highlight" "^7.10.4" +"@babel/code-frame@^7.24.7": + version "7.24.7" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.24.7.tgz#882fd9e09e8ee324e496bd040401c6f046ef4465" + integrity sha512-BcYH1CVJBO9tvyIZ2jVeXgSIMvGZ2FDRvDdOIVQyuklNKSsx+eppDEBq/g47Ayw+RqNFE+URvOShmf+f/qwAlA== + dependencies: + "@babel/highlight" "^7.24.7" + picocolors "^1.0.0" + +"@babel/compat-data@^7.25.2": + version "7.25.2" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.25.2.tgz#e41928bd33475305c586f6acbbb7e3ade7a6f7f5" + integrity sha512-bYcppcpKBvX4znYaPEeFau03bp89ShqNMLs+rmdptMw+heSZh9+z84d2YG+K7cYLbWwzdjtDoW/uqZmPjulClQ== + +"@babel/core@7.25.2": + version "7.25.2" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.25.2.tgz#ed8eec275118d7613e77a352894cd12ded8eba77" + integrity sha512-BBt3opiCOxUr9euZ5/ro/Xv8/V7yJ5bjYMqG/C1YAo8MIKAnumZalCN+msbci3Pigy4lIQfPUpfMM27HMGaYEA== + dependencies: + "@ampproject/remapping" "^2.2.0" + "@babel/code-frame" "^7.24.7" + "@babel/generator" "^7.25.0" + "@babel/helper-compilation-targets" "^7.25.2" + "@babel/helper-module-transforms" "^7.25.2" + "@babel/helpers" "^7.25.0" + "@babel/parser" "^7.25.0" + "@babel/template" "^7.25.0" + "@babel/traverse" "^7.25.2" + "@babel/types" "^7.25.2" + convert-source-map "^2.0.0" + debug "^4.1.0" + gensync "^1.0.0-beta.2" + json5 "^2.2.3" + semver "^6.3.1" + +"@babel/generator@^7.25.0": + version "7.25.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.25.0.tgz#f858ddfa984350bc3d3b7f125073c9af6988f18e" + integrity sha512-3LEEcj3PVW8pW2R1SR1M89g/qrYk/m/mB/tLqn7dn4sbBUQyTqnlod+II2U4dqiGtUmkcnAmkMDralTFZttRiw== + dependencies: + "@babel/types" "^7.25.0" + "@jridgewell/gen-mapping" "^0.3.5" + "@jridgewell/trace-mapping" "^0.3.25" + jsesc "^2.5.1" + +"@babel/helper-compilation-targets@^7.25.2": + version "7.25.2" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.25.2.tgz#e1d9410a90974a3a5a66e84ff55ef62e3c02d06c" + integrity sha512-U2U5LsSaZ7TAt3cfaymQ8WHh0pxvdHoEk6HVpaexxixjyEquMh0L0YNJNM6CTGKMXV1iksi0iZkGw4AcFkPaaw== + dependencies: + "@babel/compat-data" "^7.25.2" + "@babel/helper-validator-option" "^7.24.8" + browserslist "^4.23.1" + lru-cache "^5.1.1" + semver "^6.3.1" + +"@babel/helper-module-imports@^7.24.7": + version "7.24.7" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.24.7.tgz#f2f980392de5b84c3328fc71d38bd81bbb83042b" + integrity sha512-8AyH3C+74cgCVVXow/myrynrAGv+nTVg5vKu2nZph9x7RcRwzmh0VFallJuFTZ9mx6u4eSdXZfcOzSqTUm0HCA== + dependencies: + "@babel/traverse" "^7.24.7" + "@babel/types" "^7.24.7" + +"@babel/helper-module-transforms@^7.25.2": + version "7.25.2" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.25.2.tgz#ee713c29768100f2776edf04d4eb23b8d27a66e6" + integrity sha512-BjyRAbix6j/wv83ftcVJmBt72QtHI56C7JXZoG2xATiLpmoC7dpd8WnkikExHDVPpi/3qCmO6WY1EaXOluiecQ== + dependencies: + "@babel/helper-module-imports" "^7.24.7" + "@babel/helper-simple-access" "^7.24.7" + "@babel/helper-validator-identifier" "^7.24.7" + "@babel/traverse" "^7.25.2" + +"@babel/helper-simple-access@^7.24.7": + version "7.24.7" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.24.7.tgz#bcade8da3aec8ed16b9c4953b74e506b51b5edb3" + integrity sha512-zBAIvbCMh5Ts+b86r/CjU+4XGYIs+R1j951gxI3KmmxBMhCg4oQMsv6ZXQ64XOm/cvzfU1FmoCyt6+owc5QMYg== + dependencies: + "@babel/traverse" "^7.24.7" + "@babel/types" "^7.24.7" + +"@babel/helper-string-parser@^7.24.8": + version "7.24.8" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.24.8.tgz#5b3329c9a58803d5df425e5785865881a81ca48d" + integrity sha512-pO9KhhRcuUyGnJWwyEgnRJTSIZHiT+vMD0kPeD+so0l7mxkMT19g3pjY9GTnHySck/hDzq+dtW/4VgnMkippsQ== + "@babel/helper-validator-identifier@^7.10.4": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz#a78c7a7251e01f616512d31b10adcf52ada5e0d2" integrity sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw== +"@babel/helper-validator-identifier@^7.24.7": + version "7.24.7" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.7.tgz#75b889cfaf9e35c2aaf42cf0d72c8e91719251db" + integrity sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w== + +"@babel/helper-validator-option@^7.24.8": + version "7.24.8" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.24.8.tgz#3725cdeea8b480e86d34df15304806a06975e33d" + integrity sha512-xb8t9tD1MHLungh/AIoWYN+gVHaB9kwlu8gffXGSt3FFEIT7RjS+xWbc2vUD1UTZdIpKj/ab3rdqJ7ufngyi2Q== + +"@babel/helpers@^7.25.0": + version "7.25.0" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.25.0.tgz#e69beb7841cb93a6505531ede34f34e6a073650a" + integrity sha512-MjgLZ42aCm0oGjJj8CtSM3DB8NOOf8h2l7DCTePJs29u+v7yO/RBX9nShlKMgFnRks/Q4tBAe7Hxnov9VkGwLw== + dependencies: + "@babel/template" "^7.25.0" + "@babel/types" "^7.25.0" + "@babel/highlight@^7.10.4": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.10.4.tgz#7d1bdfd65753538fabe6c38596cdb76d9ac60143" @@ -23,11 +135,59 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.24.7": + version "7.24.7" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.24.7.tgz#a05ab1df134b286558aae0ed41e6c5f731bf409d" + integrity sha512-EStJpq4OuY8xYfhGVXngigBJRWxftKX9ksiGDnmlY3o7B/V7KIAc9X4oiK87uPJSc/vs5L869bem5fhZa8caZw== + dependencies: + "@babel/helper-validator-identifier" "^7.24.7" + chalk "^2.4.2" + js-tokens "^4.0.0" + picocolors "^1.0.0" + +"@babel/parser@^7.25.0", "@babel/parser@^7.25.3": + version "7.25.3" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.25.3.tgz#91fb126768d944966263f0657ab222a642b82065" + integrity sha512-iLTJKDbJ4hMvFPgQwwsVoxtHyWpKKPBrxkANrSYewDPaPpT5py5yeVkgPIJ7XYXhndxJpaA3PyALSXQ7u8e/Dw== + dependencies: + "@babel/types" "^7.25.2" + "@babel/standalone@^7.21.4": version "7.21.4" resolved "https://registry.yarnpkg.com/@babel/standalone/-/standalone-7.21.4.tgz#f1a7131775df87c526cc393c36d013acd2b3c609" integrity sha512-Rw4nGqH/iyVeYxARKcz7iGP+njkPsVqJ45TmXMONoGoxooWjXCAs+CUcLeAZdBGCLqgaPvHKCYvIaDT2Iq+KfA== +"@babel/template@^7.25.0": + version "7.25.0" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.25.0.tgz#e733dc3134b4fede528c15bc95e89cb98c52592a" + integrity sha512-aOOgh1/5XzKvg1jvVz7AVrx2piJ2XBi227DHmbY6y+bM9H2FlN+IfecYu4Xl0cNiiVejlsCri89LUsbj8vJD9Q== + dependencies: + "@babel/code-frame" "^7.24.7" + "@babel/parser" "^7.25.0" + "@babel/types" "^7.25.0" + +"@babel/traverse@^7.24.7", "@babel/traverse@^7.25.2": + version "7.25.3" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.25.3.tgz#f1b901951c83eda2f3e29450ce92743783373490" + integrity sha512-HefgyP1x754oGCsKmV5reSmtV7IXj/kpaE1XYY+D9G5PvKKoFfSbiS4M77MdjuwlZKDIKFCffq9rPU+H/s3ZdQ== + dependencies: + "@babel/code-frame" "^7.24.7" + "@babel/generator" "^7.25.0" + "@babel/parser" "^7.25.3" + "@babel/template" "^7.25.0" + "@babel/types" "^7.25.2" + debug "^4.3.1" + globals "^11.1.0" + +"@babel/types@^7.24.7", "@babel/types@^7.25.0", "@babel/types@^7.25.2": + version "7.25.2" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.25.2.tgz#55fb231f7dc958cd69ea141a4c2997e819646125" + integrity sha512-YTnYtra7W9e6/oAZEHj0bJehPRUlLH9/fbpT5LfB0NhQXyALCRkRs3zH9v07IYhkgpqX6Z78FnuccZr/l4Fs4Q== + dependencies: + "@babel/helper-string-parser" "^7.24.8" + "@babel/helper-validator-identifier" "^7.24.7" + to-fast-properties "^2.0.0" + "@ckeditor/ckeditor5-adapter-ckfinder@40.1.0": version "40.1.0" resolved "https://registry.yarnpkg.com/@ckeditor/ckeditor5-adapter-ckfinder/-/ckeditor5-adapter-ckfinder-40.1.0.tgz#430bed03c73f87735dfe395ba3a8f8e500fe15e8" @@ -353,6 +513,11 @@ resolved "https://registry.yarnpkg.com/@colors/colors/-/colors-1.5.0.tgz#bb504579c1cae923e6576a4f5da43d25f97bdbd9" integrity sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ== +"@discoveryjs/json-ext@^0.5.0": + version "0.5.7" + resolved "https://registry.yarnpkg.com/@discoveryjs/json-ext/-/json-ext-0.5.7.tgz#1d572bfbbe14b7704e0ba0f39b74815b84870d70" + integrity sha512-dBVuXR082gk3jsFp7Rd/JI4kytwGHecnCoTtXFb7DB6CNHp4rg5k1bhg0nWdLGLnOV71lmDzGQaLMy8iPLY0pw== + "@eonasdan/tempus-dominus@npm:@eonasdan/tempus-dominus#6.9.4": version "6.9.4" resolved "https://registry.yarnpkg.com/@eonasdan/tempus-dominus/-/tempus-dominus-6.9.4.tgz#cf3c9d223e38df2eaf18368927634bdd140c554f" @@ -409,6 +574,46 @@ resolved "https://registry.yarnpkg.com/@isaacs/string-locale-compare/-/string-locale-compare-1.1.0.tgz#291c227e93fd407a96ecd59879a35809120e432b" integrity sha512-SQ7Kzhh9+D+ZW9MA0zkYv3VXhIDNx+LzM6EJ+/65I3QY+enU6Itte7E5XX7EWrqLW2FN4n06GWzBnPoC3th2aQ== +"@jridgewell/gen-mapping@^0.3.5": + version "0.3.5" + resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz#dcce6aff74bdf6dad1a95802b69b04a2fcb1fb36" + integrity sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg== + dependencies: + "@jridgewell/set-array" "^1.2.1" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping" "^0.3.24" + +"@jridgewell/resolve-uri@^3.1.0": + version "3.1.2" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz#7a0ee601f60f99a20c7c7c5ff0c80388c1189bd6" + integrity sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw== + +"@jridgewell/set-array@^1.2.1": + version "1.2.1" + resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.2.1.tgz#558fb6472ed16a4c850b889530e6b36438c49280" + integrity sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A== + +"@jridgewell/source-map@^0.3.3": + version "0.3.6" + resolved "https://registry.yarnpkg.com/@jridgewell/source-map/-/source-map-0.3.6.tgz#9d71ca886e32502eb9362c9a74a46787c36df81a" + integrity sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ== + dependencies: + "@jridgewell/gen-mapping" "^0.3.5" + "@jridgewell/trace-mapping" "^0.3.25" + +"@jridgewell/sourcemap-codec@^1.4.10", "@jridgewell/sourcemap-codec@^1.4.14": + version "1.5.0" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz#3188bcb273a414b0d215fd22a58540b989b9409a" + integrity sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ== + +"@jridgewell/trace-mapping@^0.3.20", "@jridgewell/trace-mapping@^0.3.24", "@jridgewell/trace-mapping@^0.3.25": + version "0.3.25" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz#15f190e98895f3fc23276ee14bc76b675c2e50f0" + integrity sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ== + dependencies: + "@jridgewell/resolve-uri" "^3.1.0" + "@jridgewell/sourcemap-codec" "^1.4.14" + "@mapbox/corslite@0.0.7": version "0.0.7" resolved "https://registry.yarnpkg.com/@mapbox/corslite/-/corslite-0.0.7.tgz#29f5b6a188ba946e514bdf0b6401ed4fbe13a39e" @@ -778,6 +983,27 @@ "@types/node" "*" "@types/responselike" "*" +"@types/eslint-scope@^3.7.3": + version "3.7.7" + resolved "https://registry.yarnpkg.com/@types/eslint-scope/-/eslint-scope-3.7.7.tgz#3108bd5f18b0cdb277c867b3dd449c9ed7079ac5" + integrity sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg== + dependencies: + "@types/eslint" "*" + "@types/estree" "*" + +"@types/eslint@*": + version "9.6.0" + resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-9.6.0.tgz#51d4fe4d0316da9e9f2c80884f2c20ed5fb022ff" + integrity sha512-gi6WQJ7cHRgZxtkQEoyHMppPjq9Kxo5Tjn2prSKDSmZrCz8TZ3jSRCeTJm+WoM+oB0WG37bRqLzaaU3q7JypGg== + dependencies: + "@types/estree" "*" + "@types/json-schema" "*" + +"@types/estree@*", "@types/estree@^1.0.5": + version "1.0.5" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.5.tgz#a6ce3e556e00fd9895dd872dd172ad0d4bd687f4" + integrity sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw== + "@types/http-cache-semantics@*": version "4.0.1" resolved "https://registry.yarnpkg.com/@types/http-cache-semantics/-/http-cache-semantics-4.0.1.tgz#0ea7b61496902b95890dc4c3a116b60cb8dae812" @@ -788,6 +1014,11 @@ resolved "https://registry.yarnpkg.com/@types/json-buffer/-/json-buffer-3.0.0.tgz#85c1ff0f0948fc159810d4b5be35bf8c20875f64" integrity sha512-3YP80IxxFJB4b5tYC2SUPwkg0XQLiu0nWvhRgEatgjf+29IcWO9X1k8xRv5DGssJ/lCrjYTjQPcobJr2yWIVuQ== +"@types/json-schema@*", "@types/json-schema@^7.0.8", "@types/json-schema@^7.0.9": + version "7.0.15" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" + integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== + "@types/keyv@*": version "3.1.4" resolved "https://registry.yarnpkg.com/@types/keyv/-/keyv-3.1.4.tgz#3ccdb1c6751b0c7e52300bcdacd5bcbf8faa75b6" @@ -829,6 +1060,152 @@ resolved "https://registry.yarnpkg.com/@ungap/promise-all-settled/-/promise-all-settled-1.1.2.tgz#aa58042711d6e3275dd37dc597e5d31e8c290a44" integrity sha512-sL/cEvJWAnClXw0wHk85/2L0G6Sj8UB0Ctc1TEMbKSsmpRosqhwj9gWgFRZSrBr2f9tiXISwNhCPmlfqUqyb9Q== +"@webassemblyjs/ast@1.12.1", "@webassemblyjs/ast@^1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.12.1.tgz#bb16a0e8b1914f979f45864c23819cc3e3f0d4bb" + integrity sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg== + dependencies: + "@webassemblyjs/helper-numbers" "1.11.6" + "@webassemblyjs/helper-wasm-bytecode" "1.11.6" + +"@webassemblyjs/floating-point-hex-parser@1.11.6": + version "1.11.6" + resolved "https://registry.yarnpkg.com/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz#dacbcb95aff135c8260f77fa3b4c5fea600a6431" + integrity sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw== + +"@webassemblyjs/helper-api-error@1.11.6": + version "1.11.6" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz#6132f68c4acd59dcd141c44b18cbebbd9f2fa768" + integrity sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q== + +"@webassemblyjs/helper-buffer@1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz#6df20d272ea5439bf20ab3492b7fb70e9bfcb3f6" + integrity sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw== + +"@webassemblyjs/helper-numbers@1.11.6": + version "1.11.6" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz#cbce5e7e0c1bd32cf4905ae444ef64cea919f1b5" + integrity sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g== + dependencies: + "@webassemblyjs/floating-point-hex-parser" "1.11.6" + "@webassemblyjs/helper-api-error" "1.11.6" + "@xtuc/long" "4.2.2" + +"@webassemblyjs/helper-wasm-bytecode@1.11.6": + version "1.11.6" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz#bb2ebdb3b83aa26d9baad4c46d4315283acd51e9" + integrity sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA== + +"@webassemblyjs/helper-wasm-section@1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz#3da623233ae1a60409b509a52ade9bc22a37f7bf" + integrity sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g== + dependencies: + "@webassemblyjs/ast" "1.12.1" + "@webassemblyjs/helper-buffer" "1.12.1" + "@webassemblyjs/helper-wasm-bytecode" "1.11.6" + "@webassemblyjs/wasm-gen" "1.12.1" + +"@webassemblyjs/ieee754@1.11.6": + version "1.11.6" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz#bb665c91d0b14fffceb0e38298c329af043c6e3a" + integrity sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg== + dependencies: + "@xtuc/ieee754" "^1.2.0" + +"@webassemblyjs/leb128@1.11.6": + version "1.11.6" + resolved "https://registry.yarnpkg.com/@webassemblyjs/leb128/-/leb128-1.11.6.tgz#70e60e5e82f9ac81118bc25381a0b283893240d7" + integrity sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ== + dependencies: + "@xtuc/long" "4.2.2" + +"@webassemblyjs/utf8@1.11.6": + version "1.11.6" + resolved "https://registry.yarnpkg.com/@webassemblyjs/utf8/-/utf8-1.11.6.tgz#90f8bc34c561595fe156603be7253cdbcd0fab5a" + integrity sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA== + +"@webassemblyjs/wasm-edit@^1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz#9f9f3ff52a14c980939be0ef9d5df9ebc678ae3b" + integrity sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g== + dependencies: + "@webassemblyjs/ast" "1.12.1" + "@webassemblyjs/helper-buffer" "1.12.1" + "@webassemblyjs/helper-wasm-bytecode" "1.11.6" + "@webassemblyjs/helper-wasm-section" "1.12.1" + "@webassemblyjs/wasm-gen" "1.12.1" + "@webassemblyjs/wasm-opt" "1.12.1" + "@webassemblyjs/wasm-parser" "1.12.1" + "@webassemblyjs/wast-printer" "1.12.1" + +"@webassemblyjs/wasm-gen@1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz#a6520601da1b5700448273666a71ad0a45d78547" + integrity sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w== + dependencies: + "@webassemblyjs/ast" "1.12.1" + "@webassemblyjs/helper-wasm-bytecode" "1.11.6" + "@webassemblyjs/ieee754" "1.11.6" + "@webassemblyjs/leb128" "1.11.6" + "@webassemblyjs/utf8" "1.11.6" + +"@webassemblyjs/wasm-opt@1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz#9e6e81475dfcfb62dab574ac2dda38226c232bc5" + integrity sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg== + dependencies: + "@webassemblyjs/ast" "1.12.1" + "@webassemblyjs/helper-buffer" "1.12.1" + "@webassemblyjs/wasm-gen" "1.12.1" + "@webassemblyjs/wasm-parser" "1.12.1" + +"@webassemblyjs/wasm-parser@1.12.1", "@webassemblyjs/wasm-parser@^1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz#c47acb90e6f083391e3fa61d113650eea1e95937" + integrity sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ== + dependencies: + "@webassemblyjs/ast" "1.12.1" + "@webassemblyjs/helper-api-error" "1.11.6" + "@webassemblyjs/helper-wasm-bytecode" "1.11.6" + "@webassemblyjs/ieee754" "1.11.6" + "@webassemblyjs/leb128" "1.11.6" + "@webassemblyjs/utf8" "1.11.6" + +"@webassemblyjs/wast-printer@1.12.1": + version "1.12.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz#bcecf661d7d1abdaf989d8341a4833e33e2b31ac" + integrity sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA== + dependencies: + "@webassemblyjs/ast" "1.12.1" + "@xtuc/long" "4.2.2" + +"@webpack-cli/configtest@^2.1.1": + version "2.1.1" + resolved "https://registry.yarnpkg.com/@webpack-cli/configtest/-/configtest-2.1.1.tgz#3b2f852e91dac6e3b85fb2a314fb8bef46d94646" + integrity sha512-wy0mglZpDSiSS0XHrVR+BAdId2+yxPSoJW8fsna3ZpYSlufjvxnP4YbKTCBZnNIcGN4r6ZPXV55X4mYExOfLmw== + +"@webpack-cli/info@^2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@webpack-cli/info/-/info-2.0.2.tgz#cc3fbf22efeb88ff62310cf885c5b09f44ae0fdd" + integrity sha512-zLHQdI/Qs1UyT5UBdWNqsARasIA+AaF8t+4u2aS2nEpBQh2mWIVb8qAklq0eUENnC5mOItrIB4LiS9xMtph18A== + +"@webpack-cli/serve@^2.0.5": + version "2.0.5" + resolved "https://registry.yarnpkg.com/@webpack-cli/serve/-/serve-2.0.5.tgz#325db42395cd49fe6c14057f9a900e427df8810e" + integrity sha512-lqaoKnRYBdo1UgDX8uF24AfGMifWK19TxPmM5FHc2vAGxrJ/qtyUyFBWoY1tISZdelsQ5fBcOusifo5o5wSJxQ== + +"@xtuc/ieee754@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@xtuc/ieee754/-/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790" + integrity sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA== + +"@xtuc/long@4.2.2": + version "4.2.2" + resolved "https://registry.yarnpkg.com/@xtuc/long/-/long-4.2.2.tgz#d291c6a4e97989b5c61d9acf396ae4fe133a718d" + integrity sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ== + At.js@millerdev/At.js#master: version "1.5.3" resolved "https://codeload.github.com/millerdev/At.js/tar.gz/d1ed42f66d33cdf54b681cb026664d847ca0637d" @@ -859,6 +1236,11 @@ ace-builds@1.5.0: resolved "https://registry.yarnpkg.com/ace-builds/-/ace-builds-1.5.0.tgz#38ad4d6a6f7b50453533ee307c877a7133c33fb1" integrity sha512-1BtEfIhFl/VDNRS9R1m9F8Kmeh2uJ98CxTeBE0kBjJpv5S5N2buTVWtc1BGXL9AromN7ekBjaEBaUl+ZPn4ciA== +acorn-import-attributes@^1.9.5: + version "1.9.5" + resolved "https://registry.yarnpkg.com/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz#7eb1557b1ba05ef18b5ed0ec67591bfab04688ef" + integrity sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ== + acorn-jsx@^5.3.2: version "5.3.2" resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" @@ -869,6 +1251,11 @@ acorn@^8.7.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.1.tgz#0197122c843d1bf6d0a5e83220a788f278f63c30" integrity sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A== +acorn@^8.8.2: + version "8.12.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.12.1.tgz#71616bdccbe25e27a54439e0046e89ca76df2248" + integrity sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg== + agent-base@6: version "6.0.2" resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-6.0.2.tgz#49fff58577cfee3f37176feab4c22e00f86d7f77" @@ -891,7 +1278,26 @@ aggregate-error@^3.0.0: clean-stack "^2.0.0" indent-string "^4.0.0" -ajv@^6.10.0, ajv@^6.12.4: +ajv-formats@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/ajv-formats/-/ajv-formats-2.1.1.tgz#6e669400659eb74973bbf2e33327180a0996b520" + integrity sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA== + dependencies: + ajv "^8.0.0" + +ajv-keywords@^3.5.2: + version "3.5.2" + resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.5.2.tgz#31f29da5ab6e00d1c2d329acf7b5929614d5014d" + integrity sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ== + +ajv-keywords@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-5.1.0.tgz#69d4d385a4733cdbeab44964a1170a88f87f0e16" + integrity sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw== + dependencies: + fast-deep-equal "^3.1.3" + +ajv@^6.10.0, ajv@^6.12.4, ajv@^6.12.5: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== @@ -911,6 +1317,16 @@ ajv@^6.5.5: json-schema-traverse "^0.4.1" uri-js "^4.2.2" +ajv@^8.0.0, ajv@^8.9.0: + version "8.17.1" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-8.17.1.tgz#37d9a5c776af6bc92d7f4f9510eba4c0a60d11a6" + integrity sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g== + dependencies: + fast-deep-equal "^3.1.3" + fast-uri "^3.0.1" + json-schema-traverse "^1.0.0" + require-from-string "^2.0.2" + ansi-colors@4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-4.1.1.tgz#cbb9ae256bf750af1eab344f229aa27fe94ba348" @@ -1049,6 +1465,14 @@ aws4@^1.8.0: resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.10.0.tgz#a17b3a8ea811060e74d47d306122400ad4497ae2" integrity sha512-3YDiu347mtVtjpyV3u5kVqQLP242c06zwDOgpeRnybmXlYYsLbtTrUBUm8i8srONt+FWobl5aibnU1030PeeuA== +babel-loader@9.1.3: + version "9.1.3" + resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-9.1.3.tgz#3d0e01b4e69760cc694ee306fe16d358aa1c6f9a" + integrity sha512-xG3ST4DglodGf8qSwv0MdeWLhrDsw/32QMdTO5T1ZIp9gQur0HkCyFs7Awskr10JKXFXwpAhiCuYX5oGXnRGbw== + dependencies: + find-cache-dir "^4.0.0" + schema-utils "^4.0.0" + babel-plugin-transform-modules-requirejs-babel@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/babel-plugin-transform-modules-requirejs-babel/-/babel-plugin-transform-modules-requirejs-babel-0.1.0.tgz#492529fc07581897e0bdfdc0003165bd6fccf42c" @@ -1102,6 +1526,11 @@ bcrypt-pbkdf@^1.0.0: dependencies: tweetnacl "^0.14.3" +big.js@^5.2.2: + version "5.2.2" + resolved "https://registry.yarnpkg.com/big.js/-/big.js-5.2.2.tgz#65f0af382f578bcdc742bd9c281e9cb2d7768328" + integrity sha512-vyL2OymJxmarO8gxMr0mhChsO9QGwhynfuu4+MHTAW6czfq9humCB7rKpUjDd9YUiDPU4mzpyupFSvOClAwbmQ== + biginteger@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/biginteger/-/biginteger-1.0.3.tgz#111c682070b852d0677a1621fd33452aab674607" @@ -1198,6 +1627,16 @@ browser-stdout@1.3.1: resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60" integrity sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw== +browserslist@^4.21.10, browserslist@^4.23.1: + version "4.23.3" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.23.3.tgz#debb029d3c93ebc97ffbc8d9cbb03403e227c800" + integrity sha512-btwCFJVjI4YWDNfau8RhZ+B1Q/VLoUITrm3RlP6y1tYGWIOa+InuYiRGXUBXo8nA1qKmHMyLB/iVQg5TT4eFoA== + dependencies: + caniuse-lite "^1.0.30001646" + electron-to-chromium "^1.5.4" + node-releases "^2.0.18" + update-browserslist-db "^1.1.0" + buffer-crc32@~0.2.3: version "0.2.13" resolved "https://registry.yarnpkg.com/buffer-crc32/-/buffer-crc32-0.2.13.tgz#0d333e3f00eac50aa1454abd30ef8c2a5d9a7242" @@ -1305,6 +1744,11 @@ camelcase@^6.0.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.2.0.tgz#924af881c9d525ac9d87f40d964e5cea982a1809" integrity sha512-c7wVvbw3f37nuobQNtgsgG9POC9qMbNuMQmTCqZv23b6MIz0fcYpBiOlv9gEN/hdLdnZTDQhg6e9Dq5M1vKvfg== +caniuse-lite@^1.0.30001646: + version "1.0.30001651" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001651.tgz#52de59529e8b02b1aedcaaf5c05d9e23c0c28138" + integrity sha512-9Cf+Xv1jJNe1xPZLGuUXLNkE1BoDkqRqYyFJ9TDYSqhduqA4hu4oR9HluGoWYQC/aj8WHjsGVV+bwkh0+tegRg== + caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" @@ -1323,7 +1767,7 @@ chai@4.3.6: pathval "^1.1.1" type-detect "^4.0.5" -chalk@2.4.2, chalk@^2.0.0: +chalk@2.4.2, chalk@^2.0.0, chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== @@ -1375,6 +1819,11 @@ chownr@^2.0.0: resolved "https://registry.yarnpkg.com/chownr/-/chownr-2.0.0.tgz#15bfbe53d2eab4cf70f18a8cd68ebe5b3cb1dece" integrity sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ== +chrome-trace-event@^1.0.2: + version "1.0.4" + resolved "https://registry.yarnpkg.com/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz#05bffd7ff928465093314708c93bdfa9bd1f0f5b" + integrity sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ== + ci-info@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-4.0.0.tgz#65466f8b280fc019b9f50a5388115d17a63a44f2" @@ -1455,6 +1904,15 @@ cliui@^7.0.2: strip-ansi "^6.0.0" wrap-ansi "^7.0.0" +clone-deep@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/clone-deep/-/clone-deep-4.0.1.tgz#c19fd9bdbbf85942b4fd979c84dcf7d5f07c2387" + integrity sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ== + dependencies: + is-plain-object "^2.0.4" + kind-of "^6.0.2" + shallow-clone "^3.0.0" + clone-response@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/clone-response/-/clone-response-1.0.3.tgz#af2032aa47816399cf5f0a1d0db902f517abb8c3" @@ -1513,6 +1971,11 @@ color-support@^1.1.3: resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== +colorette@^2.0.14: + version "2.0.20" + resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.20.tgz#9eb793e6833067f7235902fcd3b09917a000a95a" + integrity sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w== + colors@1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/colors/-/colors-1.4.0.tgz#c50491479d4c1bdaed2c9ced32cf7c7dc2360f78" @@ -1538,7 +2001,7 @@ combined-stream@^1.0.6, combined-stream@^1.0.8, combined-stream@~1.0.6: dependencies: delayed-stream "~1.0.0" -commander@2: +commander@2, commander@^2.20.0: version "2.20.3" resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== @@ -1548,11 +2011,21 @@ commander@2.15.1: resolved "https://registry.yarnpkg.com/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" integrity sha512-VlfT9F3V0v+jr4yxPc5gg9s62/fIVWsd2Bk2iD435um1NlGMYdVCq+MjcXnhYq2icNOizHr1kK+5TI6H0Hy0ag== +commander@^10.0.1: + version "10.0.1" + resolved "https://registry.yarnpkg.com/commander/-/commander-10.0.1.tgz#881ee46b4f77d1c1dccc5823433aa39b022cbe06" + integrity sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug== + common-ancestor-path@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/common-ancestor-path/-/common-ancestor-path-1.0.1.tgz#4f7d2d1394d91b7abdf51871c62f71eadb0182a7" integrity sha512-L3sHRo1pXXEqX8VU28kfgUY+YGsk09hPqZiZmLacNib6XNTCM8ubYeT7ryXQw8asB1sKgcU5lkB7ONug08aB8w== +common-path-prefix@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/common-path-prefix/-/common-path-prefix-3.0.0.tgz#7d007a7e07c58c4b4d5f433131a19141b29f11e0" + integrity sha512-QE33hToZseCH3jS0qN96O/bSh3kaw/h+Tq7ngyY9eWDUnTlTNUyqfqvCXioLe5Na5jFsL78ra/wuBU4iuEgd4w== + compress-brotli@^1.3.8: version "1.3.8" resolved "https://registry.yarnpkg.com/compress-brotli/-/compress-brotli-1.3.8.tgz#0c0a60c97a989145314ec381e84e26682e7b38db" @@ -1586,6 +2059,11 @@ continuable-cache@^0.3.1: resolved "https://registry.yarnpkg.com/continuable-cache/-/continuable-cache-0.3.1.tgz#bd727a7faed77e71ff3985ac93351a912733ad0f" integrity sha1-vXJ6f67XfnH/OYWskzUakSczrQ8= +convert-source-map@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-2.0.0.tgz#4b560f649fc4e918dd0ab75cf4961e8bc882d82a" + integrity sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg== + core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" @@ -1598,7 +2076,7 @@ cross-fetch@3.1.5: dependencies: node-fetch "2.6.7" -cross-spawn@^7.0.0, cross-spawn@^7.0.2: +cross-spawn@^7.0.0, cross-spawn@^7.0.2, cross-spawn@^7.0.3: version "7.0.3" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" integrity sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w== @@ -1681,7 +2159,7 @@ dateformat@~3.0.3: resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-3.0.3.tgz#a6e37499a4d9a9cf85ef5872044d62901c9889ae" integrity sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q== -debug@3.1.0, debug@4, debug@4.3.3, debug@4.3.4, debug@^2.6.9, debug@^3.1.0, debug@^4.1.1, debug@^4.3.2, debug@^4.3.4: +debug@3.1.0, debug@4, debug@4.3.3, debug@4.3.4, debug@^2.6.9, debug@^3.1.0, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.4: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== @@ -1804,6 +2282,11 @@ ecc-jsbn@~0.1.1: jsbn "~0.1.0" safer-buffer "^2.1.0" +electron-to-chromium@^1.5.4: + version "1.5.12" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.12.tgz#ee31756eaa2e06f2aa606f170b7ad06dd402b4e4" + integrity sha512-tIhPkdlEoCL1Y+PToq3zRNehUaKp3wBX/sr7aclAWdIWjvqAe/Im/H0SiCM4c1Q8BLPHCdoJTol+ZblflydehA== + emoji-regex@^8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" @@ -1814,6 +2297,11 @@ emoji-regex@^9.2.2: resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-9.2.2.tgz#840c8803b0d8047f4ff0cf963176b32d4ef3ed72" integrity sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg== +emojis-list@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-3.0.0.tgz#5570662046ad29e2e916e71aae260abdff4f6a78" + integrity sha512-/kyM18EfinwXZbno9FyUGeFh87KC8HRQBQGildHZbEuRyWFOmv1U10o9BBp8XVZDVNNuQKyIGIu5ZYAAXJ0V2Q== + encoding@^0.1.13: version "0.1.13" resolved "https://registry.yarnpkg.com/encoding/-/encoding-0.1.13.tgz#56574afdd791f54a8e9b2785c0582a2d26210fa9" @@ -1828,16 +2316,34 @@ end-of-stream@^1.1.0, end-of-stream@^1.4.1: dependencies: once "^1.4.0" +enhanced-resolve@^5.17.0: + version "5.17.1" + resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz#67bfbbcc2f81d511be77d686a90267ef7f898a15" + integrity sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg== + dependencies: + graceful-fs "^4.2.4" + tapable "^2.2.0" + entities@~2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/entities/-/entities-2.1.0.tgz#992d3129cf7df6870b96c57858c249a120f8b8b5" integrity sha512-hCx1oky9PFrJ611mf0ifBLBRW8lUUVRlFolb5gWRfIELabBlbp9xZvrqZLZAs+NxFnbfQoeGd8wDkygjg7U85w== +entities@~3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/entities/-/entities-3.0.1.tgz#2b887ca62585e96db3903482d336c1006c3001d4" + integrity sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q== + env-paths@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/env-paths/-/env-paths-2.2.0.tgz#cdca557dc009152917d6166e2febe1f039685e43" integrity sha512-6u0VYSCo/OW6IoD5WCLLy9JUGARbamfSavcNXry/eu8aHVFei6CD3Sw+VGX5alea1i9pgPHW0mbu6Xj0uBh7gA== +envinfo@^7.7.3: + version "7.13.0" + resolved "https://registry.yarnpkg.com/envinfo/-/envinfo-7.13.0.tgz#81fbb81e5da35d74e814941aeab7c325a606fb31" + integrity sha512-cvcaMr7KqXVh4nyzGTVqTum+gAiL265x5jUWQIDLq//zOGbW+gSW/C+OWLleY/rs9Qole6AZLMXPbtIFQbqu+Q== + eonasdan-bootstrap-datetimepicker@4.17.49: version "4.17.49" resolved "https://registry.yarnpkg.com/eonasdan-bootstrap-datetimepicker/-/eonasdan-bootstrap-datetimepicker-4.17.49.tgz#5534ba581c1e7eb988dbf773e2fed8a7f48cc76a" @@ -1874,6 +2380,11 @@ error@^7.0.0: dependencies: string-template "~0.2.1" +es-module-lexer@^1.2.1: + version "1.5.4" + resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.5.4.tgz#a8efec3a3da991e60efa6b633a7cad6ab8d26b78" + integrity sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw== + es6-promise@^4.0.3: version "4.2.8" resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.8.tgz#4eb21594c972bc40553d276e510539143db53e0a" @@ -1884,6 +2395,11 @@ escalade@^3.1.1: resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== +escalade@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.2.tgz#54076e9ab29ea5bf3d8f1ed62acffbb88272df27" + integrity sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA== + escape-string-regexp@1.0.5, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" @@ -1894,6 +2410,14 @@ escape-string-regexp@4.0.0, escape-string-regexp@^4.0.0: resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== +eslint-scope@5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" + integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== + dependencies: + esrecurse "^4.3.0" + estraverse "^4.1.1" + eslint-scope@^7.1.1: version "7.1.1" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-7.1.1.tgz#fff34894c2f65e5226d3041ac480b4513a163642" @@ -1988,6 +2512,11 @@ esrecurse@^4.3.0: dependencies: estraverse "^5.2.0" +estraverse@^4.1.1: + version "4.3.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" + integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== + estraverse@^5.1.0, estraverse@^5.2.0: version "5.3.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" @@ -2008,7 +2537,7 @@ eventemitter3@^3.1.0: resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-3.1.2.tgz#2d3d48f9c346698fce83a85d7d664e98535df6e7" integrity sha512-tvtQIeLVHjDkJYnzf2dgVMxfuSGJeM/7UCG17TT4EumTfNtF+0nebF/4zWOIkCreAbtNqhGEboB6BWrwqNaw4Q== -events@^3.3.0: +events@^3.2.0, events@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/events/-/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== @@ -2030,6 +2559,13 @@ exponential-backoff@^3.1.1: resolved "https://registry.yarnpkg.com/exponential-backoff/-/exponential-backoff-3.1.1.tgz#64ac7526fe341ab18a39016cd22c787d01e00bf6" integrity sha512-dX7e/LHVJ6W3DE1MHWi9S1EYzDESENfLrYohG2G++ovZrYOkm4Knwa0mc1cn84xJOR4KEU0WSchhLbd0UklbHw== +exports-loader@5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/exports-loader/-/exports-loader-5.0.0.tgz#0e5c50baf8526237c0a2743116a3e3fa788d194f" + integrity sha512-W15EyyytBwd30yCCieTCqZSCUvU/o3etj2IUItSMjVQEzAf5xOQx8JL9iMo7ERnuAzIA6eapGSFWl7E9F+Wy9g== + dependencies: + source-map "^0.6.1" + extend@^3.0.2, extend@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" @@ -2081,7 +2617,12 @@ fast-levenshtein@2.0.6, fast-levenshtein@^2.0.6: resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= -fastest-levenshtein@^1.0.16: +fast-uri@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-3.0.1.tgz#cddd2eecfc83a71c1be2cc2ef2061331be8a7134" + integrity sha512-MWipKbbYiYI0UC7cl8m/i/IWTqfC8YXsqjzybjddLsFjStroQzsHXkc73JutMvBiXmOvapk+axIl79ig5t55Bw== + +fastest-levenshtein@^1.0.12, fastest-levenshtein@^1.0.16: version "1.0.16" resolved "https://registry.yarnpkg.com/fastest-levenshtein/-/fastest-levenshtein-1.0.16.tgz#210e61b6ff181de91ea9b3d1b84fdedd47e034e5" integrity sha512-eRnCtTTtGZFpQCwhJiUOuxPQWRXVKYDn0b2PeHfXL6/Zi53SLAzAHfVhVWK2AryC/WH05kGfxhFIPvTF0SXQzg== @@ -2119,6 +2660,14 @@ fill-range@^7.1.1: dependencies: to-regex-range "^5.0.1" +find-cache-dir@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-4.0.0.tgz#a30ee0448f81a3990708f6453633c733e2f6eec2" + integrity sha512-9ZonPT4ZAK4a+1pUPVPZJapbi7O5qbbJPdYw/NOQWZZbVLdDTYM3A4R9z/DpAM08IDaFGsvPgiGZ82WEwUDWjg== + dependencies: + common-path-prefix "^3.0.0" + pkg-dir "^7.0.0" + find-up@5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/find-up/-/find-up-5.0.0.tgz#4c92819ecb7083561e4f4a240a86be5198f536fc" @@ -2135,6 +2684,14 @@ find-up@^4.0.0, find-up@^4.1.0: locate-path "^5.0.0" path-exists "^4.0.0" +find-up@^6.3.0: + version "6.3.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-6.3.0.tgz#2abab3d3280b2dc7ac10199ef324c4e002c8c790" + integrity sha512-v2ZsoEuVHYy8ZIlYqwPe/39Cy+cFDzp4dXPaxNvkEuouymu+2Jbz0PxpKarJHYJTmv2HWT3O382qY8l4jMWthw== + dependencies: + locate-path "^7.1.0" + path-exists "^5.0.0" + findup-sync@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-4.0.0.tgz#956c9cdde804052b881b428512905c4a5f2cdef0" @@ -2279,6 +2836,11 @@ function-bind@^1.1.1: resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== +function-bind@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.2.tgz#2c02d864d97f3ea6c8830c464cbd11ab6eab7a1c" + integrity sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA== + functional-red-black-tree@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" @@ -2310,6 +2872,11 @@ gaze@^1.1.0: dependencies: globule "^1.0.0" +gensync@^1.0.0-beta.2: + version "1.0.0-beta.2" + resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" + integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== + geojson-flatten@^1.0.4: version "1.1.1" resolved "https://registry.yarnpkg.com/geojson-flatten/-/geojson-flatten-1.1.1.tgz#601aae07ba6406281ebca683573dcda69eba04c7" @@ -2367,6 +2934,11 @@ glob-parent@~5.1.2: dependencies: is-glob "^4.0.1" +glob-to-regexp@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz#c75297087c851b9a578bd217dd59a92f59fe546e" + integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw== + glob@7.1.2: version "7.1.2" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" @@ -2445,6 +3017,11 @@ global-prefix@^1.0.1: is-windows "^1.0.1" which "^1.2.14" +globals@^11.1.0: + version "11.12.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" + integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== + globals@^13.6.0, globals@^13.9.0: version "13.12.0" resolved "https://registry.yarnpkg.com/globals/-/globals-13.12.0.tgz#4d733760304230a0082ed96e21e5c565f898089e" @@ -2490,7 +3067,7 @@ graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9, graceful-fs@^4.2.6: resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.10.tgz#147d3a006da4ca3ce14728c7aefc287c367d7a6c" integrity sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA== -graceful-fs@^4.2.11: +graceful-fs@^4.2.11, graceful-fs@^4.2.4: version "4.2.11" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== @@ -2672,6 +3249,13 @@ hasha@^2.2.0: is-stream "^1.0.1" pinkie-promise "^2.0.0" +hasown@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.2.tgz#003eaf91be7adc372e84ec59dc37252cedb80003" + integrity sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ== + dependencies: + function-bind "^1.1.2" + hat@0.0.3: version "0.0.3" resolved "https://registry.yarnpkg.com/hat/-/hat-0.0.3.tgz#bb014a9e64b3788aed8005917413d4ff3d502d8a" @@ -2806,6 +3390,14 @@ import-fresh@^3.0.0, import-fresh@^3.2.1: parent-module "^1.0.0" resolve-from "^4.0.0" +import-local@^3.0.2: + version "3.2.0" + resolved "https://registry.yarnpkg.com/import-local/-/import-local-3.2.0.tgz#c3d5c745798c02a6f8b897726aba5100186ee260" + integrity sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA== + dependencies: + pkg-dir "^4.2.0" + resolve-cwd "^3.0.0" + imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" @@ -2852,6 +3444,11 @@ init-package-json@^6.0.0: validate-npm-package-license "^3.0.4" validate-npm-package-name "^5.0.0" +interpret@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/interpret/-/interpret-3.1.1.tgz#5be0ceed67ca79c6c4bc5cf0d7ee843dcea110c4" + integrity sha512-6xwYfHbajpoF0xLW+iwLkhwgvLoZDfjYfoFNu8ftMoXINzwuymNLd9u/KmwtdT2GbR+/Cz66otEGEVVUHX9QLQ== + interpret@~1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.1.0.tgz#7ed1b1410c6a0e0f78cf95d3b8440c63f78b8614" @@ -2904,6 +3501,13 @@ is-cidr@^5.0.3: dependencies: cidr-regex "4.0.3" +is-core-module@^2.13.0: + version "2.15.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.15.0.tgz#71c72ec5442ace7e76b306e9d48db361f22699ea" + integrity sha512-Dd+Lb2/zvk9SKy1TGCt1wFJFo/MWBPMX5x7KcvLajWTGuomczdQX61PvY5yK6SVACwpoexWo81IfFyoKY2QnTA== + dependencies: + hasown "^2.0.2" + is-core-module@^2.8.1: version "2.8.1" resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.8.1.tgz#f59fdfca701d5879d0a6b100a40aa1560ce27211" @@ -3045,6 +3649,15 @@ jackspeak@^2.3.5: optionalDependencies: "@pkgjs/parseargs" "^0.11.0" +jest-worker@^27.4.5: + version "27.5.1" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-27.5.1.tgz#8d146f0900e8973b106b6f73cc1e9a8cb86f8db0" + integrity sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg== + dependencies: + "@types/node" "*" + merge-stream "^2.0.0" + supports-color "^8.0.0" + jquery-color@2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/jquery-color/-/jquery-color-2.2.0.tgz#2596bb782b69d9368b7840e6b3fe1e70fdd821c3" @@ -3103,7 +3716,7 @@ jquery@3.5.1: resolved "https://registry.yarnpkg.com/jquery/-/jquery-3.5.1.tgz#d7b4d08e1bfdb86ad2f1a3d039ea17304717abb5" integrity sha512-XwIBPqcMn57FxfT+Go5pzySnm4KWkT1Tv7gjrpT1srtf8Weynl6R273VJ5GjkRb51IzMp5nbaPjJXMWeju2MKg== -"jquery@>= 1.7.1", jquery@>=1.10, jquery@>=1.7, jquery@>=1.7.2, jquery@>=1.8, "jquery@>=1.8.0 <4.0.0", jquery@>=1.9.0, jquery@^3.5.1: +"jquery@>= 1.7.1", jquery@>=1.10, jquery@>=1.7, jquery@>=1.7.2, jquery@>=1.8, "jquery@>=1.8.0 <4.0.0", jquery@^3.5.1: version "3.6.0" resolved "https://registry.yarnpkg.com/jquery/-/jquery-3.6.0.tgz#c72a09f15c1bdce142f49dbf1170bdf8adac2470" integrity sha512-JVzAR/AjBvVt2BmYhxRCSYysDsPcssdmTFnzyLEts9qNwmjmu4JTAMYubEfwVOSwpQ1I1sKKFcxhZCI2buerfw== @@ -3135,6 +3748,11 @@ jsdiff@components/jsdiff#~3.2.0: version "0.0.0" resolved "https://codeload.github.com/components/jsdiff/tar.gz/0abd2d3b90046f66e2d7d816a4d975cb1ad03b50" +jsesc@^2.5.1: + version "2.5.2" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" + integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== + json-buffer@3.0.1, json-buffer@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.1.tgz#9338802a30d3b6605fbe0613e094008ca8c05a13" @@ -3145,6 +3763,11 @@ json-parse-better-errors@^1.0.1: resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== +json-parse-even-better-errors@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" + integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== + json-parse-even-better-errors@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-3.0.1.tgz#02bb29fb5da90b5444581749c22cedd3597c6cb0" @@ -3155,6 +3778,11 @@ json-schema-traverse@^0.4.1: resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== +json-schema-traverse@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz#ae7bcb3656ab77a73ba5c49bf654f38e6b6860e2" + integrity sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug== + json-schema@0.2.3, json-schema@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.4.0.tgz#f7de4cf6efab838ebaeb3236474cbba5a1930ab5" @@ -3175,6 +3803,18 @@ json-stringify-safe@~5.0.1: resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= +json5@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.2.tgz#63d98d60f21b313b77c4d6da18bfa69d80e1d593" + integrity sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA== + dependencies: + minimist "^1.2.0" + +json5@^2.1.2, json5@^2.2.3: + version "2.2.3" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" + integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== + jsonfile@^2.1.0: version "2.4.0" resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-2.4.0.tgz#3736a2b428b87bbda0cc83b53fa3d633a35c2ae8" @@ -3429,11 +4069,41 @@ linkify-it@^3.0.1: dependencies: uc.micro "^1.0.1" +linkify-it@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/linkify-it/-/linkify-it-4.0.1.tgz#01f1d5e508190d06669982ba31a7d9f56a5751ec" + integrity sha512-C7bfi1UZmoj8+PQx22XyeXCuBlokoyWQL5pWSP+EI6nzRylyThouddufc2c1NDIcP9k5agmN9fLpA7VNJfIiqw== + dependencies: + uc.micro "^1.0.1" + livereload-js@^2.3.0: version "2.4.0" resolved "https://registry.yarnpkg.com/livereload-js/-/livereload-js-2.4.0.tgz#447c31cf1ea9ab52fc20db615c5ddf678f78009c" integrity sha512-XPQH8Z2GDP/Hwz2PCDrh2mth4yFejwA1OZ/81Ti3LgKyhDcEjsSsqFWZojHG0va/duGd+WyosY7eXLDoOyqcPw== +loader-runner@^4.2.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/loader-runner/-/loader-runner-4.3.0.tgz#c1b4a163b99f614830353b16755e7149ac2314e1" + integrity sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg== + +loader-utils@^1.0.0: + version "1.4.2" + resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.4.2.tgz#29a957f3a63973883eb684f10ffd3d151fec01a3" + integrity sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg== + dependencies: + big.js "^5.2.2" + emojis-list "^3.0.0" + json5 "^1.0.1" + +loader-utils@^2.0.0: + version "2.0.4" + resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-2.0.4.tgz#8b5cb38b5c34a9a018ee1fc0e6a066d1dfcc528c" + integrity sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw== + dependencies: + big.js "^5.2.2" + emojis-list "^3.0.0" + json5 "^2.1.2" + locate-path@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" @@ -3448,6 +4118,13 @@ locate-path@^6.0.0: dependencies: p-locate "^5.0.0" +locate-path@^7.1.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-7.2.0.tgz#69cb1779bd90b35ab1e771e1f2f89a202c2a8a8a" + integrity sha512-gvVijfZvn7R+2qyPX8mAuKcFGDf6Nc61GdvGafQsHL0sBIxfKzA+usWn4GFC/bk+QdwPUD4kWFJLhElipq+0VA== + dependencies: + p-locate "^6.0.0" + lodash-es@4.17.21: version "4.17.21" resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.21.tgz#43e626c46e6591b7750beb2b50117390c609e3ee" @@ -3503,6 +4180,13 @@ lru-cache@^10.0.1, "lru-cache@^9.1.1 || ^10.0.0": resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.2.0.tgz#0bd445ca57363465900f4d1f9bd8db343a4d95c3" integrity sha512-2bIM8x+VAf6JT4bKAljS1qUWgMsqZRPGJS6FSahIMPVvctcNhyVp7AJu7quxOW9jwkryBReKZY5tY5JYv2n/7Q== +lru-cache@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" + integrity sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w== + dependencies: + yallist "^3.0.2" + lru-cache@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" @@ -3589,6 +4273,17 @@ markdown-it@12.3.2, markdown-it@^12.3.2: mdurl "^1.0.1" uc.micro "^1.0.5" +markdown-it@^13.0.2: + version "13.0.2" + resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-13.0.2.tgz#1bc22e23379a6952e5d56217fbed881e0c94d536" + integrity sha512-FtwnEuuK+2yVU7goGn/MJ0WBZMM9ZPgU9spqlFs7/A/pDIUNSOQZhUgOqYCficIuR2QaFnrt8LHqBWsbTAoI5w== + dependencies: + argparse "^2.0.1" + entities "~3.0.1" + linkify-it "^4.0.1" + mdurl "^1.0.1" + uc.micro "^1.0.5" + mdurl@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/mdurl/-/mdurl-1.0.1.tgz#fe85b2ec75a59037f2adfec100fd6c601761152e" @@ -3620,6 +4315,11 @@ meow@^6.1.1: type-fest "^0.13.1" yargs-parser "^18.1.3" +merge-stream@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" + integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== + micromatch@^4.0.2: version "4.0.5" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" @@ -3633,6 +4333,11 @@ mime-db@1.44.0: resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.44.0.tgz#fa11c5eb0aca1334b4233cb4d52f10c5a6272f92" integrity sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg== +mime-db@1.52.0: + version "1.52.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" + integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== + mime-types@^2.1.12, mime-types@~2.1.19: version "2.1.27" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.27.tgz#47949f98e279ea53119f5722e0f34e529bec009f" @@ -3640,6 +4345,13 @@ mime-types@^2.1.12, mime-types@~2.1.19: dependencies: mime-db "1.44.0" +mime-types@^2.1.27: + version "2.1.35" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" + integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== + dependencies: + mime-db "1.52.0" + mime@^1.4.1: version "1.6.0" resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" @@ -3681,7 +4393,7 @@ minimist-options@^4.0.2: is-plain-obj "^1.1.0" kind-of "^6.0.3" -minimist@0.0.8, minimist@^1.2.5, minimist@^1.2.6: +minimist@0.0.8, minimist@^1.2.0, minimist@^1.2.5, minimist@^1.2.6: version "1.2.6" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== @@ -3777,6 +4489,13 @@ mkdirp@0.5.5, mkdirp@^0.5.0, mkdirp@^0.5.4: dependencies: minimist "^1.2.5" +mkdirp@0.5.6: + version "0.5.6" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.6.tgz#7def03d2432dcae4ba1d611445c48396062255f6" + integrity sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw== + dependencies: + minimist "^1.2.6" + mkdirp@^1.0.3, mkdirp@^1.0.4, mkdirp@~1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-1.0.4.tgz#3eb5ed62622756d79a5f0e2a221dfebad75c2f7e" @@ -3851,6 +4570,19 @@ modernizr@^3.12.0: requirejs "^2.3.6" yargs "^15.4.1" +modernizr@^3.7.1: + version "3.13.1" + resolved "https://registry.yarnpkg.com/modernizr/-/modernizr-3.13.1.tgz#0102882d91e7546b833a6b833677a9f1a4fd1eb5" + integrity sha512-jc7F04Wd8ngu+fNZYMdWmho6bdiNNnt01lAEF6WAGRay7haGzjWEj5wfBC/zNgv5BySJ+h29/ERMFX+zEcijvg== + dependencies: + doctrine "^3.0.0" + file "^0.2.2" + lodash "^4.17.21" + markdown-it "^13.0.2" + mkdirp "0.5.6" + requirejs "^2.3.7" + yargs "^15.4.1" + moment-timezone@^0.4.0, moment-timezone@^0.5.35: version "0.5.38" resolved "https://registry.yarnpkg.com/moment-timezone/-/moment-timezone-0.5.38.tgz#9674a5397b8be7c13de820fd387d8afa0f725aad" @@ -3915,6 +4647,11 @@ negotiator@^0.6.3: resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.3.tgz#58e323a72fedc0d6f9cd4d31fe49f51479590ccd" integrity sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg== +neo-async@^2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" + integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== + node-fetch@2.6.7: version "2.6.7" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad" @@ -3938,6 +4675,11 @@ node-gyp@^10.0.0, node-gyp@^10.0.1: tar "^6.1.2" which "^4.0.0" +node-releases@^2.0.18: + version "2.0.18" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.18.tgz#f010e8d35e2fe8d6b2944f03f70213ecedc4ca3f" + integrity sha512-d9VeXT4SJ7ZeOqGX6R5EM022wpL+eWPooLI+5UpWn2jCT1aosUQEhQP214x33Wkwx3JQMvIm+tIoVOdodFS40g== + nopt@^7.0.0, nopt@^7.2.0: version "7.2.0" resolved "https://registry.yarnpkg.com/nopt/-/nopt-7.2.0.tgz#067378c68116f602f552876194fd11f1292503d7" @@ -4275,6 +5017,13 @@ p-limit@^3.0.2: dependencies: yocto-queue "^0.1.0" +p-limit@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-4.0.0.tgz#914af6544ed32bfa54670b061cafcbd04984b644" + integrity sha512-5b0R4txpzjPWVw/cXXUResoD4hb6U/x9BH08L7nw+GN1sezDzPdxeRvpc9c433fZhBan/wusjbCsqwqm4EIBIQ== + dependencies: + yocto-queue "^1.0.0" + p-locate@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" @@ -4289,6 +5038,13 @@ p-locate@^5.0.0: dependencies: p-limit "^3.0.2" +p-locate@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-6.0.0.tgz#3da9a49d4934b901089dca3302fa65dc5a05c04f" + integrity sha512-wPrq66Llhl7/4AGC6I+cqxT07LhXvWL08LNXz1fENOw0Ap4sRZZ/gZpTTJ5jpurzzzfS2W/Ge9BY3LgLjCShcw== + dependencies: + p-limit "^4.0.0" + p-map@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/p-map/-/p-map-4.0.0.tgz#bb2f95a5eda2ec168ec9274e06a747c3e2904d2b" @@ -4375,6 +5131,11 @@ path-exists@^4.0.0: resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== +path-exists@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-5.0.0.tgz#a6aad9489200b21fab31e49cf09277e5116fb9e7" + integrity sha512-RjhtfwJOxzcFmNOi6ltcbcu4Iu+FL3zEj83dk4kAS+fVpTxXLO1b38RvJgT/0QwvV/L3aY9TAnyv0EOqW4GoMQ== + path-is-absolute@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" @@ -4447,6 +5208,11 @@ phantomjs-prebuilt@^2.1.3: request-progress "^2.0.1" which "^1.2.10" +picocolors@^1.0.0, picocolors@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.1.tgz#a8ad579b571952f0e5d25892de5445bcfe25aaa1" + integrity sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew== + picomatch@^2.0.4, picomatch@^2.2.1: version "2.3.0" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.0.tgz#f1f061de8f6a4bf022892e2d128234fb98302972" @@ -4469,13 +5235,20 @@ pinkie@^2.0.0: resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" integrity sha1-clVrgM+g1IqXToDnckjoDtT3+HA= -pkg-dir@4.2.0: +pkg-dir@4.2.0, pkg-dir@^4.2.0: version "4.2.0" resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-4.2.0.tgz#f099133df7ede422e81d1d8448270eeb3e4261f3" integrity sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ== dependencies: find-up "^4.0.0" +pkg-dir@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-7.0.0.tgz#8f0c08d6df4476756c5ff29b3282d0bab7517d11" + integrity sha512-Ie9z/WINcxxLp27BKOCHGde4ITq9UklYKDzVo1nhk5sqGEXU3FpkwP5GM2voTGJkGd9B3Otl+Q4uwSOeSUtOBA== + dependencies: + find-up "^6.3.0" + postcss-selector-parser@^6.0.10: version "6.0.11" resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.11.tgz#2e41dc39b7ad74046e1615185185cd0b17d0c8dc" @@ -4732,6 +5505,13 @@ rechoir@^0.7.0: dependencies: resolve "^1.9.0" +rechoir@^0.8.0: + version "0.8.0" + resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.8.0.tgz#49f866e0d32146142da3ad8f0eff352b3215ff22" + integrity sha512-/vxpCXddiX8NGfGO/mTafwjq4aFa/71pvamip0++IQk3zG8cbCj0fifNPrjjF1XMXUne91jL9OoxmdykoEtifQ== + dependencies: + resolve "^1.20.0" + redent@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/redent/-/redent-3.0.0.tgz#e557b7998316bb53c9f1f56fa626352c6963059f" @@ -4783,6 +5563,11 @@ require-directory@^2.1.1: resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= +require-from-string@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" + integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw== + require-main-filename@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" @@ -4793,7 +5578,7 @@ requirejs-babel7@^1.3.2: resolved "https://registry.yarnpkg.com/requirejs-babel7/-/requirejs-babel7-1.3.2.tgz#64ed7bb3911e5aeda4b8a755addf8d953d36c2b4" integrity sha512-6kV79aVK64oCy+46inv9F+xY5eE2LrBdZiX5F60+opFXoaXnIYSGh7UzAcoKDx6WTp7dJXGKcryme5RzxDEccw== -requirejs@2.3.7, requirejs@^2.3.6: +requirejs@2.3.7, requirejs@^2.3.6, requirejs@^2.3.7: version "2.3.7" resolved "https://registry.yarnpkg.com/requirejs/-/requirejs-2.3.7.tgz#0b22032e51a967900e0ae9f32762c23a87036bd0" integrity sha512-DouTG8T1WanGok6Qjg2SXuCMzszOo0eHeH9hDZ5Y4x8Je+9JB38HdTLT4/VA8OaUhBa0JPVHJ0pyBkM1z+pDsw== @@ -4808,6 +5593,13 @@ resolve-alpn@^1.0.0: resolved "https://registry.yarnpkg.com/resolve-alpn/-/resolve-alpn-1.2.1.tgz#b7adbdac3546aaaec20b45e7d8265927072726f9" integrity sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g== +resolve-cwd@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-3.0.0.tgz#0f0075f1bb2544766cf73ba6a6e2adfebcb13f2d" + integrity sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg== + dependencies: + resolve-from "^5.0.0" + resolve-dir@^1.0.0, resolve-dir@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-1.0.1.tgz#79a40644c362be82f26effe739c9bb5382046f43" @@ -4821,6 +5613,11 @@ resolve-from@^4.0.0: resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== +resolve-from@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" + integrity sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw== + resolve@^1.10.0: version "1.17.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.17.0.tgz#b25941b54968231cc2d1bb76a79cb7f2c0bf8444" @@ -4837,6 +5634,15 @@ resolve@^1.19.0, resolve@^1.9.0: path-parse "^1.0.7" supports-preserve-symlinks-flag "^1.0.0" +resolve@^1.20.0: + version "1.22.8" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.8.tgz#b6c87a9f2aa06dfab52e3d70ac8cde321fa5a48d" + integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== + dependencies: + is-core-module "^2.13.0" + path-parse "^1.0.7" + supports-preserve-symlinks-flag "^1.0.0" + responselike@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/responselike/-/responselike-2.0.1.tgz#9a0bc8fdc252f3fb1cca68b016591059ba1422bc" @@ -4893,6 +5699,25 @@ samsam@1.x, samsam@^1.1.3: resolved "https://registry.yarnpkg.com/samsam/-/samsam-1.3.0.tgz#8d1d9350e25622da30de3e44ba692b5221ab7c50" integrity sha512-1HwIYD/8UlOtFS3QO3w7ey+SdSDFE4HRNLZoZRYVQefrOY3l17epswImeB1ijgJFQJodIaHcwkp3r/myBjFVbg== +schema-utils@^3.0.0, schema-utils@^3.1.1, schema-utils@^3.2.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-3.3.0.tgz#f50a88877c3c01652a15b622ae9e9795df7a60fe" + integrity sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg== + dependencies: + "@types/json-schema" "^7.0.8" + ajv "^6.12.5" + ajv-keywords "^3.5.2" + +schema-utils@^4.0.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-4.2.0.tgz#70d7c93e153a273a805801882ebd3bff20d89c8b" + integrity sha512-L0jRsrPpjdckP3oPug3/VxNKt2trR8TcabrM6FOAAlvC/9Phcmm+cuAgTlxBqdBR1WJx7Naj9WHw+aOmheSVbw== + dependencies: + "@types/json-schema" "^7.0.9" + ajv "^8.9.0" + ajv-formats "^2.1.1" + ajv-keywords "^5.1.0" + select2@4.1.0-rc.0: version "4.1.0-rc.0" resolved "https://registry.yarnpkg.com/select2/-/select2-4.1.0-rc.0.tgz#ba3cd3901dda0155e1c0219ab41b74ba51ea22d8" @@ -4908,6 +5733,11 @@ select@^1.0.6: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== +semver@^6.3.1: + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== + semver@^7.0.0, semver@^7.1.1, semver@^7.3.5, semver@^7.3.7: version "7.5.4" resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" @@ -4929,6 +5759,13 @@ serialize-javascript@6.0.0: dependencies: randombytes "^2.1.0" +serialize-javascript@^6.0.1: + version "6.0.2" + resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-6.0.2.tgz#defa1e055c83bf6d59ea805d8da862254eb6a6c2" + integrity sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g== + dependencies: + randombytes "^2.1.0" + set-blocking@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" @@ -4942,6 +5779,13 @@ set-value@^4.0.1: is-plain-object "^2.0.4" is-primitive "^3.0.1" +shallow-clone@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/shallow-clone/-/shallow-clone-3.0.1.tgz#8f2981ad92531f55035b01fb230769a40e02efa3" + integrity sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA== + dependencies: + kind-of "^6.0.2" + shebang-command@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" @@ -5021,7 +5865,15 @@ socks@^2.7.1: ip-address "^9.0.5" smart-buffer "^4.2.0" -source-map@~0.6.0: +source-map-support@~0.5.20: + version "0.5.21" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" + integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== @@ -5089,21 +5941,20 @@ ssri@^10.0.0, ssri@^10.0.5: dependencies: minipass "^7.0.3" +string-replace-loader@3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/string-replace-loader/-/string-replace-loader-3.1.0.tgz#11ac6ee76bab80316a86af358ab773193dd57a4f" + integrity sha512-5AOMUZeX5HE/ylKDnEa/KKBqvlnFmRZudSOjVJHxhoJg9QYTwl1rECx7SLR8BBH7tfxb4Rp7EM2XVfQFxIhsbQ== + dependencies: + loader-utils "^2.0.0" + schema-utils "^3.0.0" + string-template@~0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/string-template/-/string-template-0.2.1.tgz#42932e598a352d01fc22ec3367d9d84eec6c9add" integrity sha1-QpMuWYo1LQH8IuwzZ9nYTuxsmt0= -"string-width-cjs@npm:string-width@^4.2.0": - version "4.2.3" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" - integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== - dependencies: - emoji-regex "^8.0.0" - is-fullwidth-code-point "^3.0.0" - strip-ansi "^6.0.1" - -"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.2.3: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -5149,7 +6000,7 @@ string_decoder@~1.1.1: dependencies: safe-buffer "~5.1.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1": +"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -5163,13 +6014,6 @@ strip-ansi@^6.0.0: dependencies: ansi-regex "^5.0.0" -strip-ansi@^6.0.1: - version "6.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" - integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== - dependencies: - ansi-regex "^5.0.1" - strip-ansi@^7.0.1, strip-ansi@^7.1.0: version "7.1.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45" @@ -5209,7 +6053,7 @@ supports-color@5.4.0: dependencies: has-flag "^3.0.0" -supports-color@8.1.1: +supports-color@8.1.1, supports-color@^8.0.0: version "8.1.1" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== @@ -5240,6 +6084,11 @@ supports-preserve-symlinks-flag@^1.0.0: resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== +tapable@^2.1.1, tapable@^2.2.0: + version "2.2.1" + resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.1.tgz#1967a73ef4060a82f12ab96af86d52fdb76eeca0" + integrity sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ== + tar-fs@2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/tar-fs/-/tar-fs-2.1.1.tgz#489a15ab85f1f0befabb370b7de4f9eb5cbe8784" @@ -5280,6 +6129,27 @@ temporary@^0.0.8: dependencies: package ">= 1.0.0 < 1.2.0" +terser-webpack-plugin@^5.3.10: + version "5.3.10" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz#904f4c9193c6fd2a03f693a2150c62a92f40d199" + integrity sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w== + dependencies: + "@jridgewell/trace-mapping" "^0.3.20" + jest-worker "^27.4.5" + schema-utils "^3.1.1" + serialize-javascript "^6.0.1" + terser "^5.26.0" + +terser@^5.26.0: + version "5.31.6" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.31.6.tgz#c63858a0f0703988d0266a82fcbf2d7ba76422b1" + integrity sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg== + dependencies: + "@jridgewell/source-map" "^0.3.3" + acorn "^8.8.2" + commander "^2.20.0" + source-map-support "~0.5.20" + text-encoding@0.6.4: version "0.6.4" resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" @@ -5322,6 +6192,11 @@ tiny-relative-date@^1.3.0: resolved "https://registry.yarnpkg.com/tiny-relative-date/-/tiny-relative-date-1.3.0.tgz#fa08aad501ed730f31cc043181d995c39a935e07" integrity sha512-MOQHpzllWxDCHHaDno30hhLfbouoYlOI8YlMNtvKe1zXbjEVhbcEovQxvZrPvtiYW630GQDoMMarCnjfyfHA+A== +to-fast-properties@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" + integrity sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog== + to-regex-range@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" @@ -5515,6 +6390,14 @@ universalify@^0.2.0: resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0" integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== +update-browserslist-db@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.1.0.tgz#7ca61c0d8650766090728046e416a8cde682859e" + integrity sha512-EdRAaAyk2cUE1wOf2DkEhzxqOQvFOoRJFNS6NeyJ01Gp2beMRpBAINjM2iDXE3KCuKhwnvHIQCJm6ThL2Z+HzQ== + dependencies: + escalade "^3.1.2" + picocolors "^1.0.1" + uri-js@^4.2.2: version "4.2.2" resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.2.2.tgz#94c540e1ff772956e2299507c010aea6c8838eb0" @@ -5591,6 +6474,14 @@ walk-up-path@^3.0.1: resolved "https://registry.yarnpkg.com/walk-up-path/-/walk-up-path-3.0.1.tgz#c8d78d5375b4966c717eb17ada73dbd41490e886" integrity sha512-9YlCL/ynK3CTlrSRrDxZvUauLzAswPCrsaCgilqFevUYpeEW0/3ScEjaa3kbW/T0ghhkEr7mv+fpjqn1Y1YuTA== +watchpack@^2.4.1: + version "2.4.2" + resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.2.tgz#2feeaed67412e7c33184e5a79ca738fbd38564da" + integrity sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw== + dependencies: + glob-to-regexp "^0.4.1" + graceful-fs "^4.1.2" + wcwidth@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/wcwidth/-/wcwidth-1.0.1.tgz#f0b0dcf915bc5ff1528afadb2c0e17b532da2fe8" @@ -5603,6 +6494,86 @@ webidl-conversions@^3.0.0: resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" integrity sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE= +webpack-cli@5.1.4: + version "5.1.4" + resolved "https://registry.yarnpkg.com/webpack-cli/-/webpack-cli-5.1.4.tgz#c8e046ba7eaae4911d7e71e2b25b776fcc35759b" + integrity sha512-pIDJHIEI9LR0yxHXQ+Qh95k2EvXpWzZ5l+d+jIo+RdSm9MiHfzazIxwwni/p7+x4eJZuvG1AJwgC4TNQ7NRgsg== + dependencies: + "@discoveryjs/json-ext" "^0.5.0" + "@webpack-cli/configtest" "^2.1.1" + "@webpack-cli/info" "^2.0.2" + "@webpack-cli/serve" "^2.0.5" + colorette "^2.0.14" + commander "^10.0.1" + cross-spawn "^7.0.3" + envinfo "^7.7.3" + fastest-levenshtein "^1.0.12" + import-local "^3.0.2" + interpret "^3.1.1" + rechoir "^0.8.0" + webpack-merge "^5.7.3" + +webpack-merge@6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/webpack-merge/-/webpack-merge-6.0.1.tgz#50c776868e080574725abc5869bd6e4ef0a16c6a" + integrity sha512-hXXvrjtx2PLYx4qruKl+kyRSLc52V+cCvMxRjmKwoA+CBbbF5GfIBtR6kCvl0fYGqTUPKB+1ktVmTHqMOzgCBg== + dependencies: + clone-deep "^4.0.1" + flat "^5.0.2" + wildcard "^2.0.1" + +webpack-merge@^5.7.3: + version "5.10.0" + resolved "https://registry.yarnpkg.com/webpack-merge/-/webpack-merge-5.10.0.tgz#a3ad5d773241e9c682803abf628d4cd62b8a4177" + integrity sha512-+4zXKdx7UnO+1jaN4l2lHVD+mFvnlZQP/6ljaJVb4SZiwIKeUnrT5l0gkT8z+n4hKpC+jpOv6O9R+gLtag7pSA== + dependencies: + clone-deep "^4.0.1" + flat "^5.0.2" + wildcard "^2.0.0" + +webpack-modernizr-loader@5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/webpack-modernizr-loader/-/webpack-modernizr-loader-5.0.0.tgz#6a7c07d3fac4b6e02964ee3be61819cf9ab811cc" + integrity sha512-D+FIZ03QtWNV536+cGp046qbJIcxPYEF0kGqP6YrM8Y1g6PqzXGdx8VYnK7VkfRuBdtqLL5rCerWYk1ncOSjJQ== + dependencies: + loader-utils "^1.0.0" + modernizr "^3.7.1" + +webpack-sources@^3.2.3: + version "3.2.3" + resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" + integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== + +webpack@5.93.0: + version "5.93.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.93.0.tgz#2e89ec7035579bdfba9760d26c63ac5c3462a5e5" + integrity sha512-Y0m5oEY1LRuwly578VqluorkXbvXKh7U3rLoQCEO04M97ScRr44afGVkI0FQFsXzysk5OgFAxjZAb9rsGQVihA== + dependencies: + "@types/eslint-scope" "^3.7.3" + "@types/estree" "^1.0.5" + "@webassemblyjs/ast" "^1.12.1" + "@webassemblyjs/wasm-edit" "^1.12.1" + "@webassemblyjs/wasm-parser" "^1.12.1" + acorn "^8.7.1" + acorn-import-attributes "^1.9.5" + browserslist "^4.21.10" + chrome-trace-event "^1.0.2" + enhanced-resolve "^5.17.0" + es-module-lexer "^1.2.1" + eslint-scope "5.1.1" + events "^3.2.0" + glob-to-regexp "^0.4.1" + graceful-fs "^4.2.11" + json-parse-even-better-errors "^2.3.1" + loader-runner "^4.2.0" + mime-types "^2.1.27" + neo-async "^2.6.2" + schema-utils "^3.2.0" + tapable "^2.1.1" + terser-webpack-plugin "^5.3.10" + watchpack "^2.4.1" + webpack-sources "^3.2.3" + websocket-driver@>=0.5.1: version "0.7.4" resolved "https://registry.yarnpkg.com/websocket-driver/-/websocket-driver-0.7.4.tgz#89ad5295bbf64b480abcba31e4953aca706f5760" @@ -5663,6 +6634,11 @@ wide-align@^1.1.5: dependencies: string-width "^1.0.2 || 2 || 3 || 4" +wildcard@^2.0.0, wildcard@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/wildcard/-/wildcard-2.0.1.tgz#5ab10d02487198954836b6349f74fff961e10f67" + integrity sha512-CC1bOL87PIWSBhDcTrdeLo6eGT7mCFtrg0uIJtqJUFyK+eJnzl8A1niH56uu7KMa5XFrtiV+AQuHO3n7DsHnLQ== + word-wrap@^1.2.3: version "1.2.5" resolved "https://registry.yarnpkg.com/@aashutoshrathi/word-wrap/-/word-wrap-1.2.5.tgz#383aeebd5c176c320d6364fb869669559bbdbac9" @@ -5673,7 +6649,8 @@ workerpool@6.2.0: resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.0.tgz#827d93c9ba23ee2019c3ffaff5c27fccea289e8b" integrity sha512-Rsk5qQHJ9eowMH28Jwhe8HEbmdYDX4lwoMWshiCXugjtHqMD9ZbiqSDLxcsfdqsETPzVUtX5s1Z5kStiIM6l4A== -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: + name wrap-ansi-cjs version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -5691,15 +6668,6 @@ wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" -wrap-ansi@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" - integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== - dependencies: - ansi-styles "^4.0.0" - string-width "^4.1.0" - strip-ansi "^6.0.0" - wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214" @@ -5748,6 +6716,11 @@ y18n@^5.0.5: resolved "https://registry.yarnpkg.com/y18n/-/y18n-5.0.8.tgz#7f4934d0f7ca8c56f95314939ddcd2dd91ce1d55" integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== +yallist@^3.0.2: + version "3.1.1" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" + integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== + yallist@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" @@ -5814,6 +6787,11 @@ yocto-queue@^0.1.0: resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== +yocto-queue@^1.0.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-1.1.1.tgz#fef65ce3ac9f8a32ceac5a634f74e17e5b232110" + integrity sha512-b4JR1PFR10y1mKjhHY9LaGo6tmrgjit7hxVIeAmyMw3jegXR4dhYqLaQF5zMXZxY7tLpMyJeLjr1C4rLmkVe8g== + zxcvbn@4.4.2: version "4.4.2" resolved "https://registry.yarnpkg.com/zxcvbn/-/zxcvbn-4.4.2.tgz#28ec17cf09743edcab056ddd8b1b06262cc73c30" From 1e3f92e3697a628c28b6d938e7461fc9e0cdb144 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 19:30:06 +0200 Subject: [PATCH 13/44] add EntryChunksPlugin for mapping entries to chunks so that all the appropriate cache chunk bundles are loaded for a given entry bundle --- .../templates/hqwebapp/partials/webpack.html | 4 +- .../hqwebapp/templatetags/hq_shared_tags.py | 31 +++++++++++++++ get_webpack_manifest.py | 21 ++++++++++ webpack/plugins.js | 38 +++++++++++++++++++ webpack/webpack.b3.common.js | 4 ++ webpack/webpack.common.js | 2 + 6 files changed, 99 insertions(+), 1 deletion(-) create mode 100644 get_webpack_manifest.py create mode 100644 webpack/plugins.js diff --git a/corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html b/corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html index fbb00679bb56..d57ef2e1b2e9 100644 --- a/corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html +++ b/corehq/apps/hqwebapp/templates/hqwebapp/partials/webpack.html @@ -5,5 +5,7 @@ window.USE_WEBPACK = {{ webpack_main|BOOL }}; console.log("Loaded webpack main module: {{ webpack_main }}"); - + {% for bundle_path in webpack_main|webpack_bundles %} + + {% endfor %} {% endif %} diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index 5f4ca634d12b..6720304d24be 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -1,4 +1,5 @@ import json +import warnings from collections import OrderedDict from datetime import datetime, timedelta @@ -744,6 +745,36 @@ def __repr__(self): return "" % (self.value,) +try: + from get_webpack_manifest import get_webpack_manifest + webpack_manifest = get_webpack_manifest() + webpack_manifest_b3 = get_webpack_manifest('webpack/manifest_b3.json') +except (ImportError, SyntaxError): + webpack_manifest = {} + webpack_manifest_b3 = {} + + +@register.filter +def webpack_bundles(entry_name): + from corehq.apps.hqwebapp.utils.bootstrap import get_bootstrap_version, BOOTSTRAP_5 + if get_bootstrap_version() == BOOTSTRAP_5: + bundles = webpack_manifest.get(entry_name, []) + webpack_folder = 'webpack' + else: + bundles = webpack_manifest_b3.get(entry_name, []) + webpack_folder = 'webpack_b3' + if not bundles: + warnings.warn(f"\x1b[33;20m" # yellow color + f"\n\n\nNo webpack manifest entry found for '{entry_name}'" + f"\nPage may have javascript errors!" + f"\nDid you forget to run `yarn dev`?\n\n" + f"\x1b[0m") + bundles = ["common.js", f"{entry_name}.js"] + return [ + f"{webpack_folder}/{bundle}" for bundle in bundles + ] + + @register.inclusion_tag('hqwebapp/basic_errors.html') def bootstrap_form_errors(form): return {'form': form} diff --git a/get_webpack_manifest.py b/get_webpack_manifest.py new file mode 100644 index 000000000000..385faa4cfd9d --- /dev/null +++ b/get_webpack_manifest.py @@ -0,0 +1,21 @@ +import json +import os +import warnings + + +def get_webpack_manifest(path=None): + manifest = {} + + if not path: + path = os.path.join('webpack/manifest.json') + if not os.path.exists(path): + warnings.warn("\x1b[33;20m" # yellow color + "\n\n\nNo webpack manifest found!" + "\nDid you run `yarn dev` or `yarn build`?\n\n" + "\x1b[0m") + return manifest + + with open(path, 'r', encoding='utf-8') as f: + manifest = json.load(f) + + return manifest diff --git a/webpack/plugins.js b/webpack/plugins.js new file mode 100644 index 000000000000..c6ed7bae5717 --- /dev/null +++ b/webpack/plugins.js @@ -0,0 +1,38 @@ +const path = require('path'); +const fs = require('fs'); + +class EntryChunksPlugin { + constructor(options = {}) { + this.options = options; + } + + apply(compiler) { + compiler.hooks.emit.tapAsync('EntryChunksPlugin', (compilation, callback) => { + const entrypoints = compilation.entrypoints; + const manifest = {}; + + entrypoints.forEach((entry, entryName) => { + manifest[entryName] = []; + + entry.chunks.forEach((chunk) => { + chunk.files.forEach((file) => { + if (file.endsWith('.js')) { + manifest[entryName].push(file); + } + }); + }); + }); + + fs.writeFileSync( + path.resolve(__dirname, this.options.filename || 'manifest.json'), + JSON.stringify(manifest, null, 2) + ); + + callback(); + }); + } +} + +module.exports = { + EntryChunksPlugin: EntryChunksPlugin, +}; diff --git a/webpack/webpack.b3.common.js b/webpack/webpack.b3.common.js index 73cc781fce6f..ee06f01d2a83 100644 --- a/webpack/webpack.b3.common.js +++ b/webpack/webpack.b3.common.js @@ -3,6 +3,7 @@ const commonDefault = require("./webpack.common"); const webpack = require('webpack'); const utils = require('./utils'); +const hqPlugins = require('./plugins'); // bootstrap 3 builds off of the default common config, // with some overrides specified below... @@ -14,6 +15,9 @@ module.exports = Object.assign({}, commonDefault, { '$': 'jquery', 'jQuery': 'jquery', // needed for bootstrap 3 to work }), + new hqPlugins.EntryChunksPlugin({ + filename: 'manifest_b3.json', + }), ], optimization: { diff --git a/webpack/webpack.common.js b/webpack/webpack.common.js index 65e66d2800b6..f5e297d7ee70 100644 --- a/webpack/webpack.common.js +++ b/webpack/webpack.common.js @@ -3,6 +3,7 @@ const path = require('path'); const webpack = require('webpack'); const utils = require('./utils'); +const hqPlugins = require('./plugins'); const aliases = { "jquery": "jquery/dist/jquery.min", @@ -81,6 +82,7 @@ module.exports = { new webpack.ProvidePlugin({ '$': 'jquery', }), + new hqPlugins.EntryChunksPlugin(), ], optimization: { From df1eebe14a9515fa00b635a66d04b89694e77874 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 19:35:17 +0200 Subject: [PATCH 14/44] add core requirement modules for bootstrap 3 and bootstrap 5 webpack entry modules --- .../apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js | 3 +++ .../apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js | 3 +++ webpack/webpack.common.js | 4 ++++ 3 files changed, 10 insertions(+) create mode 100644 corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js create mode 100644 corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js diff --git a/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js new file mode 100644 index 000000000000..563c70a248e3 --- /dev/null +++ b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js @@ -0,0 +1,3 @@ +// Core requirements for Bootstrap 3 Webpack Entry Modules +import 'hqwebapp/js/bootstrap3/common'; +import 'hqwebapp/js/bootstrap3/base_main'; diff --git a/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js new file mode 100644 index 000000000000..8fc12d17dfea --- /dev/null +++ b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js @@ -0,0 +1,3 @@ +// Core requirements for Bootstrap 5 Webpack Entry Modules +import 'hqwebapp/js/bootstrap5/common'; +import 'hqwebapp/js/bootstrap5/base_main'; diff --git a/webpack/webpack.common.js b/webpack/webpack.common.js index f5e297d7ee70..a1ee459c24ea 100644 --- a/webpack/webpack.common.js +++ b/webpack/webpack.common.js @@ -6,6 +6,10 @@ const utils = require('./utils'); const hqPlugins = require('./plugins'); const aliases = { + "commcarehq": path.resolve(utils.getStaticPathForApp('hqwebapp', 'js/bootstrap5/'), + 'commcarehq'), + "commcarehq_b3": path.resolve(utils.getStaticPathForApp('hqwebapp', 'js/bootstrap3/'), + 'commcarehq'), "jquery": "jquery/dist/jquery.min", // todo after completing requirejs migration, From 40c98294019ba3db7fac6eda90b2f2bcd4dab6d2 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 19:37:40 +0200 Subject: [PATCH 15/44] update error catching for configurable_report --- .../userreports/static/userreports/js/configurable_report.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/corehq/apps/userreports/static/userreports/js/configurable_report.js b/corehq/apps/userreports/static/userreports/js/configurable_report.js index 847365b6f6ec..d586f854816d 100644 --- a/corehq/apps/userreports/static/userreports/js/configurable_report.js +++ b/corehq/apps/userreports/static/userreports/js/configurable_report.js @@ -1,8 +1,9 @@ hqDefine("userreports/js/configurable_report", function () { var initialPageData = hqImport("hqwebapp/js/initial_page_data"); - if (typeof define === 'function' && define.amd || window.USE_REQUIREJS) { - throw new Error("This part of UCR is not yet migrated to RequireJS. Update the UCR logic in reports/js/standard_hq_report before removing this error."); + if (typeof define === 'function' && define.amd || (window.USE_REQUIREJS || window.USE_WEBPACK)) { + throw new Error("This part of UCR is not yet migrated to a Javascript Bundler (preferably Webpack). " + + "Update the UCR logic in reports/js/standard_hq_report before removing this error."); } var getStandardHQReport = function (isFirstLoad) { From 271e16aaa61c992bc8be0c14738b4d6e09502cc1 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 20:30:01 +0200 Subject: [PATCH 16/44] update webpack common modules to mirror setup with requirejs --- .../hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js | 8 ++++++++ .../hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js index 563c70a248e3..483ebb98d2dc 100644 --- a/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js +++ b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap3/commcarehq.js @@ -1,3 +1,11 @@ // Core requirements for Bootstrap 3 Webpack Entry Modules +import ko from 'knockout'; +import mapping from 'ko.mapping'; +ko.mapping = mapping; + +import 'bootstrap'; + +import 'hqwebapp/js/django'; + import 'hqwebapp/js/bootstrap3/common'; import 'hqwebapp/js/bootstrap3/base_main'; diff --git a/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js index 8fc12d17dfea..4b704dfbae12 100644 --- a/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js +++ b/corehq/apps/hqwebapp/static/hqwebapp/js/bootstrap5/commcarehq.js @@ -1,3 +1,11 @@ // Core requirements for Bootstrap 5 Webpack Entry Modules +import ko from 'knockout'; +import mapping from 'ko.mapping'; +ko.mapping = mapping; + +import 'bootstrap5'; + +import 'hqwebapp/js/django'; + import 'hqwebapp/js/bootstrap5/common'; import 'hqwebapp/js/bootstrap5/base_main'; From 8e8bda597139f3b11b067415a468f8e01d97bbe8 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 20:30:34 +0200 Subject: [PATCH 17/44] always ensure analytix is included as part of build --- webpack/generateDetails.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js index 2c176187aa61..92365b4078f3 100644 --- a/webpack/generateDetails.js +++ b/webpack/generateDetails.js @@ -72,12 +72,14 @@ if (require.main === module) { // guarantee that these aliases are always generated const aliases = { + 'analytix/js': path.join(allAppPaths.analytix, 'static/analytix/js'), 'hqwebapp/js': path.join(allAppPaths.hqwebapp, 'static/hqwebapp/js'), 'notifications/js': path.join(allAppPaths.notifications, 'static/notifications/js'), }; // guarantee that these apps are always included const appsWithEntries = [ + "analytix", "hqwebapp", "notifications", ]; From 1b3add1ecb683722f0df3463f9e4417c15ee0f8e Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 20:31:42 +0200 Subject: [PATCH 18/44] add page for testing loading of a AMD-formatted bootstrap 5 module --- .../prototype/js/webpack/bootstrap5_amd.js | 44 +++++++++++++++++++ .../prototype/webpack/bootstrap5_amd.html | 21 +++++++++ corehq/apps/prototype/urls.py | 3 ++ corehq/apps/prototype/views/webpack.py | 12 +++++ 4 files changed, 80 insertions(+) create mode 100644 corehq/apps/prototype/static/prototype/js/webpack/bootstrap5_amd.js create mode 100644 corehq/apps/prototype/templates/prototype/webpack/bootstrap5_amd.html create mode 100644 corehq/apps/prototype/views/webpack.py diff --git a/corehq/apps/prototype/static/prototype/js/webpack/bootstrap5_amd.js b/corehq/apps/prototype/static/prototype/js/webpack/bootstrap5_amd.js new file mode 100644 index 000000000000..94d9bb13e1f3 --- /dev/null +++ b/corehq/apps/prototype/static/prototype/js/webpack/bootstrap5_amd.js @@ -0,0 +1,44 @@ +'use strict'; + +hqDefine("prototype/js/webpack/bootstrap5_amd",[ + 'jquery', + 'knockout', + 'underscore', + 'hqwebapp/js/initial_page_data', + "commcarehq", // IMPORTANT :: this has to be included with any Bootstrap 5 entry point +], function ($, ko, _, initialPageData) { + /** + * This is an (HQ)AMD-formatted module, intended to be used with webpack_main as follows: + * {% webpack_main "prototype/js/webpack/bootstrap5_amd" %} + * + * It serves as a test to see that Webpack is working fine with this type of module + * and is an example of what a quick migration of an existing requirejs module might + * look like. + * + * The most important difference between a requirejs module and a webpack module of this type + * is that the webpack module requires that the "commcarehq" dependency is included + * in the list of dependencies above. Otherwise, everything else should function + * identically to the requirejs module, provided the appropriate shims are in place + * in the Webpack config for special dependencies. + * + * For details on creating new shims, see: https://webpack.js.org/loaders/exports-loader/ + * + * This file can be used to test such shims, webpack optimizations, or to carry out + * preliminary Webpack-related tests in production environments. + * + */ + console.log("\n\nBelow are some basic tests to see that this Webpack module is working as expected:\n\n"); + console.log("\nDid jQuery load?"); + console.log($); + console.log("\nDid knockout load?"); + console.log(ko); + console.log("\nDid underscore load?"); + console.log(_); + console.log("\nIs initialPageData retrievable?"); + console.log(initialPageData.get('test_initial')); + console.log("\nAre translations working?"); + console.log(gettext("yes")); + console.log("\nIs bootstrap 5 working?"); + console.log("click around the page and see that dropdowns work..."); + console.log("\n\n"); +}); diff --git a/corehq/apps/prototype/templates/prototype/webpack/bootstrap5_amd.html b/corehq/apps/prototype/templates/prototype/webpack/bootstrap5_amd.html new file mode 100644 index 000000000000..4249b62a90a3 --- /dev/null +++ b/corehq/apps/prototype/templates/prototype/webpack/bootstrap5_amd.html @@ -0,0 +1,21 @@ +{% extends 'hqwebapp/bootstrap5/base_navigation.html' %} +{% load i18n %} +{% load hq_shared_tags %} + +{% webpack_main "prototype/js/webpack/bootstrap5_amd" %} + +{% block content %} + {% initial_page_data 'test_initial' 'successfully retrieved initial page data' %} +
+

+ Testing an (HQ)AMD-formatted module loaded with Webpack +

+
+ FYI: This page uses Bootstrap 5. +
+

+ Please open the js console for troubleshooting and see + "prototype/js/webpack/bootstrap5_amd.js" for additional information. +

+
+{% endblock content %} diff --git a/corehq/apps/prototype/urls.py b/corehq/apps/prototype/urls.py index bd71d3f6710e..19447092e5c8 100644 --- a/corehq/apps/prototype/urls.py +++ b/corehq/apps/prototype/urls.py @@ -1,7 +1,10 @@ from django.urls import re_path as url from corehq.apps.prototype.views import example +from corehq.apps.prototype.views import webpack urlpatterns = [ + url(r'^webpack/b5_amd/$', webpack.bootstrap5_amd_example, + name='webpack_bootstrap5_amd_example'), url(r'^example/$', example.knockout_pagination, name='prototype_example_knockout_pagination'), url(r'^example/data/$', example.example_paginated_data, diff --git a/corehq/apps/prototype/views/webpack.py b/corehq/apps/prototype/views/webpack.py new file mode 100644 index 000000000000..4853bac06912 --- /dev/null +++ b/corehq/apps/prototype/views/webpack.py @@ -0,0 +1,12 @@ +from django.contrib.auth.decorators import login_required +from django.shortcuts import render + +from corehq import toggles +from corehq.apps.hqwebapp.decorators import use_bootstrap5 + + +@login_required +@use_bootstrap5 +@toggles.SAAS_PROTOTYPE.required_decorator() +def bootstrap5_amd_example(request): + return render(request, 'prototype/webpack/bootstrap5_amd.html', {}) From 9ab97c8291af2fa5f4db5b43ea18920d9a1d38e9 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 20:43:01 +0200 Subject: [PATCH 19/44] add page for testing loading of an AMD-formatted bootstrap 3 module --- .../prototype/js/webpack/bootstrap3_amd.js | 44 +++++++++++++++++++ .../prototype/webpack/bootstrap3_amd.html | 21 +++++++++ corehq/apps/prototype/urls.py | 2 + corehq/apps/prototype/views/webpack.py | 6 +++ 4 files changed, 73 insertions(+) create mode 100644 corehq/apps/prototype/static/prototype/js/webpack/bootstrap3_amd.js create mode 100644 corehq/apps/prototype/templates/prototype/webpack/bootstrap3_amd.html diff --git a/corehq/apps/prototype/static/prototype/js/webpack/bootstrap3_amd.js b/corehq/apps/prototype/static/prototype/js/webpack/bootstrap3_amd.js new file mode 100644 index 000000000000..6448b2041a5c --- /dev/null +++ b/corehq/apps/prototype/static/prototype/js/webpack/bootstrap3_amd.js @@ -0,0 +1,44 @@ +'use strict'; + +hqDefine("prototype/js/webpack/bootstrap3_amd",[ + 'jquery', + 'knockout', + 'underscore', + 'hqwebapp/js/initial_page_data', + "commcarehq_b3", // IMPORTANT :: this has to be included with any Bootstrap 3 entry point +], function ($, ko, _, initialPageData) { + /** + * This is an (HQ)AMD-formatted module, intended to be used with webpack_main as follows: + * {% webpack_main_b3 "prototype/js/webpack/bootstrap3_amd" %} + * + * It serves as a test to see that Webpack is working fine with this type of module + * and is an example of what a quick migration of an existing requirejs module might + * look like. + * + * The most important difference between a requirejs module and a webpack module of this type + * is that the webpack module requires that the "commcarehq_b3" dependency is included + * in the list of dependencies above. Otherwise, everything else should function + * identically to the requirejs module, provided the appropriate shims are in place + * in the Webpack config for special dependencies. + * + * For details on creating new shims, see: https://webpack.js.org/loaders/exports-loader/ + * + * This file can be used to test such shims, webpack optimizations, or to carry out + * preliminary Webpack-related tests in production environments. + * + */ + console.log("\n\nBelow are some basic tests to see that this Webpack module is working as expected:\n\n"); + console.log("\nDid jQuery load?"); + console.log($); + console.log("\nDid knockout load?"); + console.log(ko); + console.log("\nDid underscore load?"); + console.log(_); + console.log("\nIs initialPageData retrievable?"); + console.log(initialPageData.get('test_initial')); + console.log("\nAre translations working?"); + console.log(gettext("yes")); + console.log("\nIs bootstrap 5 working?"); + console.log("click around the page and see that dropdowns work..."); + console.log("\n\n"); +}); diff --git a/corehq/apps/prototype/templates/prototype/webpack/bootstrap3_amd.html b/corehq/apps/prototype/templates/prototype/webpack/bootstrap3_amd.html new file mode 100644 index 000000000000..d67c0b1bb133 --- /dev/null +++ b/corehq/apps/prototype/templates/prototype/webpack/bootstrap3_amd.html @@ -0,0 +1,21 @@ +{% extends 'hqwebapp/bootstrap3/base_navigation.html' %} +{% load i18n %} +{% load hq_shared_tags %} + +{% webpack_main_b3 "prototype/js/webpack/bootstrap3_amd" %} + +{% block content %} + {% initial_page_data 'test_initial' 'successfully retrieved initial page data' %} +
+

+ Testing an (HQ)AMD-formatted module loaded with Webpack +

+
+ FYI: This page uses Bootstrap 3. +
+

+ Please open the js console for troubleshooting and see + "prototype/js/webpack/bootstrap3_amd.js" for additional information. +

+
+{% endblock content %} diff --git a/corehq/apps/prototype/urls.py b/corehq/apps/prototype/urls.py index 19447092e5c8..c703e8c6c0de 100644 --- a/corehq/apps/prototype/urls.py +++ b/corehq/apps/prototype/urls.py @@ -5,6 +5,8 @@ urlpatterns = [ url(r'^webpack/b5_amd/$', webpack.bootstrap5_amd_example, name='webpack_bootstrap5_amd_example'), + url(r'^webpack/b3_amd/$', webpack.bootstrap3_amd_example, + name='webpack_bootstrap3_amd_example'), url(r'^example/$', example.knockout_pagination, name='prototype_example_knockout_pagination'), url(r'^example/data/$', example.example_paginated_data, diff --git a/corehq/apps/prototype/views/webpack.py b/corehq/apps/prototype/views/webpack.py index 4853bac06912..c6baf6b5d3b5 100644 --- a/corehq/apps/prototype/views/webpack.py +++ b/corehq/apps/prototype/views/webpack.py @@ -10,3 +10,9 @@ @toggles.SAAS_PROTOTYPE.required_decorator() def bootstrap5_amd_example(request): return render(request, 'prototype/webpack/bootstrap5_amd.html', {}) + + +@login_required +@toggles.SAAS_PROTOTYPE.required_decorator() +def bootstrap3_amd_example(request): + return render(request, 'prototype/webpack/bootstrap3_amd.html', {}) From cd81f562f282a69fe01e80988e4c130e822bc806 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 20:55:00 +0200 Subject: [PATCH 20/44] more complex example of a webpack module, illustrating es6 module syntax --- .../js/webpack/knockout_pagination.js | 65 +++++++++++++++++++ .../webpack/knockout_pagination.html | 49 ++++++++++++++ corehq/apps/prototype/urls.py | 2 + corehq/apps/prototype/views/webpack.py | 7 ++ 4 files changed, 123 insertions(+) create mode 100644 corehq/apps/prototype/static/prototype/js/webpack/knockout_pagination.js create mode 100644 corehq/apps/prototype/templates/prototype/webpack/knockout_pagination.html diff --git a/corehq/apps/prototype/static/prototype/js/webpack/knockout_pagination.js b/corehq/apps/prototype/static/prototype/js/webpack/knockout_pagination.js new file mode 100644 index 000000000000..5caae346efe2 --- /dev/null +++ b/corehq/apps/prototype/static/prototype/js/webpack/knockout_pagination.js @@ -0,0 +1,65 @@ +import 'commcarehq'; // IMPORTANT :: always include at beginning of any entry module + +import ko from 'knockout'; +import $ from 'jquery'; +import _ from 'underscore'; +import initialPageData from 'hqwebapp/js/initial_page_data'; + +import 'hqwebapp/js/bootstrap5/components.ko'; // for knockout pagination widget + +// The rest of the code below is otherwise the same as the core content of +// prototype/js/knockout_pagination +// ...only the imports have changed + +$(function () { + let rowData = function (data) { + let self = {}; + self.columns = ko.observableArray(data); + return self; + }; + + let exampleModel = function () { + let self = {}; + self.rows = ko.observableArray(); + + self.perPage = ko.observable(); + self.totalItems = ko.observable(); + self.itemsPerPage = ko.observable(); + + self.error = ko.observable(); + + self.goToPage = function (page) { + $.ajax({ + method: 'POST', + url: initialPageData.reverse("prototype_example_paginated_data"), + data: { + page: page, + limit: self.itemsPerPage(), + }, + success: function (data) { + self.totalItems(data.total); + self.rows.removeAll(); + _.each(data.rows, function (row) { + self.rows.push(new rowData(row)); + }); + self.error(null); + }, + error: function () { + self.error(gettext("Could not load data. " + + "Please try again later or report an issue if " + + "this problem persists.")); + }, + }); + }; + + + // Initialize with first page of data + self.onPaginationLoad = function () { + self.goToPage(1); + }; + + return self; + }; + + $('#prototype-example-knockout-pagination').koApplyBindings(new exampleModel()); +}); diff --git a/corehq/apps/prototype/templates/prototype/webpack/knockout_pagination.html b/corehq/apps/prototype/templates/prototype/webpack/knockout_pagination.html new file mode 100644 index 000000000000..6a95ab9326e9 --- /dev/null +++ b/corehq/apps/prototype/templates/prototype/webpack/knockout_pagination.html @@ -0,0 +1,49 @@ +{% extends 'hqwebapp/bootstrap5/base_navigation.html' %} +{% load i18n %} +{% load hq_shared_tags %} + +{% webpack_main "prototype/js/webpack/knockout_pagination" %} + +{% block content %} +{% registerurl "prototype_example_paginated_data" %} +

+ Prototype Example (Webpack) +

+

+ This is an example endpoint for a rapid prototype working with tabular data and knockout. +

+
+ This also serves as a more concrete example of migrating an AMD module to webpack and + updating the module to use es6 module syntax. +
+ +
+ + + + + + + + + + + + + + + + + + + + +
NameColorBig CatsDate of BirthApplicationOpened On
+ +
+{% endblock content %} diff --git a/corehq/apps/prototype/urls.py b/corehq/apps/prototype/urls.py index c703e8c6c0de..cead084a85c4 100644 --- a/corehq/apps/prototype/urls.py +++ b/corehq/apps/prototype/urls.py @@ -7,6 +7,8 @@ name='webpack_bootstrap5_amd_example'), url(r'^webpack/b3_amd/$', webpack.bootstrap3_amd_example, name='webpack_bootstrap3_amd_example'), + url(r'^webpack/pagination/$', webpack.knockout_pagination, + name='webpack_knockout_pagination'), url(r'^example/$', example.knockout_pagination, name='prototype_example_knockout_pagination'), url(r'^example/data/$', example.example_paginated_data, diff --git a/corehq/apps/prototype/views/webpack.py b/corehq/apps/prototype/views/webpack.py index c6baf6b5d3b5..86d25e4c71ef 100644 --- a/corehq/apps/prototype/views/webpack.py +++ b/corehq/apps/prototype/views/webpack.py @@ -16,3 +16,10 @@ def bootstrap5_amd_example(request): @toggles.SAAS_PROTOTYPE.required_decorator() def bootstrap3_amd_example(request): return render(request, 'prototype/webpack/bootstrap3_amd.html', {}) + + +@login_required +@use_bootstrap5 +@toggles.SAAS_PROTOTYPE.required_decorator() +def knockout_pagination(request): + return render(request, 'prototype/webpack/knockout_pagination.html', {}) From 44155f4e1f181960e53f57395537df5b3a551996 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 20:59:48 +0200 Subject: [PATCH 21/44] update warning hints for misloaded bundles --- corehq/apps/hqwebapp/templatetags/hq_shared_tags.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index 6720304d24be..1cd77a7773d1 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -767,7 +767,7 @@ def webpack_bundles(entry_name): warnings.warn(f"\x1b[33;20m" # yellow color f"\n\n\nNo webpack manifest entry found for '{entry_name}'" f"\nPage may have javascript errors!" - f"\nDid you forget to run `yarn dev`?\n\n" + f"\nDid you try restarting `yarn dev` and `runserver`?\n\n" f"\x1b[0m") bundles = ["common.js", f"{entry_name}.js"] return [ From b92456b34aaa781dc6676d53393312101a8b72a8 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 21:00:24 +0200 Subject: [PATCH 22/44] add extra hint for misloaded bootstrap3 webpack bundles --- corehq/apps/hqwebapp/templatetags/hq_shared_tags.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index 1cd77a7773d1..15195c24e809 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -756,8 +756,9 @@ def __repr__(self): @register.filter def webpack_bundles(entry_name): - from corehq.apps.hqwebapp.utils.bootstrap import get_bootstrap_version, BOOTSTRAP_5 - if get_bootstrap_version() == BOOTSTRAP_5: + from corehq.apps.hqwebapp.utils.bootstrap import get_bootstrap_version, BOOTSTRAP_5, BOOTSTRAP_3 + bootstrap_version = get_bootstrap_version() + if bootstrap_version == BOOTSTRAP_5: bundles = webpack_manifest.get(entry_name, []) webpack_folder = 'webpack' else: @@ -769,7 +770,12 @@ def webpack_bundles(entry_name): f"\nPage may have javascript errors!" f"\nDid you try restarting `yarn dev` and `runserver`?\n\n" f"\x1b[0m") - bundles = ["common.js", f"{entry_name}.js"] + if bootstrap_version == BOOTSTRAP_3: + warnings.warn("\x1b[33;20m" # yellow color + "Additionally, did you remember to use `webpack_main_b3` " + "for this Bootstrap 3 module?\n\n" + "\x1b[0m") + bundles = [f"{entry_name}.js"] return [ f"{webpack_folder}/{bundle}" for bundle in bundles ] From d2bcf23d84454bc06717ecb5005ed33e8388e56f Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 21:34:59 +0200 Subject: [PATCH 23/44] don't show warnings during unit testing --- corehq/apps/hqwebapp/templatetags/hq_shared_tags.py | 13 +++++++------ get_webpack_manifest.py | 10 ++++++---- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index 15195c24e809..16f623c3f02f 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -765,12 +765,13 @@ def webpack_bundles(entry_name): bundles = webpack_manifest_b3.get(entry_name, []) webpack_folder = 'webpack_b3' if not bundles: - warnings.warn(f"\x1b[33;20m" # yellow color - f"\n\n\nNo webpack manifest entry found for '{entry_name}'" - f"\nPage may have javascript errors!" - f"\nDid you try restarting `yarn dev` and `runserver`?\n\n" - f"\x1b[0m") - if bootstrap_version == BOOTSTRAP_3: + if not settings.UNIT_TESTING: + warnings.warn(f"\x1b[33;20m" # yellow color + f"\n\n\nNo webpack manifest entry found for '{entry_name}'" + f"\nPage may have javascript errors!" + f"\nDid you try restarting `yarn dev` and `runserver`?\n\n" + f"\x1b[0m") + if bootstrap_version == BOOTSTRAP_3 and not settings.UNIT_TESTING: warnings.warn("\x1b[33;20m" # yellow color "Additionally, did you remember to use `webpack_main_b3` " "for this Bootstrap 3 module?\n\n" diff --git a/get_webpack_manifest.py b/get_webpack_manifest.py index 385faa4cfd9d..1e57af60111f 100644 --- a/get_webpack_manifest.py +++ b/get_webpack_manifest.py @@ -1,6 +1,7 @@ import json import os import warnings +from django.conf import settings def get_webpack_manifest(path=None): @@ -9,10 +10,11 @@ def get_webpack_manifest(path=None): if not path: path = os.path.join('webpack/manifest.json') if not os.path.exists(path): - warnings.warn("\x1b[33;20m" # yellow color - "\n\n\nNo webpack manifest found!" - "\nDid you run `yarn dev` or `yarn build`?\n\n" - "\x1b[0m") + if not settings.UNIT_TESTING: + warnings.warn("\x1b[33;20m" # yellow color + "\n\n\nNo webpack manifest found!" + "\nDid you run `yarn dev` or `yarn build`?\n\n" + "\x1b[0m") return manifest with open(path, 'r', encoding='utf-8') as f: From af5983f31e0b38ba301f845ef1243ede92f9f6b4 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 21:35:13 +0200 Subject: [PATCH 24/44] add yarn build to js tests --- docker/run.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/docker/run.sh b/docker/run.sh index b0b9cebcad54..0a4c24a0a9f2 100755 --- a/docker/run.sh +++ b/docker/run.sh @@ -212,6 +212,7 @@ function _run_tests { function _test_javascript { SKIP_GEVENT_PATCHING=1 ./manage.py migrate --noinput + yarn build ./manage.py runserver 0.0.0.0:8000 &> commcare-hq.log & _wait_for_runserver logmsg INFO "grunt test ${js_test_args[*]}" From 816e30bae493ec5e8cf22ac1d4acc1fde81aaaf2 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Tue, 20 Aug 2024 21:40:02 +0200 Subject: [PATCH 25/44] fix typo in filename --- ...genereate_webpack_settings.py => generate_webpack_settings.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename corehq/apps/hqwebapp/management/commands/{genereate_webpack_settings.py => generate_webpack_settings.py} (100%) diff --git a/corehq/apps/hqwebapp/management/commands/genereate_webpack_settings.py b/corehq/apps/hqwebapp/management/commands/generate_webpack_settings.py similarity index 100% rename from corehq/apps/hqwebapp/management/commands/genereate_webpack_settings.py rename to corehq/apps/hqwebapp/management/commands/generate_webpack_settings.py From 3bb5bbc25194d74e93191e231bb86fe5d9745ca6 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:20:36 +0200 Subject: [PATCH 26/44] update eslint to allow es6 and node globals & config --- .eslintrc.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.eslintrc.js b/.eslintrc.js index 835f951d9750..6ae0b5680f2f 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -7,6 +7,7 @@ module.exports = { // https://eslint.org/docs/4.0.0/user-guide/configuring#specifying-parser-options "parserOptions": { "ecmaVersion": 6, + "sourceType": "module", }, // http://eslint.org/docs/user-guide/configuring#specifying-environments @@ -37,6 +38,10 @@ module.exports = { "beforeEach": false, "nv": false, "d3": false, + "require": false, + "module": false, + "__dirname": false, + "process": false, }, // http://eslint.org/docs/rules/ From 2ec2941e80d33458e16d7c44784019d10ec832ec Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:21:11 +0200 Subject: [PATCH 27/44] don't throw warning unless in debug mode (and not in unit testing mode) --- corehq/apps/hqwebapp/templatetags/hq_shared_tags.py | 4 ++-- get_webpack_manifest.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index 16f623c3f02f..06bda0a979ec 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -765,13 +765,13 @@ def webpack_bundles(entry_name): bundles = webpack_manifest_b3.get(entry_name, []) webpack_folder = 'webpack_b3' if not bundles: - if not settings.UNIT_TESTING: + if not settings.UNIT_TESTING and settings.DEBUG: warnings.warn(f"\x1b[33;20m" # yellow color f"\n\n\nNo webpack manifest entry found for '{entry_name}'" f"\nPage may have javascript errors!" f"\nDid you try restarting `yarn dev` and `runserver`?\n\n" f"\x1b[0m") - if bootstrap_version == BOOTSTRAP_3 and not settings.UNIT_TESTING: + if bootstrap_version == BOOTSTRAP_3 and not settings.UNIT_TESTING and settings.DEBUG: warnings.warn("\x1b[33;20m" # yellow color "Additionally, did you remember to use `webpack_main_b3` " "for this Bootstrap 3 module?\n\n" diff --git a/get_webpack_manifest.py b/get_webpack_manifest.py index 1e57af60111f..7dca466a6581 100644 --- a/get_webpack_manifest.py +++ b/get_webpack_manifest.py @@ -10,7 +10,7 @@ def get_webpack_manifest(path=None): if not path: path = os.path.join('webpack/manifest.json') if not os.path.exists(path): - if not settings.UNIT_TESTING: + if not settings.UNIT_TESTING and settings.DEBUG: warnings.warn("\x1b[33;20m" # yellow color "\n\n\nNo webpack manifest found!" "\nDid you run `yarn dev` or `yarn build`?\n\n" From 1d0f50835074082637fa396c44cbe926c9018840 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:22:43 +0200 Subject: [PATCH 28/44] add docstrings --- webpack/appPaths.js | 5 +++ webpack/generateDetails.js | 37 ++++++++++++++++++++ webpack/plugins.js | 15 ++++++++ webpack/utils.js | 71 ++++++++++++++++++++++++++++++++++++++ 4 files changed, 128 insertions(+) diff --git a/webpack/appPaths.js b/webpack/appPaths.js index cef1388061c4..8897f9caa4a8 100644 --- a/webpack/appPaths.js +++ b/webpack/appPaths.js @@ -32,6 +32,11 @@ const appRenames = { }; const hasTemplateFolder = function (dirEnt) { + /** + * Returns `true` if `dirEnt` has a `templates` folder. + * + * @type {boolean} + */ const templatePath = path.resolve(APPS_PATH, dirEnt.name, TEMPLATES_DIR); try { return fs.readdirSync(templatePath); diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js index 92365b4078f3..24ad17fecb03 100644 --- a/webpack/generateDetails.js +++ b/webpack/generateDetails.js @@ -5,6 +5,30 @@ const path = require('path'); const appPaths = require('./appPaths'); const scanTemplates = function (dir, entryRegex, allAppPaths, details, isProdMode) { + /** + * This recursively scans all template files within a given directory, looking + * for a metch to the `entryRegex` specified above. The first group this entry regex + * (`match[1]`) should return the webpack entry name, eg `hqwebapp/js/some_page`. + * + * As they are discovered, entries are appended to the `details.entries` dictionary. + * Additionally, `details.aliases` is updated when an app alias is first found, + * eg `hqwebapp/js` (the first two folders in the entry name). + * Lastly, the (unique) application name is added to `details.appsWithEntries` + * + * @param dir - path to directory to begin scanning + * @param entryRegex - regex for identifying an entry in an .html page (see examples below) + * @param allAppPaths (dict) - keys are all the applications being scanned + * and values are paths to each application's folder + * @param details (dict) - the dictionary that will be modified by this function, formatted as follows: + * { + * entries: {}, + * aliases: {}, + * appsWithEntries: [], + * } + * @param isProdMode (boolean) - `true` if this should be run in production mode, the difference + * being that entry filenames end in `.[contenthash].js`, which is necessary for + * cache busting on production. + */ const files = fs.readdirSync(dir); files.forEach((file) => { @@ -48,6 +72,19 @@ const scanTemplates = function (dir, entryRegex, allAppPaths, details, isProdMod }; const getDetails = function (entryRegex, allAppPaths, isProdMode) { + /** + * Generates the details for a given `entryRegex`. + * + * @param entryRegex - regex for identifying an entry in an .html page (see examples below) + * @param allAppPaths (dict) - keys are all the applications being scanned for entries (all applications that + * have `template` folders). The values are paths to each application's root folder. + * eg. `"hqwebapp": "/path/to/corehq/apps/hqwebapp"` + * @param isProdMode (boolean) - `true` if this should be run in production mode, the difference + * being that entry filenames end in `.[contenthash].js`, which is necessary for + * cache busting on production. + * + * @type {{entries: {}, aliases: {}, appsWithEntries: []}} + */ const details = { entries: {}, aliases: {}, diff --git a/webpack/plugins.js b/webpack/plugins.js index c6ed7bae5717..dfcd6ca62a7f 100644 --- a/webpack/plugins.js +++ b/webpack/plugins.js @@ -2,6 +2,21 @@ const path = require('path'); const fs = require('fs'); class EntryChunksPlugin { + /** + * This custom plugin creates a json file (default manifest.json), which contains + * all the Webpack Entries (aka Modules) with a list of all the required Chunks + * needed to properly load that module without javascript errors. + * + * Chunks are generated based on Cache Group Chunks, which are chunked by modules + * and vendors (npm_modules), and contain the common code shared between multiple + * entry points that can be cached to improve subsequent page load performance. + * + * `get_webpack_manifest.py` in the root directory then ingests the manifest. + * The data used by the `webpack_modules` template tag in `hq_shared_tags` to return + * a list of modules to load in `hqwebapp/partials/webpack.html`. + * + * @param options (dict) — leave blank for default settings of specify filename + */ constructor(options = {}) { this.options = options; } diff --git a/webpack/utils.js b/webpack/utils.js index 2dd8643af624..2a22b284953d 100644 --- a/webpack/utils.js +++ b/webpack/utils.js @@ -16,14 +16,32 @@ const fetchJsonDataOrDefault = function (filePath, defaultData) { return fetchedData; }; +// Note: This is taken from `details.json`, which is generated by +// `node webpack/generateDetails.js`. This script is always run prior to the webpack +// build as part of `yarn dev` or `yarn build`. const DETAILS = fetchJsonDataOrDefault(DETAILS_FILE, {}); + +// Note: `settings.json` can be generated by `./manage.py generate_webpack_settings` +// if you have a custom `STATIC_ROOT` set in `localsettings.py`. Otherwise, the +// default configuration is fine. const SETTINGS = fetchJsonDataOrDefault(SETTINGS_FILE, { staticfilesPath: path.resolve(__BASE, 'staticfiles'), }); + const WEBPACK_PATH = path.join(SETTINGS.staticfilesPath, 'webpack'); const WEBPACK_B3_PATH = path.join(SETTINGS.staticfilesPath, 'webpack_b3'); const getStaticFolderForApp = function (appName) { + /** + * Returns the full path to an application's static folder. + * eg /path/to/corehq/apps/hqwebapp/static + * + * The full path for the application is obtained from `details.json`, + * which is generated by `node webpack/generateDetails.js`. This script is always + * run prior to the webpack build as part of `yarn dev` or `yarn build` + * + * @type {string} + */ const appPath = DETAILS.allAppPaths[appName]; if (!appPath) { console.warn(`No path found for ${appName}`); @@ -32,12 +50,43 @@ const getStaticFolderForApp = function (appName) { }; const getStaticPathForApp = function (appName, directory) { + /** + * A quick utility for generating full paths to directories within + * an app's static folder. + * + * Given an appName like `hqwebapp` and a directory like `hqwebapp/js`, + * this returns the full path to that static files directory + * /path/to/corehq/apps/hqwebapp/static/hqwebapp/js + * + * @type {string} + */ directory = directory || ""; const staticFolder = getStaticFolderForApp(appName); return path.resolve(staticFolder, appName, directory); }; const getEntries = function (otherEntry) { + /** + * Entries in Webpack are also referred to as "modules". These + * entries are determined by the `webpack_main` or `webpack_main_b3` template + * tags in `hq_shared_tags.py` + * + * For instance, {% webpack_main `hqwebapp/js/some_page` %} + * Where the entry then looks something like: + * ``` + * "hqwebapp/js/some_page": { + * import: '/path/to/corehq/apps/hqwebapp/static/hqwebapp/js/some_page.js', + * // the path of the output file that will live in `staticfiles/webpack` + * filename: 'hqwebapp/js/some_page.js`, + * } + * ``` + * + * The entries within `DETAILS` are taken from `details.json`, which is generated + * by `node webpack/generateDetails.js`. This script is always run prior to the webpack + * build as part of `yarn dev` or `yarn build` + * + * @type {{b3: {}}} + */ const otherEntries = { 'b3': DETAILS.b3Entries, }; @@ -49,6 +98,28 @@ const getAllAliases = function (aliases) { }; const getCacheGroups = function () { + /** + * Cache Groups are effectively parent "modules" containing shared code + * amongst the generated entries. There is a common chunk to contain the most widely + * shared code across the codebase, a vendor chunk which includes code from npm dependencies + * that changes less frequently than code within the codebase. Lastly, there are chunks + * for commonly shared code (if needed, based on size requirements) within each app. + * + * Cache Groups are "modules" of shared code across different entries that can be + * cached by the browser so the unique code for a particular entry point can be condensed. + * Subsequent loads of pages within HQ or pages within a particular app of HQ can rely + * on reading the cache of this common code rather than requesting an enormous entry + * point file each time. + * + * See Webpack's documentation to learn more about Code Splitting and Cache Groups: + * https://webpack.js.org/plugins/split-chunks-plugin/ + * + * `appsWithEntries` from `DETAILS` is taken from `details.json`, which is generated + * by `node webpack/generateDetails.js`. This script is always run prior to the webpack + * build as part of `yarn dev` or `yarn build`. + * + * @type {dict} - a dict of cache group definitions + */ const cacheGroups = { common: { name: 'common', From e96fe87c61edb61bdf0a6f749c96fff15d0915f5 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:23:30 +0200 Subject: [PATCH 29/44] fix test...requirjs_main is only present in context if actually called with a parameter --- corehq/apps/app_manager/tests/test_views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/corehq/apps/app_manager/tests/test_views.py b/corehq/apps/app_manager/tests/test_views.py index 559763fe9aef..e7a59cc97ce0 100644 --- a/corehq/apps/app_manager/tests/test_views.py +++ b/corehq/apps/app_manager/tests/test_views.py @@ -581,7 +581,7 @@ def test_view_form_legacy(self, mock1): 'nav_menu_media_specifics', 'user', 'TIME_ZONE', 'domain', 'module_brief', 'timezone', 'active_tab', 'data_registry_enabled', 'confirm', 'messages', 'releases_active', 'show_status_page', 'show_search_workflow', 'data_registries', 'label', 'underscore', 'forloop', 'show_shadow_modules', - 'requirejs_main', 'SUPPORT_EMAIL', 'valid_parents_for_child_module', 'parent_case_modules', + 'SUPPORT_EMAIL', 'valid_parents_for_child_module', 'parent_case_modules', 'current_url_name', 'LANGUAGE_BIDI', 'DEFAULT_MESSAGE_LEVELS', 'show_report_modules', 'BASE_MAIN', 'app_id', 'request', 'MINIMUM_PASSWORD_LENGTH', 'type', 'is_saas_environment', 'show_all_projects_link', 'enterprise_mode', 'csrf_token', 'WS4REDIS_HEARTBEAT', 'is_dimagi_environment', 'domain_names', From a1ceb03180a7688eee79726d3388dcef0d320da0 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:33:53 +0200 Subject: [PATCH 30/44] run command as cchq user to fix permissions issue writing to file --- docker/run.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/run.sh b/docker/run.sh index 0a4c24a0a9f2..ed65ce173534 100755 --- a/docker/run.sh +++ b/docker/run.sh @@ -212,7 +212,7 @@ function _run_tests { function _test_javascript { SKIP_GEVENT_PATCHING=1 ./manage.py migrate --noinput - yarn build + su cchq -c "yarn build" ./manage.py runserver 0.0.0.0:8000 &> commcare-hq.log & _wait_for_runserver logmsg INFO "grunt test ${js_test_args[*]}" From ed7c2fbf21c79bb91f09a9a3223e65b95daa7d12 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:34:25 +0200 Subject: [PATCH 31/44] update priority config with hqwebapp having a higher priority than other apps --- webpack/utils.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/webpack/utils.js b/webpack/utils.js index 2a22b284953d..155534b6c8da 100644 --- a/webpack/utils.js +++ b/webpack/utils.js @@ -125,13 +125,13 @@ const getCacheGroups = function () { name: 'common', chunks: 'all', minChunks: 2, - priority: 1, + priority: 2, // if two cache groups might share a module, prioritize loading into common }, vendor: { test: /[\\/]node_modules[\\/]/, name: 'vendor', chunks: 'all', - priority: 1, + priority: 2, }, }; @@ -142,7 +142,8 @@ const getCacheGroups = function () { name: `${appName}/${appName}.bundle`, chunks: 'all', minChunks: 1, - priority: 0, + // hqwebapp shares the highest priority among the modules + priority: (appName === 'hqwebapp') ? 1 : 0, }; }); return cacheGroups; From 2dfc80b15e4e9d16ed5d8b621ebe4f39107af40b Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 15:34:40 +0000 Subject: [PATCH 32/44] "Bootstrap 5 Migration - Rebuilt diffs" --- .../hqwebapp/js/commcarehq.js.diff.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 corehq/apps/hqwebapp/tests/data/bootstrap5_diffs/javascript/hqwebapp/js/commcarehq.js.diff.txt diff --git a/corehq/apps/hqwebapp/tests/data/bootstrap5_diffs/javascript/hqwebapp/js/commcarehq.js.diff.txt b/corehq/apps/hqwebapp/tests/data/bootstrap5_diffs/javascript/hqwebapp/js/commcarehq.js.diff.txt new file mode 100644 index 000000000000..546b935bda0a --- /dev/null +++ b/corehq/apps/hqwebapp/tests/data/bootstrap5_diffs/javascript/hqwebapp/js/commcarehq.js.diff.txt @@ -0,0 +1,18 @@ +--- ++++ +@@ -1,11 +1,11 @@ +-// Core requirements for Bootstrap 3 Webpack Entry Modules ++// Core requirements for Bootstrap 5 Webpack Entry Modules + import ko from 'knockout'; + import mapping from 'ko.mapping'; + ko.mapping = mapping; + +-import 'bootstrap'; ++import 'bootstrap5'; + + import 'hqwebapp/js/django'; + +-import 'hqwebapp/js/bootstrap3/common'; +-import 'hqwebapp/js/bootstrap3/base_main'; ++import 'hqwebapp/js/bootstrap5/common'; ++import 'hqwebapp/js/bootstrap5/base_main'; From 776ecf4b31ef49b8dc4a1236db50054aa3e29462 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:44:26 +0200 Subject: [PATCH 33/44] responding to lint warning ''use strict' is unnecessary inside of modules strict' --- webpack/appPaths.js | 2 -- webpack/generateDetails.js | 2 -- webpack/utils.js | 2 -- webpack/webpack.b3.common.js | 2 -- webpack/webpack.common.js | 2 -- webpack/webpack.dev.js | 2 -- webpack/webpack.prod.js | 2 -- 7 files changed, 14 deletions(-) diff --git a/webpack/appPaths.js b/webpack/appPaths.js index 8897f9caa4a8..0062119cb295 100644 --- a/webpack/appPaths.js +++ b/webpack/appPaths.js @@ -1,5 +1,3 @@ -'use strict'; - const fs = require('fs'); const path = require('path'); diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js index 24ad17fecb03..22a25cb4a8ff 100644 --- a/webpack/generateDetails.js +++ b/webpack/generateDetails.js @@ -1,5 +1,3 @@ -'use strict'; - const fs = require('fs'); const path = require('path'); const appPaths = require('./appPaths'); diff --git a/webpack/utils.js b/webpack/utils.js index 155534b6c8da..64a19b7ec406 100644 --- a/webpack/utils.js +++ b/webpack/utils.js @@ -1,5 +1,3 @@ -'use strict'; - const path = require("path"); const fs = require("fs"); diff --git a/webpack/webpack.b3.common.js b/webpack/webpack.b3.common.js index ee06f01d2a83..26bb8b0b331e 100644 --- a/webpack/webpack.b3.common.js +++ b/webpack/webpack.b3.common.js @@ -1,5 +1,3 @@ -'use strict'; - const commonDefault = require("./webpack.common"); const webpack = require('webpack'); const utils = require('./utils'); diff --git a/webpack/webpack.common.js b/webpack/webpack.common.js index a1ee459c24ea..b38050450004 100644 --- a/webpack/webpack.common.js +++ b/webpack/webpack.common.js @@ -1,5 +1,3 @@ -'use strict'; - const path = require('path'); const webpack = require('webpack'); const utils = require('./utils'); diff --git a/webpack/webpack.dev.js b/webpack/webpack.dev.js index b58f4156ae26..f7abafba8286 100644 --- a/webpack/webpack.dev.js +++ b/webpack/webpack.dev.js @@ -1,5 +1,3 @@ -'use strict'; - const { merge } = require('webpack-merge'); const common = require('./webpack.common'); const b3Common = require('./webpack.b3.common'); diff --git a/webpack/webpack.prod.js b/webpack/webpack.prod.js index 45f80a9f8fdb..e0f297f776a1 100644 --- a/webpack/webpack.prod.js +++ b/webpack/webpack.prod.js @@ -1,5 +1,3 @@ -'use strict'; - const { merge } = require('webpack-merge'); const common = require('./webpack.common'); const b3Common = require('./webpack.b3.common'); From 9bab56fa1839ebec22f7bb12e0f982ca61cdf230 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:46:05 +0200 Subject: [PATCH 34/44] respnding to lint error ''module' is already defined as a built-in global variable no-redeclare' --- .eslintrc.js | 1 - 1 file changed, 1 deletion(-) diff --git a/.eslintrc.js b/.eslintrc.js index 6ae0b5680f2f..e026842fe9df 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -39,7 +39,6 @@ module.exports = { "nv": false, "d3": false, "require": false, - "module": false, "__dirname": false, "process": false, }, From 2a0006b4c6b3a6a6864ca2344d4fbd1b7009191b Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:49:08 +0200 Subject: [PATCH 35/44] disable no-useless-escape linting and provide note --- webpack/generateDetails.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js index 22a25cb4a8ff..1ddb5e0622bf 100644 --- a/webpack/generateDetails.js +++ b/webpack/generateDetails.js @@ -1,3 +1,6 @@ +/* eslint-disable no-useless-escape */ +// NOTE: double escapes are needed for file path delimiters in webpack regexes for cross-platform support + const fs = require('fs'); const path = require('path'); const appPaths = require('./appPaths'); From 442fadad29cf01eb37ceac10ee0f8205fb014075 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:53:22 +0200 Subject: [PATCH 36/44] ignore webpack manifest warnings in docs build --- scripts/test-make-docs.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/test-make-docs.sh b/scripts/test-make-docs.sh index ab4c5384e737..8f7760febf5b 100644 --- a/scripts/test-make-docs.sh +++ b/scripts/test-make-docs.sh @@ -24,6 +24,7 @@ WHITELIST_PATTERNS=( '^\s*$' # ignore lines containing only whitespace 'logger is being changed to' # ignore error when FIX_LOGGER_ERROR_OBFUSCATION is true 'yacc table file version is out of date' # warning whenever building docs on a freshly created virtual environment + 'No webpack manifest found' # ignore webpack manifest warnings # Only whitelist docs build warnings/errors when absolutely necessary ) From 06d9fee4ce759a1e07415b89a97500e18a4707a0 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 17:55:49 +0200 Subject: [PATCH 37/44] remove requirejs_main from expected contexts, as requirejs is not being used and the tag was modified to not be inserted into context if it doesn't have a value --- corehq/apps/app_manager/tests/test_views.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/corehq/apps/app_manager/tests/test_views.py b/corehq/apps/app_manager/tests/test_views.py index e7a59cc97ce0..5b8c27b416ef 100644 --- a/corehq/apps/app_manager/tests/test_views.py +++ b/corehq/apps/app_manager/tests/test_views.py @@ -557,7 +557,7 @@ def test_view_form_legacy(self, mock1): 'WEBSOCKET_URI', 'selected_form', 'module', 'MINIMUM_PASSWORD_LENGTH', 'MINIMUM_ZXCVBN_SCORE', 'SUPPORT_EMAIL', 'app_view_options', 'show_advanced', 'role_version', 'custom_assertions', 'is_app_settings_page', 'domain_names', 'latest_version_for_build_profiles', 'ANALYTICS_CONFIG', - 'csrf_token', 'LANGUAGE_CODE', 'app_name', 'requirejs_main', 'sub', 'is_saas_environment', + 'csrf_token', 'LANGUAGE_CODE', 'app_name', 'sub', 'is_saas_environment', 'selected_module', 'add_ons_layout', 'is_dimagi_environment', 'TIME_ZONE', 'env', 'add_ons', 'show_shadow_forms', 'can_edit_apps', 'ANALYTICS_IDS', 'active_tab', 'current_url_name', 'show_release_mode', 'application_profile_url', 'linkable_domains', 'domain_links', @@ -607,7 +607,7 @@ def test_view_form_legacy(self, mock1): 'show_release_mode', 'linked_name', 'linked_version', 'latest_commcare_version', 'nav_menu_media_specifics', 'user', 'TIME_ZONE', 'domain', 'case_config_options', 'timezone', 'root_requires_same_case', 'active_tab', 'confirm', 'messages', 'releases_active', 'show_status_page', - 'form_filter_patterns', 'form_workflows', 'label', 'underscore', 'forloop', 'requirejs_main', + 'form_filter_patterns', 'form_workflows', 'label', 'underscore', 'forloop', 'SUPPORT_EMAIL', 'current_url_name', 'LANGUAGE_BIDI', 'DEFAULT_MESSAGE_LEVELS', 'show_report_modules', 'BASE_MAIN', 'xform_languages', 'app_id', 'request', 'allow_usercase', 'MINIMUM_PASSWORD_LENGTH', 'type', 'is_saas_environment', 'show_all_projects_link', 'enterprise_mode', 'module_is_multi_select', 'csrf_token', From e0b722c61e63b5878759d545282178ae374695e9 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 18:09:58 +0200 Subject: [PATCH 38/44] marking all webpack-related build files and utils as node eslint-env --- webpack/appPaths.js | 2 ++ webpack/generateDetails.js | 1 + webpack/plugins.js | 1 + webpack/utils.js | 1 + webpack/webpack.b3.common.js | 1 + webpack/webpack.common.js | 1 + webpack/webpack.dev.js | 1 + webpack/webpack.prod.js | 1 + 8 files changed, 9 insertions(+) diff --git a/webpack/appPaths.js b/webpack/appPaths.js index 0062119cb295..15671124fcc3 100644 --- a/webpack/appPaths.js +++ b/webpack/appPaths.js @@ -1,3 +1,5 @@ +/* eslint-env node */ + const fs = require('fs'); const path = require('path'); diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js index 1ddb5e0622bf..ae42344b4eee 100644 --- a/webpack/generateDetails.js +++ b/webpack/generateDetails.js @@ -1,3 +1,4 @@ +/* eslint-env node */ /* eslint-disable no-useless-escape */ // NOTE: double escapes are needed for file path delimiters in webpack regexes for cross-platform support diff --git a/webpack/plugins.js b/webpack/plugins.js index dfcd6ca62a7f..7291fdfa2d1d 100644 --- a/webpack/plugins.js +++ b/webpack/plugins.js @@ -1,3 +1,4 @@ +/* eslint-env node */ const path = require('path'); const fs = require('fs'); diff --git a/webpack/utils.js b/webpack/utils.js index 64a19b7ec406..50ed456a7e13 100644 --- a/webpack/utils.js +++ b/webpack/utils.js @@ -1,3 +1,4 @@ +/* eslint-env node */ const path = require("path"); const fs = require("fs"); diff --git a/webpack/webpack.b3.common.js b/webpack/webpack.b3.common.js index 26bb8b0b331e..d06dfb42f731 100644 --- a/webpack/webpack.b3.common.js +++ b/webpack/webpack.b3.common.js @@ -1,3 +1,4 @@ +/* eslint-env node */ const commonDefault = require("./webpack.common"); const webpack = require('webpack'); const utils = require('./utils'); diff --git a/webpack/webpack.common.js b/webpack/webpack.common.js index b38050450004..466b5343eee5 100644 --- a/webpack/webpack.common.js +++ b/webpack/webpack.common.js @@ -1,3 +1,4 @@ +/* eslint-env node */ const path = require('path'); const webpack = require('webpack'); const utils = require('./utils'); diff --git a/webpack/webpack.dev.js b/webpack/webpack.dev.js index f7abafba8286..b3df23b7ee1f 100644 --- a/webpack/webpack.dev.js +++ b/webpack/webpack.dev.js @@ -1,3 +1,4 @@ +/* eslint-env node */ const { merge } = require('webpack-merge'); const common = require('./webpack.common'); const b3Common = require('./webpack.b3.common'); diff --git a/webpack/webpack.prod.js b/webpack/webpack.prod.js index e0f297f776a1..62923796bbf6 100644 --- a/webpack/webpack.prod.js +++ b/webpack/webpack.prod.js @@ -1,3 +1,4 @@ +/* eslint-env node */ const { merge } = require('webpack-merge'); const common = require('./webpack.common'); const b3Common = require('./webpack.b3.common'); From 747a5c9fd7e8bd69dd6127f932e614831f74d953 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 18:37:01 +0200 Subject: [PATCH 39/44] add additional lines to ignore from the webpack manifest --- scripts/test-make-docs.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/test-make-docs.sh b/scripts/test-make-docs.sh index 8f7760febf5b..915520d9e55b 100644 --- a/scripts/test-make-docs.sh +++ b/scripts/test-make-docs.sh @@ -24,7 +24,10 @@ WHITELIST_PATTERNS=( '^\s*$' # ignore lines containing only whitespace 'logger is being changed to' # ignore error when FIX_LOGGER_ERROR_OBFUSCATION is true 'yacc table file version is out of date' # warning whenever building docs on a freshly created virtual environment + 'get_webpack_manifest.py' # ignore webpack manifest warning 'No webpack manifest found' # ignore webpack manifest warnings + 'Did you run `yarn dev` or `yarn build`?' # ignore webpack manifest warning + 'warnings.warn\("\\x1b\[33;20m" # yellow color' # ignore webpack manifest warning # Only whitelist docs build warnings/errors when absolutely necessary ) From fdc8b3c8778032602d4108ec60ac979f51562f19 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 19:54:49 +0200 Subject: [PATCH 40/44] remove new global escapes, as setting eslint-env was the better move for specific files --- .eslintrc.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index e026842fe9df..16d950d13d56 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -38,9 +38,6 @@ module.exports = { "beforeEach": false, "nv": false, "d3": false, - "require": false, - "__dirname": false, - "process": false, }, // http://eslint.org/docs/rules/ From 9331275d38fdce9753bf4935f51a7c1625cd771f Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 19:55:46 +0200 Subject: [PATCH 41/44] add another webpack string to whitelist --- scripts/test-make-docs.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/test-make-docs.sh b/scripts/test-make-docs.sh index 915520d9e55b..2e79b4d9e1e9 100644 --- a/scripts/test-make-docs.sh +++ b/scripts/test-make-docs.sh @@ -28,6 +28,7 @@ WHITELIST_PATTERNS=( 'No webpack manifest found' # ignore webpack manifest warnings 'Did you run `yarn dev` or `yarn build`?' # ignore webpack manifest warning 'warnings.warn\("\\x1b\[33;20m" # yellow color' # ignore webpack manifest warning + "\[0m" # another webpack build artifact # Only whitelist docs build warnings/errors when absolutely necessary ) From dfd86d571485154f21fba0099a9be35e975154b8 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Thu, 22 Aug 2024 21:58:10 +0200 Subject: [PATCH 42/44] fix running webpack build in python-sharded-and-javascript --- docker/run.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docker/run.sh b/docker/run.sh index ed65ce173534..85bf0d6724fd 100755 --- a/docker/run.sh +++ b/docker/run.sh @@ -138,6 +138,9 @@ function run_tests { su cchq -c "/bin/bash ../run_tests $argv_str" 2>&1 log_group_end # only log group end on success (notice: `set -e`) if [ "$TEST" == "python-sharded-and-javascript" ]; then + logmsg INFO "Building Webpack" + chown -R cchq:cchq ./webpack + su cchq -c "yarn build" su cchq -c scripts/test-prod-entrypoints.sh scripts/test-make-requirements.sh scripts/test-serializer-pickle-files.sh @@ -212,7 +215,6 @@ function _run_tests { function _test_javascript { SKIP_GEVENT_PATCHING=1 ./manage.py migrate --noinput - su cchq -c "yarn build" ./manage.py runserver 0.0.0.0:8000 &> commcare-hq.log & _wait_for_runserver logmsg INFO "grunt test ${js_test_args[*]}" From c791df88ba2340c77f53f920ec63ff8326561290 Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Fri, 23 Aug 2024 18:16:35 +0200 Subject: [PATCH 43/44] move webpack build related json files to _build directory --- .gitignore | 2 +- .../management/commands/generate_webpack_settings.py | 5 +++-- corehq/apps/hqwebapp/templatetags/hq_shared_tags.py | 2 +- get_webpack_manifest.py | 2 +- webpack/appPaths.js | 2 ++ webpack/generateDetails.js | 7 ++++++- webpack/plugins.js | 3 ++- webpack/utils.js | 5 +++-- 8 files changed, 19 insertions(+), 9 deletions(-) diff --git a/.gitignore b/.gitignore index 61bfa61fb5a1..d2beb6af5bae 100644 --- a/.gitignore +++ b/.gitignore @@ -87,4 +87,4 @@ corehq/apps/hqwebapp/static/hqwebapp/js/lib/modernizr.js .direnv # webpack build related -/webpack/*.json +/webpack/_build/ diff --git a/corehq/apps/hqwebapp/management/commands/generate_webpack_settings.py b/corehq/apps/hqwebapp/management/commands/generate_webpack_settings.py index 2f3795748dbc..2492c0e04150 100644 --- a/corehq/apps/hqwebapp/management/commands/generate_webpack_settings.py +++ b/corehq/apps/hqwebapp/management/commands/generate_webpack_settings.py @@ -6,7 +6,7 @@ import corehq -WEBPACK_BASE_DIR = Path(corehq.__file__).resolve().parent.parent / "webpack" +WEBPACK_BUILD_DIR = Path(corehq.__file__).resolve().parent.parent / "webpack" / "_build" class Command(BaseCommand): @@ -17,5 +17,6 @@ def handle(self, **options): webpack_settings = { 'staticfilesPath': settings.STATIC_ROOT, } - with open(WEBPACK_BASE_DIR / "settings.json", "w") as f: + WEBPACK_BUILD_DIR.mkdir(parents=True, exist_ok=True) + with open(WEBPACK_BUILD_DIR / "settings.json", "w") as f: json.dump(webpack_settings, f) diff --git a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py index 06bda0a979ec..4fc3cb5e832a 100644 --- a/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py +++ b/corehq/apps/hqwebapp/templatetags/hq_shared_tags.py @@ -748,7 +748,7 @@ def __repr__(self): try: from get_webpack_manifest import get_webpack_manifest webpack_manifest = get_webpack_manifest() - webpack_manifest_b3 = get_webpack_manifest('webpack/manifest_b3.json') + webpack_manifest_b3 = get_webpack_manifest('webpack/_build/manifest_b3.json') except (ImportError, SyntaxError): webpack_manifest = {} webpack_manifest_b3 = {} diff --git a/get_webpack_manifest.py b/get_webpack_manifest.py index 7dca466a6581..854b44bfd2ef 100644 --- a/get_webpack_manifest.py +++ b/get_webpack_manifest.py @@ -8,7 +8,7 @@ def get_webpack_manifest(path=None): manifest = {} if not path: - path = os.path.join('webpack/manifest.json') + path = os.path.join('webpack/_build/manifest.json') if not os.path.exists(path): if not settings.UNIT_TESTING and settings.DEBUG: warnings.warn("\x1b[33;20m" # yellow color diff --git a/webpack/appPaths.js b/webpack/appPaths.js index 15671124fcc3..43098a9896dd 100644 --- a/webpack/appPaths.js +++ b/webpack/appPaths.js @@ -4,6 +4,7 @@ const fs = require('fs'); const path = require('path'); const __BASE = path.resolve(__dirname, '..'); +const BUILD_ARTIFACTS_DIR = path.resolve(__dirname, '_build'); const TEMPLATES_DIR = 'templates'; const APPS_PATH = path.resolve(__BASE, 'corehq', 'apps'); const EX_SUBMODULES_PATH = path.resolve(__BASE, 'corehq', 'ex-submodules'); @@ -65,4 +66,5 @@ const getAllAppPaths = function () { module.exports = { getAllAppPaths: getAllAppPaths, TEMPLATES_DIR: TEMPLATES_DIR, + BUILD_ARTIFACTS_DIR: BUILD_ARTIFACTS_DIR, }; diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js index ae42344b4eee..eddcc066ad6c 100644 --- a/webpack/generateDetails.js +++ b/webpack/generateDetails.js @@ -106,6 +106,11 @@ const getDetails = function (entryRegex, allAppPaths, isProdMode) { // When run from the command line: if (require.main === module) { + + if (!fs.existsSync(appPaths.BUILD_ARTIFACTS_DIR)) { + fs.mkdirSync(appPaths.BUILD_ARTIFACTS_DIR); + } + const isProductionMode = process.argv.includes('--prod'); const allAppPaths = appPaths.getAllAppPaths(); @@ -136,7 +141,7 @@ if (require.main === module) { ); fs.writeFileSync( - path.resolve(__dirname, 'details.json'), + path.join(appPaths.BUILD_ARTIFACTS_DIR, 'details.json'), JSON.stringify({ entries: defaultDetails.entries, b3Entries: b3Details.entries, diff --git a/webpack/plugins.js b/webpack/plugins.js index 7291fdfa2d1d..e0f0dccfe82b 100644 --- a/webpack/plugins.js +++ b/webpack/plugins.js @@ -1,6 +1,7 @@ /* eslint-env node */ const path = require('path'); const fs = require('fs'); +const appPaths = require('./appPaths'); class EntryChunksPlugin { /** @@ -40,7 +41,7 @@ class EntryChunksPlugin { }); fs.writeFileSync( - path.resolve(__dirname, this.options.filename || 'manifest.json'), + path.join(appPaths.BUILD_ARTIFACTS_DIR, this.options.filename || 'manifest.json'), JSON.stringify(manifest, null, 2) ); diff --git a/webpack/utils.js b/webpack/utils.js index 50ed456a7e13..2f29f85cf07c 100644 --- a/webpack/utils.js +++ b/webpack/utils.js @@ -1,10 +1,11 @@ /* eslint-env node */ const path = require("path"); +const appPaths = require("./appPaths"); const fs = require("fs"); const __BASE = path.resolve(__dirname, '..'); -const SETTINGS_FILE = path.resolve(__dirname, 'settings.json'); -const DETAILS_FILE = path.resolve(__dirname, 'details.json'); +const SETTINGS_FILE = path.join(appPaths.BUILD_ARTIFACTS_DIR, 'settings.json'); +const DETAILS_FILE = path.join(appPaths.BUILD_ARTIFACTS_DIR, 'details.json'); const fetchJsonDataOrDefault = function (filePath, defaultData) { let fetchedData = defaultData; From 29e01ac1139b79a3c1fc3cd45c71630f17bd5cec Mon Sep 17 00:00:00 2001 From: Biyeun Buczyk Date: Sun, 25 Aug 2024 16:58:01 +0200 Subject: [PATCH 44/44] refactor alwaysIncludeApps to make requirement clearer (with docs) --- webpack/generateDetails.js | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/webpack/generateDetails.js b/webpack/generateDetails.js index eddcc066ad6c..15b4bbc6a1e1 100644 --- a/webpack/generateDetails.js +++ b/webpack/generateDetails.js @@ -114,19 +114,22 @@ if (require.main === module) { const isProductionMode = process.argv.includes('--prod'); const allAppPaths = appPaths.getAllAppPaths(); - // guarantee that these aliases are always generated - const aliases = { - 'analytix/js': path.join(allAppPaths.analytix, 'static/analytix/js'), - 'hqwebapp/js': path.join(allAppPaths.hqwebapp, 'static/hqwebapp/js'), - 'notifications/js': path.join(allAppPaths.notifications, 'static/notifications/js'), - }; - - // guarantee that these apps are always included - const appsWithEntries = [ + // Always build with these applications even if there are no webpack entries found within + // the application templates. + // Applications are often listed here if there are entries from other apps referencing modules in + // these apps, but there are no existing webpack entries from these apps (yet). + const alwaysIncludeApps = [ "analytix", "hqwebapp", "notifications", ]; + const aliases = {}; + const appsWithEntries = []; + alwaysIncludeApps.forEach((appName) => { + let appDir = `${appName}/js`; + aliases[appDir] = path.join(allAppPaths[appName], `static/${appDir}`); + appsWithEntries.push(appName); + }); // This splits the builds into bootstrap 5 and bootstrap 3 versions const defaultDetails = getDetails(