@airfleet/generator-init 0.30.0 → 0.32.0

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.
Files changed (100) hide show
  1. package/generators/plugin/templates/.github/workflows/release-plugin.yml +6 -3
  2. package/generators/plugin/templates/.github/workflows/test-wordpress.yml +0 -2
  3. package/generators/plugin/templates/composer-scoped.json.ejs +1 -1
  4. package/generators/plugin/templates/composer-scoped.lock.ejs +122 -122
  5. package/generators/plugin/templates/gitignore +1 -0
  6. package/generators/plugin/templates/package.json.ejs +1 -1
  7. package/generators/project/templates/.deployignore +4 -0
  8. package/generators/project/templates/.github/workflows/test-wordpress-root-lightyear.yml +0 -2
  9. package/generators/project-plugin/index.js +230 -0
  10. package/generators/project-plugin/templates/.airfleet-release +1 -0
  11. package/generators/project-plugin/templates/.deployignore +54 -0
  12. package/generators/project-plugin/templates/.editorconfig +18 -0
  13. package/generators/project-plugin/templates/.env +0 -0
  14. package/generators/project-plugin/templates/.gitattributes +12 -0
  15. package/generators/project-plugin/templates/.github/workflows/create-asana-attachment.yaml +19 -0
  16. package/generators/project-plugin/templates/.github/workflows/test-wordpress.yml +44 -0
  17. package/generators/project-plugin/templates/.husky/gitignore +1 -0
  18. package/generators/project-plugin/templates/.husky/pre-commit +4 -0
  19. package/generators/project-plugin/templates/.parcelrc +4 -0
  20. package/generators/project-plugin/templates/.prettierignore +15 -0
  21. package/generators/project-plugin/templates/.vscode/airfleet.code-snippets.ejs +186 -0
  22. package/generators/project-plugin/templates/.vscode/settings.json +33 -0
  23. package/generators/project-plugin/templates/CHANGELOG.md +10 -0
  24. package/generators/project-plugin/templates/LICENSE.ejs +2 -0
  25. package/generators/project-plugin/templates/README.md.ejs +16 -0
  26. package/generators/project-plugin/templates/acf-json/.gitkeep +0 -0
  27. package/generators/project-plugin/templates/acf-json/field-groups/.gitkeep +0 -0
  28. package/generators/project-plugin/templates/acf-json/option-pages/.gitkeep +0 -0
  29. package/generators/project-plugin/templates/acf-json/option-pages/airfleet-site-settings.json +22 -0
  30. package/generators/project-plugin/templates/acf-json/post-types/.gitkeep +0 -0
  31. package/generators/project-plugin/templates/acf-json/taxonomies/.gitkeep +0 -0
  32. package/generators/project-plugin/templates/assets/admin/styles/admin.entry.scss +2 -0
  33. package/generators/project-plugin/templates/assets/editor/styles/editor.entry.scss +23 -0
  34. package/generators/project-plugin/templates/assets/frontend/fonts/.gitkeep +0 -0
  35. package/generators/project-plugin/templates/assets/frontend/images/.gitkeep +0 -0
  36. package/generators/project-plugin/templates/assets/frontend/scripts/index.entry.js +3 -0
  37. package/generators/project-plugin/templates/assets/frontend/styles/_main.scss +3 -0
  38. package/generators/project-plugin/templates/assets/frontend/styles/_placeholders.scss +3 -0
  39. package/generators/project-plugin/templates/assets/frontend/styles/_root.scss +4 -0
  40. package/generators/project-plugin/templates/assets/frontend/styles/critical.entry.scss +1 -0
  41. package/generators/project-plugin/templates/assets/frontend/styles/index.entry.scss +6 -0
  42. package/generators/project-plugin/templates/assets/frontend/styles/main/_body.scss +6 -0
  43. package/generators/project-plugin/templates/assets/frontend/styles/main/_reset.scss +121 -0
  44. package/generators/project-plugin/templates/assets/frontend/styles/placeholders/_button.scss +43 -0
  45. package/generators/project-plugin/templates/assets/frontend/styles/placeholders/_container.scss +12 -0
  46. package/generators/project-plugin/templates/assets/frontend/styles/placeholders/_sections.scss +6 -0
  47. package/generators/project-plugin/templates/assets/frontend/styles/root/_fonts.scss +21 -0
  48. package/generators/project-plugin/templates/assets/login/.gitkeep +0 -0
  49. package/generators/project-plugin/templates/assets/shared/styles/_figma-variables.scss +7 -0
  50. package/generators/project-plugin/templates/assets/shared/styles/_lib.scss +4 -0
  51. package/generators/project-plugin/templates/assets/shared/styles/_root.scss +6 -0
  52. package/generators/project-plugin/templates/assets/shared/styles/_shared.scss +1 -0
  53. package/generators/project-plugin/templates/assets/shared/styles/lib/_mixins.scss +6 -0
  54. package/generators/project-plugin/templates/assets/shared/styles/lib/_scss-variables.scss +2 -0
  55. package/generators/project-plugin/templates/assets/shared/styles/lib/mixins/_background.scss +11 -0
  56. package/generators/project-plugin/templates/assets/shared/styles/lib/mixins/_body.scss +4 -0
  57. package/generators/project-plugin/templates/assets/shared/styles/lib/mixins/_breakpoints.scss +79 -0
  58. package/generators/project-plugin/templates/assets/shared/styles/lib/mixins/_helpers.scss +35 -0
  59. package/generators/project-plugin/templates/assets/shared/styles/lib/mixins/_list-inline.scss +23 -0
  60. package/generators/project-plugin/templates/assets/shared/styles/lib/mixins/_position.scss +24 -0
  61. package/generators/project-plugin/templates/composer-scoped.json.ejs +8 -0
  62. package/generators/project-plugin/templates/composer-scoped.lock.ejs +124 -0
  63. package/generators/project-plugin/templates/composer.json.ejs +52 -0
  64. package/generators/project-plugin/templates/figma/design-tokens/.gitkeep +0 -0
  65. package/generators/project-plugin/templates/figma/design-tokens/manifest.json +5 -0
  66. package/generators/project-plugin/templates/gitignore +15 -0
  67. package/generators/project-plugin/templates/inc/Features/Menus.php.ejs +22 -0
  68. package/generators/project-plugin/templates/inc/Setup/AjaxVariables.php.ejs +22 -0
  69. package/generators/project-plugin/templates/inc/Setup/AjaxVariablesAdmin.php.ejs +22 -0
  70. package/generators/project-plugin/templates/inc/Setup/Breakpoints.php.ejs +18 -0
  71. package/generators/project-plugin/templates/inc/Setup/Colors.php.ejs +17 -0
  72. package/generators/project-plugin/templates/inc/Setup/RegisterViews.php.ejs +64 -0
  73. package/generators/project-plugin/templates/inc/Setup.php.ejs +30 -0
  74. package/generators/project-plugin/templates/index.php +1 -0
  75. package/generators/project-plugin/templates/package.json.ejs +85 -0
  76. package/generators/project-plugin/templates/phpcs.xml.ejs +23 -0
  77. package/generators/project-plugin/templates/plugin-name.php.ejs +65 -0
  78. package/generators/project-plugin/templates/scoper.custom.php.ejs +8 -0
  79. package/generators/project-plugin/templates/views/blocks/.gitkeep +0 -0
  80. package/generators/project-plugin/templates/views/components/.gitkeep +0 -0
  81. package/generators/project-plugin/templates/views/custom-templates/.gitkeep +0 -0
  82. package/generators/project-plugin/templates/views/parcelkeep.entry.scss +0 -0
  83. package/generators/project-plugin/templates/views/partials/footer/footer.blade.php.ejs +4 -0
  84. package/generators/project-plugin/templates/views/partials/footer/footer.php.ejs +4 -0
  85. package/generators/project-plugin/templates/views/partials/header/header.blade.php.ejs +12 -0
  86. package/generators/project-plugin/templates/views/partials/header/header.php.ejs +12 -0
  87. package/generators/project-plugin/templates/views/partials/layout/layout.blade.php.ejs +3 -0
  88. package/generators/project-plugin/templates/views/partials/layout/layout.php.ejs +5 -0
  89. package/generators/project-plugin/templates/views/templates/index/index.blade.php.ejs +30 -0
  90. package/generators/project-plugin/templates/views/templates/index/index.php.ejs +32 -0
  91. package/generators/project-plugin/templates/views/templates/not-found/not-found.blade.php.ejs +3 -0
  92. package/generators/project-plugin/templates/views/templates/not-found/not-found.php.ejs +5 -0
  93. package/generators/project-plugin/templates/views/templates/page/page.blade.php.ejs +10 -0
  94. package/generators/project-plugin/templates/views/templates/page/page.php.ejs +12 -0
  95. package/generators/project-plugin/templates/views/templates/single/single.blade.php.ejs +28 -0
  96. package/generators/project-plugin/templates/views/templates/single/single.php.ejs +30 -0
  97. package/generators/project-plugin/templates/views-elements/.gitkeep +0 -0
  98. package/generators/project-plugin/templates/views-elements/partials/button/ButtonSetup.php.ejs +32 -0
  99. package/generators/project-plugin/templates/views-elements/partials/button/button.entry.scss +13 -0
  100. package/package.json +1 -1
