Planet Drupal

Subscribe to Planet Drupal feed
Drupal.org - aggregated feeds in category Planet Drupal
Updated: 9 hours 27 min ago

Drupal Association blog: Next Steps: Putting the Governance Task Force Recommendations into Action - Part 1

30 January 2019 - 5:40am

Towards the end of last year, the Governance Task Force concluded their six-month process and developed a list of thirteen recommendations for evolving Drupal's governance. This followed almost a year of efforts that engaged many stakeholders in the community to share thoughts on Drupal's governance model. Those recommendations were published in a blog, promoted by Dries, and made available in individual issues for community feedback.

We want to thank everyone for their participation in this process.

In particular we'd like to thank David, Ela, Stella, Lyndsey, Rachel, Hussain, and Adam as the leaders of the Governance Task Force.

I would also like to thank the many other community members who have been highly engaged in this process from start to finish. More than a hundred community members  attended community governance roundtables—both virtually and in person—or participated in one-on-one interviews, from across the globe.

Still more members of our community shared their voices in the issue queues, chat rooms, or discussions on these and other blog updates.

Finally, I want to thank all of the existing community bodies who have been crucial in bringing Drupal to this point, and will continue to be a fundamental part of our evolving governance. Groups like the CWG, the Core Maintainer Team, DD&I, the mentorship and contribution team, and a number of others play a critical role in our governance.

It reflects the tremendous care that everyone involved has for this community and a strong commitment to ensuring that this project continues to be a leader, not just in open source technology but also in open source community governance.

The next step is to put those recommendations into action. The Drupal Association is only one part of the community, and only one stakeholder in this effort, but there are a number of things we feel we can do to help move these recommendations forward.

In accordance with our values and principles, when evaluating potential actions, our goal is to identify immediate feasibility and prioritize impact. A number of the task force's recommendations are topics we can tackle very quickly, whereas others, like ones that require fundraising, may have a longer time horizon. Understand, this is not a commentary on the *importance* of any individual recommendation, but rather on which items can be executed quickly and which will take a more extended effort.

Part 1 of this series will focus on the immediate next steps that the Drupal Association can take to help support these recommendations. Part 2 will address the recommendations that will be an ongoing effort over the medium and long term.

Immediate next steps Grow the Community Working Group (CWG) to offer more support

There is already progress on the recommendation to "Grow the Community Working Group (CWG) to offer more support." Serendipitously, at the same time as the Governance Task Force recommendations were released, the Community Working Group submitted a proposal for a revised charter to Dries and the Drupal Association Board.

The revised charter included complementary changes in-line with the recommendations of the Governance Task Force. Perhaps most powerfully, the proposed changes included two key new elements:

  1. The CWG would switch from reporting to Dries himself to a subcommittee of the Drupal Association Board that consists of a three-member review panel: the two community elected board members and a third person external to the community. This leverages expertise from another open source project and offers a different perspective outside of Drupal.
  2. Providing support and resources for proactive initiatives to enable community health and support efforts. The CWG has long wanted to increase its ability to improve health and equity in our community and the DA can now support these activities.

This change also ensures that the Community Working Group has the appropriate legal and insurance support for its activities, clarifies the membership process, provides term limits for membership, and provides financial support for CWG activities.

The Board was pleased to receive this proposal from the Community Working Group, and voted to adopt the proposed changes in the Dec 5, 2018 board meeting. For more details, review the original proposal from the CWG here, as well as the official charter page which reflects the new updated charter.

Build a new community website to centralize communication and promote new opportunities

Another recommendation of the Governance Task Force that we are able to immediately act on is the recommendation to centralize communication and promote new opportunities for all aspects of the Drupal community. In particular this recommendation focuses on centralizing information about events across the globe, multilingual support, an improved home for regional groups and local associations, and community governance and support.

This recommendation aligns with one of the Drupal Association 2019 goals, which is to "Help the community follow the same path, by amplifying the voices of those who define that path." (For a little more context on our 2019 goals, check out our recent newsletter).

The task force specifically recommended a new dedicated community website, with functionality in many ways similar to an updated Groups.Drupal.org, as well as multilingual support and a strategy for coordinating community messaging and efforts. I'm pleased to report that this is an area in which the Drupal Association has already begun work. While our technical implementation will remain on Drupal.org, rather than as a separate sub-site, the proposed recommendations align closely with initiatives Association staff are working on right now.

Community Liaison Rachel Lawson has already worked with members of the community to create a new Drupal.org/Community portal. This initial change is just the first step: providing a pathway for various personas to find their way to the right part of the community to meet their interest and needs. As this is being written, we are also working on enhancements in line with the Governance Task Force recommendation: support for dedicated sections for key community bodies and providing collaboration tools similar to those that were first put in place for groups.drupal.org many years ago, but enhanced for our current needs.

Expect to hear more about these changes soon.

In the meantime, if you belong to a working group or similar, Rachel Lawson would like to speak with you about making space for your use on Drupal.org/community.

A glossary of key community terms, in clear, translatable language

