1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-12-13 23:48:55 +01:00
fab-manager/app/frontend/src/javascript/components
2022-10-13 18:38:42 +02:00
..
angular fix typo 2022-06-15 13:39:27 +02:00
authentication-provider (bug) OIDC scopes are not shown in the configuration form select 2022-07-06 12:59:45 +02:00
base (bug) prevent links on nothing in wysiwyg editor 2022-10-12 17:02:02 +02:00
cart (bug) cannot load order withdrawal instructions 2022-10-13 11:23:35 +02:00
coupon (bug) app always check coupon code in admin panier if change item quantity 2022-10-04 16:51:38 +02:00
dashboard (quality) move orders-dashboard to the dashboard folder 2022-10-04 15:03:29 +02:00
events fixed imports 2022-06-21 12:18:54 +02:00
form (feat) prevent show product in store if price not set 2022-09-27 15:58:59 +02:00
group Removed unused imports 2022-08-23 15:15:49 +02:00
machines Merge branch 'product_store-inte' into product_store-store 2022-09-07 09:27:57 +02:00
payment (quality) refactored categories sorting + fix ts issues 2022-09-07 17:30:21 +02:00
payment-schedule (merge) Merge branch 'dev' into product-store 2022-10-05 17:16:04 +02:00
plan-categories linted all code expected profile-custom-fields/* and proof-of-identity/* 2022-06-21 12:10:00 +02:00
plans (bug) plan's categories descriptions are not shown 2022-09-27 16:01:22 +02:00
prepaid-packs Removed unused imports 2022-08-23 15:15:49 +02:00
pricing (feat) show reservations panel 2022-06-29 15:34:04 +02:00
profile-completion Use union type instead of enum for SettingName 2022-08-23 13:12:13 +02:00
profile-custom-fields linted profile-custom-fields 2022-06-21 14:10:51 +02:00
settings Use union type instead of enum for SettingName 2022-08-23 13:12:13 +02:00
socials Use union type instead of enum for SettingName 2022-08-23 13:12:13 +02:00
store (bug) product limit stock error 2022-10-13 18:38:42 +02:00
subscriptions (wip) lint for scoped-translation 2022-06-20 18:06:15 +02:00
supporting-documents fix styling issues + rename proof of identity 2022-06-22 14:18:33 +02:00
user (merge) Merge branch 'dev' into product-store 2022-10-05 17:16:04 +02:00
document-filters.tsx (typing) use TDateISO for typing dates 2022-05-04 14:05:36 +02:00
README.md fixed imports 2022-06-21 12:18:54 +02:00

components

This directory is holding the components built with React.

During the migration phase, these components may be included in the legacy angularJS app using react2angular.

These components must be written using the following conventions:

  • The component name must be in CamelCase.
  • The component must be exported as a named export (no export default).
  • A component FooBar must have a className="foo-bar" attribute on its top-level element.
  • The stylesheet associated with the component must be located in app/frontend/src/stylesheets/modules/same-directory-structure/foo-bar.scss.
  • All methods in the component must be commented with a comment block.
  • Other constants and variables must be commented with an inline block.
  • Depending on if we want to use the <Suspense> wrapper or not, we can export the component directly or wrap it in a <Loader> wrapper.
  • When a component is used in angularJS, the wrapper is required. The component must be named like const Foo (no export if not used in React) and must have a const FooWrapper at the end of its file, which wraps the component in a <Loader>.
  • Translations must be grouped per component. For example, the FooBar component must have its translations in the config/locales/app.$SCOPE.en.yml file, under the foo_bar key.
  • Most of these rules are validated by eslint-plugin-fabmanager. Please ensure you write eslint valid code, and think twice you have a very good reason before disabling any rule.