Skip to content

Latest commit

 

History

History
127 lines (90 loc) · 5.87 KB

README.md

File metadata and controls

127 lines (90 loc) · 5.87 KB

TWBase Theme

A Starter theme for Drupal built with Tailwind CSS.

tailwindcss drupal LICENSE

⚠️ WARNING: TWBase is under development and not yet ready for production 🐞

Recommended Modules

As TWBase Theme use Tailwind Typography I recommends you to install TWBase Theme Utilities modules with this theme. It load the styles.css provided by TWBase Theme and add the prose (tw-prose) extra class to the editor body to reflects the frontend while editing node in admin section. Otherwise the content in your editor may look slightly poor and naked... 🙀. The module also provide an admin interface to control the frontpage showcase content and last but not least: it allows you to define showcase and related options per content type 🥳.

Demo

A very basic demo is available with the TWBase Theme Utilities modules installed.

ToDo

  • Allow to change frontpage showcase image in theme settings. Thanks to Tdnshah
  • Provide blocks placement on install ?
  • Test multilingual site with language switcher
  • Rename branch 9.1.x to 1.x
  • Create a Pre Release 1.0.0-rc1

Development dependencies

To install all dependencies run npm install from theme root directory.

CSS compilation

Development compilation

To watch changes while "playing" with css and html class, run npm run watch from theme root directory.

Building for production

By default, for development purpose the outputed css file is not minified. To minify it, uncomment cssnano in the plugins section of postcss.config.js :

// postcss.config.js
module.exports = {
  plugins: {
    'postcss-import': {},
    tailwindcss: {},
    autoprefixer: {},
    //Uncomment this to minify the outputed css file
//     cssnano: {
//       preset: "default",
//     },
  }
}

When you're happy with all this, build the final css file by running the command npm run build from theme root directory.

Credits

Creator

It's me! drupix

Icons + Demo Images

Other

Special thanks to Bob den Otter 🌷🇳🇱 and all contributors of Bolt default theme who introduced me with Tailwind.


License

The MIT License (MIT)

Copyright (c) 2021 Enzo Di Resta (aka drupix)

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

TWBase incorporates Font Awesome. Font Awesome is distributed under the terms of the Font Awesome Free License.

TWBase incorporates photographs from Unsplash.