The Drupal community has a long history as one of the largest and most closely knit communities in open source. On the whole, this has been tremendously positive, and is something for us to take great pride in, but the Governance Task Force rightly recognized a key concern that this creates: it does not scale. A lot of the language we use to describe our community, our leadership, and our governance is undefined or taken for granted. Even for longtime very engaged members there is no guarantee that our personal understandings of key community terms are shared.

Fortunately, we should be able to improve our collective understanding of what these critical terms mean. By assembling an engaged group of community members, DA staff, and existing project leaders we should be able to create an initial glossary of this key community language, and with the help of regional leaders in our global community, ensure that the language is clear and easily translatable.

If you would like to participate in this effort, you can do so in this issue.

Improving collaboration/understanding between the Drupal Association and community

This is another of the Governance Task Force recommendations that can both receive immediate action, but will also always be an ongoing process of iteration and improvement. The recommendation to improve the ways that the Drupal Association collaborates with the community, and in turn to improve the community's understanding of the Drupal Association's work, is a critical one. As the interim Executive Director at the Association and 13-year community member, this is also work very close to my heart.  

There are many steps we can take to move this recommendation forward, but a few of the ones we've taken in the last months or are planning to take in the new year include:

Lastly, here at the Association we can and should continue to strive toward communicating the existing ways we serve the community, many of which could help to support recommendations of the Governance Task Force. For example, when Kevin Thull recently announced the unofficial Drupal recording initiative, it had not occurred to him to consider applying for the Community Cultivation Grant program. This was eye-opening for us, because if it does not occur to even a highly engaged community member like Kevin to apply for a grant, how can we expect others to be aware of the opportunity?

By publicizing Kevin's story, and those of others who have participated in these programs, we encourage others to apply for these opportunities. The pool of funding for these programs is not unlimited, but we certainly encourage community members to apply.

Just the beginning

Acting on these first recommendations is only the beginning. In part 2 we'll address the additional recommendations of the Governance Task Force, and in particular how the Drupal Association can support these more medium and long term efforts. The work of evolving Drupal's governance will be a continuous process, and the Drupal Association is only one stakeholder in the outcome, but by working together with the community we believe we can take significant strides in this direction.

Categories: Drupal

OSTraining: How to Build Drupal Slideshow Using Views and Slick

30 January 2019 - 4:20am

One of our OSTraining members asked how it was possible to make multiple displays for Drupal 8 slideshows.

In this tutorial, I will show you how to build a slideshow that uses your article content type to make a slideshow with a teaser.

Categories: Drupal

Drupal Atlanta Medium Publication: How to Ignore Local Changes to Your settings.php File in Drupal 8 with Git

30 January 2019 - 2:40am
Why not just use the .gitignore file?Photo by Tim Wright on Unsplash

As many of you know, I am a huge Pantheon hosting fanboy and can still remember the days during the beta launch of being blown away that I have three different environments out of the box, with dev, test and live. Another great service they added recently is that all sites receive SSL certificates automatically and all you have to do is redirect all traffic to use HTTPS. In Drupal 8 they suggest doing this in your settings.php file.

After adding the redirect code everything works great until you fire up your local environment (I am currently using Lando) and you are getting a blank screen. After further investigation, you notice it’s the redirect to HTTPS that is causing the issue. My first thought was to make sure my settings.local.php file was correctly being used but for the life of me, I could not get that file to override the redirect code in my settings.php file. If you are reading this and have a better idea on to how to accomplish this then let me know in the comments :)

My next thought was to simply add the settings.php file to my .gitignore file but when I went to my production website I was prompted to reinstall my Drupal site. When adding a file to .gitignore the repo pretends it doesn’t exist so therefore Drupal was telling me to reinstall. Whoooops, my production site kind of needs this file hahahah. So I thought to myself,

How can I ignore my settings.php file in my local repo but still have the original file on production?

After attending Google University for 10 minutes, I stumbled upon a medium post by Ian Gloude regarding the git update-index command. In their article “Git skip-worktree and how I used to hate config files,” there is a great explanation of the concept, but for me the lightbulb really went off when reading the Git documentation hint, “see also git-add[1] for a more user-friendly way to do some of the most common operations on the index.” Basically git update-index tells Git what to watch in your repo.

Now that we understand what git update-index does, the real magic happens with the options that you can add to the command. In this case, the option that Ian Gloude suggested is the --skip-worktreeoption. The Git documentation explains that the skip worktree bit tells the git index to assume the file is unchanged from this point on regardless if there is an actual change. So what does this mean for us? It means you can change your file on your local environment while the original file on your production server remains unchanged.

Here is the command I use prior to uncommenting out the pantheon redirect code.

git update-index --skip-worktree /sites/default/settings.php

When I need to make some changes to the production settings.php file I can tell Git to watch the file again with this command.

git update-index —-no-skip-worktree web/sites/default/settings.php

Anyway, I hope this helps you keep your local and production environments running smoothly while maintaining your settings differently.

If you are interested in contributing a blog post or want to get more involved with the Atlanta Drupal Users Group (ADUG) please feel free to reach out info@drupalatlanta.org

How to Ignore Local Changes to Your settings.php File in Drupal 8 with Git was originally published in Drupal Atlanta on Medium, where people are continuing the conversation by highlighting and responding to this story.

