Skip to content

Instantly share code, notes, and snippets.

View airstrike's full-sized avatar
🎯
bringing presentations and spreadsheets to the 21st century

Andy airstrike

🎯
bringing presentations and spreadsheets to the 21st century
View GitHub Profile
@airstrike
airstrike / .vimrc
Created February 22, 2025 21:50
latest .vimrc (works in vim and VSCode)
" VIM user interface
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Set 7 lines to the curors - when moving vertical..
set so=4
set ruler "Always show current position
set cmdheight=1 "The commandbar height
" Set backspace config
set backspace=eol,start,indent
set whichwrap+=<,>,h,l
@airstrike
airstrike / window.rs
Created February 7, 2025 01:23
iced::daemon with only two windows
use std::collections::BTreeMap;
use iced::advanced::graphics::image::image_rs::ImageFormat;
use iced::{window, Size, Subscription, Task, Element};
use crate::theme::constants::WINDOW_ICON;
use crate::theme::Theme;
use crate::{app, assistant};
#[derive(Debug)]
pub enum Message {
@airstrike
airstrike / font_sampler.rs
Created January 31, 2025 02:43
iced font sampler
use iced::Alignment::Center;
use iced::Length::Fill;
use iced::font::{self, Font};
use iced::widget::{column, horizontal_rule, pick_list, row, scrollable, text, text_input};
use iced::{Element, Size, Task};
use std::collections::HashMap;
// Font candidates with their names and possible paths
const FONT_CANDIDATES: &[(&str, &[&str])] = &[
("Menlo", &[
@airstrike
airstrike / QualityHuntComponent.tsx
Created January 15, 2025 19:52
A React component for a curated product launch platform that focuses on quality over quantity. Features a daily showcase carousel, ranked submissions, and a clean, minimalist design. Built with React and Tailwind CSS.
import React, { useState } from 'react';
import { Clock, ArrowUp, MessageSquare, ChevronLeft, ChevronRight, Search, ExternalLink } from 'lucide-react';
const LaunchPlatform = () => {
const [currentSlide, setCurrentSlide] = useState(0);
const todaysLaunches = [
{
id: 1,
name: "CodePilot Pro",
@airstrike
airstrike / markdown.rs
Created January 10, 2025 20:05
A variation of iced's markdown widget which includes a "copy" button for codeblocks
use iced::widget::{button, column, container, hover, rich_text, row, scrollable, text, Button};
use iced::widget::{horizontal_space, markdown};
use iced::{padding, Element, Font, Length, Pixels};
pub use iced::widget::markdown::{HeadingLevel, Item, Settings, Style, Url};
/// Display a bunch of Markdown items with copy functionality for code blocks.
pub fn view<'a, Message, Theme, Renderer>(
items: impl IntoIterator<Item = &'a Item>,
settings: Settings,
@airstrike
airstrike / main.rs
Created December 14, 2024 19:45
owned LLVM Context pattern for `iced`
use std::collections::HashMap;
use components::sidebar;
use desmos_compiler::{
expressions::{ExpressionId, Expressions},
lang::backends::llvm::{codegen::compile_all_exprs, CompiledExprs},
};
use graph::GraphRenderer;
use iced::{
alignment::Horizontal,
@airstrike
airstrike / Permafrost.jsx
Created November 29, 2024 02:54
Permafrost Archive Manager
/**
* Permafrost.jsx
*
* A React component that provides a modern, interactive UI for viewing and managing
* archive files (ZIP, etc.). Features include:
*
* - File/folder browsing with sorting capabilities
* - Detailed metadata sidebar
* - MacOS-style window controls
* - File type icons and size formatting
@airstrike
airstrike / WireshartViz.jsx
Created November 24, 2024 17:13
Wireshart
/**
* WireshartViz.jsx
*
* Dependencies:
* - react
* - recharts
* - tailwindcss
*
* Required imports:
* import React, { useState, useEffect } from 'react';
@airstrike
airstrike / transcript.md
Created October 20, 2024 23:15
FPSLaunch Design Meeting with Claude 3.5 Sonnet

airstrike: Create a tailwind-css based landing page like the attached. Minimalistic, some text on the left, an image on the right, and then some description down the page, some colored or gradient background. Nothing too fancy. Use Google fonts and CDN-provided resources and give me the full html, css, js so I can put it on a jsfiddle and see what it looks like. Thanks!

image


Claude: I understand you'd like me to create a Tailwind CSS-based landing page inspired by the image you've shared, without directly copying it. I'll design a minimalistic page with text on the left, an image on the right, and some description further down. I'll use Google Fonts and CDN-provided resources to create this layout. Here's the HTML, CSS, and JavaScript code for a similar but original design:

image

@airstrike
airstrike / smart_rectangle.rs
Created August 6, 2024 21:06
Smart Rectangles
//! Rectangles of every kind! Assumes negative sizes imply that the Rectangle
//! was drawn from bottom to top, right to left, or both.
use iced::{Point, Rectangle, Size};
/// Creates a `Rectangle` that ensures positive dimensions.
///
/// If the size is negative in either direction, it subtracts it from the
/// top-left coordinates accordingly and flips it to a positive sign. This way,
/// if a rectangle is drawn from bottom-right to top-left, it still results in a