GithubHelp home page GithubHelp logo

default-small-business-theme's Introduction

Default Small Business Theme

This theme is designed to showcase what Gutenberg can do with regards to themes. It is intended as a work in progress, at least until v1 of the new editor (and maybe beyond).

Block focused

If something isn't a block yet, this theme will not have it. As each block happens, the theme will gain that functionality.

Styling just like Gutenberg

The idea of the default look for this theme is to as closely replicate that of the Gutenberg editor output as possible. As a result the focus is on that styling not creating a new look.. yet. As things grow, we may have styles and go further into what the theme can have... who knows.

default-small-business-theme's People

Contributors

alaczek avatar allancole avatar crunnells avatar danieldudzic avatar laurelfulford avatar mendezcode avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

default-small-business-theme's Issues

Change editor font enqueue from inline to an action hook

While poking around in the editor styles, I noticed that external font resources are being enqueued via @import from editor.css. A better, more portable solution, would be to enqueue it in functions.php via similar code:

/**
 * Gutenberg Editor Styles
 */
function business_theme_editor_styles() {
	wp_enqueue_style( 'business-theme-fonts', business_theme_fonts_url() );
	wp_enqueue_style( 'business-theme-editor-block-style', get_template_directory_uri() . '/editor.css' );
}
add_action( 'enqueue_block_editor_assets', 'business_theme_editor_styles' );

That should enqueue any external font resources that were defined in business_theme_fonts_url()

Create Menu UI for desktop and mobile

Desktop

Add a responsive menu UI. On desktop it may need to use a priority+ display so that the links always stay on one line.

desktop full width singular view
Desktop with dropdown:
desktop menu with dropdown

Mobile

Ideally the menu should be positioned at the bottom of the UI on mobile

mobile menu-1
mobile menu-2 swipe

Editor Styles: block boundaries overlap

When using the Gutenberg editor with the Business theme, block boundaries overlap each other, making some blocks (especially wrapper blocks like columns) almost impossible to select.

business-theme-editor

Option to hide homepage title - issues roundup.

I did some testing of this feature before deploying, and found some minor issues:

  • I'm seeing a space above the cover image, when it's the first element on the page
    image
    In general the space should not be there, if the first element of the content is an image, gallery, cover, or video.

  • If a page created with classic editor is used, there is not space above the first element
    image

  • I was wondering if we should change the option name from "Hide Front Page Title" to "Hide homepage Title", since in the select above it, it's called "Homepage"

cc @crunnells

"Cover Image" block renamed to "Cover"

The Cover image block was renamed to just "Cover", and all the classes with it. So .wp-block-cover-image is now just .wp-block-cover, and .wp-block-cover-image-text is now .wp-block-cover-text.

Add Option to Hide Home Page/Front Page Title

After talking to @ianstewart, @fditrapani, @michaeldcain and @davemart-in, we decided we needed the flexibility hide the home page/front page title on a site. This allows the customer more design flexibility.

We'd want to do this in a theme option, but we could put that setting in the Homepage Settings of the Customizer. This title would just be hidden off screen visually so as to not impact SEO or accessibility.

If we do that, there is potentially some CSS we'd want to adjust. See this video from @davemart-in: https://cl.ly/07f9d07ad8f4

cc: @alaczek

Editor styles: Redundant enqueuing of editor styles

I mentioned this during Business Elegant's review, but right now the editor styles are enqueued two different ways into the new block editor:

This method is standard, and I think a bit more predictable: https://github.com/Automattic/default-small-business-theme/blob/master/functions.php#L192-L199 It links the stylesheet, as is, to the page.

This method is actually intended for existing TinyMCE stylesheets in older themes (like Twenty Seventeen): https://github.com/Automattic/default-small-business-theme/blob/master/functions.php#L75-L76 So it's basically expecting stylesheets that only reference HTML elements (h1, table), and maybe some classes like .gallery.

The second method embeds the styles in the head of the page, prefixed with the class .editor-styles-wrapper. This makes these styles a lot more "powerful" and overridy than they would be enqueued in the first method. Because of that, when this is updated some careful testing will be needed, to make sure those styles still work as expected.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.