Categories: Drupal

Flocon de toile | Freelance Drupal: Switch an existing Drupal 8 project under composer

30 January 2019 - 2:04am

Composer has become a must for relatively ambitious Drupal 8 projects. Even if it is still possible to initialize a Drupal 8 project with drush or simply by downloading a zip archive, these two methods can become limiting over time. Or at least not to facilitate the installation of new modules with dependencies on third-party libraries.

Another of the reasons I have encountered, why some Drupal 8 projects have not been initiated by Composer, is the lack of Composer support on some shared hosting, even so-called professional ones.

Categories: Drupal

Agiledrop.com Blog: The Story of Agiledrop: Cultivating Strong Relationships with Clients

30 January 2019 - 1:40am

We've started a series of blog posts that tell the story of what makes our developers successful when working with other Drupal teams. The third chapter analyzes the steps we take to form and maintain a strong, healthy relationship with our clients.

READ MORE
Categories: Drupal

Drupixels: Resolve Drupal error: unable to unlink old 'sites/default/settings.php': Permission denied

29 January 2019 - 10:01pm
Everything was going well with your Drupal setup on local and then GIT STRICKS BACK. You are trying to do a git checkout and moving to a different branch but now you have an error of GIT not able to unlink file and a modified file.
Categories: Drupal

OSTraining: How to Pin Images in Drupal 8

29 January 2019 - 7:06pm

The "Imagepin" module allows you to create pins inside an image and display descriptive text when you hover over those pins.

This is useful because the image will not appear clogged with lots of descriptive text. From the other hand, since users like (unconsciously) this kind of interaction, it will help promote your content and increase the click rate of the “calls to action” of your page.

Categories: Drupal

Electric Citizen: Spring conference updates

29 January 2019 - 12:42pm

We're in the deep of winter in Minneapolis, but thinking about spring and the upcoming conferences we'll be attending. Or at least later this winter.

Here's a short list of what we've got scheduled so far, and where we could meet up.

Categories: Drupal

Nextide Blog: Innovating Healthcare with Drupal

29 January 2019 - 10:14am

Innovation within Canadian healthcare continues to provide better care experiences for those using the system.  As the population ages and strains our facilities to care for those nearing their end-of-life, hospitals are looking at technological solutions to ease the burden on emergency rooms and give people access to accurate and timely healthcare.   Nextide partnered with uCarenet, a Toronto-based e-health company, to create an innovative health and wellness application to monitor the condition of palliative care patients for a major Canadian hospital.

 

Categories: Drupal

Drupal blog: European Commission will start offering bug bounties for Open Source software

29 January 2019 - 9:39am

This blog has been re-posted and edited with permission from Dries Buytaert's blog.

The European Commission worked with the Drupal Security Team to set aside 89,000€ (or roughly $100,000 USD) for a Drupal bug bounty.

The European Commission made an exciting announcement; it will be awarding bug bounties to the security teams of Open Source software projects that the European Commission relies on.

If you are not familiar with the term, a bug bounty is a monetary prize awarded to people who discover and correctly report security issues.

Julia Reda — an internet activist, Member of the European Parliament (MEP) and co-founder of the Free and Open Source Software Audit (FOSSA) project — wrote the following on her blog:

Like many other organizations, institutions like the European Parliament, the Council and the Commission build upon Free Software to run their websites and many other things. But the Internet is not only crucial to our economy and our administration, it is the infrastructure that runs our everyday lives.

With more than 150 Drupal sites, the European Commission is a big Drupal user, and has a large internal Drupal community. The European Commission set aside 89,000€ (or roughly $100,000 USD) for a Drupal bug bounty. They worked closely with Drupal's Security Team to set this up. To participate in the Drupal bug bounty, read the guidelines provided by Drupal's Security Team.

Over the years I've had many meetings with the European Commission, presented keynotes at some of its events, and more. During that time, I've seen the European Commission evolve from being hesitant about Open Source, to recognizing the many benefits that Open Source provides for its key ICT services, to truly embracing Open Source.

In many ways, the European Commission followed classic Open Source adoption patterns; adoption went from being technology-led (bottom-up or grassroots) to policy-led (top-down and institutionalized), and now the EU is an active participant and contributor.

Today, the European Commission is a shining example and role model for how governments and other large organizations can contribute to Open Source (just like how the White House used to be).

The European Commission is actually investing in Drupal in a variety of ways — the bug bounty is just one example of that — but more about that in a future blog post.

 January 28, 2019

 1 min read time

 Permalink

Categories: Drupal

Agaric Collective: Agaric 2018 Year in Review - Expanding the Open Web, Building the Solidarity Economy

29 January 2019 - 7:13am

As it was for much of the world, 2018 was a combination of extremes for Agaric and the free and open web. Happily, we expanded our team, launched new sites, and empowered our clients through libre software. Unhappily, many of us and our communities endured health issues, political instability, and the effects of climate change.

For the open web, we disappointedly saw the United States officially end Net Neutrality while we excitedly watched the European Union begin enforcing comprehensive privacy laws with its General Data Protection Regulation. We were disgusted by tech giants like Facebook and Palantir diverting and deflecting from the abuses they carry out, but we were also inspired by workers at companies like Amazon and Google forcing their bosses to do better.

