Replaced Moment with Carbon #84

Merged
are0h merged 5 commits from develop into beta 2 years ago

@ -1,6 +1,8 @@
<?php <?php
return (new PhpCsFixer\Config()) $config = new PhpCsFixer\Config();
return $config
->setRiskyAllowed(true)
->setRules([ ->setRules([
'@PSR12' => true, '@PSR12' => true,
'array_indentation' => true, 'array_indentation' => true,
@ -20,7 +22,7 @@ return (new PhpCsFixer\Config())
'multiline_whitespace_before_semicolons' => [ 'multiline_whitespace_before_semicolons' => [
'strategy' => 'no_multi_line', 'strategy' => 'no_multi_line',
], ],
'single_quote' => true, 'single_quote' => false,
'binary_operator_spaces' => [ 'binary_operator_spaces' => [
'default' => 'single_space', 'default' => 'single_space',
@ -50,7 +52,6 @@ return (new PhpCsFixer\Config())
'extra', 'extra',
'parenthesis_brace_block', 'parenthesis_brace_block',
'throw', 'throw',
] ]
], ],
'no_multiline_whitespace_around_double_arrow' => true, 'no_multiline_whitespace_around_double_arrow' => true,
@ -68,5 +69,6 @@ return (new PhpCsFixer\Config())
'ordered_imports' => [ 'ordered_imports' => [
'sort_algorithm' => 'none', 'sort_algorithm' => 'none',
], ],
//Other rules here...
]) ])
->setLineEnding("\n"); ->setLineEnding("\n");

@ -1,13 +1,9 @@
![This is Fipamo](https://playvicio.us/base-assets/images/fipamo-brand.png)
# Fipamo means to save # Fipamo means to save
The Fipamo project was born from a need for a simple, easy to use no data blog platform that doesn't require much effort to set up and maintain. Fipamo uses Markdown to handle posts and renders them to flat html so you can serve them from anywhere. No complicated set ups. No long list of dependencies. Just set up and go. The Fipamo project was born from a need for a simple, easy to use no data blog platform that doesn't require much effort to set up and maintain. Fipamo uses Markdown to handle posts and renders them to flat html so you can serve them from anywhere. No complicated set ups. No long list of dependencies. Just set up and go.
Because nobody has time for all that. Because nobody has time for all that.
## Check the (WIP) Docs to get you started. <br> ## Check the (WIP) Docs to get you started. <br>
[Getting Started](https://code.playvicio.us/Are0h/Fipamo/wiki/00---Start) <br> [Getting Started](https://koodu.ubiqueros.com/are0h/Fipamo/wiki/00---Start) <br>
[Install](https://code.playvicio.us/Are0h/Fipamo/wiki/01---Install) <br>
[Using Fipamo](https://code.playvicio.us/Are0h/Fipamo/wiki/02-Usage) <br>

@ -225,7 +225,6 @@ class APIControl
]; ];
break; break;
} }
$response->getBody()->write(json_encode($result)); $response->getBody()->write(json_encode($result));
return $response->withHeader('Content-Type', 'application/json'); return $response->withHeader('Content-Type', 'application/json');
} }

