One place for hosting & domains

      Global

      Decoding WordPress: An Introduction to Global Styles


      WordPress blocks and Full-Site Editing (FSE) features make building and styling a successful website quick and easy.

      Global Styles can help you unify the appearance of your WordPress site without having to edit single blocks or pages. So whether you want to change your background color or adjust the heading typography, you’ll be able to make your modifications in a single place, resulting in a more cohesive and all-around better User Experience (UX).

      In this post, we’ll walk you through Global Styles. We’ll explain what they are, their benefits, and how the new features work. Then we’ll discuss how to use them to style your WordPress website. Let’s get started!

      An Overview of WordPress Global Styles

      Before working with Global Styles, it’s important to understand what they are and how they operate. This feature works in conjunction with theme.json, a new theme settings file. Developers can use theme.json to define defaults for a site as well as individual blocks. Gutenberg automatically applies this JSON when you place the file in the root directory of a block-based theme.

      This file is one of the most useful tools of the new full site editor in WordPress 5.9. The file lets theme authors share Global Styles as well as Global Settings. WordPress reformats the data taken from these JSON objects and turns it into CSS. Then users can further customize the styles in the WordPress editor.

      In previous iterations of the Gutenberg plugin, you had to register support for the style properties of a block before you were able to work with them in theme.json. Also, in classic themes and older versions, you had to use PHP to define things such as your color choices and fonts. Then you needed to add styles for the front and back end sides of your theme.

      However, with the latest release, when you use a theme with the theme.json file in place, WordPress automatically adds the styles defined there to your stylesheet. You can use this system to add entirely new color palettes, change the typography of themes, and more.

      Why Use WordPress Global Styles

      No matter your skill level, you’ll likely find using Global Styles an intuitive and accessible experience. Overall, it can streamline the web design process by making it easier to change the look and feel of your site. If you’re a WordPress beginner, taking advantage of these Global Styles may mean that you won’t need to hire a developer in order to design your website. Sorry, developers.

      On the flip side though, this new feature might be particularly useful for theme developers. That’s because Global Styles helps WordPress developers style blocks within the Block Editor. This can be highly advantageous, especially for new theme authors. It offers a variety of controls that minimize the need to create custom solutions for styling a site.

      In other words, Global Styles simplifies theme development to a great degree. As a result, it can help developers avoid damaging design mistakes.

      Skip the line and get tips right in your inbox

      Click below to sign up for more how-to’s and tutorials just like this one, delivered to your inbox.

      marketing tips

      Creating the theme.json File

      The theme.json file contains two important parts: settings and styles. Settings refer to a list of global or contextual configuration values that determine how the editor and blocks behave. For example, it influences which controls are enabled by default, which controls are hidden from the User Interface (UI), the available color palette, typography settings, etc.

      Styles handles the theme’s design language and enables theme authors to define elements such as:

      • Font size
      • Line height
      • Background colors
      • Link colors

      If you want to create a theme.json file, you can make a new file of that name and then place it inside the root folder of your theme. All the contents of your file should be inserted inside two curly brackets: { }.

      Next, you’ll use property names and values within double quotes and separated with a colon, for example:

      {
      
      "property-name": "value"
      
      }

      The property name can either be a setting or a block name. Below is an example of a very basic theme.json file:

      {
      
          "version": 1,
      
          "settings": {},
      
          "styles": {},
      
          "customTemplates": {},
      
          "templateParts": {}
      
      }

      Version 1 of the theme.json format is the earliest, most stable version. However, version 2 is used starting with WordPress 5.9. While the version section must be the first to follow the opening curly bracket, the subsequent sections can be placed in any order.

      As we mentioned, the two main sections of the file are Settings and Styles. So let’s have a closer look at the presets for each.

      Settings Presets

      Presets refer to the default controls as well as any custom CSS properties and are generated by the values in theme.json. Some of the main preset categories include:

      • Color
      • Typography
      • Layout
      • Spacing

      Categories can also have subcategories. For example, a subcategory of Color could be Color Palette:

      {
      
      "version": 2,
      
      "settings": {
      
      "color": {
      
      "palette": [
      
      {

      Each preset also creates a custom CSS property using the “–wp–preset–{preset-category}–{preset-slug}” naming convention.

      There are a ton of presets and examples that you can use to create your theme.json file, so we won’t go over all of them here. However, you can refer to the WordPress Handbook for more detailed guidance.

      Styles Presets

      Styles presets control the styles of objects within blocks. For example, the following would be a way to use the hex value for a background and a Global Styles preset for the text color:

      {
      
              "version": 2,
      
      "settings": { ... },
      
      "styles": {
      
      "color": {
      
      "background": "#FBF",
      
      "text": "var(--wp--preset--color--purple)"
      
      }
      
      }
      
      }

      If we wanted to change the heading color of a block, it would look similar to this:

      {
      
              "version": 2,
      
      "settings": {...},
      
      "styles": {
      
      ...,
      
                     "blocks": {
      
                   "core/heading": {
      
           "color": {
      
            "text": "var(--wp--preset--color--blue)"
      
           }

      Again, there are nearly infinite examples and ways to use presets for block styles. You can refer to WordPress documentation for a full breakdown.

      There are also Template and Template parts sections. These include the base files of your theme, such as index.html, as well as sections to organize and structure your theme.

      How to Style Your WordPress Site Using Global Styles

      If you’re looking for a beginner-friendly way to use Global Styles to style your website, you can use the Global Styles interface with a WordPress block theme. Note that you will only have access to the Styles interface with WordPress 5.9 or higher.

      Choosing a Block-Based Theme

      First, you’ll need a block-based theme. To find one, you can navigate to the WordPress Theme Directory from your admin dashboard by browsing to Appearance > Themes > Add New. Next, you can click on the Feature Filter and select Full Site Editing, followed by Apply:

      WordPress Full-Site Editing theme feature filter

      Once you find a WordPress theme you like, you can hover your mouse over it, then select Install followed by Activate. We’ll be using Twenty Twenty-Two, which may already be installed if you are using WordPress 5.9 or later.

      Accessing the Styles Interface

      Next, head over to your Theme Editor (Appearance > Editor). In the top right-hand corner of the screen, you’ll see a half-shaded circle, which represents the Styles panel:

      WordPress Global styles panel

      When you first click on it, it will present a Styles Welcome Guide. If you need access to this in the future, you can find it by clicking on the three vertical dots in the upper right-hand corner and selecting Welcome Guide.

      The preview window shows you how the current style of your theme looks. Under the Styles panel, you’ll find settings for:

      • Typography
      • Colors
      • Layout
      • Blocks

      Let’s take a closer look at each.

      Typography

      Under Typography, you can manage the typography settings for two elements: Text and Links.

      You can change the font family and size:

      WordPress Global Styles typography settings screen

      You can also adjust the line height and select a font-weight. You’ll have these same options for your links. When you’re done, remember to save your changes.

      Colors

      Under Colors, you’ll find the default color presets that come with your theme. To create your own color palettes, you can enter the HEX value numbers or use the drag-and-drop color picker to generate your preferred colors:

      WordPress Global Styles color settings

      You can also rename the colors to something more identifiable or descriptive than the standard hexadecimal alphanumeric values. You can add custom gradients, apply duo-tone filters to images, and more.

      Next, you can modify the colors for three main elements: Background, Text, and Links. You can also select any of these elements to customize the styling. The changes will be applied instantly as you are editing.

      Layout

      Under Layout, you can adjust padding and other elements. This is straightforward and can be very useful when you need to make a minor adjustment (for example, for the sake of page symmetry).

      Blocks

      Finally, you can change the appearance of individual blocks. After you select Blocks from the Styles panel, you’ll find a list of blocks on your site.

      Let’s say you wanted to change the style of your Heading block. You can select Heading from the list, then adjust its Colors and Typography settings:

      Styling options for the WordPress Heading block

      When you’re done, you can click on Save. If you ever want to revert back to the theme styles you had before making changes, you can navigate to the Styles panel, click on the three vertical dots, and then select Reset to defaults.

      A Better Way to Use and Style WordPress

      WordPress is continuously working to improve the editing experience for its users. Now, thanks to Global Styles, theme development has just become that much easier for both beginners and seasoned professionals.

      As discussed in this post, you can create a theme.json file to apply Global Styles configurations to your theme. You can also use the Styles editor with a block-based theme to customize the appearance of your site. All this makes designing a successful website a breeze.

      DreamHost is a team of experienced web experts. We understand the importance of optimizing your WordPress experience. We promise to support your efforts using the latest open-source tech and award-winning support. Check out our Managed WordPress hosting plans today to learn more!

      Do More with DreamPress

      DreamPress Plus and Pro users get access to Jetpack Professional (and 200+ premium themes) at no added cost!

      Managed WordPress Hosting - DreamPress



      Source link

      VIDEO: Skillshot Reaches Its Global Esports Audience with Network Solutions from INAP


      The proliferation of online servers and online streaming paved the way for esports to become a billion-dollar industry, enabling gamers to compete with users from around the world and legions of fans to watch along. Skillshot Media is at the forefront of this global gaming phenomenon, building this fast-growing community by hosting online and offline video game competitions for amateurs and pros alike. To support tournaments, global leagues and live arena events, Skillshot turns to INAP to deliver the exceptional infrastructure performance it requires to prevent game killing latency and lag. Check out the video below to learn why Skillshot is powered by INAP.

       

      “This competitive gaming phenomenon that used to be limited to your neighborhood arcade or couch is now played globally and watched globally, and that depends on exceptional performance,” said Todd Harris, Skillshot’s CEO. “When you’re playing a game, lag kills. Latency is your enemy. Having a partner that can deliver a product specific to the demanding gaming audience, that’s very important.”

      INAP helps Skillshot to combat latency and meet performance expectations, keeping their audience connected and in the game.

      “Performance can mean a lot of different things,” said INAP Solution Engineer David Heidgerken. “From a network standpoint, performance is low latency, low jitter, low packet loss. From an infrastructure perspective, INAP has servers across the globe so we can be where your users are.”

      “Often people just think of performance as speed, but it can be just making someone’s business better,” added Josh Williams, Vice President of Channel and Solutions Engineering. “As the games have evolved, as the technology has evolved, we’ve evolved with that. We’ve been able to adapt and support our customers in those gaming verticals. The core of our business has been letting the gaming publishers be able to focus on what they need to, and that’s that gaming experience, rather than having to worry about what’s going on on the back end.”

      Laura Vietmeyer


      READ MORE



      Source link

      INAP Executive Spotlight: Mary Jane Horne, SVP, Global Network Services


      In the INAP Executive Spotlight series, we interview senior leaders across the organization, hearing candid reflections about their careers, the mentors who shaped them and big lessons learned along the way.Mary Jane Horne headshot black and white

      Next in the series is Mary Jane Horne, SVP of Global Network Services. With over 25 years of network and operations experience, Horne currently oversees INAP’s network engineering, carrier management, and global support teams, and is responsible for these activities across INAP’s worldwide footprint.

      Horne shares the lessons she’s learned throughout her career, working in the technology, media and telecommunications industries in the U.S. and abroad. Read on to learn what she loves about her role in tech, and the advice that she has for those looking to progress along their career path.

      The interview has been lightly edited for clarity and length.

      How did you get started in network engineering? What inspired you to pursue it?

      Growing up, my dad was an engineer. I started out in college as a computer science major, but switched after my first year to engineering. I spent five years at Northeastern University in Boston studying electrical and computer engineering, and I worked for the federal government while in school.

      After graduation, I went to work for the phone company, and my first job was as a central office design engineer. I was given some of the best advice of my career by my first manager, which was to move around as much as I could at the “doer “level, to figure out how the company worked. I had 10 jobs in the 13 and a half years I worked there, with a variety of roles in field engineering, technical sales support, customer service and corporate development. I learned how interdependent everyone was, and how best to improve important processes.

      After deciding to change companies to a small fiber start up, I realized the most important part of any company is its foundation. In the roles I held there, we created the strategy for the company, built out the network, thought out of the box for customer solutions and drove sales from $100k in year one to $64.5M in year five. Here is where I truly embraced the role network plays in driving the success of the company.

      Can you tell us more about your work with the global network services team? What are some challenges with that part of the business?

      Our global network strategy started by going from metro to metro and grooming the network components (both fiber and lit services) which eliminated of a lot of unnecessary costs in running the network. We also lit an express 100-gig ring between 3 key data center locations (Dallas/NY/San Jose) to carry more of our own traffic on-net. We have, since the completion of these first 2 initiatives, been upgrading a majority of the US and trans-Atlantic backbones to 100gig as well, to provide much needed additional capacity. We’re deploying new state of the art technology from Ciena on the fiber and bandwidth we are purchasing, allowing us to provide scalability and redundancy, while giving us the opportunity to develop new products in the future. When all is said and done with these three initiatives, the network operating expenses are flat with what they were before, however, our capacity will be three times what it was in the old network.

      We also have the software side of the network. We have CDN, Performance IP®, Managed DNS, as well as other in-house tools supported by the team. They are continuously evaluating where we need to take these products in order to stay competitive, which may include partnering and white labeling. How do we get these products launched across this network that we are deploying and upgrading? Global network services is not just a foundation, but it’s also the product and services that ride across the network. We have infrastructure evolution, as well as product evolution, and that’s where I focus with the team.

      What do you love about your role in tech?

      Learning new things and trying new things is part of who I am. Because tech is ever changing, it’s always been very exciting for me. I think as tech has evolved, some people have fallen off the bandwagon since they don’t keep up with the latest and greatest trends.

      In tech, you must be a person who looks to the future. I look at what’s coming up, not just how I need to design a network for today, and what the customers need today, but what I need three years from now. What should I consider now to prepare for any changes that might come down the road? That’s one of the things that I’ve always been attracted to in the tech industry— looking far enough ahead to say, “I need to do this, but I don’t want to be shortsighted and do it the cheap way just to get done with today. I want to look at how to do it the best way, so we are ready for the future, and we can then move forward faster.” Tech gives me exciting opportunities to do that.

      Of the qualities you possess, which do you think has been the greatest influence on your success?

      The ability to try anything and rise to challenges, even when I have no idea what I’m doing. I credit my boss, Pete Aquino [INAP CEO], for challenging me over the course of our working relationship. He would say, “I have a need for X.” And I’d say, “I’ve never done that before.” He’d respond, “That’s fine. I know you’ll figure it out.”

      I have learned so much because I did things that I never would have done anywhere else in my career, because somebody trusted me to figure it out. The only thing you need to say to me is it’s impossible, or everyone else who tried couldn’t do it, because now I’m sure I’m going to get it done. I love a challenge. I think that’s driven me through my career.

      Who are some of the people that have mentored you in your career?

      Some of the best advice I’ve ever been given came from another other female leader in the industry. When I wanted to make that jump from being a manager to the next level, my boss at the time was a female director, and that was considered quite the accomplishment (back then) at a phone company. I said to her, “’I’m ready, I’m looking to move up. I’m really excited.” She gave me the second best piece of advice I’ve ever been given: Just because you are really good at what you do today, does not mean you ready for the next level. She pointed out, in order to be considered for the next level, you need to continuously demonstrate leadership qualities and focus on how you embrace and lead change.

      That was an eye opening, great piece of advice. That’s when I made some drastic changes and left the big stable environment to go to a risky startup, where you have to lead every day to be successful.

      If you had to pick a piece of advice that you’d give to someone pursuing IT or network engineering as a career path, what would that be?

      I just approved some training for people who want to learn more. Don’t be afraid to ask for that. Always stay current, always stay hungry, always learn as much as you can, and learn across platforms. It’ll make you more valuable.

      Also, tell your boss what you need and what you’re interested in. You must have open communication with your manager. We are not mind readers, so talk about what your plans might be, or ask for help in developing them. We are the ones who have to drive our own careers.

      Are there any other big lessons you’ve learned in your career that you want to share?

      I learned to take a step back and think about things in the big picture, instead of just what I’m doing today. What I decide to do today could affect what other people will be doing well into the future, especially in technology. Ask yourself, am I really making the right choice, or do I need to evaluate other options?

      I also believe we should cross-train people. At a minimum, I think we should have people sit in somebody else’s job for a week or two, and swap chairs. It gives employees appreciation for other roles and responsibilities that they may not truly understand or have misjudged. It also may help folks develop a path to pursue other roles in the future.

      I was lucky enough in my career to be able to move from department to department, so I could get a better view of how a company worked. You can’t always do that in smaller companies, but I think those are valuable lessons to learn. We should spend more time educating one another on how things work at INAP.

      Laura Vietmeyer


      READ MORE



      Source link