In looking back, we celebrate the victories and learn from the challenges—with our eyes set on serving our clients better, expanding the open web, and building an economy based on solidarity rather than exploitation.

To that end, here are the highlights of our work from last year and our intentions for the new year.

Read more and discuss at agaric.coop.

Categories: Drupal

Dries Buytaert: Acquia retrospective 2018

29 January 2019 - 6:06am

Every year, I sit down to write my annual Acquia retrospective. It's a rewarding exercise, because it allows me to reflect on how much progress Acquia has made in the past 12 months.

Overall, Acquia had an excellent 2018. I believe we are a much stronger company than we were a year ago; not only because of our financial results, but because of our commitment to strengthen our product and engineering teams.

If you'd like to read my previous retrospectives, they can be found here: 2017,2016, 2015, 2014, 2013, 2012, 2011, 2010, 2009. This year marks the publishing of my tenth retrospective. When read together, these posts provide a comprehensive overview of Acquia's growth and trajectory.

Updating our brand to best reflect our vision

Exiting 2017, Acquia doubled down on our transition from website management to digital experience management. In 2018, we updated our product positioning and brand narrative to reflect this change. This included a new Acquia Experience Platform diagram:

The Acquia Platform is divided into two key parts: the Experience Factory and the Marketing Hub. Drupal and Acquia Lightning power every side of the experience. The Acquia Platform supports our customers throughout the entire life cycle of a digital experience — from building to operating and optimizing digital experiences.

In 2018, the Acquia marketing team also worked hard to update Acquia's brand. The result is a refreshed look and updated brand positioning that better reflects our vision, culture, and the value we offer our customers. This included updating our tagline to read: Experience Digital Freedom.

I think Acquia's updated brand looks great, and it's been exciting to see it come to life. From highway billboards to Acquia Engage in Austin, our updated brand has been very well received.

When Acquia Engage attendees arrived at the Austin-Bergstrom International Airport for Acquia Engage 2018, they were greeted by an Acquia display.Business momentum

This year, Acquia surpassed $200 million in annualized revenue. Overall new subscription bookings grew 33 percent year over year, and we ended the year with nearly 900 employees.

Mike Sullivan completed his first year as Acquia's CEO, and demonstrated a strong focus on improving Acquia's business fundamentals across operational efficiency, gross margins, and cost optimization. The results have been tangible, as Acquia has realized unprecedented financial growth in 2018:

  • Channel-partner bookings grew 52 percent
  • EMEA-based bookings grew 103 percent
  • Gross profit grew 39 percent
  • Adjusted EBITDA grew 78 percent
  • Free cash flow grew 84 percent
2018 was a record year for Acquia. Year-over-year highlights include new subscription bookings, EMEA-based bookings, free cash flow, and more.International growth and expansion

In 2018, Acquia also witnessed unprecedented success in Europe and Asia, as new bookings in EMEA were up more than 100 percent. This included expanding our European headquarters to a new and larger space with a ribbon-cutting ceremony with the mayor of Reading in the U.K.

Acquia also expanded its presence in Asia Pacific, and opened Tokyo-based operations in 2018. Over the past few years I visited Japan twice, and I'm excited for the opportunities that doing business in Japan offers.

We selected Pune as the location for our new India office, and we are in the process of hiring our first Pune-based engineers.

Acquia now has four offices in the Asia Pacific region serving customers like Astellas Pharmaceuticals, Muji, Mediacorp, and Brisbane City Council.

Acquia product information, translated into Japanese.Acquia Engage

In 2018, we welcomed more than 650 attendees to Austin, Texas, for our annual customer conference, Acquia Engage. In June, we also held our first Acquia Engage Europe and welcomed 300 attendees.

Our Engage conferences included presentations from customers like Paychex, NBC Sports, Wendy's, West Corporation, General Electric, Charles Schwab, Pac-12 Networks, Blue Cross Blue Shield, Bayer, Virgin Sport, and more. We also featured keynote presentations from our partner network, including VMLY&R, Accenture Interactive, IBM iX and MRM//McCann.

Both customers and partners continue to be the most important driver of Acquia's product strategy, and it's always rewarding to hear about this success first hand. In fact, 2018 customer satisfaction levels remain extremely high at 94 percent.

Partner program

Finally, Acquia's partner network continues to become more sophisticated. In the second half of 2018, we right sized our partner community from 2,270 firms to 226. This was a bold move, but our goal was to place a renewed focus on the partners who were both committed to Acquia and highly capable. As a result, we saw almost 52 percent year-over-year growth in partner-sourced ACV bookings. This is meaningful because for every $1 Acquia books in collaboration with a partner, our partner makes about $5 in services revenue.

Analyst recognition

In 2018, the top industry analysts published very positive reviews about Acquia. I'm proud that Acquia was recognized by Forrester Research as the leader for strategy and vision in The Forrester Wave: Web Content Management Systems, Q4 2018. Acquia was also named a leader in the 2018 Gartner Magic Quadrant for Web Content Management, marking our placement as a leader for the fifth year in a row.

