Nifty Corners Cube

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Rounded corners the javascript way
Nifty Corners Cube

StackOverflow.com

VN:F [1.9.22_1171]
Rating: 8.5/10 (13 votes cast)

Random snippets of all sorts of code, mixed with a selection of help and advice.

Latest leaf selected in MantineUI Tree component

27 December 2025 @ 6:12 pm

I'm trying to use MantineUI Tree component with very simple tree data: const treeData: TreeNodeData[] = [ { label: "parent 1", value: "1", children: [ { label: "child 1-1", value: "1-1" }, { label: "child 1-2", value: "1-2" }, ], }, { label: "parent 2", value: "2", children: [ { label: "child 2-1", value: "2-1" }, { label: "child 2-2", value: "2-2" }, ], }, ] The parent nodes only serve as grouping, so clicking on them should only expand/collapse children. Instead, when user clicks on a child, I must know the clicked child value and other components will update depending on this. I'm trying to get this with useTree hook, but it doesn't seem to have something like "onSelected" event. So I'm trying with

Puppeteer PDF generation uses wrong font in production

27 December 2025 @ 6:08 pm

I’m generating PDFs using Puppeteer in a Node.js application. Locally, fonts render correctly, but in production, some fonts (notably Courier New) are replaced with a different font in the generated PDF. Expected behavior Text explicitly styled with Courier New should render using that font in the final PDF. Actual behavior In production, the PDF renders the text using a different monospace font, even though Courier New is specified. Example HTML <p><font face="Courier New">Text Here</font></p> Or via CSS: font-family: "Courier New", Courier, "Liberation Mono", monospace; Why does Puppeteer replace Courier New with another font in production, and how can I ensure the exact font is used when generating PDFs? Specifically: Is this caused by missing sys

T-SQL ETL update evaluation recommendation: What is the most elegant & performative way to evaluate a source value to update a target value?

27 December 2025 @ 6:05 pm

What recommendations might be offered for the most elegant and performative way with T-SQL to evaluate whether a source value should update a target value as part of an ETL update process in which dozens of target table row values need to be evaluated? This is a roll-your-own ETL design approach question using PowerShell for basic orchestration, leveraging stored procedures for performance where it matters. Reported raw files will be loaded to a table of unique rows containing the best reported values. This table will later in the ETL process be refactored into a 3NF normalized structure. After a volatile staging area table (VSA) is populated with records from a source, each record in VSA needs to be evaluated as either a new record to insert into a target persistent staging area table (PSA), or to update an existing record in the target PSA table. Insert is easy (using a hash evaluation of essential record keys, such as a Person ID, if the hash of keys is unique). Upd

Angular Vitest not working in Test Explorer - Need to call TestBed.initTestEnvironment() first

27 December 2025 @ 5:53 pm

Why is it that when I run Angular Vitest tests in the terminal is works fine: Shows running tests in the terminal But running the same tests in the Test Explorer fails: Shows running tests in the VSCode Test Explorer I tried adding import { BrowserTestingModule, platformBrowserTesting } from "@angular/platform-browser/testing"; TestBed.initTestEnvironment(BrowserTestingModule, platformBrowserTesting()); But that just makes them both fail. There is also no @angular/platform-browser-dynamic in the project anymore as I'm using Angular 21

Using getElements after building div's using JS

27 December 2025 @ 5:46 pm

