From fff721dd185f5b97f7ae7a6e64189e55887ff590 Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Sun, 05 Jul 2026 18:36:57 +0000
Subject: [PATCH] =Cleaning up the Square integration (still a bit more to do yet). Also majorly overhauled /rest/ files to ignore a rest request 'user' paramater, and rely on get_current_user_id() instead.
---
inc/managers/IconsManager.php | 17 ++++++++++++++---
1 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/inc/managers/IconsManager.php b/inc/managers/IconsManager.php
index 45890c5..a57b8a7 100644
--- a/inc/managers/IconsManager.php
+++ b/inc/managers/IconsManager.php
@@ -144,6 +144,7 @@
'apple-logo',
'check-circle',
'close-circle',
+ 'faders-horizontal',
'cloud-slash',
'exclamation-mark',
'cloud-arrow-down',
@@ -194,6 +195,7 @@
// ]
];
+
// Add icons from content/taxonomy/user configs (like old behavior)
$configIcons = $this->getIconsFromConfigs();
if (!empty($configIcons)) {
@@ -208,7 +210,6 @@
if (isset($allIcons[$this->source])) {
$icons = array_merge($icons, $allIcons[$this->source]);
}
-
if (!empty($icons)) {
$this->include($icons);
}
@@ -355,7 +356,7 @@
if (Site::has('dashboard')) {
$map['dash'] = 'door';
}
- if (Site::has('magicLink')) {
+ if (Site::has('magic_link')) {
$map['magicLink'] = 'magic-wand';
}
if (Site::hasAnyIntegration()) {
@@ -373,6 +374,7 @@
protected function registerGlobalHooks(): void
{
add_action('wp_loaded', [self::class, 'checkCSS']);
+ add_action('shutdown', [self::class, 'checkCSS']);
}
/**
@@ -623,7 +625,7 @@
/**
* Get raw SVG content for CSS mask-image
*/
- protected function getRawSvg(string $name, ?string $style = null): ?string
+ public function getRawSvg(string $name, ?string $style = null): ?string
{
if (!$style) {
$style = $this->style;
@@ -670,6 +672,15 @@
foreach ($names as $icon) {
$svg = $this->getEncodedSVG($icon, $style);
if ($svg !== '') {
+ if ($icon === 'caret-down') {
+ $css .= 'details summary::after,';
+ } elseif ($icon === 'faders-horizontal') {
+ $css .= 'details.all-filters summary::after,';
+ } elseif ($icon === 'link') {
+ $css .= 'input[type=url],';
+ } elseif ($icon === apply_filters('jvbSeparatorLogo', 'logo')) {
+ $css .= 'hr.logo::before,';
+ }
$css .= ".icon-{$icon}{$styleClass}{";
$css .= "--icon:url('data:image/svg+xml;base64,{$svg}');";
$css .= "}";
--
Gitblit v1.10.0