Product milestones Acquia's product evolution between 2008 and 2018. When Acquia was founded, our mission was to provide commercial support for Drupal and to be the "Red Hat for Drupal"; 12 years later, the Acquia Platform helps organizations build, operate and optimize Drupal-based experiences.

2018 was one of the busiest years I have experienced; it was full of non-stop action every day. My biggest focus was working with Acquia's product and engineering team. We focused on growing and improving our R&D organization, modernizing Acquia Cloud, becoming user-experience first, redesigning the Acquia Lift user experience, working on headless Drupal, making Drupal easier to use, and expanding our commerce strategy.

Hiring, hiring, hiring

In partnership with Mike, we decided to increase the capacity of our research and development team by 60 percent. At the close of 2018, we were able to increase the capacity of our research and development team by 45 percent percent. We will continue to invest in growing our our R&D team in 2019.

I spent a lot of our time restructuring, improving and scaling the product organization to make sure we could handle the increased capacity and build out a world-class R&D organization.

As the year progressed, R&D capacity increasingly came online and our ability to innovate not only improved but accelerated significantly. We entered 2019 in a much better position, as we now have a lot more capacity to innovate.

Acquia Cloud

Acquia Cloud and Acquia Cloud Site Factory support some of the largest and most mission-critical websites in the world. The scope and complexity that Acquia Cloud and Acquia Cloud Site Factory manages is enormous. We easily deliver more than 30 billion page views a month (excluding CDN).

Over the course of 10 years, the Acquia Cloud codebase had grown very large. Updating, testing and launching new releases took a long time because we had one large, monolithic codebase. This was something we needed to change in order to add new features faster.

Over the course of 2018, the engineering team broke the monolithic codebase down into discrete components that can be tested and released independently. We launched our component-based architecture in June. Since then, the engineering team has released changes to production 650 times, compared to our historic pace of doing one release per quarter.

This graph shows how we moved Acquia Cloud from a monolithic code base to a component-based code base. Each color on the graph represents a component. The graph shows how releases of Acquia Cloud (and the individual components in particular) have accelerated in the second half of the year.

Planning and designing for all of these services took a lot of time and focus, and was a large priority for the entire engineering team (including me). The fruits of these efforts will start to become more publicly visible in 2019. I'm excited to share more with you in future blog posts.

Acquia Cloud also remains the most secure and compliant cloud for Drupal. As we were componentizing the Acquia Cloud platform, the requirements to maintain our FedRAMP compliance became much more stringent. In April, the GDPR deadline was also nearing. Executing on hundreds of FedRAMP- and GDPR-related tasks emerged as another critical priority for many of our product and engineering teams. I'm proud that the team succeeded in accomplishing this amid all the other changes we were making.

Customer experience first

Over the years, I've felt Acquia lacked a focus on user experience (UX) for both developers and marketers. As a result, increasing the capacity of our R&D team included doubling the size of the UX team.

We've stepped up our UX research to better understand the needs and challenges of those who use Acquia products. We've begun to employ design-first methodologies, such as design sprints and a lean-UX approach. We've also created roles for customer experience designers, so that we're looking at the full customer journey rather than just our product interfaces.

With the extra capacity and data-driven changes in place, we've been working hard on updating the user experience for the entire Acquia Experience Platform. For example, you can see a preview of our new Acquia Lift product in this video, which has an increased focus on UX:

Drupal

In 2018, Drupal 8 adoption kept growing and Drupal also saw an increase in the number of community contributions and contributors, both from individuals and from organizations.

Acquia remains very committed to Drupal, and was the largest contributor to the project in 2018. We now have more than 15 employees who contribute to Drupal full time, in addition to many others that contribute periodically. In 2018, the Drupal team's main areas of focus have been Layout Builder and the API-first initiative:

  • Layout Builder: Layout Builder offers content authors an easy-to-use page building experience. It's shaping up to be one of the most useful and pervasive features ever added to Drupal because it redefines the how editors control the appearance of their content without having to rely on a developer.
  • API First: This initiative has given Drupal a true best-in-class web services API for using Drupal as a headless content management system. Headless Drupal is one of the fastest growing segments of Drupal implementations.
Our R&D team gathered in Boston for our annual Build Week in June 2018.Content and Commerce

Adobe's acquisition of Magento has been very positive for us; we're now the largest commerce-agnostic content management company to partner with. As a result, we decided to extend our investments in headless commerce and set up partnerships with Elastic Path and BigCommerce. The momentum we've seen from these partnerships in a short amount of time is promising for 2019.

The market continues to move in Acquia's direction

In 2019, I believe Acquia will continue to be positioned for long-term growth. Here are a few reasons why:

  • The current markets for content and digital experience management continues to grow rapidly, at approximately 20 percent per year.
  • Digital transformation is top-of-mind for all organizations, and impacts all elements of their business and value chain.
  • Open source adoption continues to grow at a furious pace and has seen tremendous business success in 2018.
  • Cloud adoption continues to grow. Unlike most of our CMS competitors, Acquia was born in the cloud.
  • Drupal and Acquia are leaders in headless and decoupled content management, which is a fast growing segment of our market.
  • Conversational interfaces and augmented reality continues to grow, and we embraced these channels a few years ago. Acquia Labs, our research and innovation lab, explored how organizations can use conversational UIs to develop beyond-the-browser experiences, like cooking with Alexa, and voice-enabled search for customers like Purina.