I understand that building up the page using JS creates an issue using the getElements functions to create an array of objects, due to the DOM status. So I have tried a few different solutions but not found a good one for what I want to achieve. So I guess I try to solve this the wrong way. I have a dynamic questionnaire where some answers are supposed to be sorted in order by the respondent. The original approach was something like this. From my Django backend I feed the page with all questions/answers/type etc, and questions by page. I have reduced the types and stripped the code from formatting. I hope it is possible to follow. var to_drag=null function generateQ(q_id,Section) { const questionObj = QData.find(q => q.q_id === q_id); if (questionObj) { // Example: Create a new div and append the question to it const div = document.createElement("div"); div.setAttribute("id"

How to intercept a markdown file and display as HTML?

27 December 2025 @ 5:37 pm

As part of my application, I want to use QWebEngineView to display the contents of a local markdown file as an HTML page. Local files will end in '.md'. In Qt version 6.9 I wrote the following code to override the QWebEnginePage behaviour: from PyQt6.QtWebEngineCore import QWebEnginePage from urllib.parse import urlparse import markdown2 class MyView(QWebEnginePage): def acceptNavigationRequest(self, qurl, navtype, mainframe) -> bool: parse_info = urlparse(qurl.url()) if parse_info.scheme.lower() == "file": if parse_info.path.lower().endswith(".md"): my_html = markdown2.markdown_path(parse_info.path) self.setHtml(myhtml, baseUrl=qurl) return False In Qt 6.9, this worked, the file was rendered as an HTML page. Today my system upgraded to Qt 6.10. This same code now crashes the application (no message - exit

Cannot publish Google site, no drop down beside Publish button [closed]

27 December 2025 @ 5:19 pm

Can anyone help? Trying to set up a Google site. enter image description hereI have got my domain name verified by Google but cannot publish the Google site and connect them. If I press the publish button I get the screen below and if I add the address in the top box I get the above. Any ideas?

Finding an operator for 3 distinct values with bitwise operations

27 December 2025 @ 5:09 pm

Consider the set {A,B,C} and an operator op defined by the following table A op A = A A op B = A A op C = A B op A = A B op B = B B op C = C C op A = A C op B = C C op C = B I would like to encode A,B and C with bits values and then define the operator op by some bitwise operations. For instance, one can set constexpr auto A = 0b001; constexpr auto B = 0b010; constexpr auto C = 0b100; then one can (empirically) define the operator by auto op (auto x, auto y) { return ((x&A) | (y&A)) | (x&B & y&B) | ((x&C & y&C)>>1) | ((x<<1) & y&C) | ((y<<1) & x&C); } which seems to give correct results (see here). However, I came to this solution by a trial and error approach and

Is there any performance difference between applying a bunch of CSS classes to each child of an element or using selectors in a CSS file

27 December 2025 @ 1:27 pm

Let's say I have a table with many many rows: <ul> <tr> <td>column1</td><td>column2</td><td>column3</td><td>column4</td> <td>column1</td><td>column2</td><td>column3</td><td>column4</td> ... add a bazillion more lines </tr> </ul> if I had to add a lot of styling to those rows and cells, is there any performance difference between bloating the HTML markup with a framework's CSS classes, such as: <tr class="table-row"> <td class="table-cell p-4 pl-8 text-gray-500 dark:border-white/10 dark:text-gray-300">column1</td> <td class="table-cell p-4 pl-8 text-gray-500 dark:border-white/10 dark:text-gray-300">column2</td> <td class="table-cell p-4 pl-8 text-gray-500 dark:border-white/10 dark:text-gray-300">column

Anomaly with padding, margin, and display

27 December 2025 @ 6:08 am

So, I have a div named highlights which contains a bunch of cards. When I put #highlights into another div, named about which only has padding: 5rem 0; (margin would cause the same effect) for its CSS, each card's content is cut short significantly. When highlights is not a child of about or if you remove about's CSS, the cards fully encapsulate their content. This anomaly is only, as far as I know, visible on mobile. I do not have this problem at all on my laptop nor when I use chrome's resolution simulator to test what my website would look like different resolutions. However, when I checked using my IPhone 14 Pro, all my cards' content were cut short even though it was all fine on my laptop under the same resolution. The code below exemplifies the issue. The first highlight is under about and the second about is a direct child of body.

960.gs

VN:F [1.9.22_1171]
Rating: 8.0/10 (1 vote cast)

CSS Grid System layout guide
960.gs

IconPot .com

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Totally free icons

Interface.eyecon.ro

VN:F [1.9.22_1171]
Rating: 6.0/10 (1 vote cast)

Interface elements for jQuery
Interface.eyecon.ro

ThemeForest.net

VN:F [1.9.22_1171]
Rating: 7.0/10 (2 votes cast)

WordPress Themes, HTML Templates.

kuler.adobe.com

VN:F [1.9.22_1171]
Rating: 8.0/10 (1 vote cast)

color / colour themes by design

webanalyticssolutionprofiler.com

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)

Web Analytics::Free Resources from Immeria
webanalyticssolutionprofiler.com

WebAIM.org

VN:F [1.9.22_1171]
Rating: 4.0/10 (1 vote cast)

Web Accessibility In Mind

2026 Predictions: The Next Big Shifts in Web Accessibility

22 December 2025 @ 11:22 pm

I’ve lived long enough, and worked in accessibility long enough, to have honed a healthy skepticism when I hear about the Next Big Thing. I’ve seen lush website launches that look great, until I activate a screen reader. Yet, in spite of it all, accessibility does evolve, but quietly rather than dramatically. As I gaze […]

Word and PowerPoint Alt Text Roundup

31 October 2025 @ 7:14 pm

Introduction In Microsoft Word and PowerPoint, there are many types of non-text content that can be given alternative text. We tested the alternative text of everything that we could think of in Word and PowerPoint and then converted these files to PDFs using Adobe’s Acrobat PDFMaker (the Acrobat Tab on Windows), Adobe’s Create PDF cloud […]

Accessibility by Design: Preparing K–12 Schools for What’s Next

30 July 2025 @ 5:51 pm

Delivering web and digital accessibility in any environment requires strategic planning and cross-organizational commitment. While the goal (ensuring that websites and digital platforms do not present barriers to individuals with disabilities) and the standards (the Web Content Accessibility Guidelines) remain constant, implementation must be tailored to each organization’s needs and context.   For K–12 educational agencies, […]

Up and Coming ARIA 

30 May 2025 @ 6:19 pm

If you work in web accessibility, you’ve probably spent a lot of time explaining and implementing the ARIA roles and attributes that have been around for years—things like aria-label, aria-labelledby, and role="dialog". But the ARIA landscape isn’t static. In fact, recent ARIA specifications (especially ARIA 1.3) include a number of emerging and lesser-known features that […]

Global Digital Accessibility Salary Survey Results

27 February 2025 @ 8:45 pm

In December 2024 WebAIM conducted a survey to collect salary and job-related data from professionals whose job responsibilities primarily focus on making technology and digital products accessible and usable to people with disabilities. 656 responses were collected. The full survey results are now available. This survey was conducted in conjunction with the GAAD Foundation. The GAAD […]

Join the Discussion—From Your Inbox

31 January 2025 @ 9:01 pm

Which WebAIM resource had its 25th birthday on November 1, 2024? The answer is our Web Accessibility Email Discussion List! From the halcyon days when Hotmail had over 35 million users, to our modern era where Gmail has 2.5 billion users, the amount of emails in most inboxes has gone from a trickle to a […]

Using Severity Ratings to Prioritize Web Accessibility Remediation

22 November 2024 @ 6:30 pm

So, you’ve found your website’s accessibility issues using WAVE or other testing tools, and by completing manual testing using a keyboard, a screen reader, and zooming the browser window. Now what? When it comes to prioritizing web accessibility fixes, ranking the severity of each issue is an effective way to prioritize and make impactful improvements. […]

25 Accessibility Tips to Celebrate 25 Years

31 October 2024 @ 4:38 pm

As WebAIM celebrates our 25 year anniversary this month, we’ve shared 25 accessibility tips on our LinkedIn and Twitter/X social media channels. All 25 quick tips are compiled below. Tip #1: When to Use Links and Buttons Links are about navigation. Buttons are about function. To eliminate confusion for screen reader users, use a <button> […]

Celebrating WebAIM’s 25th Anniversary

30 September 2024 @ 10:25 pm

25 years ago, in October of 1999, the Web Accessibility In Mind (WebAIM) project began at Utah State University. In the years previous, Dr. Cyndi Rowland had formed a vision for how impactful the web could be on individuals with disabilities, and she learned how inaccessible web content would pose significant barriers to them. Knowing […]

Introducing NCADEMI: The National Center on Accessible Digital Educational Materials & Instruction 

30 September 2024 @ 10:25 pm

Tomorrow, October 1st, marks a significant milestone in WebAIM’s 25 year history of expanding the potential of the web for people with disabilities. In partnership with our colleagues at the Institute for Disability Research, Policy & Practice at Utah State University, we’re launching a new technical assistance center. The National Center on Accessible Digital Educational […]

CatsWhoCode.com

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Titbits for web designers and alike

Unable to load the feed. Please try again later.