Update block icons, favicon logic, and translations

Changed block icon from 'admin-links' to 'embed-generic' and updated related dashicon classes in block.js. Updated CSS for placeholder icon display. In git-embed-feicode.php, switched all favicon URLs to use cn.cravatar.com for better reliability, improved owner type detection logic, and bumped plugin version to 1.1.0. Updated and regenerated Chinese translation files to reflect UI and terminology changes.
This commit is contained in:
feibisi 2025-08-14 11:35:48 +08:00
parent abd72452dd
commit fb4c759459
8 changed files with 42 additions and 19 deletions

View file

@ -21,7 +21,7 @@
registerBlockType('git-embed-feicode/repository', {
title: __('Git Repository', 'git-embed-feicode'),
description: __('Embed a Git repository with information and stats', 'git-embed-feicode'),
icon: 'admin-links',
icon: 'embed-generic',
category: 'embed',
supports: {
align: ['left', 'center', 'right', 'wide', 'full']
@ -212,7 +212,7 @@
if (!repoData) {
return el('div', { className: 'git-embed-placeholder' },
el('div', { className: 'git-embed-placeholder-content' },
el('span', { className: 'dashicons dashicons-admin-links git-embed-placeholder-icon' }),
el('span', { className: 'dashicons dashicons-embed-generic git-embed-placeholder-icon' }),
el('h3', null, __('Git Repository Embed', 'git-embed-feicode')),
el('p', null, __('Configure your repository details in the sidebar', 'git-embed-feicode'))
)
@ -261,7 +261,7 @@
}),
el('div', { className: 'git-embed-title-content' },
el('h3', { className: 'git-embed-title' },
el('span', { className: 'dashicons dashicons-admin-links git-embed-repo-icon' }),
el('span', { className: 'dashicons dashicons-embed-generic git-embed-repo-icon' }),
el('a', {
href: repoData.html_url,
target: '_blank',

View file

@ -454,9 +454,8 @@ line-height: 1.25;
.git-embed-placeholder-icon {
font-size: 48px;
display: block;
display: contents;
margin-bottom: 16px;
color: #0073aa;
}
.git-embed-placeholder h3 {