Although we hold a leadership position in our market, our relative market share is small. These trends mean that we should have plenty of opportunity to grow in 2019 and beyond.

Thank you

While 2018 was an incredibly busy year, it was also very rewarding. I have a strong sense of gratitude, and admire every Acquian's relentless determination and commitment to improve. As always, none of these results and milestones would be possible without the hard work of the Acquia team, our customers, partners, the Drupal community, and our many friends.

I've always been pretty transparent about our trajectory (e.g. Acquia 2009 roadmap and Acquia 2017 strategy) and will continue to do so in 2019. We have some big plans for 2019, and I'm excited to share them with you. If you want to get notified about what we have in store, you can subscribe to my blog at https://dri.es/subscribe.

Thank you for your support in 2018!

Categories: Drupal

ThinkShout: Unlocking the Mystery of Custom Twig Functions

29 January 2019 - 4:00am

When Drupal 8 came out, it introduced the Drupal community to the concept of separating the theming layer from the logic layer through the Twig templating language. This had many advantages. For one, instead of needing to know PHP, a themer could just know Twig – an extremely stripped-down templating engine that has a few syntax elements, minimal built-in operators, and only about 50 provided functions. Additionally, the limited list of available functions makes it much harder to shoehorn heavy logic or even more dangerous things like SQL queries directly into the theming layer.

There are, of course, trade-offs. While the list of functions Twig provides is quite robust, it didn’t take long for Drupal developers to recognize snippets of code they needed to do over and over again within their templates. As such, Drupal provided a handful of custom functions and filters specific to core functionality, like the ‘without’ filter, which “Removes child elements from a copy of the original array” – i.e. lets you print the contents of a render array without certain fields.

The contrib space provides even more options for Twig themers – modules like Twig Tweak or Twig Field Value provides additional functions and filters for things themers often need to do over and over, like render a block within a template, or grab a field’s raw value.

But sometimes you still find yourself repeating the same code over and over within your templates. Maybe it’s a bit of logic specific to the project you’re working on. Or maybe it’s a piece of code that needs logic too complex to be put in a template. Or maybe it requires context not easily accessible within the template, like a setting controlled in the Drupal admin area.

In these cases you can create your own custom Twig functions.

What you’ll need:

Creating a custom Twig filter is relatively simple. You’ll just need the following things to begin:

  • A custom module you can add code to
  • A service declaration .yml file with reference to the twig.extension tag
  • A class that extends the \Twig_Extension class

If you have those things, you can create as many Twig filters or functions as you’d like from within one class file. Making the filters or functions available is just one cache clear away!

A practical example:

Note, the finished module created below is also available here.

Let’s say you want to print out a field label within a template. For example, the default Drupal 8 Article display shows the label for the Tags field:

Let’s say we also, for some reason, wanted to put the “Tags” label somewhere else on the page, like right under the node’s “Submitted” information. Out of the box, you can use Twig to get the label’s raw value if you’re extending your node.twig.html file:

{{ content.field_tags['#title'] }}

That works!

Now, suppose a site builder decides they don’t want to show the label on the Tags field anymore. They go into the admin area, change the field value on the label from “Above” to “Hidden”, and reload the entity.

If you’re using the Twig Field Value module and use this syntax:

{{ content.field_tags|field_label }}

The same thing happens. That’s because the field_label function doesn’t take into account the settings on the admin side either.

If we want to print out a label in a custom place, but still have the label respect the admin settings, we can create our own Twig function. Building on the idea of the Twig Field Value module’s filter “field_label” filter, let’s call our custom function “field_respectful_label”.

As outlined above, first you need to create a service. The quickest way to do this is using the Drupal console “generate:service” command.

Let’s assume you’ve already got a module called “custom_twig”. The command to generate this service would look like this:

$ drupal generate:service // Welcome to the Drupal service generator Enter the module name [address]: > custom_twig Enter the service name [custom_twig.default]: > custom_twig.my_custom_twig_items Enter the Class name [DefaultService]: > MyCustomTwigItems Create an interface (yes/no) [yes]: > no Do you want to load services from the container? (yes/no) [no]: > no Enter the path for the services [/modules/custom/custom_twig/src/]: > Do you want proceed with the operation? (yes/no) [yes]: > // cache:rebuild Rebuilding cache(s), wait a moment please. [OK] Done clearing cache(s). Generated or updated files 1 - modules/custom/custom_twig/custom_twig.services.yml 2 - modules/custom/custom_twig/src/MyCustomTwigItems.php

This creates two files. The custom_twig.services.yml file:

services: custom_twig.my_custom_twig_items: class: Drupal\custom_twig\MyCustomTwigItems arguments: []

And the MyCustomTwigItems php file:

