Skip to content

Instantly share code, notes, and snippets.

@gbluv
gbluv / d3chart.module.css
Last active March 10, 2026 12:52
line chart d3
.chartContainer {
position: relative;
width: 100%;
background-color: #0a1a14;
border-radius: 8px;
overflow: hidden;
}
.chart {
display: block;
@gbluv
gbluv / final-organasing prompt.md
Created March 9, 2026 21:02
updated prompt with two-way testing

Role

You are a senior financial data analyst specializing in transaction monitoring systems, behavioral analytics, and rule-based financial controls.


Task

You are given a CSV dataset where each row represents a rule condition used by a client.

@gbluv
gbluv / json_store_parser.js
Created March 9, 2026 20:45
json_store_parser.js
const fs = require("fs")
// load rules file
const rules = JSON.parse(fs.readFileSync("rules.json", "utf8"))
const rows = []
for (const rule of rules) {
let parsed
@gbluv
gbluv / rules_analysis_prompt
Created March 9, 2026 20:15
prompt to get rules analysis
**Role:**
You are a senior data analyst specializing in financial transaction classification and rule analysis.
**Task:**
Analyze a list of JSON records representing client rules.
Each record contains:
* `user_id`
* `rule_category_name`
* `json_data` which contains:
I have a LiquidGlassBorder component with a static conic-gradient border.
I need to add a loading prop that rotates the gradient.
Requirements:
- Add a `loading` boolean prop (default false)
- Add a `speed` number prop in seconds (default 3)
- When loading=true, the gradient should rotate infinitely
- The element itself must NOT rotate — only the gradient angle animates
- Content inside must be completely unaffected
@gbluv
gbluv / gist:03e99615da34a52b60ac900e9cc9d6c9
Last active February 22, 2026 22:59
FullWorkingActivityIndicator
import { useEffect } from "react";
const styles = `
.lgbWrapper {
position: relative;
display: flex;
isolation: isolate;
width: 100%;
height: 100%;
overflow: hidden;
previously when a user switched to the Transactions table and there was no data, we showed a message prompting them to click on the first point. With the new implementation, they will see a “data table loading” message, which isn’t accurate because it won’t disappear. At this stage, we can’t reliably determine whether the data is still loading or if there’s simply no data.
Would you be okay if we remove the custom message for now and let the grid display either the loading indicator or the default “no data available” state instead?
@gbluv
gbluv / gist:2815d7550f3f08f3e711552e3205e56b
Last active February 20, 2026 17:08
Loading indicator
import { useEffect, useState } from "react";
const styles = `
@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@300;400&display=swap');
body, html {
margin: 0;
padding: 0;
background: #000;
min-height: 100vh;

You are modifying an existing D3 + React cell rendering implementation.

CRITICAL RULE: You are ONLY allowed to change the TEXT COLOR behavior and ONLY for cells that have anomaly data.

You must NOT change:

  • Gradients
  • Blur filters
  • Border stroke
@gbluv
gbluv / d3-cell.js
Last active February 15, 2026 13:13
"use client"
import { useRef, useEffect } from "react"
import * as d3 from "d3"
export function D3Cell({ value, size = 160 }) {
const containerRef = useRef(null)
useEffect(() => {
if (!containerRef.current) return