@saltcorn/server 0.6.4-beta.6 → 0.7.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/auth/admin.js CHANGED
@@ -249,7 +249,7 @@ router.get(
249
249
  label: "",
250
250
  key: (r) =>
251
251
  r.disabled
252
- ? span({ class: "badge badge-danger" }, "Disabled")
252
+ ? span({ class: "badge bg-danger" }, "Disabled")
253
253
  : "",
254
254
  },
255
255
  {
@@ -444,8 +444,8 @@ router.get(
444
444
  h5(
445
445
  req.__("Currently: "),
446
446
  letsencrypt
447
- ? span({ class: "badge badge-primary" }, req.__("Enabled"))
448
- : span({ class: "badge badge-secondary" }, req.__("Disabled"))
447
+ ? span({ class: "badge bg-primary" }, req.__("Enabled"))
448
+ : span({ class: "badge bg-secondary" }, req.__("Disabled"))
449
449
  ),
450
450
  letsencrypt
451
451
  ? post_btn(
@@ -490,8 +490,8 @@ router.get(
490
490
  h5(
491
491
  req.__("Currently: "),
492
492
  has_custom
493
- ? span({ class: "badge badge-primary" }, req.__("Enabled"))
494
- : span({ class: "badge badge-secondary" }, req.__("Disabled"))
493
+ ? span({ class: "badge bg-primary" }, req.__("Enabled"))
494
+ : span({ class: "badge bg-secondary" }, req.__("Disabled"))
495
495
  ),
496
496
  // TBD change to button
497
497
  link(
@@ -610,7 +610,7 @@ router.get(
610
610
  div(
611
611
  user.api_token
612
612
  ? span(
613
- { class: "mr-1" },
613
+ { class: "me-1" },
614
614
  req.__("API token for this user: ")
615
615
  ) + code(user.api_token)
616
616
  : req.__("No API token issued")
@@ -627,7 +627,7 @@ router.get(
627
627
  // button for remove api token
628
628
  user.api_token &&
629
629
  div(
630
- { class: "mt-4 ml-2 d-inline-block" },
630
+ { class: "mt-4 ms-2 d-inline-block" },
631
631
  post_btn(
632
632
  `/useradmin/remove-api-token/${user.id}`,
633
633
  // TBD localization
package/auth/routes.js CHANGED
@@ -421,7 +421,7 @@ router.get(
421
421
  );
422
422
  const restore = restore_backup(
423
423
  req.csrfToken(),
424
- [i({ class: "fas fa-upload mr-2 mt-2" }), req.__("Restore a backup")],
424
+ [i({ class: "fas fa-upload me-2 mt-2" }), req.__("Restore a backup")],
425
425
  `/auth/create_from_restore`
426
426
  );
427
427
  res.sendAuthWrap(req.__(`Create first user`), form, {}, restore);
@@ -1121,7 +1121,7 @@ const userSettings = async ({ req, res, pwform, user }) => {
1121
1121
  // api token for user
1122
1122
  div(
1123
1123
  user.api_token
1124
- ? span({ class: "mr-1" }, req.__("API token for this user: ")) +
1124
+ ? span({ class: "me-1" }, req.__("API token for this user: ")) +
1125
1125
  code(user.api_token)
1126
1126
  : req.__("No API token issued")
1127
1127
  ),
@@ -1137,7 +1137,7 @@ const userSettings = async ({ req, res, pwform, user }) => {
1137
1137
  // button for remove api token
1138
1138
  user.api_token &&
1139
1139
  div(
1140
- { class: "mt-4 ml-2 d-inline-block" },
1140
+ { class: "mt-4 ms-2 d-inline-block" },
1141
1141
  post_btn(
1142
1142
  `/auth/remove-api-token`,
1143
1143
  // TBD localization
package/locales/en.json CHANGED
@@ -650,7 +650,7 @@
650
650
  "Not allowed": "Not allowed",
651
651
  "You are trying to create a tenant while connecting via an IP address rather than a domain. This will probably not work.": "You are trying to create a tenant while connecting via an IP address rather than a domain. This will probably not work.",
652
652
  "Create tenant warning": "Create tenant warning",
653
- "Show a warning to users creating a tenant disclaiming warrenty of availability or security": "Show a warning to users creating a tenant disclaiming warrenty of availability or security",
653
+ "Show a warning to users creating a tenant disclaiming warranty of availability or security": "Show a warning to users creating a tenant disclaiming warranty of availability or security",
654
654
  "A list view shown on the left, to select rows": "A list view shown on the left, to select rows",
655
655
  "The view to show the selected row": "The view to show the selected row",
656
656
  "Location": "Location",
@@ -805,7 +805,7 @@
805
805
  "Triggers run actions in response to events.": "Triggers run actions in response to events.",
806
806
  "No files": "No files",
807
807
  "Cookie duration (hours)": "Cookie duration (hours)",
808
- "Set to 0 for expration at the end of browser session": "Set to 0 for expration at the end of browser session",
808
+ "Set to 0 for expiration at the end of browser session": "Set to 0 for expiration at the end of browser session",
809
809
  "Cookie duration (hours) when remember ticked": "Cookie duration (hours) when remember ticked",
810
810
  "Forget table": "Forget table",
811
811
  "Table %s forgotten. You can now discover it.": "Table %s forgotten. You can now discover it.",
package/locales/ru.json CHANGED
@@ -527,7 +527,7 @@
527
527
  "Currently: ": "В настоящий момент: ",
528
528
  "Disabled": "Отключен(о)",
529
529
  "Enable LetsEncrypt HTTPS": "Использовать LetsEncrypt HTTPS",
530
- "HTTPS encryption with custom SSL certificate": "Шифрование HTTPS с использованием заданного здесь сертификата SSL",
530
+ "HTTPS encryption with custom SSL certificate": "Шифрование HTTPS с использованием стороннего сертификата SSL",
531
531
  "Or use custom SSL certificates, including wildcard certificates for multitenant applications": "Или использовать кастомные сертификаты SSL, включая сертификаты wildcard, для мультиненатных приложений",
532
532
  "Style": "Стиль",
533
533
  "Not all themes support menu buttons": "Не все темы поддерживают кнопки в меню",
@@ -535,7 +535,7 @@
535
535
  "Role to create tenants": "Роль, которой разрешено создание тенатов",
536
536
  "Minimum user role required to create a new tenant": "Минимальная роль для создания тенантов",
537
537
  "Create tenant warning": "Предупреждение при создании тенанта",
538
- "Show a warning to users creating a tenant disclaiming warrenty of availability or security": "Показывать пользователям при создании тенанта предупреждение об ограничениях доступности и безопасности",
538
+ "Show a warning to users creating a tenant disclaiming warranty of availability or security": "Показывать пользователям при создании тенанта предупреждение об ограничениях доступности и безопасности",
539
539
  "Name of the field": "Название поля",
540
540
  "The type determines the kind of data that can be stored in the field": "Тип поля определяет состав данных, которые могут быть сохранены в полей",
541
541
  "Calculated from other fields with a formula": "Вычисляется по формуле. В формуле можно использовать другие поля для вычисления",
@@ -584,10 +584,10 @@
584
584
  "Set page title": "Задать название страницы",
585
585
  "Skip this section if you do not want to set the page title": "Не заполняйте данную секцию, если вы не хотите задать название страницы",
586
586
  "Page title is a formula?": "Название страницы является формулой?",
587
- "Edit custom SSL certificates": "Настроить кастомный SSL сертификат",
588
- "Custom SSL certificate": "Кастомный SSL сертификат",
589
- "Custom SSL private key": "Кастомный SSL приватный ключ",
590
- "Custom SSL certificates": "Кастомные SSL сертификаты",
587
+ "Edit custom SSL certificates": "Настроить сторонние SSL сертификаты",
588
+ "Custom SSL certificate": "SSL сертификат",
589
+ "Custom SSL private key": "SSL приватный ключ",
590
+ "Custom SSL certificates": "SSL сертификаты",
591
591
  "Set Base URL configuration first": "Сначала необходимо задать Базовый URL в конфигурации",
592
592
  "Base URL domain %s does not match hostname %s": "Домен Базового URL %s не соответствует hostname %s",
593
593
  "This is the rank of the user role, lower role IDs will be able to access more resources.": "Это ранг пользовательской роли. Роли с меньшими ID будут иметь доступ к большему набору информации (ресурсам).",
@@ -651,19 +651,102 @@
651
651
  "Email sent to %s with no errors": "Email отправлен %s без ошибок",
652
652
  "Action %s run successfully with no console output": "Действие (триггер) %s выполнено успешно без вывода результатов в консоль",
653
653
  "Edit trigger %s": "Изменить триггер %s",
654
- "%s constraints": "%s constraints",
655
- "Add constraint": "Add constraint",
656
- "Tick the boxes for the fields that should be jointly unique": "Tick the boxes for the fields that should be jointly unique",
657
- "Add constraint to %s": "Add constraint to %s",
658
- "New table name": "New table name",
659
- "Rename table %s": "Rename table %s",
660
- "Started recalculating stored fields": "Started recalculating stored fields",
661
- "The user name to access SMTP server for sending emails.": "The user name to access SMTP server for sending emails.",
662
- "The user password or app password to access SMTP server for sending emails. If your SMTP provider allows to create app password for using from application We recommends to use app password instead of user password.": "The user password or app password to access SMTP server for sending emails. If your SMTP provider allows to create app password for using from application We recommends to use app password instead of user password.",
663
- "The port of your SMTP server": "The port of your SMTP server",
664
- "Description allows to give more information about field": "Description allows to give more information about field",
665
- "Not allowed": "Not allowed",
666
- "Ownership field": "Ownership field",
667
- "The user referred to in this field will be the owner of the row": "The user referred to in this field will be the owner of the row",
668
- "None": "None"
654
+ "%s constraints": "%s констрейнт(ов)",
655
+ "Add constraint": "Добавить констрейнт",
656
+ "Tick the boxes for the fields that should be jointly unique": "Установите флажки для полей, которые должны быть совместно уникальными",
657
+ "Add constraint to %s": "Добавить констрейнт к %s",
658
+ "New table name": "Новое имя таблицы",
659
+ "Rename table %s": "Переименовать таблицу %s",
660
+ "Started recalculating stored fields": "Начался перерасчет вычисляемых полей",
661
+ "The user name to access SMTP server for sending emails.": "Имя пользователя для доступа к серверу SMTP (для отправки email).",
662
+ "The user password or app password to access SMTP server for sending emails. If your SMTP provider allows to create app password for using from application We recommends to use app password instead of user password.": "Пароль пользователя или приложения для доступа к SMTP сервера (используется для отправки email). Если ваш провайдер SMTP позволяет создать отдельный пароль или токен для приложения, мы рекомендуем использовать пароль приложения вместо пароля пользователя.",
663
+ "The port of your SMTP server": "SMTP порт",
664
+ "Description allows to give more information about field": "Описание позволяет дать больше информции о поле",
665
+ "Not allowed": "Не разрешено",
666
+ "Ownership field": "Поле Владельца",
667
+ "The user referred to in this field will be the owner of the row": "Пользователь, указанный в данном поле, будет владельцем записи",
668
+ "None": "None",
669
+ "Pages are the web pages of your application built with a drag-and-drop builder. They have static content, and by embedding views, dynamic content.": "Страницы - это веб-страницы внутри приложения. Они создаются с помощью drug-n-drop построителя. Они могут содержать статический контент, также в них можно встраивать представления и динамический контент.",
670
+ "No pages": "Нет страниц",
671
+ "Views display data from tables. A view is a view template applied to a table, with configuration.": "Представления отображают данные из таблиц. Представления стоятся на основе шаблонов и конфигурируются.",
672
+ "No views": "Нет представлений",
673
+ "Tables organise data by fields and rows.": "Таблицы позволяют организовать данные в поля и строки.",
674
+ "CSV upload": "CSV загрузка",
675
+ "Triggers run actions in response to events.": "Триггеры выполняются действия в ответ на события.",
676
+ "No triggers": "Нет триггеров",
677
+ "No files": "Нет файлов",
678
+ "Home Timezone": "Домашняя Timezone",
679
+ "2FA policy": "2FA policy",
680
+ "Role to generate API keys": "Роль для API keys",
681
+ "User should have this role or higher to generate API keys in their user settings": "User should have this role or higher to generate API keys in their user settings",
682
+ "Cookie duration (hours)": "Срок действия Cookie (в часах)",
683
+ "Set to 0 for expiration at the end of browser session": "Если установить значение 0, Cookies будут действовать до окончания сессии браузера",
684
+ "Cookie duration (hours) when remember ticked": "Срок действия Cookie (в часах), когда установлен флажок \"Запомнить\"",
685
+ "Order field": "Order field",
686
+ "Section field": "Section field",
687
+ "Optional. String type with options, each of which will become a menu section": "Указывать необязательно. Строковый тип с набором значений, каждая из которых станет секцией меню",
688
+ "Label formula": "Label формлуа",
689
+ "URL formula": "URL формула",
690
+ "Include formula": "Include formula",
691
+ "If specified, only include in menu rows that evaluate to true": "Если указано, то в меню отображаются только секции (строки), для которых формула вычислилась со значением true",
692
+ "Not all themes support all locations": "Некоторые темы могут не поддерживать все языки",
693
+ "Library": "Библиотека",
694
+ "Languages": "Языки",
695
+ "Library: component assemblies that can be used in the builder": "Библиотека: компоненты для использования построителем интерфейсов",
696
+ "Language": "Язык",
697
+ "Locale": "Локализация",
698
+ "Add language": "Добавить язык",
699
+ "Default language": "Язык по-умолчанию",
700
+ "Storage": "Хранилище",
701
+ "Table or Channel": "Таблица или Канал",
702
+ "Event types": "Типы событий",
703
+ "Custom": "Custom",
704
+ "Log settings": "Настройки логов",
705
+ "Event log": "Лог событий",
706
+ "Custom Events": "Пользовательские События (Events)",
707
+ "Channels": "Каналы",
708
+ "Create custom event": "Добавить пользовательское событие",
709
+ "Which events should be logged?": "Укажите события, которые должны логироваться?",
710
+ "Events to log": "Логируемые события",
711
+ "Channel": "Канал",
712
+ "Use Amazon S3": "Использовать Amazon S3",
713
+ "Use Amazon S3 (or compatible) service to store files. If disabled, Saltcorn uses local disk. WARNING: Changing this may break your uploaded files!": "Использовать для хранения файлов сервис Amazon S3 (или совместимый). Изначально Saltcorn использует локальный диск для хранения файлов. ПРЕДУПРЕЖДЕНИЕ: Изменение данной настройки может привести к потери ранее загруженных файлов!",
714
+ "Amazon S3 Bucket": "Amazon S3 Bucket",
715
+ "Name you selected for your S3 bucket in AWS.": "Название (Bucket Name) вашей корзины (bucket) S3 в AWS.",
716
+ "Amazon S3 Path Prefix": "Amazon S3 Path Prefix",
717
+ "Prefix you selected for your S3 bucket in AWS.": "Префикс (Prefix) вашей корзины (bucket) S3 в AWS.",
718
+ "Amazon S3 Endpoint": "Amazon S3 Endpoint",
719
+ "Hostname of your S3 Compatible Storage provider. Defaults to 's3.amazonaws.com'.": "Имя хоста используемого S3 совместимого сервиса. Значение по-умолчанию 's3.amazonaws.com'.",
720
+ "Amazon S3 Region": "Amazon S3 Region",
721
+ "AWS region you selected when creating your S3 bucket. Default ti 'us-east-1'.": "Регион, указанный при создании корзины (bucket) S3 в AWS S3. Значение по-умолчанию 'us-east-1'.",
722
+ "Amazon S3 Access Key ID": "Amazon S3 Access Key ID",
723
+ "Only required if you do not want to authenticate to S3 using an IAM role. Enter the Access Key ID provided by your Amazon EC2 administrator.": "Требуется указать только, если вы не используете IAM role для аутентификации в S3. Введите Access Key ID, предоставленный вашим администратором Amazon EC2.",
724
+ "Amazon S3 Secret Access Key": "Amazon S3 Secret Access Key",
725
+ "The secret access key associated with your Amazon S3 Access Key ID.": "Секретный ключ доступа (access key), связанный с вашим Amazon S3 Access Key ID.",
726
+ "Use Amazon S3 Secure Connection.": "Использовать безопасное подключение к Amazon S3.",
727
+ "Connect to Amazon S3 (or compatible) securely.": "Подключиться к сервису Amazon S3 (или совместимому) безопасно.",
728
+ "Storage settings": "Настройки хранилища",
729
+ "Two-factor authentication": "Двухфакторная аутентификация",
730
+ "Two-factor authentication is disabled": "Двухфакторная аутентификация отключена",
731
+ "Forget table": "Забыть таблицу",
732
+ "Ownership formula": "Формула Владельца",
733
+ "User is treated as owner if true. In scope: ": "Ownership formula. Пользователь воспринимается как владелец, если значение формулы true. В рамках: ",
734
+ "This is a translation of a different field in a different language": "Это трансляция полей на разные языки",
735
+ "Language locale of translation": "Language locale of translation",
736
+ "Slug": "Slug",
737
+ "Field that can be used for a prettier URL structure": "Поле, которе используется для настройки структуры URL",
738
+ "Column width": "Ширина столбца",
739
+ "Column width units": "Единицы измерения для ширины столбца",
740
+ "Row inclusion formula": "Формула включения строки",
741
+ "Only include rows where this formula is true": "Row inclusion formula. Включать только строки, для которых формула имеет значение true",
742
+ "Transpose": "Транспонировать",
743
+ "Display one column per line": "Отображать один столбец на одной строке",
744
+ "Vertical column width": "Высота столбца",
745
+ "Vertical width units": "Единицы измерения высоты столбца",
746
+ "Preset %s": "Preset %s",
747
+ "Edit properties": "Edit properties",
748
+ "Yes": "Да",
749
+ "Event type which runs the trigger": "Тип события, которое запускает триггер",
750
+ "Leave blank for all channels": "Если не заполнено, используются все каналы",
751
+ "User must have this role or higher to make API call for action (trigger)": "Пользователь должен иметь указанную роль и выше для выполнение вызова API действия (триггера)"
669
752
  }
package/markup/admin.js CHANGED
@@ -73,8 +73,8 @@ const add_edit_bar = ({ role, title, contents, what, url, req }) => {
73
73
  const bar = div(
74
74
  { class: "alert alert-light d-print-none admin-edit-bar" },
75
75
  title,
76
- what && span({ class: "ml-1 badge badge-primary" }, what),
77
- a({ class: "ml-4", href: url }, "Edit ", i({ class: "fas fa-edit" }))
76
+ what && span({ class: "ms-1 badge bg-primary" }, what),
77
+ a({ class: "ms-4", href: url }, "Edit ", i({ class: "fas fa-edit" }))
78
78
  );
79
79
 
80
80
  if (contents.above) {
@@ -25,16 +25,16 @@ const {
25
25
  const { link } = require("@saltcorn/markup");
26
26
 
27
27
  /**
28
- * @param {object} args
28
+ * @param {object} args
29
29
  * @returns {string}
30
30
  */
31
31
  const show_function_arguments = (args) =>
32
32
  (args || []).map(({ name, type }) => `${name}: ${type}`).join(", ");
33
33
 
34
34
  /**
35
- * @param {object} plugin
36
- * @param {string} key
37
- * @param {object} def
35
+ * @param {object} plugin
36
+ * @param {string} key
37
+ * @param {object} def
38
38
  * @returns {*}
39
39
  */
40
40
  const withCfg = (plugin, key, def) =>
@@ -45,21 +45,21 @@ const withCfg = (plugin, key, def) =>
45
45
  : plugin.plugin_module[key] || def;
46
46
 
47
47
  /**
48
- * @param {object} plugin
49
- * @param {object} req
48
+ * @param {object} plugin
49
+ * @param {object} req
50
50
  * @returns {*}
51
51
  */
52
52
  const plugin_types_info_card = (plugin, req) => ({
53
53
  type: "card",
54
54
  title: req.__("Types"),
55
55
  contents: plugin.plugin_module.types.map((type) =>
56
- span({ class: "badge badge-primary ml-2" }, type.name)
56
+ span({ class: "badge bg-primary ms-2" }, type.name)
57
57
  ),
58
58
  });
59
59
 
60
60
  /**
61
- * @param {object} plugin
62
- * @param {object} req
61
+ * @param {object} plugin
62
+ * @param {object} req
63
63
  * @returns {*}
64
64
  */
65
65
  const plugin_functions_info_card = (plugin, req) => ({
@@ -69,10 +69,10 @@ const plugin_functions_info_card = (plugin, req) => ({
69
69
  .map(([nm, v]) =>
70
70
  div(
71
71
  h4(
72
- { class: "d-inline mr-2" },
72
+ { class: "d-inline me-2" },
73
73
  `${nm}(${show_function_arguments(v["arglist"])})`
74
74
  ),
75
- v.isAsync && span({ class: "badge badge-primary" }, "async"),
75
+ v.isAsync && span({ class: "badge bg-primary" }, "async"),
76
76
  v.returns ? p(req.__("Returns: "), v.returns) : null,
77
77
  p(v.description)
78
78
  )
@@ -81,8 +81,8 @@ const plugin_functions_info_card = (plugin, req) => ({
81
81
  });
82
82
 
83
83
  /**
84
- * @param {object} plugin
85
- * @param {object} req
84
+ * @param {object} plugin
85
+ * @param {object} req
86
86
  * @returns {*}
87
87
  */
88
88
  const plugin_viewtemplates_info_card = (plugin, req) => ({
@@ -94,7 +94,7 @@ const plugin_viewtemplates_info_card = (plugin, req) => ({
94
94
  });
95
95
 
96
96
  /**
97
- * @param {object} repo
97
+ * @param {object} repo
98
98
  * @returns {*}
99
99
  */
100
100
  const showRepository = (repo) =>
package/package.json CHANGED
@@ -1,17 +1,17 @@
1
1
  {
2
2
  "name": "@saltcorn/server",
3
- "version": "0.6.4-beta.6",
3
+ "version": "0.7.0-beta.1",
4
4
  "description": "Server app for Saltcorn, open-source no-code platform",
5
5
  "homepage": "https://saltcorn.com",
6
6
  "main": "index.js",
7
7
  "license": "MIT",
8
8
  "dependencies": {
9
- "@saltcorn/base-plugin": "0.6.4-beta.6",
10
- "@saltcorn/builder": "0.6.4-beta.6",
11
- "@saltcorn/data": "0.6.4-beta.6",
12
- "@saltcorn/admin-models": "0.6.4-beta.6",
13
- "@saltcorn/markup": "0.6.4-beta.6",
14
- "@saltcorn/sbadmin2": "0.6.4-beta.6",
9
+ "@saltcorn/base-plugin": "0.7.0-beta.1",
10
+ "@saltcorn/builder": "0.7.0-beta.1",
11
+ "@saltcorn/data": "0.7.0-beta.1",
12
+ "@saltcorn/admin-models": "0.7.0-beta.1",
13
+ "@saltcorn/markup": "0.7.0-beta.1",
14
+ "@saltcorn/sbadmin2": "0.7.0-beta.1",
15
15
  "@socket.io/cluster-adapter": "^0.1.0",
16
16
  "@socket.io/sticky": "^1.0.1",
17
17
  "aws-sdk": "^2.1037.0",