<?php namespace Drupal\custom_twig; /** * Class MyCustomTwigItems. */ class MyCustomTwigItems { /** * Constructs a new MyCustomTwigItems object. */ public function __construct() { } }

We now need to alter these files slightly. For the services.yml file, we will need to remove the “arguments” line, and add a reference to the twig extension tag:

services: custom_twig.my_custom_twig_items: class: Drupal\custom_twig\MyCustomTwigItems tags: - { name: twig.extension }

In the MyCustomTwigItems.php file, we can make a few changes as well. First, the MyCustomTwigItems class must extend the \Twig_Extension class. We can also get rid of the constructor, which leaves you with a very bare class declaration:

/** * Class MyCustomTwigItems. */ class MyCustomTwigItems extends \Twig_Extension { }

You now have a skeleton service in place, but it’s currently not doing anything. To let Twig know about a new Twig filter, you implement the “getFilters” method on this class:

/** * {@inheritdoc} */ public function getFilters() { return [ new \Twig_SimpleFilter('field_respectful_label', [$this, 'getRespectfulFieldLabel']), ]; }

The syntax above links up the string “field_respectful_label” (which will be used in our twig templates) to the method “getRespectfulFieldLabel”, a function we’ll create within our current MyCustomTwigItems class. Note that this syntax means you can call your custom filter whatever you want, although you will want to stick to the accepted coding style for Twig functions (lowercase letters and underscores, aka snake_case) and Drupal class methods (lowerCamelCase). Also notice that here we’re extending the “getFilters()” method on the parent class. There’s also a “getFunctions()” method, which is how you’d define a function. For more on the difference between Filters and Functions in Twig, refer to the Extending Twig documentation.

Then you just write your custom method! Here’s the full code for the getRespectfulFieldLabel method, which you’d place anywhere within the MyCustomTwigItems class declaration:

