Skip to content

Commit 9a6bc3a

Browse files
author
Teemu Suoranta
committed
add: rebranding, buttons module, configurable colors, finishing touches
1 parent 1c8db60 commit 9a6bc3a

File tree

184 files changed

+3343
-2954
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

184 files changed

+3343
-2954
lines changed

.jshintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@ gulpfile.js
22
node_modules/**
33
modules/*/node_modules/**
44
modules/*/assets/vendor/**
5+
modules/*/assets/*/vendor/**

404.php

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* @link https://codex.wordpress.org/Creating_an_Error_404_Page
66
*
7-
* @package aucor_starter
7+
* @package axio
88
*/
99

1010
get_header(); ?>
@@ -17,24 +17,25 @@
1717

1818
<div id="primary" class="primary primary--404">
1919

20-
<article class="entry entry--404">
20+
<article class="entry entry--404">
2121

22-
<div class="entry__content">
23-
<p><?php ask_e('404: Page not found description'); ?></p>
22+
<div class="entry__content blocks">
2423

25-
<?php if (class_exists('Aucor_Search_Form')) : ?>
26-
<?php
27-
Aucor_Search_Form::render([
28-
'attr' => [
29-
'class' => ['search-form--404'],
30-
],
31-
]);
32-
?>
33-
<?php endif; ?>
24+
<p><?php ask_e('404: Page not found description'); ?></p>
3425

35-
</div>
26+
<?php if (class_exists('X_Search_Form')) : ?>
27+
<?php
28+
X_Search_Form::render([
29+
'attr' => [
30+
'class' => ['search-form--404'],
31+
],
32+
]);
33+
?>
34+
<?php endif; ?>
3635

37-
</article>
36+
</div>
37+
38+
</article>
3839

3940
</div><!-- #primary -->
4041

README.md

Lines changed: 29 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
# Aucor Starter
1+
# Axio by Generaxion (previously Aucor Starter)
22

33
**🖥 For developer from developers:**
44

