How to Add Internal “Borders” Between Rows & Columns in a CSS Grid Layout
In Drupal 9.4, jQuery.once() has been removed. However, there's a Javascript function, once(), that can replace it with a little rewriting:
var closeButton = $("#off-canvas .offcanvas__close");
closeButton.once().on("click", function () {
closeOffCanvas();
});
once takes 3 arguments: 1. Arbitrary key, 2. CSS selector, 3. context
❗When you install qBittorrent, make sure to install NordVPN first. Then you want to make sure to limit qBittorrent so it will only use NordVPN’s connection (saving you from getting in trouble if you forget to turn on the VPN before torrenting).
- Make sure NordVPN is disconnected
- In Terminal, type
ifconfig
- Connect NordVPN
- In Terminal, type
ifconfig
again - Find the connection that’s been added (in my case, it was utun4)
- In qBittorrent, open the preferences and click on Advanced
- Set the Network Interface to your NordVPN connection and click OK.
- Test it by heading over to the Ubuntu alternative downloads page (these files are totally legal to download, so if something goes wrong you won’t get in trouble)
- Pick a few versions of Ubuntu to download, and load the (old fashioned non-magnet 😛 ) torrent files into qBittorrent
To list the fonts that are available on your system, run the following command in the terminal:
system_profiler -json SPFontsDataType | grep \"family | sort | uniq
This will show the name you need to supply to VSCode to use the font.
Any font that is activated on the Mac will be available to VSCode. I am using a patched font, and by applying the name that is shown using the command above, I was able to use it in VSCode.
/** | |
* implements hook_page_attachments_alter | |
* @param array $attachments | |
*/ | |
//thanks: https://www.drupal.org/theme-guide/8/assets#configurable-javascript | |
function gavias_tico_subtheme_page_attachments_alter(array &$attachments) { | |
/** | |
* Hotjar tracking code for NIJC | |
*/ |
[Fix for Prettier Error: Unexpected doc.type 'concat']
As of 10-30-2023, the Prettier Melody plugin that allows Prettier to work on .twig files hasn't been updated in ages. Meanwhile, Prettier has been updated to 3.0, which (it turns out) was a breaking change as far as the Twig Melody plugin is concerned.
Downgrade your Prettier to 2.8 using npm install [email protected]
// Add this to an appropriate php file in your theme | |
// Change the function name and the "visually-hidden" class name as appropriate | |
// Note that this is a WireMedia theme, so is using their icons function. | |
// You can use css to create the chevron instead | |
require_once 'icons.php'; | |
function j40a_parent_menu_item_buttons($output, $item, $depth, $args) { | |
if (in_array('menu-item-has-children', $item->classes, true)) { |
/**
* Helper function / example code to check
* if the given configuration (by name)
* exists in active configuration.
* @param string $configName
* The id of the configuration to check.
*
* @return boolean
*
use Drupal\taxonomy\Entity\Vocabulary;
use Drupal\field\Entity\FieldStorageConfig;
use Drupal\field\Entity\FieldConfig;
use Drupal\taxonomy\Entity\Term;
/**
* Implements hook_install().
*/
function radicati_social_install() {