/** * Twig filter callback: Only return a field's label if not hidden. * * @param array $build * Render array of a field. * * @return string * The label of a field. If $build is not a render array of a field, NULL is * returned. */ public function getRespectfulFieldLabel(array $build) { // Only proceed if this is a renderable field array. if (isset($build['#theme']) && $build['#theme'] == 'field') { // Find out the label value. $disrespectful_label = isset($build['#title']) ? $build['#title'] : NULL; // Find out the visibility status of the label. $display_label = isset($build['#label_display']) ? ($build['#label_display'] != 'hidden') : FALSE; return ($disrespectful_label && $display_label) ? $disrespectful_label : NULL; } return NULL; }

If we now use our custom twig filter in the node.html.twig file, the label behaves as expected:

{{ content.field_tags|field_respectful_label }}

There is now no label showing up on the front end, because we’ve hidden the label in the backend. If I went and changed the label visibility setting to “Above”, the label does show up. No code changes required:

And with that you have a new, custom Twig filter.

In conclusion, I hope this article demystifies the functions and filters you can use with Twig in Drupal 8. And if you’re inspired, feel free to use the example code as a starting point for your own custom functions or filters.

Categories: Drupal

Evolving Web: Insights Into the New Design of the Drupal Admin UI

28 January 2019 - 9:54pm

We at Evolving Web are really excited to see the progress being made on improving the Drupal admin UI. As a designer, I’m curious about the process that drives such a huge project. I talked to the designer in charge of the refreshed interface, Cristina Chumillas, and got super interesting insights into what’s behind the new design.
 

Claro – fresh and clear

So far, Cristina and the team developed a new theme which is called “Claro”. The main UX problems in the existing admin UI have not been addressed yet. However, the visual refresh is already a great improvement! In Spanish, “Claro” means “clear” and this seems to be the main motivation.

The old admin interface (left) and the new UI design (right).

I especially like the new colour palette that is a literal refresh with grey tones that are slightly bluish and a primary blue that is very lively. Compared to the old warm colour scheme, this simple step results in a much more modern look. The contrast has been increased a bit, which has several positive effects. It helps create a clear hierarchy and, of course, it helps make the interface more accessible. 

Interaction Design Challenges

I asked Cristina about the biggest challenge in the redesign. She said that complying with the latest accessibility standards was a tough one. 

“We are not designing for a private company, we are designing for Drupal and this means for anyone. The design has to be accessible for anyone.”

One example Cristina gave me was the form field designs. The initial form fields were similar to those in the Material Design system, with the label inside the input field. Once you select the field, the label floats to the top. It is an elegant technique that has become popular over the last few years. However, Cristina remarked that this kind of animated form design caused a problem with accessibility.

“We decided not to implement something that is super fancy.”

I appreciate the fact that the team behind the new Drupal design puts the user front and centre. The purpose of the redesign is not to create something original for the sake of being extraordinary. On the contrary, the goal is a clear design that prefers well-known design patterns over personality. This doesn’t mean that they kept the old form UI, which was mainly the browser default. The new form design is simple, but clear and therefore very usable.
 

Form field examples of the old UI (left) and of the new design system (right).

  Hierarchy & Proportions

The new UI system is extensive. It includes different states of interactive elements which results in a very consistent design from page to page. Sometimes, these little details make a huge difference. Let’s compare the old and the new second-level of the toolbar. The size ratio between the font size and the icon is not very balanced in the current UI. The chevron buttons have the heaviest visual weight which makes it difficult for the active page to stand out. 
 

Old second level toolbar (left) and new toolbar (right)

The new design uses the primary blue for highlighting active states. The chevrons are simple and don’t draw too much attention. The third-level of the menu is visually separated by a light blue background which also communicates depth.
 

Typography – Fluid and Flexible

I asked Cristina what she enjoyed most during this project. She didn’t have to think long:

“Typography! – Something that I’m really looking forward to implementing is Fluid Typography.”

Fluid Typography is a CSS trick which adjusts the font size and line height based on screen size. Instead of jumping from one size to the next bigger size at a breakpoint, the changes are fluid. This creates a really smooth responsive web experience.

Image credits: css-tricks.com/snippets/css/fluid-typography

Cristina and her team decided to use system fonts instead of a brand typeface in the new UI. She told me that it’s not about branding when you create a functional user interface. They didn’t want the typeface to take too much attention. Cristina pointed out that it is the functionality and usability of software like Drupal that counts. A smooth user experience with the application itself is more important than the branding. Besides, other elements such as the colour palette help with the recognition of the brand.

“Using system fonts feels more natural, more like working with your system and for the user it is not really important that it is Drupal or something else. It is just a tool.”

System font examples (Apple, Windows Vista and KDE)

Another reason for the use of system fonts, Cristina told me, is that sometimes the font is changed to the system font anyway, for instance in other languages that are not included in the character set. Depending on the language, the range of word length is huge as well. When designing an interface like Drupal, you have to keep it flexible anyway.

“There are some languages that are short, and then there is German…” 

As a last question, I asked Cristina, if she had one ultimate tip for other designers to improve their UI design. Her advice was: “Keep in mind that when we are dealing with content management UI, it is not about advertising, not about branding. UI should not be invisible, but it should serve a purpose.” 
“It should serve the user needs?” I suggested.
“Exactly! The [admin] UI should be useful for creating content – in our case, because that’s what Drupal is for – instead of being super fancy.”
 

About Cristina and the team

Cristina Chumillas is a very experienced designer with a background in graphic design and frontend development. She has been active in the Drupal community for many years and works as Creative Director and partner at Ymbra, a Drupal web agency based in Barcelona. The other designers contributing to the Claro theme are Sascha Eggenberger, Archita Arora as well as Dennis Cohn.

Next steps

Following the work on these visual improvements, the team will continue with this user-centered approach and address functionality issues. Suzanne and I helped figure out usability problems in different CMS’s in a comparative study in November and are currently working on a follow-up study to gather more data about how editors create more complex content. Cristina told me that our findings will help guide the the user experience of the Drupal admin interface. We can’t wait to see the results of the next steps!

 

+ more awesome articles by Evolving Web
Categories: Drupal

Agaric Collective: <div class="flow_middle">

28 January 2019 - 6:14pm

Agaric is facilitating a full day training at DrupalCon Seattle to help you understand how to import content into your to Drupal 8 website.

This training is open for attendees with intermediate experience with Drupal- familiarity with installing a Drupal site and installing modules. We… Read more

Categories: Drupal

Agaric Collective: <div class="flow_middle">

28 January 2019 - 6:14pm

People often ask about the free software tools Agaric uses to manage our cooperative business. In this article, we share some of the free software tools we use for office tasks and administration as well as communications. These are Agaric's chosen resources -- the tools we… Read more,

Video embed

Categories: Drupal

Agaric Collective: <div class="flow_middle">

28 January 2019 - 6:14pm

With Europe threatening $25,000,000 fines and Facebook losing $80,000,000,000 of stock value, are you paying attention to data privacy yet? If millions and billions of dollars in news headlines never grabbed you, maybe you've noticed the dozens of e-mails from services you'd forgotten… Read more

Categories: Drupal

Agaric Collective: <div class="flow_middle">

28 January 2019 - 6:14pm

Being able to share an article via a social network is a common request on a project.

Fortunately for Drupal 8 there is a module for that called Social Simple. This module allows you to display a share button on a node for the most popular social… Read more

Categories: Drupal

Agaric Collective: <div class="flow_middle">

28 January 2019 - 6:14pm

The program for DrupalCon is evolving constantly. Among the changes for Nashville 2018 new tracks have been added and some have been merged. That is the case for the Symfony and PHP tracks.

Many topics clearly belong to a single track, but others could fit in more than one. When we had a dedicated Symfony track a session about Twig could be submitted to the Symfony or front end tracks. A session about Drupal Console could be… Read more

Categories: Drupal

Agaric Collective: <div class="flow_middle">

28 January 2019 - 6:14pm

Over 8 years have passed since there was a DrupalCamp in tropical Nicaragua. With the help of a diverse group of volunteers, sponsors, and university faculty staff, we held our second one. DrupalCamp Lagos y Volcanes ("Lakes & Volcanoes") was a great success with over 100 people attending in 2 days. It was a big undertaking so we followed giants' footsteps to prepare for our event. Lots of the ideas were taken from some of the organizers' experience while attending Drupal events.… Read more

Categories: Drupal

Pages