5-
Superior Gutenberg WordPress starter theme with modern build tools by **[Generaxion](https://www.generaxion.com)**. 200+ hours of development over 4 years to make the greatest starting point for WordPress site.
5+
Superior Gutenberg WordPress starter theme with modern build tools by **[Generaxion](https://www.generaxion.com)**. 250+ hours of development over 6 years to make the greatest starting point for WordPress site.
66

7-
**Demo:** **[starter.aucor.fi](https://starter.aucor.fi)**
7+
**Demo:** **[axio.generax.io](https://axio.generax.io)**
88

99
**🔌 Required plugins:**
1010

@@ -13,11 +13,9 @@ Superior Gutenberg WordPress starter theme with modern build tools by **[Generax
1313

1414
**🏷 Buzz-words**:
1515

16-
Gutenberg, Gulp, Yarn, SVG, SASS, Browsersync, a11y, l18n, Polylang, Schema.org, Native lazyload, BEM, Babel, Responsive images
16+
Gutenberg, Gulp, Yarn, SVG, SASS, Browsersync, a11y, l18n, Advanced Custom Fields, Polylang, Schema.org, Native lazyload, BEM, Babel, Responsive images
1717

18-
![aucor-starter](https://user-images.githubusercontent.com/9577084/75164116-f3dee180-5728-11ea-9eab-e2bfa89805cf.png)
19-
20-
![Google Chrome performance audit](https://user-images.githubusercontent.com/9577084/82218626-d8990200-9924-11ea-8060-263426cde897.png)
18+
![screenshot-axio-generaxion](https://user-images.githubusercontent.com/9577084/119238078-08d33c00-bb49-11eb-916f-770af029c75e.png)
2119

2220
## Table of contents
2321

@@ -87,17 +85,16 @@ Do these theme installation steps before modifying anything.
8785

8886
#### Run setup
8987

90-
![Project setup with setup.sh](https://user-images.githubusercontent.com/9577084/28662834-236bda4e-72c4-11e7-98db-67b25a289b4f.png)
88+
![Project setup with setup.sh](https://user-images.githubusercontent.com/9577084/119214675-40060680-bad1-11eb-9587-0f8d41f5c938.png)
9189

9290
Run setup wizard in theme root with bash `sh bin/setup.sh`
9391

9492
| **Field** | **Meaning** | **Default** |
9593
|---|---|---|
96-
| **Site name** | Name in style.css | `Aucor Starter` |
97-
| **Unique id** | Prefix and ID for code. Recommended length 1-5 characters. | `aucor_starter` |
98-
| **Local development url** | Browsersync's mirror URL. Stored at `/assets/manifest.js` | `https://aucor-starter.local` |
99-
| **Author name** | Author in style.css | `Aucor Oy` |
100-
| **Author URL** | Author URL in style.css | `https://www.aucor.fi` |
94+
| **Site name** | Name in style.css | `Axio by Generaxion` |
95+
| **Local development url** | Browsersync's mirror URL. Stored at `/assets/manifest.js` | `https://axio-starter.local` |
96+
| **Author name** | Author in style.css | `Generaxion` |
97+
| **Author URL** | Author URL in style.css | `https://www.generaxion.com` |
10198

10299
#### Run localizator (if needed)
103100

@@ -109,7 +106,7 @@ Theme strings are by default in English but we do support Finnish and probably S
109106

110107
#### Install Aucor Core
111108

112-
Some of the functionality of Aucor Starter require plugin Aucor Core. The plugin is centrally updated so that sites using starter will be easier to maintain and there will be less duplicate code from project to project. Aucor Starter won't have fatal errors without it, but for example localization won't work without it.
109+
Some of the functionality of Axio by Generaxion require plugin Aucor Core. The plugin is centrally updated so that sites using starter will be easier to maintain and there will be less duplicate code from project to project. Axio by Generaxion won't have fatal errors without it, but for example localization won't work without it.
113110

114111
Download Aucor Core from [WordPress.org](https://wordpress.org/plugins/aucor-core/) or [Github](https://github.com/aucor/aucor-core) and activate.
115112

@@ -160,15 +157,15 @@ Components get their power from abstract class Component that keeps in the struc
160157
There are two basic ways to use component:
161158

162159
```
163-
Aucor_Teaser::render();
164-
Aucor_Teaser::get();
160+
X_Teaser::render();
161+
X_Teaser::get();
165162
```
166163

167164
The render function prints out the HTML markup of the component and get will return it. You can pass arguments in an array like so:
168165

169166
```
170-
Aucor_Teaser::render(['id' => 123]);
171-
Aucor_Teaser::render([
167+
X_Teaser::render(['id' => 123]);
168+
X_Teaser::render([
172169
'id' => 123
173170
'hide_image' => true,
174171
]);
@@ -184,13 +181,13 @@ All components can be interacted with the same way. It is up to the component to
184181
* Component: Componet's name
185182
*
186183
* @example
187-
* Aucor_Components_Name::render([
184+
* X_Components_Name::render([
188185
* 'title' => 'Title',
189186
* 'description' => 'Descriptive text'
190187
* 'image' => 123
191188
* ]);
192189
*/
193-
class Aucor_Components_Name extends Aucor_Component {
190+
class X_Components_Name extends X_Component {
194191

195192
public static function frontend($data) {
196193
?>
@@ -199,7 +196,7 @@ class Aucor_Components_Name extends Aucor_Component {
199196
<?php if (!empty($data['image'])) : ?>
200197

201198
<div class="components-name__image">
202-
Aucor_Image::render([
199+
X_Image::render([
203200
'id' => $data['image'],
204201
'size' => 'large',
205202
]);
@@ -293,7 +290,7 @@ A few modules are required or there are more changes needed than just deleting t
293290
| `/svg/` | Yes | Component to display SVG sprite icons |
294291
| `/teaser/` | Yes | Component to display teaser cards |
295292
| `/background/` | - | Replacement for core/group block with background color, image or video options. |
296-
| `/button/` | - | Replacement for core/button block with ACF block and component. |
293+
| `/buttons/` | - | Replacement for core/buttons block with ACF block and component. |
297294
| `/core-columns/` | - | Gutenberg columns block |
298295
| `/core-embed/` | - | Gutenberg embed blocks |
299296
| `/core-gallery/` | - | Gutenberg gallery block |
@@ -603,7 +600,7 @@ Put all icons to `/assets/sprite/` and Gulp will combine and minify them into `/
603600
In PHP you can get these images with:
604601

605602
```php
606-
<?php Aucor_SVG::render([
603+
<?php X_SVG::render([
607604
'name' => 'facebook'
608605
]); ?>
609606
```
@@ -646,6 +643,7 @@ The `/inc/_conf/` directory has some essential settings for theme that you basic
646643

647644
* `register-assets.php` has all CSS and JS enqueues to templates as well as any arbitary code added to header or footer.
648645
* `register-blocks.php` defines which Gutenberg blocks are allowed. Notice that all blocks that are not defined here are not allowed and modules add their own blocks to the mix.
646+
* `register-colors.php` configure background colors to be available in blocks using backgrounds (background, media & text).
649647
* `register-image-sizes.php` register all global image sizes and responsive image sizes.
650648
* `register-localization.php` all global translatable strings for Polylang.
651649

@@ -655,13 +653,13 @@ Directory `/inc/helpers/`.
655653

656654
#### Dates
657655

658-
Function: `aucor_starter_get_posted_on()`
656+
Function: `x_get_posted_on()`
659657

660658
Get published date.
661659

662660
#### Hardcoded ids
663661

664-
Function: `aucor_starter_get_hardcoded_id($key)`
662+
Function: `x_get_hardcoded_id($key)`
665663

666664
Save all harcoded ids in one place in refer them through this function. Example:
667665

@@ -673,7 +671,7 @@ Save all harcoded ids in one place in refer them through this function. Example:
673671
*
674672
* @return int harcoded id
675673
*/
676-
function aucor_starter_get_hardcoded_id($key = '') {
674+
function x_get_hardcoded_id($key = '') {
677675
678676
switch ($key) {
679677
@@ -689,13 +687,13 @@ function aucor_starter_get_hardcoded_id($key = '') {
689687
```
690688

691689
Used in template:
692-
`aucor_starter_get_hardcoded_id('some-id')`
690+
`x_get_hardcoded_id('some-id')`
693691

694692
**Protip:** Avoid hardcoding ids if possible. If you really need to do it, centralize them into this function.
695693

696694
#### Last edited
697695

698-
Function: `aucor_starter_last_edited($asset)`
696+
Function: `x_last_edited($asset)`
699697

700698
Get last edited timestamp from asset files. Timestamps are saved in `/assets/last-edited.json`.
701699

@@ -787,14 +785,14 @@ Enqueue string to frontend with `wp_localize_script()`:
787785

788786
```php
789787
add_action('wp_enqueue_scripts', function() {
790-
wp_localize_script('aucor_starter-js', 'theme_strings_variable_name', [
788+
wp_localize_script('x-js', 'theme_strings_variable_name', [
791789
'prev' => ask__('Lightbox: Prev'),
792790
'next' => ask__('Lightbox: Next'),
793791
]);
794792
});
795793
```
796794

797-
This makes a global JS variable before given script id (here aucor_starter-js) and you can use string in JS:
795+
This makes a global JS variable before given script id (here x-js) and you can use string in JS:
798796

799797
```js
800798
console.log(theme_strings_variable_name.prev);
@@ -898,7 +896,7 @@ Gutenberg is the new default WordPress editor so it is not a great long term pla
898896

899897
#### Gutenberg styles
900898

901-
Aucor Starter includes default Gutenberg styles on front-end and overrides them with from theme. This makes a site more future-proof as Gutenberg will have breaking changes in future where some features will not work properly without correct styles (and default styles will take care of them to some degree). You may have to override some opinionated defaults, though.
899+
Axio by Generaxion includes default Gutenberg styles on front-end and overrides them with from theme. This makes a site more future-proof as Gutenberg will have breaking changes in future where some features will not work properly without correct styles (and default styles will take care of them to some degree). You may have to override some opinionated defaults, though.
902900

903901
In Gutenberg editor, there are still lots of default styles so there might be a few inconsistensies between front-end and back-end. This will get better in future versions of Gutenberg and starter.
904902

0 commit comments

Comments
 (0)