repo
stringclasses
341 values
file_path
stringlengths
29
173
language
stringclasses
2 values
file_type
stringclasses
4 values
code
stringlengths
2
1.66M
tokens
int64
2
598k
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/Util/getTexture.luau
luau
.luau
local InsertService = game:GetService("InsertService") local MarketplaceService = game:GetService("MarketplaceService") local RunService = game:GetService("RunService") local loadAssetTextureTypes = { Enum.AssetType.Face.Value, Enum.AssetType.Shirt.Value, Enum.AssetType.Pants.Value, Enum.AssetType.TShirt.Value, } ...
355
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/Util/getUserInfo.luau
luau
.luau
local UserService = game:GetService("UserService") local RunService = game:GetService("RunService") local Function = require(script.Parent:WaitForChild("Function")) local Signal = require(script.Parent:WaitForChild("Signal")) local SafePlayerAdded = require(script.Parent:WaitForChild("SafePlayerAdded")) type UserInfo...
790
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/Util/init.luau
luau
.luau
local Logger = require(script:WaitForChild("Logger")) export type Log = Logger.Log export type LogType = Logger.LogType export type Logger = Logger.Logger --- @class Util local Util = { --- @within Util --- @prop Logger Logger Logger = Logger, Defer = require(script:WaitForChild("Defer")), Function = require(sc...
361
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/Util/iterPageItems.luau
luau
.luau
local function pagesToTable(pages) local items = {} while true do table.insert(items, pages:GetCurrentPage()) if pages.IsFinished then break end pages:AdvanceToNextPageAsync() end return items end local function iterPageItems(pages) local contents = pagesToTable(pages) local pageNum = 1 local lastPag...
142
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/Popup.luau
luau
.luau
local MarketplaceService = game:GetService("MarketplaceService") local RunService = game:GetService("RunService") local Util = require(script.Parent.Parent.Util) local LocalPlayer = game.Players.LocalPlayer if RunService:IsServer() then return false end local vip = Instance.new("Frame") vip.Name = "VIP" vip.Anchor...
5,028
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/Purchasables.luau
luau
.luau
return { chatCommands = { 115444443724463, -- 40% off chat commands 110019084552349, -- chat commands 130880915606069, -- elite 84349662672781, -- epic 129439770798699, -- hero 132161234381156, -- legend 89859349616824, -- mythic 102980653148583, -- eternal }, chatCommandsLower = { 88978146769822, ...
1,299
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/Title/init.luau
luau
.luau
local CollectionService = game:GetService("CollectionService") local RunService = game:GetService("RunService") local Package = script.Parent.Parent.Parent local Flux = require(Package:WaitForChild("Flux")) local Oklab = Flux.Color.Oklab local function sortKeypoints(a, b) return a.Time < b.Time end local Title = ...
1,845
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/UGC/AlphaWings/Animate/Animate.luau
luau
.luau
local TweenService = game:GetService("TweenService") local Animate = { timeScale = 1, } function Animate.getBoneFromPose(rig: Instance, pose: Pose): Motor6D? if not pose.Parent then return end local poseParentName = pose.Parent.Name for i, v in rig:GetDescendants() do if v:IsA("Bone") and v.Name == pose.Name...
631
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/UGC/AlphaWings/Animate/init.client.luau
luau
.luau
local part = script.Parent local Animate = require(script:WaitForChild("Animate")) local Animations = script:WaitForChild("Animations") local fall = Animations:WaitForChild("fall") local idle = Animations:WaitForChild("idle") local idle2 = Animations:WaitForChild("idle2") local humanoid = part.Parent.Parent:FindFirs...
445
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/UGC/AlphaWings/Bones.luau
luau
.luau
local part = Instance.new("Part") part.Anchored = true part.CanCollide = false part.CanQuery = false part.CanTouch = false part.Locked = true part.Transparency = 1 local boneL1 = Instance.new("Bone", part) boneL1.Name = "Bone_l" boneL1.CFrame = CFrame.new(-0.576, 0, 0) * CFrame.Angles(0, 0, math.rad(76.663)) local bo...
426
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/UGC/AlphaWings/init.luau
luau
.luau
local CollectionService = game:GetService("CollectionService") local InsertService = game:GetService("InsertService") local RunService = game:GetService("RunService") local Package = script.Parent.Parent.Parent.Parent local Flux = require(Package:WaitForChild("Flux")) local Util = require(Package.Shared:WaitForChild(...
1,043
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/UGC/Crown.luau
luau
.luau
local CollectionService = game:GetService("CollectionService") local InsertService = game:GetService("InsertService") local RunService = game:GetService("RunService") local Package = script.Parent.Parent.Parent.Parent local Flux = require(Package:WaitForChild("Flux")) local Util = require(Package.Shared:WaitForChild(...
1,195
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/Shared/VIP/init.luau
luau
.luau
local Auth = require(script.Parent:WaitForChild("Auth")) local Data = require(script.Parent:WaitForChild("Data")) local Util = require(script.Parent:WaitForChild("Util")) local Popup = require(script:WaitForChild("Popup")) local Purchasables = require(script:WaitForChild("Purchasables")) local Title = require(script:W...
3,091
kohls-admin/kohls-admin
kohls-admin-kohls-admin-d4d40b0/src/init.luau
luau
.luau
-- src/init.luau --- @class MainModule if shared._K_INTERFACE then return shared._K_INTERFACE end local RunService = game:GetService("RunService") local requireStart = os.clock() local Client = script:WaitForChild("Client") local Server = RunService:IsServer() and script:WaitForChild("Server") local Shared = script:...
1,692
Coyenn/awesome-roblox-ts
Coyenn-awesome-roblox-ts-6ce8003/update.luau
luau
.luau
local process = require("@lune/process") local fs = require("@lune/fs") local task = require("@lune/task") local serde = require("@lune/serde") local README_PATH = "README.md" -- Header for the README.md file local README_HEADER = [[ # Awesome Roblox-TS A list of all packages for [roblox-ts](https://roblox-ts.com/)....
1,447
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/App.luau
luau
.luau
local plugin = script:FindFirstAncestorWhichIsA("Plugin") local Players = game:GetService("Players") local ContentProvider = game:GetService("ContentProvider") local UserService = game:GetService("UserService") local MarketplaceService = game:GetService("MarketplaceService") local HttpService = game:GetService("HttpSe...
7,330
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/ClientFalbackApp/init.luau
luau
.luau
-- If the user is play-testing on the client, fallback to this since the plugin won't work local plugin = script:FindFirstAncestorOfClass("Plugin") local ClientFallbackApp = {} ClientFallbackApp.__index = ClientFallbackApp local Theme = require(script.Parent.UI.Theme).global local StyleState = script.Parent.UI.Style...
416
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/DeserializerState.luau
luau
.luau
--!strict -- Stuff for deserialization with buffers. local plugin = script:FindFirstAncestorOfClass("Plugin") local DESERIALIZATION_KEY = "DataDelve_Deserialization" type PlaceSettings = { -- path to the default deserializer defaultDeserializer: {string}?, } type DeserializationSettings = { [--[[placeId:]] stri...
957
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/ExportImportHelper.luau
luau
.luau
local plugin = script:FindFirstAncestorWhichIsA("Plugin") local SelectionService = game:GetService("Selection") local StudioService = game:GetService("StudioService") local HttpService = game:GetService("HttpService") local ScriptEditorService = game:GetService("ScriptEditorService") local RunService = game:GetServic...
627
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/History.luau
luau
.luau
-- History for datastore connections and keys local MAIN_HISTORY_KEY = "DataDelveHistory alpha 1" local Types = require(script.Parent.Types) local History = {} History.__index = History function History.new(gameId: number) local self = setmetatable({ gameId = tostring(gameId), }, History) -- Sorted by most re...
906
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/Pages.luau
luau
.luau
-- Wrapper for page APIs -- TBH this causes too much indirection, kind of annoying to use local Pages = {} Pages.__index = Pages type PagesState = unknown type PagesInterface = { initialize: () -> (PagesState?, string?), next: (PagesState) -> { items: { unknown }?, isFinished: boolean } | { error: string }, } funct...
767
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/Session.luau
luau
.luau
-- Main interface with datastores local Types = require(script.Parent.Types) local Pages = require(script.Parent.Pages) local DataStoreService = game:GetService("DataStoreService") local Settings = require(script.Parent.Settings) local Session = {} Session.__index = Session -- Static function Session.new() local...
2,392
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/Settings.luau
luau
.luau
--!strict local ViewerTypes = require(script.Parent.UI.Viewers.Types) local BufferViewerTypes = require(script.Parent.UI.BufferViewers.Types) local MAIN_SETTINGS_KEY = "DataDelveSetting alpha 1" export type SettingsData = { themePreset: string, themeAccent: string, hideGameName: boolean, highlightColors: "Defaul...
378
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/Transactor.luau
luau
.luau
--!strict export type Transaction = () -> () export type TransactorImplementation = { __index: TransactorImplementation, new: () -> Transactor, destroy: (Transactor) -> (), transact: (Transactor, Transaction) -> boolean, } export type TransactorFields = { locked: boolean, lockedChanged: RBXScriptSignal, _lo...
288
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/Types.luau
luau
.luau
--!strict -- I was going to use this more, but I forgot about it. Now it houses these two types. type OldDataStoreConnectionBase = { name: string, scope: string?, isOrdered: boolean, } type OldAllScopesDataStoreConnection = OldDataStoreConnectionBase & { isOrdered: false, allScopes: true, } type OldNormalDataSto...
292
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/BufferViewers/Deserializer.luau
luau
.luau
--!strict local SelectionService = game:GetService("Selection") local ScriptEditorService = game:GetService("ScriptEditorService") local Types = require(script.Parent.Types) local ViewerTypes = require(script.Parent.Parent.Viewers.Types) local UIMessages = require(script.Parent.Parent.UIMessages) local Theme = requir...
2,767
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/BufferViewers/Hex/DataInspector.luau
luau
.luau
--!strict -- I will document later. For now, good luck! 🫡 export type DataInspectorSizing = "fillContainer" | "fillContainerY" export type DataInspectorNewParams = { container: GuiObject, -- Default is "fillContainer" sizing: DataInspectorSizing?, theme: ThemeData, } export type ThemeData = { background: Color...
2,968
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/BufferViewers/Hex/FormProvider/init.luau
luau
.luau
--!strict local HexEditor = require(script.Parent.HexEditor) local Validators = require(script.Parent.Parent.Parent.Parent.Validators) local constrainTextBoxStyleState = require(script.Parent.Parent.Parent.Utilities.constrainTextBoxStyleState) local StyleState = script.Parent.Parent.Parent.StyleState local LabelStyl...
1,167
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/BufferViewers/Hex/HexEditor.luau
luau
.luau
--!strict -- I will document later. For now, good luck! 🫡 -- Parameters when using HexEditor.new(container, params, dependencies): -- "fillContainer" makes the hex editor fill up the entire container (UDim2.fromScale(1, 1)) -- "fillContainerY" makes the hex hex editor fill up the Y-axis, but take up only as much spa...
15,219
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/BufferViewers/Hex/init.luau
luau
.luau
--!strict local Theme = require(script.Parent.Parent.Theme) local Types = require(script.Parent.Types) local HexEditor = require(script.HexEditor) local DataInspector = require(script.DataInspector) local FormProvider = require(script.FormProvider) export type HexImplementation = { __index: HexImplementation, from...
1,373
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/BufferViewers/Types.luau
luau
.luau
--!strict local UIMessages = require(script.Parent.Parent.UIMessages) local Theme = require(script.Parent.Parent.Theme) export type BufferViewerMode = "Hex" | "Deserializer" export type BufferViewerFromOptions = { uiMessages: UIMessages.UIMessages, theme: Theme.Theme, inputReceiver: GuiObject, widget: PluginGui,...
187
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/ModalState.luau
luau
.luau
--!strict -- Keeps track if the UI has a modal or not. type ModalStateImplementation = { __index: ModalStateImplementation, new: () -> ModalState, push: (ModalState) -> (), pop: (ModalState) -> (), wrap: <T>(ModalState, action: () -> T) -> T, pushId: (ModalState, id: string) -> (), popId: (ModalState, id...
357
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/PopupHelper/init.luau
luau
.luau
-- Helps with popup stuff -- `clamp` clamps an object so it doesn't go out of bounds of a container -- `attach` attach an object to another object so it moves with that object -- `modal` turns an object into a modal so it blocks input from other objects -- `attach` and `modal` return objects that should be destroyed on...
1,956
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/BackgroundStyleState.luau
luau
.luau
local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.StyleStateHelper) local BackgroundStyleState = {} BackgroundStyleState.__index = BackgroundStyleState type BackgroundStyleStateOptions = { style: "default" | "popup" | "image" | "header", } function BackgroundStyleSta...
373
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/BreadcrumbsStyleState/init.luau
luau
.luau
-- Handles bread crumbs -- If the breadcrumbs is too long for the window, it will switch into a dropdown local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.StyleStateHelper) local ButtonStyleState = require(script.Parent.ButtonStyleState) local SelectStyleState = requi...
2,346
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/ButtonStyleState.luau
luau
.luau
local StyleStateHelper = require(script.Parent.StyleStateHelper) local ButtonStyleState = {} ButtonStyleState.__index = ButtonStyleState export type ButtonStyle = "primary" | "secondary" | "transparent" | "dormant" | "input" export type ButtonStyleStateFromOptions = { style: ButtonStyle | nil, disabled: boolean?, }...
1,361
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/CheckboxStyleState.luau
luau
.luau
local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local ButtonStyleState = require(script.Parent.Parent.ButtonStyleState) local CheckboxStyleState = {} CheckboxStyleState.__index = CheckboxStyleState export type CheckboxOptions = { default: b...
778
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/DatePickerStyleState.luau
luau
.luau
--!strict -- This wraps over TextBox -- Maybe later, can adjust for other locales. -- Also could add a calender popup. -- Use :getValue to get the value (unix timestamp milliseconds) -- Valid Formats: -- MM/DD/YY -- MM-DD-YY -- Month Day, Year -- Month Day -- ISO 8601 local TextBoxStyleState = require(script.Parent...
1,661
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/OverlayTextBoxStyleState.luau
luau
.luau
--!strict -- Only works with text box that are not multiline -- Does not support text boxes with UIPadding that uses Scale local TextService = game:GetService("TextService") local Players = game:GetService("Players") local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local Theme = require(script...
1,201
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/SelectStyleState/init.luau
luau
.luau
--!strict local TextService = game:GetService("TextService") local TweenService = game:GetService("TweenService") local Theme = require(script.Parent.Parent.Parent.Theme) local PopupHelper = require(script.Parent.Parent.Parent.PopupHelper) local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local...
2,305
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/ShortcutsTextBoxStyleState/init.luau
luau
.luau
--!strict -- This handles "shortcuts text box" which are text box with shortcuts that auto replace special sequences. -- Shortcuts: -- @username: This will replace @username with the id of the user with that name -- Use :getText(errorHandler) to get the text instead of textBox.Text -- Must pass in a function to han...
662
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/ShortcutsTextBoxStyleState/parseShortcuts.luau
luau
.luau
--!strict export type ShortcutType = "normal" | "escapedNormal" | "mention" export type ShortcutPiece = { type: ShortcutType, content: string, -- "escapedNormal" will always start with \\ which should be ignored -- "mention" will always start with @ which should be ignored } export type ShortcutsString = { Shortc...
1,006
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/SwitchStyleState.luau
luau
.luau
--!strict -- Same as Checkbox, just styled differently local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local ButtonStyleState = require(script.Parent.Parent.ButtonStyleState) local SwitchStyleState = {} SwitchStyleState.__index = SwitchStyleState export type SwitchOptions = { default: boolea...
579
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Input/TextBoxStyleState/init.luau
luau
.luau
local PopupHelper = require(script.Parent.Parent.Parent.PopupHelper) local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local TextBoxStyleState = {} TextBoxStyleState.__index = TextBoxStyleState function TextBoxStyleState.from(theme: any, textBox: TextBox & { UIStroke: UIStroke }) local self = s...
1,112
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/LabelStyleState.luau
luau
.luau
local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.StyleStateHelper) local LabelStyleState = {} LabelStyleState.__index = LabelStyleState export type LabelStyleStateFromOptions = { style: "text" | "error" | nil, emphasis: "normal" | "light" | nil } function LabelStyl...
574
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/LoadMoreListStyleState.luau
luau
.luau
-- Provide a `createItemStyleState(...)` function. -- Other consumers of the StyleState can then call `:add(...)` which will use the `createItemStyleState` to add a StyleState into the list. -- `Pages` does this when a new page is loaded. -- -- StyleStates produced from `createItemStyleState` can have method `setSelect...
940
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/ScrollingFrameStyleState.luau
luau
.luau
--!strict local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.StyleStateHelper) local ScrollingFrame = {} ScrollingFrame.__index = ScrollingFrame function ScrollingFrame.from(theme, scrollingFrame: ScrollingFrame) local self = setmetatable({ scrollingFrame = scrollin...
190
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/SeparatorStyleState.luau
luau
.luau
local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.StyleStateHelper) local SeparatorStyleState = {} SeparatorStyleState.__index = SeparatorStyleState function SeparatorStyleState.from(theme, separator: Frame) local self = setmetatable({ separator = separator, them...
263
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/StyleStateHelper.luau
luau
.luau
export type TransitionSpeed = "fast" | "slow" | "instant" | "veryFast" | "superDuperFast" | nil export type StyleState = { from: (theme: any, object: GuiObject, ...any) -> StyleState, update: (StyleState, TransitionSpeed) -> (), destroy: (StyleState, completely: boolean?) -> (), } local TweenService = game:GetServ...
550
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/StyleStateWrapper.luau
luau
.luau
-- Utility class useful for one-off style states. -- See `UI.createUserCard` for example local StyleStateHelper = require(script.Parent.StyleStateHelper) local StyleStateWrapper = {} StyleStateWrapper.__index = StyleStateWrapper export type StyleStateWrapperOptions = { autoFollowTheme: boolean?, -- default: true o...
352
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/TabsStyleState/init.luau
luau
.luau
local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.StyleStateHelper) local ButtonStyleState = require(script.Parent.ButtonStyleState) local TabsStyleState = {} TabsStyleState.__index = TabsStyleState function TabsStyleState.from(theme, frame: Frame) local buttons = {}...
736
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Utility/ConfirmDialogStyleState/init.luau
luau
.luau
-- TODO: should auto-follow theme when using.createDialog local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local PopupHelper = require(script.Parent.Parent.Parent.PopupHelper) local BackgroundStyleState = require(script.Parent.Parent.BackgroundStyleState) local ButtonStyleState = require(script...
734
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Utility/ContextMenuStyleState/init.luau
luau
.luau
-- TODO: should auto-follow theme when using.createMenu local TweenService = game:GetService("TweenService") local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local PopupHelper = require(script.Parent.Parent.Parent.PopupHelper) local TRY_CLOSE_SUBMENU_DELAY = 0.275 local ContextMenuStyleState ...
2,844
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Utility/LoadingBarStyleState/init.luau
luau
.luau
-- Should be used ephemerally -- Example: -- ``` -- local styleState = LoadingBarStyleState.from(theme, frame) -- task.spawn(styleState.animate, styleState) -- task.wait(5) -- styleState:destroy() -- ``` local Theme = require(script.Parent.Parent.Parent.Theme) local GRADIENT_BILINEAR = NumberSequence.new({ NumberSe...
684
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Utility/PopupFormStyleState/init.luau
luau
.luau
--!strict local StyleStateHelper = require(script.Parent.Parent.StyleStateHelper) local StyleStateWrapper = require(script.Parent.Parent.StyleStateWrapper) local PopupHelper = require(script.Parent.Parent.Parent.PopupHelper) local BackgroundStyleState = require(script.Parent.Parent.BackgroundStyleState) local ButtonS...
639
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/StyleState/Utility/SkeletonStyleState/init.luau
luau
.luau
-- Should be used ephemerally -- Just apply this to any object. -- Objects in the children that have attribute "SkeletonPlaceholder" will be styled. -- If they also have "DeleteWithSkeleton" attribute they will be deleted when the skeleton is deleted. --- Call :animate to animate the skeleton local TweenService = ga...
587
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Theme/Oklab.luau
luau
.luau
local Oklab = {} function Oklab.fromLinearSrgb(c: vector): vector local l = 0.4122214708 * c.x + 0.5363325363 * c.y + 0.0514459929 * c.z; local m = 0.2119034982 * c.x + 0.6806995451 * c.y + 0.1073969566 * c.z; local s = 0.0883024619 * c.x + 0.2817188376 * c.y + 0.6299787005 * c.z; local l_ = l ^ (1/3); local m_ ...
833
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Theme/init.luau
luau
.luau
--!strict local StudioSettings = settings().Studio local Oklab = require(script.Oklab) local Theme = {} Theme.__index = Theme Theme.accentHues = { red = 0, orange = 21, yellow = 42, yellowGreen = 72, green = 115, greenBlue = 140, seaGreen = 165, cyan = 190, blue = 220, purpleBlue = 235, purple = 265, pin...
8,678
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Tooltip/init.luau
luau
.luau
--!strict local TextService = game:GetService("TextService") local TweenService = game:GetService("TweenService") local PopupHelper = require(script.Parent.PopupHelper) local Tooltip = {} Tooltip.__index = Tooltip local FrameTemplate = script.FrameTemplate local DropShadowTemplate = script.DropShadowTemplate local ...
1,717
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/UIMessages/init.luau
luau
.luau
-- Utility to send alerts/toasts -- Layout manually calculated (no AutomaticSize). local TweenService = game:GetService("TweenService") local TextService = game:GetService("TextService") local StyleState = script.Parent.StyleState local PopupHelper = require(script.Parent.PopupHelper) local StyleStateWrapper = requi...
2,161
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/TimestampHelper.luau
luau
.luau
--!strict local TimestampHelper = {} -- Guesses what time of timestamp a number is, or nil if it doesn't look like a timestamp -- The second parameter is if the guess should be conservative and guess it's not a timestamp -- more often. function TimestampHelper.guessTimestampType(n: number, conservative: "conservative...
315
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/byteLengthToReadableString.luau
luau
.luau
--!strict local giga = 10^9 local mega = 10^6 local kilo = 10^3 return function(bytes: number) return tostring(bytes):reverse():gsub("(%d%d%d)", "%1,"):gsub(",$", ""):reverse() end
61
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/checkTrulyVisible.luau
luau
.luau
--!strict return function(object: GuiObject): boolean local current: any = object while current do if (not current) or not current.Visible then return false end current = current.Parent if current:IsA("LayerCollector") then break elseif not current:IsA("GuiObject") then return false end end re...
88
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/constrainTextBoxStyleState.luau
luau
.luau
--!strict -- Makes sure a TextBox matches a validator. return function(textBoxStyleState, validators: { (string) -> (boolean, string?) }) textBoxStyleState.textBox:GetPropertyChangedSignal("Text"):Connect(function() if textBoxStyleState.textBox.Text == "" then textBoxStyleState:setError(nil :: string?):update("...
142
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/createTabSwitchGroup.luau
luau
.luau
--!strict -- Makes it so when you press tab, it switches between the TextBoxes. local checkTrulyVisible = require(script.Parent.checkTrulyVisible) return function(textBoxes: { TextBox }) local currentSelected = nil local currentConnection: RBXScriptConnection? = nil for i, textBox in textBoxes do -- Don't need...
410
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/disableFrameWhenModalAppears.luau
luau
.luau
-- `PopupHelper.modal` creates a frame to block input, but it does not block MouseMovement inputs. -- To fix that, this utility function will detect when the input blocking frame of `PopupHelper.modal` -- appears and disable `Interactable` for all the frames you give it. This will prevent MouseMovement -- inputs from b...
334
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/getHighlightColors.luau
luau
.luau
-- Gets highlight colors for the TreeViewer. Depends on global state from `Settings` -- to see if it should use the built-in theme or the script editors theme. export type Colors = { plain: Color3, background: Color3, hoverBackground: Color3, selectBackground: Color3, scrollbar: Color3, mainAccent: Color3, r...
909
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/lockObjectWithoutResize.luau
luau
.luau
--!strict -- Sets the position of an object without triggering AutomaticSize resizing. -- Assumes UIPadding only has offset padding. -- EXAMPLE: This is used in the `Insert Into/After` menus for the expand button which is -- positioned at the top right. return function( object: GuiObject, container: GuiOb...
240
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/promptKeyValueForm.luau
luau
.luau
-- Form that has two fields (each one is optional, but you must have one field active) -- Used in: -- - Insert Into/After -- - Insert for OrderedDataStore local Assets = script.Parent.Parent.Assets local StyleState = script.Parent.Parent.StyleState local StyleStateWrapper = require(StyleState.StyleStateWrapper) local...
1,849
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Utilities/showShadowOnScroll.luau
luau
.luau
return function(scrollingFrame: ScrollingFrame, shadow: Frame) return scrollingFrame:GetPropertyChangedSignal("CanvasPosition"):Connect(function() shadow.Visible = scrollingFrame.CanvasPosition.Y > 10 end) end
45
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Viewers/Code/CodeEditor.luau
luau
.luau
--!strict local TextService = game:GetService("TextService") local Types = require(script.Parent.Types) export type NewOptions = { theme: Types.Theme, doLex: (source: string) -> {Token}, } export type Token = { kind: string, start: number, length: number, } type CodeEditorObject = Types.TextEditorObject & { _...
3,219
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Viewers/Code/DumbEditor.luau
luau
.luau
--!strict -- Editor with missing no highlighting or error capabilties. local Types = require(script.Parent.Types) export type NewOptions = { theme: Types.Theme, } export type DumbEditorObject = Types.TextEditorObject & { _textChanged: BindableEvent, _activeErrorsChanged: BindableEvent, _frame: ScrollingFrame,...
916
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Viewers/Code/Types.luau
luau
.luau
--!strict export type Theme = { padding: {top: number, left: number, bottom: number, right: number}, font: Font, -- should be monospace textSize: number, backgroundColor: Color3, textColor: Color3, disabledTextColor: Color3, scrollbarThickness: number, scrollbarColor: Color3, tokenColors: {[string]: string},...
301
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Viewers/Code/init.luau
luau
.luau
--!strict local Settings = require(script.Parent.Parent.Parent.Settings) local Theme = require(script.Parent.Parent.Theme) local UIMessages = require(script.Parent.Parent.UIMessages) local json5 = require(script.Parent.Parent.Parent.json5) local JSONHelper = require(script.Parent.Parent.Parent.JSONHelper) local Type...
2,306
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Viewers/Types.luau
luau
.luau
--!strict local JSONHelper = require(script.Parent.Parent.Parent.JSONHelper) local Theme = require(script.Parent.Parent.Theme) local UIMessages = require(script.Parent.Parent.UIMessages) local ModalState = require(script.Parent.Parent.ModalState) export type ViewerMode = "Tree" | "Code" export type KeyInfo = { Crea...
615
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Views/HistoryView.luau
luau
.luau
--!strict local Theme = require(script.Parent.Parent.Theme) local History = require(script.Parent.Parent.Parent.History) local Types = require(script.Parent.Parent.Parent.Types) local Assets = script.Parent.Parent.Assets local StyleState = script.Parent.Parent.StyleState local StyleStateHelper = require(StyleState.S...
1,490
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Views/OrderedDataStoreView/OrderedDataStoreKeyStyleState.luau
luau
.luau
local OrderedDataStoreKeyStyleState = {} OrderedDataStoreKeyStyleState.__index = OrderedDataStoreKeyStyleState function OrderedDataStoreKeyStyleState.from(theme, highlightColors, frame) local self = setmetatable({ theme = theme, frame = frame, _highlightColors = highlightColors, selecting = false, _disabl...
503
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Views/OrderedDataStoreView/init.luau
luau
.luau
--!strict local DESCENDING_ICON = "rbxassetid://17650920474" local ASCENDING_ICON = "rbxassetid://17650919434" local rfmt = require(script.Parent.Parent.Parent.rfmt) local StyleState = script.Parent.Parent.StyleState local Assets = script.Parent.Parent.Assets local Settings = require(script.Parent.Parent.Parent.Set...
3,886
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Views/SearchView.luau
luau
.luau
--!strict local TweenService = game:GetService("TweenService") local Assets = script.Parent.Parent.Assets local StyleState = script.Parent.Parent.StyleState local Theme = require(script.Parent.Parent.Theme) local PopupHelper = require(script.Parent.Parent.PopupHelper) local ViewerTypes = require(script.Parent.Parent...
1,590
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Views/SettingsView/AccentColorButtonStyleState.luau
luau
.luau
local TweenService = game:GetService("TweenService") local Theme = require(script.Parent.Parent.Parent.Theme) local StyleStateHelper = require(script.Parent.Parent.Parent.StyleState.StyleStateHelper) local ButtonStyleState = require(script.Parent.Parent.Parent.StyleState.ButtonStyleState) local AccentColorButtonStyl...
341
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Views/SettingsView/init.luau
luau
.luau
--!strict local SelectionService = game:GetService("Selection") local ServerScriptService = game:GetService("ServerScriptService") local ChangeHistoryService = game:GetService("ChangeHistoryService") local rfmt = require(script.Parent.Parent.Parent.rfmt) local StyleState = script.Parent.Parent.StyleState local Asset...
2,365
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Views/VersionsView.luau
luau
.luau
--!strict local DESCENDING_ICON = "rbxassetid://17650920474" local ASCENDING_ICON = "rbxassetid://17650919434" local rfmt = require(script.Parent.Parent.Parent.rfmt) local StyleState = script.Parent.Parent.StyleState local Assets = script.Parent.Parent.Assets local Session = require(script.Parent.Parent.Parent.Sess...
3,523
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Widgets/BufferWidget.luau
luau
.luau
--!strict local plugin = script:FindFirstAncestorOfClass("Plugin") local StudioService = game:GetService("StudioService") local Settings = require(script.Parent.Parent.Parent.Settings) local UIMessages = require(script.Parent.Parent.UIMessages) local Theme = require(script.Parent.Parent.Theme) local Types = require(...
1,470
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/Widgets/SingleKeyWidget.luau
luau
.luau
--!strict -- This is a widget for a single key, used for "Open in New Widget" local plugin = script:FindFirstAncestorOfClass("Plugin") local HttpService = game:GetService("HttpService") local Theme = require(script.Parent.Parent.Theme) local Session = require(script.Parent.Parent.Parent.Session) local Transactor = r...
1,524
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/UI/init.luau
luau
.luau
local rfmt = require(script.Parent.rfmt) local Types = require(script.Parent.Types) local Theme = require(script.Theme) local Validators = require(script.Parent.Validators) local PopupHelper = require(script.PopupHelper) local Tooltip = require(script.Tooltip) local Assets = script.Assets local StyleState = script.S...
4,604
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/Validators.luau
luau
.luau
--!strict export type Validator = (any) -> (boolean, string?) -- return 1: success, return 2: reason local Validators: { [string]: Validator } = {} local function isValidInteger(str: unknown): boolean local number = tonumber(str) if number then local isValidInteger = (number == math.floor(number)) and number == n...
687
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/main.server.luau
luau
.luau
--!strict type App = { new: (id: string) -> App, toggleEnabled: (App) -> (), getEnabled: (App) -> boolean, enabledChanged: RBXScriptSignal, } local IS_CANARY = script.Parent.IsCanaryRelease.Value local RunService = game:GetService("RunService") local App = require(script.Parent.App) :: App local ClientFallback...
495
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/rfmt.luau
luau
.luau
-- Rich-Text ForMaT -- Convience functions for wrapping things in rich text tags. local rfmt = {} function rfmt.code(s: string): string return `<font face="RobotoMono">{s}</font>` end return rfmt
53
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/tests/JSONHelper.server.luau
luau
.luau
local JSONHelper = require(script.Parent.Parent.JSONHelper) assert(JSONHelper.toInputString({}, "array") == "[]") assert(JSONHelper.toInputString({ 1, 2, 3, 4, 5, 6 }, "array") == "[]") assert(JSONHelper.toInputString({}, "object") == "{}") assert(JSONHelper.toInputString({ hey = "world" }, "object") == "{}") assert...
275
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/tests/TreeViewer/fuzzJSON.luau
luau
.luau
--!strict -- Actions to generate random JSON+buffer-acceptable value type Action = (depth: number) -> any local MAX_DEPTH = 10 local actions: { Action } local stringAction: Action = function() local s = table.create(12) while true do local got = math.random() if got < 0.3 then break else table.insert(...
483
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/tests/TreeViewer/fuzzUserIds.luau
luau
.luau
--!strict return function() local ids = {} for _ = 1, math.random(0, 100) do table.insert(ids, math.random(1, 10_000_000)) end return ids end
51
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/tests/TreeViewer/init.server.luau
luau
.luau
-- Tests for tree viewer local FUZZ_TESTS = 25 local Theme = require(script.Parent.Parent.UI.Theme) local Tree = require(script.Parent.Parent.UI.Viewers.Tree) local fuzzUserIds = require(script.fuzzUserIds) local fuzzJSON = require(script.fuzzJSON) type SearchForQuery = { key: string | number, value: any?, isContai...
14,064
pinehappi/DataDelve
pinehappi-DataDelve-191db10/src/tests/Validators.server.luau
luau
.luau
local Validators = require(script.Parent.Parent.Validators) assert(Validators.empty(math.random(100000000))) assert(Validators.integer(0)) assert(Validators.integer(10)) assert(Validators.integer(-10)) assert(not Validators.integer(0.001)) assert(not Validators.integer(10.1)) assert(not Validators.integer(-10.1)) ass...
199
Kampfkarren/ultimate-list
Kampfkarren-ultimate-list-d166119/src/Components/ScrollingFrame.luau
luau
.luau
local RunService = game:GetService("RunService") local Src = script:FindFirstAncestor("ultimate-list") local DataSources = require(Src.DataSources) local Dimensions = require(Src.Dimensions) local React = require(Src.Parent.React) local ReactBindingsRenderer = require(Src.Renderers.ReactBindingsRenderer) local ReactSt...
1,184
Kampfkarren/ultimate-list
Kampfkarren-ultimate-list-d166119/src/Components/init.luau
luau
.luau
local ScrollingFrame = require(script.ScrollingFrame) local Components = {} Components.ScrollingFrame = ScrollingFrame return Components
27
Kampfkarren/ultimate-list
Kampfkarren-ultimate-list-d166119/src/DataSources/DataSourceMethods.luau
luau
.luau
local Src = script:FindFirstAncestor("ultimate-list") local DataSources = require(script.Parent) local exhaustiveMatch = require(Src.Util.exhaustiveMatch) local DataSourceMethods = {} function DataSourceMethods.get<T>( dataSource: DataSources.DataSource<T>, startIndex: number ): DataSources.DataSourceCursor<T>? a...
656
Kampfkarren/ultimate-list
Kampfkarren-ultimate-list-d166119/src/DataSources/init.luau
luau
.luau
local DataSources = {} export type DataSource<T> = { type: "array", array: { T }, } | { type: "mutableSource", methods: MutableDataSourceMethods<T>, } export type MutableDataSourceMethods<T> = { -- Get a cursor to the nth element get: (startIndex: number) -> DataSourceCursor<T>?, -- Get the total leng...
532
Kampfkarren/ultimate-list
Kampfkarren-ultimate-list-d166119/src/DebugFlags.luau
luau
.luau
local DebugFlags = {} DebugFlags.shouldLog = false return DebugFlags
16
Kampfkarren/ultimate-list
Kampfkarren-ultimate-list-d166119/src/Dimensions/DimensionsMethods.luau
luau
.luau
-- TODO: Throughout this, assert that UDims are what is expected (scale only on opposite direction) local Src = script:FindFirstAncestor("ultimate-list") local DataSourceMethods = require(Src.DataSources.DataSourceMethods) local DataSources = require(Src.DataSources) local Dimensions = require(script.Parent) local exh...
1,922
Kampfkarren/ultimate-list
Kampfkarren-ultimate-list-d166119/src/Dimensions/adjustPositionToScrollAxis.luau
luau
.luau
local Src = script:FindFirstAncestor("ultimate-list") local exhaustiveMatch = require(Src.Util.exhaustiveMatch) local function adjustPositionToScrollAxis(position: UDim2, scrollAxis: number, direction: "x" | "y"): UDim2 if direction == "x" then return UDim2.new(0, position.X.Offset - scrollAxis, position.Y.Scale, ...
140