Skip to content

Instantly share code, notes, and snippets.

View qstudio's full-sized avatar

Ray qstudio

View GitHub Profile
<?php
/**
* The template for displaying comments
*
* This is the template that displays the area of the page that contains both the current comments
* and the comment form.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*
* @package WordPress
<?php
// factory.php
$dashboard = new q\user\controller\dashboard();
$dashboard->hooks();
// dashboard.php
namespace q\theme\child\controller;
<?php
// factory.php
$page = new q\theme\child\controller\page();
$page->hooks();
// page.php
namespace q\theme\child\controller;
<?php
// factory.php
$page = new q\theme\child\controller\page();
$page->hooks();
// page.php
namespace q\theme\child\controller;
@qstudio
qstudio / willow-native-templates.php
Last active December 20, 2020 12:34
Adding native WordPress templates to Willow
<?php
// factory.php
$config = new q\theme\child\core\config();
$config->hooks();
// config.php
namespace q\theme\child\core;
<?php
$ui = new ui();
$ui->hooks();
class ui {
function __construct(){}
function hooks() {
// share-this https://github.com/MaxArt2501/share-this
// vars ##
$share-this-vertical-offset: -.25em !default;
$share-this-background: #333 !default;
$share-this-foreground: #fff !default;
$share-this-highlight-link: rgba(#fff, .25) !default;
$share-this-border-radius: .25em !default;
$share-this-arrow-size: .5em !default;
/* https://github.com/MaxArt2501/share-this */
"use strict";
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
!function (e, t) {
"object" == (typeof exports === "undefined" ? "undefined" : _typeof(exports)) && "undefined" != typeof module ? module.exports = t() : "function" == typeof define && define.amd ? define(t) : (e = e || self).ShareThis = t();
}(void 0, function () {
"use strict";
@qstudio
qstudio / loop.html
Last active November 7, 2020 12:34
<div>
<h1>ONE: First loop</h1>
<h5>ONE: Title One</h5>
<h5>ONE: Title Two</h5>
</div>
<div>
<h1>ONE: Second loop</h1>
<h5>ONE: TITLE ONE</h5>
<h5>ONE: TITLE TWO</h5>
{~ ui~loop {+
<div>
<h1>ONE: First loop</h1>
{@ {: one :}
<h5>{{ title }}</h5>
@}
</div>
<div>
<h1>ONE: Second loop</h1>
{@ {: one :}