@ -34,7 +34,6 @@ class RouteControl
switch (isset($args['first']) ? $args['first'] : 'index') { switch (isset($args['first']) ? $args['first'] : 'index') {
case 'api': case 'api':
//$result = APIControl::post($request, $response, $args); //$result = APIControl::post($request, $response, $args);
//var_dump($result);
return APIControl::post($request, $response, $args); return APIControl::post($request, $response, $args);
break; break;
default: default:

@ -3,7 +3,6 @@
namespace brain\utility; namespace brain\utility;
use Carbon\Carbon; use Carbon\Carbon;
use brain\data\Settings;
class Maintenance class Maintenance
{ {

@ -2,12 +2,13 @@
namespace brain\utility; namespace brain\utility;
use function _\filter;
use function _\find;
use brain\data\Book; use brain\data\Book;
use brain\data\Settings; use brain\data\Settings;
use Mni\FrontYAML\Parser; use Mni\FrontYAML\Parser;
use function _\filter;
use function _\find;
class Sorting class Sorting
{ {
private static $p_tags = []; private static $p_tags = [];
@ -16,6 +17,7 @@ class Sorting
public function __construct() public function __construct()
{ {
} }
public static function tags() public static function tags()
{ {
$pages = (new Book('../content/pages'))->getContents(); $pages = (new Book('../content/pages'))->getContents();
@ -36,6 +38,7 @@ class Sorting
return self::$p_tags; return self::$p_tags;
} }
private static function tagPages($tag, $pages) private static function tagPages($tag, $pages)
{ {
$tagged = []; $tagged = [];
@ -52,6 +55,7 @@ class Sorting
return $tagged; return $tagged;
} }
public static function archive() public static function archive()
{ {
$pages = (new Book('../content/pages'))->getContents(); $pages = (new Book('../content/pages'))->getContents();
@ -64,10 +68,13 @@ class Sorting
if (!find($years, ['year' => trim($date[0])])) { if (!find($years, ['year' => trim($date[0])])) {
$findPages = filter($pages, ['createdYear' => trim($date[0])]); $findPages = filter($pages, ['createdYear' => trim($date[0])]);
// var_dump($findPages); // var_dump($findPages);
array_push($years, [ array_push(
'year' => trim($date[0]), $years,
'count' => count($findPages), [
]); 'year' => trim($date[0]),
'count' => count($findPages),
]
);
} }
} }
foreach ($years as $year) { foreach ($years as $year) {
@ -77,12 +84,15 @@ class Sorting
foreach ($filtered as $obj) { foreach ($filtered as $obj) {
$month = date('m', date($obj['rawCreated'])); $month = date('m', date($obj['rawCreated']));
if (!find($sorted, ['month' => $month])) { if (!find($sorted, ['month' => $month])) {
$perMonth = filter($pages, [ $perMonth = filter(
'path' => $year['year'] . '/' . $month, $pages,
'deleted' => false, [
'published' => true, 'path' => $year['year'] . '/' . $month,
'layout' => 'page', 'deleted' => false,
]); 'published' => true,
'layout' => 'page',
]
);
array_push($sorted, [ array_push($sorted, [
'month' => $month, 'month' => $month,
'full_month' => date('F', date($obj['rawCreated'])), 'full_month' => date('F', date($obj['rawCreated'])),
@ -99,6 +109,7 @@ class Sorting
return self::$p_archive; return self::$p_archive;
} }
public static function page($page) public static function page($page)
{ {
$config = new Settings(); $config = new Settings();

@ -0,0 +1,66 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="theme-color" content="#FFFFFF"/>
<title>
{% block title %}
{{ title }}
{% endblock %}
</title>
{% block stylesheets %}{% endblock %}
</head>
<body>
<div id="notifications" class="notifications">
<div id="notify-message" class="notify-message">
<div id="notify-good" class="notify-icon">
<svg viewbox="0 0 20 20" class="icons"><use xlink:href="/assets/images/global/sprite.svg#entypo-emoji-flirt"/></svg>
</div>
<div id="notify-lame" class="notify-icon">
<svg viewbox="0 0 20 20" class="icons"><use xlink:href="/assets/images/global/sprite.svg#entypo-emoji-sad"/></svg>
</div>
<div id="notify-working" class="notify-icon">
<svg id="notify-working-icon" viewbox="0 0 20 20" class="icons"><use xlink:href="/assets/images/global/sprite.svg#entypo-cog"/></svg>
</div>
<div id="notify-text">
<div id="notify-progress"></div>
<p id="message-text">MESSAGE TEXT</p>
</div>
</div>
</div>
<div id="main-content" class="main-container">
<section id="dash-index-content">
{% if status %}
<header id="header">
<div id="wrapper">
{% apply spaceless %}
<div id="left">
<a href="/dashboard"><img id="the-logo" src="/assets/images/global/fipamo-logo.svg"/></a>
</div>
<div id="right">
{% if status %}
{% apply spaceless %}
{{ include("dash/partials/navigation.twig") }}
{% endapply %}
{% endif %}
</div>
{% endapply %}
</div>
</header>
{% endif %}
{% apply spaceless %}
{% block mainContent %}{% endblock %}
{% endapply %}
</section>
</div>
<footer></footer>
{% block javascripts %}{% endblock %}
</body>
</html>

@ -30,36 +30,32 @@
</div> </div>
</div> </div>
<div id="main-content" class="main-container"> {% if status %}
<section id="dash-index-content"> <header>
{% if status %} {% apply spaceless %}
<header id="header"> <nav>
<div id="wrapper"> <div role="nav-left">
<a href="/dashboard"><img id="the-logo" src="/assets/images/global/fipamo-logo.svg"/></a>
</div>
<div>
NOTIFICATIONS
</div>
<div role="nav-right">
{% if status %}
{% apply spaceless %} {% apply spaceless %}
<div id="left"> {{ include("dash/partials/navigation.twig") }}
<a href="/dashboard"><img id="the-logo" src="/assets/images/global/fipamo-logo.svg"/></a>
</div>
<div id="right">
{% if status %}
{% apply spaceless %}
{{ include("dash/partials/navigation.twig") }}
{% endapply %}
{% endif %}
</div>
{% endapply %} {% endapply %}
</div> {% endif %}
</div>
</header> </nav>
{% endif %}
{% apply spaceless %}
{% block mainContent %}{% endblock %}
{% endapply %} {% endapply %}
{% endif %}
</section> </header>
<main>
{% apply spaceless %}
</div> {% block mainContent %}{% endblock %}
{% endapply %}
</main>
<footer></footer> <footer></footer>
{% block javascripts %}{% endblock %} {% block javascripts %}{% endblock %}
</body> </body>

@ -1,13 +1,13 @@
<div id="dash-login"> <section role="login">
<div id="dash-form" class="dash-form"> <div>
<img id="the-logo" src="/assets/images/global/fipamo-logo.svg"/> <img id="the-logo" src="/assets/images/global/fipamo-logo.svg"/>
<form id="login" class='login' name="login" method="POST"> </div>
<input type="text" name="handle" class="form-control" placeholder="Handle" required "> <form id="login" class='login' name="login" method="POST" onsubmit="return false;">
<input type="password" name="password" class="form-control" placeholder="Password" required"> <input type="text" name="handle" class="form-control" placeholder="Handle" required/>
<button id="login-btn" class='login-btn' type='submit'> <input type="password" name="password" class="form-control" placeholder="Password" required/>
ID, PLEASE <button id="login-btn" class='login-btn'>
</button><br /><br /> ID, PLEASE
<a href="/dashboard/reset-password"> Forgot Password?</a> </button>
</form> <a href="/dashboard/reset-password">?</a>
</div> </form>
</div> </section>

@ -1,58 +1,51 @@
<div id="dash-recent"> <section role="index-header">
<div id="recent-list"> <div>
<div class="recent-header"> <h1>Recent</h1>
<div class="index-header-left">
Recent
</div>
<div class="index-header-right">
<a href='/dashboard/pages' title="view pages">
<button>
<svg class="page-link">
<use xlink:href="/assets/images/global/sprite.svg#entypo-archive"/>
</svg>
</button>
</a>
<a href='/dashboard/page/add/new' title="add new page">
<button>
<svg class="page-link">
<use xlink:href="/assets/images/global/sprite.svg#entypo-plus"/>
</svg>
</button>
</a>
</div>
</div>
<br/>
{% if data["entryCount"] != 0 %}
{% for page in data['pages'] %}
{% if page.media[0].type == 'mp4' %}
<a href="/dashboard/page/edit/{{ page.uuid }}" id="{{ page.uuid }}" class="post-video-link recent-link">
<video class="post-video" loop muted autoplay>
<source src="{{ page.media[0].file }}" type="video/mp4">
Sorry, your browser doesn't support embedded videos.
</video>
<label>
{{ page.title }}
</label>
{{ include("dash/partials/recent-options.twig") }}
</a>
{% else %}
<a href="/dashboard/page/edit/{{ page.uuid }}" id="{{ page.uuid }}" class="post-link recent-link" style="background: url({{ page.media[0].file }}) no-repeat center center / cover">
<label>
{{ page.title }}
</label>
{{ include("dash/partials/recent-options.twig") }}
</a>
{% endif %}
{% endfor %}
{% else %}
There are no pages
{% endif %}
</div>
</div> </div>
<div>
<a href='/dashboard/pages' title="view pages">
<button>
<svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-archive"/>
</svg>
</button>
</a>
<a href='/dashboard/page/add/new' title="add new page">
<button>
<svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-plus"/>
</svg>
</button>
</a>
</div>
</section>
<section role="index-recent-pages">
{% if data["entryCount"] != 0 %}
{% for page in data['pages'] %}
{% if page.media[0].type == 'mp4' %}
<a href="/dashboard/page/edit/{{ page.uuid }}" id="{{ page.uuid }}" class="post-video-link recent-link">
<video class="post-video" loop muted autoplay>
<source src="{{ page.media[0].file }}" type="video/mp4">
Sorry, your browser doesn't support embedded videos.
</video>
{{ include("dash/partials/recent-meta.twig") }}
</a>
{% else %}
<a href="/dashboard/page/edit/{{ page.uuid }}" id="{{ page.uuid }}" class="post-link recent-link" style="background: url({{ page.media[0].file }}) no-repeat center center / cover">
{{ include("dash/partials/recent-meta.twig") }}
</a>
{% endif %}
{% endfor %}
{% else %}
There are no pages
{% endif %}
</section>

@ -1,21 +1,23 @@
<div id="dash-menu"> <div role="menu">
<a id="settings" href="/dashboard/settings" title="settings"> <a id="settings" href="/dashboard/settings" title="settings">
<button> <button>
<svg class="menu"> <svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-sound-mix"/> <use xlink:href="/assets/images/global/sprite.svg#entypo-sound-mix"/>
</svg> </svg>
</button> </button>
</a> . </a>
.
<a id="navigation" href="/dashboard/navigation" title="edit navigation"> <a id="navigation" href="/dashboard/navigation" title="edit navigation">
<button> <button>
<svg class="menu"> <svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-list"/> <use xlink:href="/assets/images/global/sprite.svg#entypo-list"/>
</svg> </svg>
</button> </button>
</a> . </a>
.
<a id="navigation" href="/dashboard/logout" title="log out"> <a id="navigation" href="/dashboard/logout" title="log out">
<button> <button>
<svg class="menu"> <svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-log-out"/> <use xlink:href="/assets/images/global/sprite.svg#entypo-log-out"/>
</svg> </svg>
</button> </button>

@ -0,0 +1,43 @@
{% if page.menu == 'true' %}
{% set menu = "true" %}
{% else %}
{% set menu = "false" %}
{% endif %}
{% if page.published == 'true' %}
{% set published = "true" %}
{% else %}
{% set published = "false" %}
{% endif %}
{% if page.featured == 'true' %}
{% set featured = "true" %}
{% else %}
{% set featured = "false" %}
{% endif %}
<aside>
<strong>
{{ page.updated }}
</strong>
<hr/>
<strong>
{{ page.title }}
</strong>
<hr/>
<button data-active="{{ menu }}">
<svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-add-to-list"/>
</svg>
</button>
<button data-active="{{ published }}">
<svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-globe"/>
</svg>
</button>
<button data-active="{{ featured }}">
<svg role="icon">
<use xlink:href="/assets/images/global/sprite.svg#entypo-star"/>
</svg>
</button>
</aside>

@ -1,42 +0,0 @@
<div id="options">
{% if page.menu == 'true' %}
{% set menu = "true" %}
{% else %}
{% set menu = "false" %}
{% endif %}
{% if page.published == 'true' %}
{% set published = "true" %}
{% else %}
{% set published = "false" %}
{% endif %}
{% if page.featured == 'true' %}
{% set featured = "true" %}
{% else %}
{% set featured = "false" %}
{% endif %}
<div id="option-left">
<button data-active="{{ menu }}">
<svg>
<use xlink:href="/assets/images/global/sprite.svg#entypo-add-to-list"/>
</svg>
</button>
<button data-active="{{ published }}">
<svg>
<use xlink:href="/assets/images/global/sprite.svg#entypo-globe"/>
</svg>
</button>
<button data-active="{{ featured }}">
<svg>
<use xlink:href="/assets/images/global/sprite.svg#entypo-star"/>
</svg>
</button>
</div>
<div id="option-right">
<span>
{{ page.updated }}
</span>
</div>
</div>

@ -5,21 +5,17 @@
{% endblock %} {% endblock %}
{% block stylesheets %} {% block stylesheets %}
<link rel="stylesheet" type="text/css" href="/assets/css/dash.css?=acvcnh"> <link rel="stylesheet" type="text/css" href="/assets/css/dash/start.css?=dfdfrtr">
{% endblock %} {% endblock %}
{% block mainContent %} {% block mainContent %}
<div id="dash-index"> {% if status %}
<div id="dash-index-wrapper"> {% apply spaceless %}
{% if status %} {{ include("dash/partials/index.twig") }}
{% apply spaceless %} {% endapply %}
{{ include("dash/partials/index.twig") }} {% else %}
{% endapply %} {{ include("dash/forms/login.twig") }}
{% else %} {% endif %}
{{ include("dash/forms/login.twig") }}
{% endif %}
</div>
</div>
{% endblock %} {% endblock %}
{% block javascripts %} {% block javascripts %}

@ -35,8 +35,8 @@
"license": "UNLICENSED", "license": "UNLICENSED",
"author": "Are0h", "author": "Are0h",
"scripts": { "scripts": {
"watch": "sass --watch src/styles:public/assets/css & npx parcel watch src/com/Start.js --dist-dir public/assets/scripts --public-url /assets/scripts", "watch": "npx parcel watch src/com/Start.js --dist-dir public/assets/scripts --public-url /assets/scripts",
"build": "sass src/styles:public/assets/css & npx parcel build src/com/Start.js --dist-dir public/assets/scripts --public-url /assets/scripts" "build": "npx parcel build src/com/Start.js --dist-dir public/assets/scripts --public-url /assets/scripts"
}, },
"description": "Front end script for the most chill blog framework ever.", "description": "Front end script for the most chill blog framework ever.",
"repository": "https://code.playvicio.us/Are0h/Fipamo" "repository": "https://code.playvicio.us/Are0h/Fipamo"

@ -0,0 +1,43 @@
{
"name": "fipamo-dash",
"version": "2.5.1-beta",
"private": true,
"apidoc": {
"name": "Fipamo API",
"version": "1.0.0",
"description": "The most chill API for the most chill blog framework"
},
"devDependencies": {
"@babel/preset-env": "^7.16.5",
"babel-cli": "^6.26.0",
"eslint": "^8.11.0",
"eslint-plugin-babel": "^5.3.1",
"parcel": "^2.0.1",
"prettier": "^2.6.0",
"stylelint": "^14.8.2",
"stylelint-config-prettier-scss": "^0.0.1",
"stylelint-config-standard-scss": "^3.0.0"
},
"dependencies": {
"@babel/core": "^7.16.5",
"@babel/eslint-parser": "^7.16.5",
"animejs": "^3.2.1",
"babel-plugin-prismjs": "^2.1.0",
"babel-preset-env": "^1.7.0",
"bulma": "^0.9.3",
"caret-pos": "^2.0.0",
"jsdoc": "^3.6.7",
"minami": "^1.2.3",
"prismjs": "^1.25.0",
"sass": "^1.45.1",
"sortablejs": "^1.14.0"
},
"license": "UNLICENSED",
"author": "Are0h",
"scripts": {
"watch": "sass --watch src/styles:public/assets/css & npx parcel watch src/com/Start.js --dist-dir public/assets/scripts --public-url /assets/scripts",
"build": "sass src/styles:public/assets/css & npx parcel build src/com/Start.js --dist-dir public/assets/scripts --public-url /assets/scripts"
},
"description": "Front end script for the most chill blog framework ever.",
"repository": "https://code.playvicio.us/Are0h/Fipamo"
}

@ -1,33 +1,33 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg width="100%" height="100%" viewBox="0 0 486 678" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;"> <svg width="100%" height="100%" viewBox="0 0 462 462" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;">
<g id="Logo" transform="matrix(1.36867,0,0,1.36867,-351.696,-71.9183)"> <g transform="matrix(1.58717,0,0,1.58717,-403.964,-376.506)">
<g transform="matrix(2.31599,0,0,2.31599,218.53,-99.4797)"> <g transform="matrix(1,0,0,1,200.753,94.1743)">
<path d="M93.67,140.92L93.67,140.921C105.569,140.921 115.216,150.567 115.216,162.467L115.216,172.724L115.216,172.724L115.216,182.262C115.216,194.161 105.569,203.808 93.669,203.808C81.976,203.217 74.12,195.969 72.237,184.474L72.282,182.737L72.282,162.467L72.205,160.847C72.775,149.587 82.728,141.121 93.67,140.92Z" style="fill:rgb(252,99,153);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(252,99,153);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,-437.697)"> <g transform="matrix(1,0,0,1,200.753,201.192)">
<path d="M93.67,211.678L93.67,211.678C105.569,211.678 115.216,221.324 115.216,233.224L115.216,243.481L115.216,243.481L115.216,253.019C115.216,264.919 105.569,274.565 93.669,274.565C81.976,273.975 74.12,266.726 72.237,255.232L72.282,253.495L72.282,233.224L72.205,231.604C72.775,220.344 82.728,211.878 93.67,211.678Z" style="fill:rgb(252,99,153);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(252,99,153);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,241.338)"> <g transform="matrix(1,0,0,1,307.732,201.192)">
<path d="M93.67,69.288L93.67,69.288C105.569,69.288 115.216,78.934 115.216,90.834L115.216,101.091L115.216,101.091L115.216,110.629C115.216,122.528 105.569,132.175 93.669,132.175C81.976,131.584 74.12,124.336 72.237,112.842L72.282,111.105L72.282,90.834L72.205,89.214C72.775,77.954 82.728,69.488 93.67,69.288Z" style="fill:rgb(171,183,183);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(252,99,153);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,-104.112)"> <g transform="matrix(1,0,0,1,414.761,201.192)">
<path d="M38.059,142.92L38.059,142.921C49.958,142.921 59.605,152.567 59.605,164.467L59.605,174.724L59.605,174.724L59.605,184.262C59.605,196.161 49.958,205.808 38.058,205.808C26.365,205.217 18.509,197.969 16.626,186.474L16.671,184.737L16.671,164.467L16.594,162.847C17.164,151.587 27.117,143.121 38.059,142.92Z" style="fill:rgb(252,99,153);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(171,183,183);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,-104.112)"> <g transform="matrix(1,0,0,1,200.753,308.228)">
<path d="M148.331,142.92L148.331,142.921C160.23,142.921 169.877,152.567 169.877,164.467L169.877,174.724L169.877,174.724L169.877,184.262C169.877,196.161 160.23,205.808 148.331,205.808C136.637,205.217 128.782,197.969 126.898,186.474L126.943,184.737L126.943,164.467L126.867,162.847C127.436,151.587 137.389,143.121 148.331,142.92Z" style="fill:rgb(171,183,183);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(252,99,153);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,-437.697)"> <g transform="matrix(1,0,0,1,307.732,308.228)">
<path d="M38.059,211.678L38.059,211.678C49.958,211.678 59.605,221.324 59.605,233.224L59.605,243.481L59.605,243.481L59.605,253.019C59.605,264.919 49.958,274.565 38.058,274.565C26.365,273.975 18.509,266.726 16.626,255.232L16.671,253.495L16.671,233.224L16.594,231.604C17.164,220.344 27.117,211.878 38.059,211.678Z" style="fill:rgb(252,99,153);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(171,183,183);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,-437.697)"> <g transform="matrix(1,0,0,1,414.761,308.228)">
<path d="M148.331,211.678L148.331,211.678C160.23,211.678 169.877,221.324 169.877,233.224L169.877,243.481L169.877,243.481L169.877,253.019C169.877,264.919 160.23,274.565 148.331,274.565C136.637,273.975 128.782,266.726 126.898,255.232L126.943,253.495L126.943,233.224L126.867,231.604C127.436,220.344 137.389,211.878 148.331,211.678Z" style="fill:rgb(252,99,153);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(171,183,183);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,241.338)"> <g transform="matrix(1,0,0,1,414.761,94.1743)">
<path d="M38.059,69.288L38.059,69.288C49.958,69.288 59.605,78.934 59.605,90.834L59.605,101.091L59.605,101.091L59.605,110.629C59.605,122.528 49.958,132.175 38.058,132.175C26.365,131.584 18.509,124.336 16.626,112.842L16.671,111.105L16.671,90.834L16.594,89.214C17.164,77.954 27.117,69.488 38.059,69.288Z" style="fill:rgb(252,99,153);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(252,99,153);"/>
</g> </g>
<g transform="matrix(2.31599,0,0,2.31599,218.53,241.338)"> <g transform="matrix(6.12323e-17,1,-1,6.12323e-17,581.547,183.453)">
<path d="M148.331,69.288L148.331,69.288C160.23,69.288 169.877,78.934 169.877,90.834L169.877,101.091L169.877,101.091L169.877,110.629C169.877,122.528 160.23,132.175 148.331,132.175C136.637,131.584 128.782,124.336 126.898,112.842L126.943,111.105L126.943,90.834L126.867,89.214C127.436,77.954 137.389,69.488 148.331,69.288Z" style="fill:rgb(171,183,183);fill-rule:nonzero;"/> <circle cx="92.268" cy="181.547" r="38.502" style="fill:rgb(252,99,153);"/>
</g> </g>
</g> </g>
</svg> </svg>

Before

Width:  |  Height:  |  Size: 4.6 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

@ -537,10 +537,10 @@ class Base {
// methods // methods
//-------------------------- //--------------------------
start() { start() {
if (document.getElementById("dash-form") || document.getElementById("dash-init")) { if (document.getElementById("login") || document.getElementById("dash-init")) {
var options = document.getElementsByClassName("init-option"); var options = document.getElementsByClassName("init-option");
for(let index = 0; index < options.length; index++)options[index].addEventListener("click", (e)=>this.handleOptions(e)); for(let index = 0; index < options.length; index++)options[index].addEventListener("click", (e)=>this.handleOptions(e));
if (document.getElementById("dash-form")) document.getElementById("login-btn").addEventListener("click", (e)=>this.handleLogin(e)); if (document.getElementById("login")) document.getElementById("login-btn").addEventListener("click", (e)=>this.handleLogin(e));
else { else {
document.getElementById("init-blog").addEventListener("click", (e)=>this.handleSetup(e)); document.getElementById("init-blog").addEventListener("click", (e)=>this.handleSetup(e));
document.getElementById("blog-restore").addEventListener("click", (e)=>this.handleRestore(e)); document.getElementById("blog-restore").addEventListener("click", (e)=>this.handleRestore(e));

@ -20,15 +20,12 @@ export default class Base {
// methods // methods
//-------------------------- //--------------------------
start() { start() {
if ( if (document.getElementById('login') || document.getElementById('dash-init')) {
document.getElementById('dash-form') ||
document.getElementById('dash-init')
) {
var options = document.getElementsByClassName('init-option'); var options = document.getElementsByClassName('init-option');
for (let index = 0; index < options.length; index++) { for (let index = 0; index < options.length; index++) {
options[index].addEventListener('click', e => this.handleOptions(e)); options[index].addEventListener('click', e => this.handleOptions(e));
} }
if (document.getElementById('dash-form')) { if (document.getElementById('login')) {
document document
.getElementById('login-btn') .getElementById('login-btn')
.addEventListener('click', e => this.handleLogin(e)); .addEventListener('click', e => this.handleLogin(e));

Loading…
Cancel
Save