Skip to content

science-feedback/SF-wordpress

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Health Feedback Wordpress Theme

Install a Wordpress app first

  1. Download a wordpress boilerplate here

  2. Use MAMP and don't forget to start Start Servers at each new use.

  3. Install the Health Feedback wordpress-theme:

cd wp-content/themes && git clone [email protected]:HealthFeedback/wordpress-theme.git

In the admin, don't forget to activate the theme.

  1. Install these Plugins in the wp-content/plugins

Database Sync Media Library Plus Claim-Reviews Evaluation_Plugin Toolset Types People

  1. Synchronize with the database of the prod website
  • Make sure you have activate the Database Sync plugin.
  • Go to Settings/Database Sync and copy paste the token found there
  • Press the Sync button and then the Pull button

N.B.: Make sure you have been made an admin if you want to have access to the Media Library and Page editing rights.

  1. Synchronize your media library

Develop the wordpress theme

Made with Sage

Requirements

Prerequisite How to check How to install
PHP >= 5.4.x php -v php.net
Node.js 0.12.x node -v nodejs.org
gulp >= 3.8.10 gulp -v npm install -g gulp
Bower >= 1.3.12 bower -v npm install -g bower

For more installation notes, refer to the Install gulp and Bower section in this document.

Features

  • gulp build script that compiles both Sass and Less, checks for JavaScript errors, optimizes images, and concatenates and minifies files
  • BrowserSync for keeping multiple browsers and devices synchronized while testing, along with injecting updated CSS and JS into your browser while you're developing
  • Bower for front-end package management
  • asset-builder for the JSON file based asset pipeline
  • Sass Bootstrap
  • Theme wrapper
  • ARIA roles and microformats
  • Posts use the hNews microformat
  • Multilingual ready and over 30 available community translations

Configuration

Edit lib/config.php to enable or disable theme features

Edit lib/init.php to setup navigation menus, post thumbnail sizes, post formats, and sidebars.

Theme development

Sage uses gulp as its build system and Bower to manage front-end packages.

Install gulp and Bower

Building the theme requires node.js. We recommend you update to the latest version of npm: npm install -g npm@latest.

From the command line:

  1. Install gulp and Bower globally with npm install -g gulp bower
  2. Navigate to the theme directory, then run npm install
  3. Run bower install

You now have all the necessary dependencies to run the build process.

Available gulp commands

  • gulp — Compile and optimize the files in your assets directory
  • gulp watch — Compile assets when file changes are made
  • gulp --production — Compile assets for production (no source maps).

Using BrowserSync

To use BrowserSync during gulp watch you need to update devUrl at the bottom of assets/manifest.json to reflect your local development hostname.

For example, if your local development URL is http://project-name.dev you would update the file to read:

...
  "config": {
    "devUrl": "http://project-name.dev"
  }
...

If your local development URL looks like http://localhost:8888/project-name/ you would update the file to read:

...
  "config": {
    "devUrl": "http://localhost:8888/project-name/"
  }
...

Tips

If you want a quick screenshot on the fly based on a url

<img
  class="fact-check-card__row__verdict__img"
  src="http://s.wordpress.com/mshots/v1/<?php echo get_post_meta( get_the_ID(), 'link', true)?>?w=400&h=400"
/>

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published