@@ -0,0 +1,12 @@
1
+ *.js eol=lf
2
+ *.jsx eol=lf
3
+ *.ts eol=lf
4
+ *.tsx eol=lf
5
+ *.json eol=lf
6
+ *.md eol=lf
7
+ *.yml eol=lf
8
+ *.yaml eol=lf
9
+ *.css eol=lf
10
+ *.scss eol=lf
11
+ *.php eol=lf
12
+ *.xml eol=lf
@@ -0,0 +1,19 @@
1
+ name: ✍️ Asana Create PR Attachment
2
+
3
+ on:
4
+ pull_request:
5
+ types: [opened, reopened]
6
+
7
+ jobs:
8
+ create-asana-attachment-job:
9
+ runs-on: ubuntu-latest
10
+ timeout-minutes: 1
11
+ name: Create pull request attachments on Asana tasks
12
+ steps:
13
+ - name: Create pull request attachments
14
+ uses: Asana/create-app-attachment-github-action@latest
15
+ id: postAttachment
16
+ with:
17
+ asana-secret: ${{ secrets.ASANA_SECRET }}
18
+ - name: Log output status
19
+ run: echo "Status is ${{ steps.postAttachment.outputs.status }}"
@@ -0,0 +1,44 @@
1
+ name: 🧪 Test
2
+
3
+ on:
4
+ push:
5
+ branches: ["staging", "development"]
6
+ pull_request:
7
+ branches: ["main", "staging", "development"]
8
+ workflow_dispatch:
9
+
10
+ jobs:
11
+ test:
12
+ runs-on: ubuntu-latest
13
+
14
+ steps:
15
+ - name: 🚚 Get latest code
16
+ uses: actions/checkout@v3
17
+
18
+ - name: ⚙️ Setup PHP
19
+ uses: shivammathur/setup-php@v2
20
+ with:
21
+ php-version: "8.2"
22
+ ini-values: short_open_tag=1
23
+ env:
24
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25
+
26
+ - name: ⚙️ Setup Node
27
+ uses: actions/setup-node@v3
28
+ with:
29
+ node-version: 16
30
+
31
+ - name: 🔨 Increase composer timeout
32
+ run: composer --global config process-timeout 1500
33
+
34
+ - name: 🔨 Composer install
35
+ run: composer install --prefer-dist --no-ansi --no-interaction --no-progress --optimize-autoloader
36
+
37
+ - name: 🔨 npm install
38
+ run: npm ci
39
+
40
+ - name: 🔬 Test
41
+ run: npm test
42
+
43
+ - name: 📦 Build
44
+ run: npm run build --if-present
@@ -0,0 +1,4 @@
1
+ #!/bin/sh
2
+ . "$(dirname "$0")/_/husky.sh"
3
+
4
+ npx lint-staged
@@ -0,0 +1,4 @@
1
+ {
2
+ "extends": "@parcel/config-default",
3
+ "reporters": ["...", "parcel-reporter-bundle-manifest"]
4
+ }
@@ -0,0 +1,15 @@
1
+ node_modules
2
+ coverage
3
+ .npmrc
4
+ vendor
5
+ dist
6
+ .parcel-cache
7
+ .eslintcache
8
+ .stylelintcache
9
+ .phpcscache
10
+ .composer-cache
11
+ acf-json
12
+ CHANGELOG.md
13
+ .github
14
+ vendor-scoped
15
+ wp-content
@@ -0,0 +1,186 @@
1
+ {
2
+ "Airfleet Feature": {
3
+ "scope": "php,html",
4
+ "prefix": "affeat",
5
+ "body": [
6
+ "<?php",
7
+ "",
8
+ "namespace Airfleet\\Plugins\\<%= nameNoAirfleet.pascal %>\\\\${TM_DIRECTORY/^.+[\\/\\\\]+(.*)$/$1/};",
9
+ "",
10
+ "use Airfleet\\Plugins\\<%= nameNoAirfleet.pascal %>\\Vendor\\Airfleet\\Framework\\Features\\BasePluginFeature;",
11
+ "",
12
+ "class $TM_FILENAME_BASE extends BasePluginFeature {",
13
+ " public function initialize(): void {",
14
+ " $0",
15
+ " }",
16
+ "}",
17
+ ""
18
+ ],
19
+ "description": "Create a new plugin feature"
20
+ },
21
+ "Airfleet View Controller": {
22
+ "scope": "php,html",
23
+ "prefix": "afctrl",
24
+ "body": [
25
+ "<?php",
26
+ "",
27
+ "namespace Airfleet\\Plugins\\<%= nameNoAirfleet.pascal %>\\Views\\\\${1|Components,Blocks,Partials,Templates,CustomTemplates|}\\\\${TM_FILENAME_BASE/(.+)Controller/$1/};",
28
+ "",
29
+ "use Airfleet\\Plugins\\Views\\View\\ViewController;",
30
+ "",
31
+ "class $TM_FILENAME_BASE extends ViewController {",
32
+ " $2",
33
+ "}",
34
+ ""
35
+ ],
36
+ "description": "Create a new view controller"
37
+ },
38
+ "Airfleet View Setup": {
39
+ "scope": "php,html",
40
+ "prefix": "afsetup",
41
+ "body": [
42
+ "<?php",
43
+ "",
44
+ "namespace Airfleet\\Plugins\\<%= nameNoAirfleet.pascal %>\\Views\\\\${1|Components,Blocks,Partials,Templates,CustomTemplates|}\\\\${TM_FILENAME_BASE/(.+)Setup/$1/};",
45
+ "",
46
+ "use Airfleet\\Plugins\\Views\\View\\ViewSetup;",
47
+ "",
48
+ "class $TM_FILENAME_BASE extends ViewSetup {",
49
+ " public function initialize(): void {",
50
+ " $2",
51
+ " }",
52
+ "}",
53
+ ""
54
+ ],
55
+ "description": "Create a new view setup file"
56
+ },
57
+ "Airfleet Script": {
58
+ "scope": "javascript",
59
+ "prefix": "afjs",
60
+ "body": [
61
+ "export class ${TM_FILENAME_BASE/([^.]*)(\\..+)*$/${1:/pascalcase}/} {",
62
+ " initialize() {",
63
+ " const { domReady } = window._airfleet.elements.core;",
64
+ "",
65
+ " domReady(() => {",
66
+ " $1",
67
+ " });",
68
+ " }",
69
+ "}",
70
+ "",
71
+ "new ${TM_FILENAME_BASE/([^.]*)(\\..+)*$/${1:/pascalcase}/}().initialize();",
72
+ ""
73
+ ],
74
+ "description": "Create a view script"
75
+ },
76
+ "Airfleet Stylesheet": {
77
+ "scope": "scss,css,postcss",
78
+ "prefix": "afcss",
79
+ "body": [
80
+ ".${1|afc,afb,afp,aft|}-${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/} {",
81
+ " $2",
82
+ "}",
83
+ ""
84
+ ],
85
+ "description": "Create a view stylesheet"
86
+ },
87
+ "Airfleet Block Meta": {
88
+ "scope": "json",
89
+ "prefix": "afblockmeta",
90
+ "body": [
91
+ "{",
92
+ " \"$schema\": \"https://advancedcustomfields.com/schemas/json/main/block.json\",",
93
+ " \"name\": \"${1|airfleet/,airfleet/elements-|}${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/}\",",
94
+ " \"title\": \"$2${TM_FILENAME_BASE/([^\\.]*)(\\.block)?$/${1:/capitalize}/}\",",
95
+ " \"description\": \"$3\",",
96
+ " \"keywords\": [\"airfleet\", \"${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/}\"$4]",
97
+ " \"supports\": { \"anchor\": true }",
98
+ "}",
99
+ ""
100
+ ],
101
+ "description": "Create a JSON meta file for a block"
102
+ },
103
+ "Airfleet Pattern Meta": {
104
+ "scope": "json",
105
+ "prefix": "afpatternmeta",
106
+ "body": [
107
+ "{",
108
+ " \"name\": \"${1|airfleet/pattern-|}${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/}\",",
109
+ " \"title\": \"$2${TM_FILENAME_BASE/([^\\.]*)(\\.block)?$/${1:/capitalize}/}\",",
110
+ " \"description\": \"$3\",",
111
+ " \"keywords\": [\"airfleet\", \"pattern\", \"${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/}\"$4]",
112
+ "}",
113
+ ""
114
+ ],
115
+ "description": "Create a JSON meta file for a pattern"
116
+ },
117
+ "Airfleet Block Template (PHP)": {
118
+ "scope": "php,html",
119
+ "prefix": "afblockphp",
120
+ "body": [
121
+ "<section <?php echo \\$_all_attrs( [ 'class' => 'afb-$TM_FILENAME_BASE' ] ); ?>>",
122
+ " $1",
123
+ "</section>",
124
+ ""
125
+ ],
126
+ "description": "Bootstrap a PHP template for a block"
127
+ },
128
+ "Airfleet Block Template (Blade)": {
129
+ "scope": "blade",
130
+ "prefix": "afblock",
131
+ "body": [
132
+ "<section @all_attrs( [ 'class' => 'afb-${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/}' ] )>",
133
+ " $1",
134
+ "</section>",
135
+ ""
136
+ ],
137
+ "description": "Bootstrap a Blade template for a block"
138
+ },
139
+ "Airfleet Component Template (PHP)": {
140
+ "scope": "php,html",
141
+ "prefix": "afcompphp",
142
+ "body": [
143
+ "<div <?php echo \\$_all_attrs( [ 'class' => 'afc-$TM_FILENAME_BASE' ] ); ?>>",
144
+ " $1",
145
+ " <?php echo \\$_slot; ?>",
146
+ "</div>",
147
+ ""
148
+ ],
149
+ "description": "Bootstrap a PHP template for a component"
150
+ },
151
+ "Airfleet Component Template (Blade)": {
152
+ "scope": "blade",
153
+ "prefix": "afcomp",
154
+ "body": [
155
+ "<div @all_attrs( [ 'class' => 'afc-${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/}' ] )>",
156
+ " $1",
157
+ " {!! \\$_slot !!}",
158
+ "</div>",
159
+ ""
160
+ ],
161
+ "description": "Bootstrap a Blade template for a component"
162
+ },
163
+ "Airfleet Partial Template (PHP)": {
164
+ "scope": "php,html",
165
+ "prefix": "afpartialphp",
166
+ "body": [
167
+ "<div <?php echo \\$_all_attrs( [ 'class' => 'afp-$TM_FILENAME_BASE' ] ); ?>>",
168
+ " $1",
169
+ " <?php echo \\$_slot; ?>",
170
+ "</div>",
171
+ ""
172
+ ],
173
+ "description": "Bootstrap a PHP template for a partial"
174
+ },
175
+ "Airfleet Partial Template (Blade)": {
176
+ "prefix": "afpartial",
177
+ "body": [
178
+ "<div @all_attrs( [ 'class' => 'afp-${TM_FILENAME_BASE/([^.]*)(\\..+)*$/$1/}' ] )>",
179
+ " $1",
180
+ " {!! \\$_slot !!}",
181
+ "</div>",
182
+ ""
183
+ ],
184
+ "description": "Bootstrap a Blade template for a partial"
185
+ }
186
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "editor.codeActionsOnSave": {
3
+ "source.fixAll": "explicit",
4
+ "source.fixAll.eslint": "explicit"
5
+ },
6
+ "editor.formatOnSave": true,
7
+ "stylelint.validate": ["css", "scss", "postcss"],
8
+ "phpSniffer.autoDetect": true,
9
+ "[php]": {
10
+ "editor.defaultFormatter": "wongjn.php-sniffer"
11
+ },
12
+ "[javascript]": {
13
+ "editor.defaultFormatter": "dbaeumer.vscode-eslint"
14
+ },
15
+ "[javascriptreact]": {
16
+ "editor.defaultFormatter": "dbaeumer.vscode-eslint"
17
+ },
18
+ "[typescript]": {
19
+ "editor.defaultFormatter": "dbaeumer.vscode-eslint"
20
+ },
21
+ "[typescriptreact]": {
22
+ "editor.defaultFormatter": "dbaeumer.vscode-eslint"
23
+ },
24
+ "[postcss]": {
25
+ "editor.defaultFormatter": "esbenp.prettier-vscode"
26
+ },
27
+ "[scss]": {
28
+ "editor.defaultFormatter": "esbenp.prettier-vscode"
29
+ },
30
+ "[css]": {
31
+ "editor.defaultFormatter": "esbenp.prettier-vscode"
32
+ }
33
+ }
@@ -0,0 +1,10 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](http://keepachangelog.com/)
6
+ and this project adheres to [Semantic Versioning](http://semver.org/).
7
+
8
+ ## [Unreleased]
9
+
10
+ ### Added
@@ -0,0 +1,2 @@
1
+ Copyright (c) <%= year %> Airfleet <dev@airfleet.co> (https://www.airfleet.co/)
2
+ All rights reserved.
@@ -0,0 +1,16 @@
1
+ # <%= name.title %> WordPress Plugin
2
+
3
+ [![🧪 Test](<%= repositoryBase %>/actions/workflows/test-wordpress.yml/badge.svg)](<%= repositoryBase %>/actions/workflows/test-wordpress.yml)
4
+
5
+ <%= answers.pluginDescription %>
6
+
7
+ ## Getting Started
8
+
9
+ ```bash
10
+ composer install
11
+ npm install
12
+ ```
13
+
14
+ ## License
15
+
16
+ © [Airfleet](https://www.airfleet.co/)
@@ -0,0 +1,22 @@
1
+ {
2
+ "key": "ui_options_page_659577aa68c5c",
3
+ "title": "Airfleet Site Settings",
4
+ "active": true,
5
+ "menu_order": 0,
6
+ "page_title": "Airfleet Site Settings",
7
+ "menu_slug": "airfleet-site-settings",
8
+ "parent_slug": "options-general.php",
9
+ "advanced_configuration": 1,
10
+ "icon_url": "",
11
+ "menu_title": "Site Settings",
12
+ "position": "",
13
+ "redirect": false,
14
+ "description": "",
15
+ "update_button": "Update",
16
+ "updated_message": "Options Updated",
17
+ "capability": "edit_posts",
18
+ "data_storage": "options",
19
+ "post_id": "",
20
+ "autoload": 0,
21
+ "modified": 1704294791
22
+ }
@@ -0,0 +1,2 @@
1
+ @import '../../shared/styles/root';
2
+ @import '../../shared/styles/shared';
@@ -0,0 +1,23 @@
1
+ @import '../../shared/styles/lib';
2
+ @import '../../frontend/styles/root';
3
+ @import '../../frontend/styles/placeholders';
4
+
5
+ @mixin fix-editor-conflicts {
6
+ p {
7
+ // Reset font size and line-height for paragraphs
8
+ // (something else is setting it in backend)
9
+ font-size: inherit;
10
+ line-height: inherit;
11
+ }
12
+ }
13
+
14
+ :where(.acf-block-preview) {
15
+ /* stylelint-disable-next-line no-invalid-position-at-import-rule */
16
+ @import '../../frontend/styles/main';
17
+
18
+ // ! Theme body
19
+ @include theme-body-styles();
20
+
21
+ // ! Editor overrides
22
+ @include fix-editor-conflicts();
23
+ }
@@ -0,0 +1,3 @@
1
+ if (module.hot) {
2
+ module.hot.accept();
3
+ }
@@ -0,0 +1,3 @@
1
+ // ! Import main styles
2
+ @import 'main/reset';
3
+ @import 'main/body';
@@ -0,0 +1,3 @@
1
+ @import 'placeholders/sections';
2
+ @import 'placeholders/button';
3
+ @import 'placeholders/container';
@@ -0,0 +1,4 @@
1
+ // ! Imports that should be at the root/top of the styles
2
+ // ! These cannot be scoped under other selectors
3
+ @import 'root/fonts';
4
+ @import '../../shared/styles/root';
@@ -0,0 +1 @@
1
+ @import '../../shared/styles/lib';
@@ -0,0 +1,6 @@
1
+ // ! For variables and mixins, check the shared lib folder
2
+ @import '../../shared/styles/lib';
3
+ @import 'root';
4
+ @import '../../shared/styles/shared';
5
+ @import 'main';
6
+ @import 'placeholders';
@@ -0,0 +1,6 @@
1
+ @import '../../../shared/styles/lib';
2
+
3
+ body {
4
+ // ! Update the styles inside the mixin instead of adding them here! This will ensure editor previews look consistent.
5
+ @include theme-body-styles();
6
+ }
@@ -0,0 +1,121 @@
1
+ // ! This file is for global resets that are independent of project
2
+ @import '../../../shared/styles/lib';
3
+
4
+ * {
5
+ margin: 0;
6
+ }
7
+
8
+ *,
9
+ *::before,
10
+ *::after {
11
+ box-sizing: border-box;
12
+ }
13
+
14
+ body {
15
+ /* stylelint-disable-next-line plugin/no-unsupported-browser-features */
16
+ text-size-adjust: 100%;
17
+ -webkit-tap-highlight-color: transparent;
18
+ -webkit-font-smoothing: antialiased;
19
+ min-height: 100vh;
20
+ line-height: 1.4;
21
+ }
22
+
23
+ ul[role='list'],
24
+ ol[role='list'] {
25
+ list-style: none;
26
+ }
27
+
28
+ :where(h1, h2, h3, h4, button, input, label) {
29
+ line-height: 1.1;
30
+ }
31
+
32
+ p,
33
+ h1,
34
+ h2,
35
+ h3,
36
+ h4,
37
+ h5,
38
+ h6 {
39
+ overflow-wrap: break-word;
40
+ }
41
+
42
+ p {
43
+ text-wrap: pretty;
44
+ }
45
+
46
+ a:not([class]) {
47
+ text-decoration-skip-ink: auto;
48
+ color: currentcolor;
49
+ }
50
+
51
+ video,
52
+ canvas,
53
+ svg,
54
+ img,
55
+ picture {
56
+ max-width: 100%;
57
+ display: block;
58
+ }
59
+
60
+ img {
61
+ height: auto;
62
+ }
63
+
64
+ input,
65
+ button,
66
+ textarea,
67
+ select {
68
+ font-family: inherit;
69
+ font-size: inherit;
70
+ }
71
+
72
+ textarea {
73
+ /* stylelint-disable-next-line plugin/no-unsupported-browser-features */
74
+ resize: vertical;
75
+
76
+ &:not([rows]) {
77
+ min-height: 10em;
78
+ }
79
+ }
80
+
81
+ fieldset {
82
+ min-width: 0;
83
+ padding: 0;
84
+ border: 0;
85
+ }
86
+
87
+ b,
88
+ strong {
89
+ font-weight: bolder;
90
+ }
91
+
92
+ table {
93
+ caption-side: bottom;
94
+ border-collapse: collapse;
95
+ }
96
+
97
+ iframe {
98
+ border: 0;
99
+ }
100
+
101
+ label {
102
+ display: inline-block;
103
+ }
104
+
105
+ [type='search'] {
106
+ appearance: textfield;
107
+ outline-offset: -2px;
108
+ }
109
+
110
+ [hidden] {
111
+ display: none;
112
+ }
113
+
114
+ :target {
115
+ scroll-margin-block: 5ex;
116
+ }
117
+
118
+ ::placeholder {
119
+ color: inherit;
120
+ opacity: 1;
121
+ }
@@ -0,0 +1,43 @@
1
+ :root {
2
+ // Default
3
+ --afs-button-font-size: 1rem;
4
+ --afs-button-padding-x: 16px;
5
+ --afs-button-padding-y: 6px;
6
+ --afs-button-border-width: 1px;
7
+ --afs-button-border-style: solid;
8
+ --afs-button-border-color: #ccc;
9
+ --afs-button-border-color-hover: #3a3a3a;
10
+ --afs-button-border-radius: 4px;
11
+ --afs-button-text-color: #000;
12
+ --afs-button-text-color-hover: #fff;
13
+ --afs-button-background: #fff;
14
+ --afs-button-background-hover: #3a3a3a;
15
+
16
+ // Primary
17
+ --afs-button-primary-font-size: var(--afs-button-font-size);
18
+ --afs-button-primary-padding-x: var(--afs-button-padding-x);
19
+ --afs-button-primary-padding-y: var(--afs-button-padding-y);
20
+ --afs-button-primary-border-width: var(--afs-button-border-width);
21
+ --afs-button-primary-border-style: var(--afs-button-border-style);
22
+ --afs-button-primary-border-radius: var(--afs-button-border-radius);
23
+ --afs-button-primary-border-color: #a9b1b2;
24
+ --afs-button-primary-border-color-hover: #ccc;
25
+ --afs-button-primary-text-color: #000;
26
+ --afs-button-primary-text-color-hover: #000;
27
+ --afs-button-primary-background: #fff;
28
+ --afs-button-primary-background-hover: #ccc;
29
+
30
+ // Secondary
31
+ --afs-button-secondary-font-size: var(--afs-button-font-size);
32
+ --afs-button-secondary-padding-x: var(--afs-button-padding-x);
33
+ --afs-button-secondary-padding-y: var(--afs-button-padding-y);
34
+ --afs-button-secondary-border-width: var(--afs-button-border-width);
35
+ --afs-button-secondary-border-style: var(--afs-button-border-style);
36
+ --afs-button-secondary-border-radius: var(--afs-button-border-radius);
37
+ --afs-button-secondary-border-color: #30387d;
38
+ --afs-button-secondary-border-color-hover: #ccc;
39
+ --afs-button-secondary-text-color: #000;
40
+ --afs-button-secondary-text-color-hover: #000;
41
+ --afs-button-secondary-background: #fff;
42
+ --afs-button-secondary-background-hover: #ccc;
43
+ }
@@ -0,0 +1,12 @@
1
+ :root {
2
+ --afs-container-max-width: 1200px;
3
+ --afs-container-padding-x: 40px;
4
+ }
5
+
6
+ .container {
7
+ margin-inline: auto;
8
+ max-width: calc(
9
+ var(--afs-container-max-width) + var(--afs-container-padding-x)
10
+ );
11
+ padding-inline: calc(var(--afs-container-padding-x) * 0.5);
12
+ }
@@ -0,0 +1,6 @@
1
+ [style*='wp-block-airfleet-elements'],
2
+ section {
3
+ &:nth-child(odd) {
4
+ background-color: var(--afa-color-neutral-150);
5
+ }
6
+ }