First draft
This commit is contained in:
@@ -87,7 +87,7 @@ class HostingSupport1984UI
|
|||||||
*
|
*
|
||||||
* @return String The path.
|
* @return String The path.
|
||||||
*/
|
*/
|
||||||
private function view_path(string $view_file)
|
private function view_path(string $view_file): string
|
||||||
{
|
{
|
||||||
return plugin_dir_path(__FILE__) . self::VIEWS_DIR . $view_file;
|
return plugin_dir_path(__FILE__) . self::VIEWS_DIR . $view_file;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,11 +2,13 @@
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* Plugin Name: 1984 Hosting Support
|
* Plugin Name: 1984 Hosting Support
|
||||||
* Version: 1.0.1
|
* Version: 1.1.0
|
||||||
* Author: 1984 ehf
|
* Author: 1984 ehf.
|
||||||
* Author URI: https://1984.hosting
|
* Author URI: https://1984.hosting
|
||||||
* Description: Support plugin for 1984 Hosting customers.
|
* Description: Support plugin for 1984 Hosting customers.
|
||||||
* Update URI: https://git.1984.is/1984/1984-hosting-support/
|
* Update URI: https://git.1984.is/1984/1984-hosting-support/
|
||||||
|
* Text Domain: hostingsupport1984
|
||||||
|
* Domain Path: /languages
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -97,7 +99,7 @@ class HostingSupport1984
|
|||||||
*
|
*
|
||||||
* @return Boolean
|
* @return Boolean
|
||||||
*/
|
*/
|
||||||
public function load_textdomain()
|
public function load_textdomain(): bool
|
||||||
{
|
{
|
||||||
return load_plugin_textdomain(
|
return load_plugin_textdomain(
|
||||||
'hostingsupport1984',
|
'hostingsupport1984',
|
||||||
@@ -191,25 +193,34 @@ class HostingSupport1984
|
|||||||
return $links;
|
return $links;
|
||||||
}
|
}
|
||||||
|
|
||||||
$warning_text = '1984: Please do not deactivate or delete this plugin - part of your WordPress Service Pack.';
|
$warning_text =
|
||||||
|
__('1984 Hosting: Please do not deactivate or delete this plugin - part of your WordPress Service Pack.', 'hostingsupport1984');
|
||||||
|
|
||||||
$logo_1984_url = plugins_url('icons/1984-hosting-logo.webp', __FILE__);
|
$logo_1984_url = plugins_url('icons/1984-hosting-logo.webp', __FILE__);
|
||||||
$logo_patchstack = plugins_url('icons/patchstack-logo.svg', __FILE__);
|
$logo_patchstack = plugins_url('icons/patchstack-logo.svg', __FILE__);
|
||||||
|
|
||||||
$warning_icon =
|
$title_1984 = __('Visit 1984 Hosting Homepage', 'hostingsupport1984');
|
||||||
'<span class="dashicons dashicons-warning" aria-hidden="true" style="color:#b32d2e;vertical-align:text-bottom;margin-right:6px;"></span>';
|
$title_patchstack = __('Visit Patchstack Homepage', 'hostingsupport1984');
|
||||||
|
|
||||||
$links[] =
|
$container_open =
|
||||||
'<span class="description" style="color:#b32d2e;font-weight:700;display:inline-flex;align-items:center;line-height:1;">' . $warning_icon . esc_html($warning_text) . '</span>' .
|
'<span class="description" style="color:#b32d2e;font-weight:700;display:inline-grid;grid-template-columns:auto 1fr;column-gap:6px;row-gap:4px;align-items:center;line-height:1.5;vertical-align:middle;">';
|
||||||
'<span class="description" style="margin-left:6px;display:inline-flex;align-items:center;gap:4px;">'
|
|
||||||
|
$warning_icon =
|
||||||
|
'<span class="dashicons dashicons-warning" aria-hidden="true" style="color:#b32d2e;grid-column:1;"></span>';
|
||||||
|
|
||||||
|
$text_html = '<span style="grid-column:2;">' . esc_html($warning_text) . '</span>';
|
||||||
|
|
||||||
|
|
||||||
|
$logos_html =
|
||||||
|
'<span style="grid-column:2;display:inline-flex;align-items:center;gap:4px;">'
|
||||||
.
|
.
|
||||||
'<a href="https://1984.hosting" target="_blank" rel="noopener noreferrer" title="1984 Hosting" aria-label="1984 Hosting (opens in a new tab)">'
|
'<a href="https://1984.hosting" target="_blank" rel="noopener noreferrer" title="' . esc_attr($title_1984) . '" aria-label="' . esc_attr($title_1984) . '">'
|
||||||
.
|
.
|
||||||
'<img src="' . esc_url($logo_1984_url) . '" alt="1984 Hosting" style="height:16px;width:auto;display:inline-block;" />'
|
'<img src="' . esc_url($logo_1984_url) . '" alt="1984 Hosting" style="height:16px;width:auto;display:inline-block;" />'
|
||||||
.
|
.
|
||||||
'</a>'
|
'</a>'
|
||||||
.
|
.
|
||||||
'<a href="https://patchstack.com" target="_blank" rel="noopener noreferrer" title="Patchstack" aria-label="Patchstack (opens in a new tab)">'
|
'<a href="https://patchstack.com" target="_blank" rel="noopener noreferrer" title="' . esc_attr($title_patchstack) . '" aria-label="' . esc_attr($title_patchstack) . '">'
|
||||||
.
|
.
|
||||||
'<img src="' . esc_url($logo_patchstack) . '" alt="Patchstack" style="height:16px;width:auto;display:inline-block;" />'
|
'<img src="' . esc_url($logo_patchstack) . '" alt="Patchstack" style="height:16px;width:auto;display:inline-block;" />'
|
||||||
.
|
.
|
||||||
@@ -217,6 +228,8 @@ class HostingSupport1984
|
|||||||
.
|
.
|
||||||
'</span>';
|
'</span>';
|
||||||
|
|
||||||
|
$links[] = $container_open . $warning_icon . $text_html . $logos_html . '</span>';
|
||||||
|
|
||||||
return $links;
|
return $links;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
0
build-locales.sh
Normal file → Executable file
0
build-locales.sh
Normal file → Executable file
Binary file not shown.
@@ -1,41 +1,69 @@
|
|||||||
|
# Copyright (C) 2025 1984 ehf.
|
||||||
|
# This file is distributed under the same license as the 1984 Hosting Support plugin.
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: 1984 Big Brother\n"
|
"Project-Id-Version: 1984 Hosting Support 1.1.0\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/1984-hosting-"
|
||||||
"POT-Creation-Date: 2021-01-19 10:05+0000\n"
|
"support\n"
|
||||||
"PO-Revision-Date: 2021-01-19 10:09+0000\n"
|
"Last-Translator: Sævar Bergur Sigurgeirsson <saevar@1984.is>\n"
|
||||||
"Last-Translator: \n"
|
"Language-Team: none\n"
|
||||||
"Language-Team: Íslenska\n"
|
|
||||||
"Language: is_IS\n"
|
|
||||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
"Content-Transfer-Encoding: 8bit\n"
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
"X-Generator: Loco https://localise.biz/\n"
|
"POT-Creation-Date: 2025-12-02T11:00:44+00:00\n"
|
||||||
"X-Loco-Version: 2.4.2; wp-5.6"
|
"PO-Revision-Date: 2025-12-02T11:00:44+00:00\n"
|
||||||
|
"X-Generator: WP-CLI 2.12.0\n"
|
||||||
|
"X-Domain: hostingsupport1984\n"
|
||||||
|
"Language: is\n"
|
||||||
|
|
||||||
#: 1984-hosting-support-ui.php:100
|
#. Plugin Name of the plugin
|
||||||
|
#: 1984-hosting-support.php 1984-hosting-support-ui.php:49
|
||||||
msgid "1984 Hosting Support"
|
msgid "1984 Hosting Support"
|
||||||
msgstr "Aðstoð og stuðningur hjá 1984"
|
msgstr "Aðstoð og stuðningur hjá 1984 Hosting"
|
||||||
|
|
||||||
#. Name of the plugin
|
#. Description of the plugin
|
||||||
msgid "1984-hosting-support.php"
|
#: 1984-hosting-support.php
|
||||||
|
msgid "Support plugin for 1984 Hosting customers."
|
||||||
|
msgstr "Stuðningsviðbót fyrir viðskiptavini 1984 Hosting."
|
||||||
|
|
||||||
|
#. Author of the plugin
|
||||||
|
#: 1984-hosting-support.php
|
||||||
|
msgid "1984 ehf."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:31
|
#. Author URI of the plugin
|
||||||
|
#: 1984-hosting-support.php
|
||||||
|
msgid "https://1984.hosting"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: 1984-hosting-support.php:194
|
||||||
|
msgid ""
|
||||||
|
"1984 Hosting: Please do not deactivate or delete this plugin - part of your "
|
||||||
|
"WordPress Service Pack."
|
||||||
|
msgstr ""
|
||||||
|
"1984 Hosting: Vinsamlegast ekki slökkva á eða eyða þessari viðbót – hún er "
|
||||||
|
"hluti af WordPress þjónustupakkanum þínum."
|
||||||
|
|
||||||
|
#: 1984-hosting-support.php:309
|
||||||
|
msgid ""
|
||||||
|
"For security, this action is blocked: 1984 Hosting Support and Patchstack "
|
||||||
|
"cannot be deactivated or deleted while this policy is active."
|
||||||
|
msgstr ""
|
||||||
|
"Af öryggisástæðum er þessari aðgerð hafnað: 1984 Hosting Support og Patchstack "
|
||||||
|
"er ekki hægt að slökkva á eða eyða meðan þessi regla er virk."
|
||||||
|
|
||||||
|
#: views/support-dashboard-widget.php:21
|
||||||
msgid "My Profile"
|
msgid "My Profile"
|
||||||
msgstr "Minn aðgangur"
|
msgstr "Minn aðgangur"
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:15
|
#: views/support-dashboard-widget.php:34
|
||||||
msgid "My Sites, Domains & VPSs"
|
msgid "My Sites, Domains & VPSs"
|
||||||
msgstr "Vefir, lén og sýndarvélar"
|
msgstr "Vefir, lén og sýndarvélar"
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:15
|
#: views/support-dashboard-widget.php:48
|
||||||
msgid "Knowledge Base"
|
msgid "Knowledge Base"
|
||||||
msgstr "Viskubrunnur 1984"
|
msgstr "Viskubrunnur 1984"
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:15
|
#: views/support-dashboard-widget.php:62
|
||||||
msgid "Contact Support"
|
msgid "Contact Support"
|
||||||
msgstr "Fá aðstoð"
|
msgstr "Fá aðstoð"
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,41 +1,60 @@
|
|||||||
|
# Copyright (C) 2025 1984 ehf.
|
||||||
|
# This file is distributed under the same license as the 1984 Hosting Support plugin.
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: 1984 Big Brother\n"
|
"Project-Id-Version: 1984 Hosting Support 1.1.0\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/1984-hosting-support\n"
|
||||||
"POT-Creation-Date: 2021-01-19 10:05+0000\n"
|
"Last-Translator: Sævar Bergur Sigurgeirsson <saevar@1984.is>\n"
|
||||||
"PO-Revision-Date: 2021-01-19 10:09+0000\n"
|
"Language-Team: none\n"
|
||||||
"Last-Translator: \n"
|
|
||||||
"Language-Team: Íslenska\n"
|
|
||||||
"Language: is_IS\n"
|
|
||||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
"Content-Transfer-Encoding: 8bit\n"
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
"X-Generator: Loco https://localise.biz/\n"
|
"POT-Creation-Date: 2025-12-02T11:00:44+00:00\n"
|
||||||
"X-Loco-Version: 2.4.2; wp-5.6"
|
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||||
|
"X-Generator: WP-CLI 2.12.0\n"
|
||||||
|
"X-Domain: hostingsupport1984\n"
|
||||||
|
|
||||||
#: 1984-hosting-support-ui.php:100
|
#. Plugin Name of the plugin
|
||||||
|
#: 1984-hosting-support.php
|
||||||
|
#: 1984-hosting-support-ui.php:49
|
||||||
msgid "1984 Hosting Support"
|
msgid "1984 Hosting Support"
|
||||||
msgstr "Aðstoð og stuðningur hjá 1984"
|
msgstr "Aðstoð og stuðningur hjá 1984"
|
||||||
|
|
||||||
#. Name of the plugin
|
#. Description of the plugin
|
||||||
msgid "1984-hosting-support.php"
|
#: 1984-hosting-support.php
|
||||||
|
msgid "Support plugin for 1984 Hosting customers."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:31
|
#. Author of the plugin
|
||||||
|
#: 1984-hosting-support.php
|
||||||
|
msgid "1984 ehf."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#. Author URI of the plugin
|
||||||
|
#: 1984-hosting-support.php
|
||||||
|
msgid "https://1984.hosting"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: 1984-hosting-support.php:194
|
||||||
|
msgid "1984 Hosting: Please do not deactivate or delete this plugin - part of your WordPress Service Pack."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: 1984-hosting-support.php:309
|
||||||
|
msgid "For security, this action is blocked: 1984 Hosting Support and Patchstack cannot be deactivated or deleted while this policy is active."
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: views/support-dashboard-widget.php:21
|
||||||
msgid "My Profile"
|
msgid "My Profile"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:15
|
#: views/support-dashboard-widget.php:34
|
||||||
msgid "My Sites, Domains & VPSs"
|
msgid "My Sites, Domains & VPSs"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:15
|
#: views/support-dashboard-widget.php:48
|
||||||
msgid "Knowledge Base"
|
msgid "Knowledge Base"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: views/support-dashboard-widget.php:15
|
#: views/support-dashboard-widget.php:62
|
||||||
msgid "Contact Support"
|
msgid "Contact Support"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user