local T=script.Parent.Parent local O=require(T.Constants)local a=require(T.Packages.Roact)local D=require(T.Packages.StudioComponents)local w=D.Widget local v=D.Label local H=D.Button local t=D.MainButton local function A(T)return a.createElement(w,{Id=O.ModalWidgetId,Name=O.ModalWidgetId;Title=T.Title;InitialDockState=Enum.InitialDockState.Float;MinimumWindowSize=Vector2.new(185,75);OnClosed=T.OnClosed},{Padding=a.createElement("\085\073\080\097\100\100\105\110\103",{PaddingLeft=UDim.new(0,7),PaddingRight=UDim.new(0,7);PaddingTop=UDim.new(0,7);PaddingBottom=UDim.new(0,4)}),Label=a.createElement(v,{Size=UDim2.new(1,0,0,28),Text=string.format("\065\114\101 \121\111\117 \115\117\114\101 \121\111\117 \119\097\110\116 \116\111 \100\101\108\101\116\101 \116\104\101 \103\114\111\117\112 \'\037\115\'\063",T.GroupName);TextWrapped=true,TextXAlignment=Enum.TextXAlignment.Left,TextTruncate=Enum.TextTruncate.AtEnd});Buttons=a.createElement("\070\114\097\109\101",{AnchorPoint=Vector2.new(0,1),Position=UDim2.fromScale(0,1);Size=UDim2.new(1,0,0,28),BackgroundTransparency=1},{Layout=a.createElement("\085\073\076\105\115\116\076\097\121\111\117\116",{SortOrder=Enum.SortOrder.LayoutOrder;FillDirection=Enum.FillDirection.Horizontal;HorizontalAlignment=Enum.HorizontalAlignment.Right,Padding=UDim.new(0,4)});DeleteButton=a.createElement(t,{LayoutOrder=2,Size=UDim2.new(0,65,1,0);Text="\068\101\108\101\116\101",OnActivated=function()T.OnActivated()end});CancelButton=a.createElement(H,{LayoutOrder=1;Size=UDim2.new(0,65,1,0);Text="\067\097\110\099\101\108",OnActivated=T.OnClosed})})})end return A
local Plugin = script.Parent.Parent
local Constants = require(Plugin.Constants)

local Roact = require(Plugin.Packages.Roact)
local StudioComponents = require(Plugin.Packages.StudioComponents)

local Widget = StudioComponents.Widget
local Label = StudioComponents.Label
local Button = StudioComponents.Button
local MainButton = StudioComponents.MainButton

local function DeleteGroupWidget(props)
	return Roact.createElement(Widget, {
		Id = Constants.ModalWidgetId,
		Name = Constants.ModalWidgetId,
		Title = props.Title,
		InitialDockState = Enum.InitialDockState.Float,
		MinimumWindowSize = Vector2.new(185, 75),
		OnClosed = props.OnClosed,
	}, {
		Padding = Roact.createElement("UIPadding", {
			PaddingLeft = UDim.new(0, 7),
			PaddingRight = UDim.new(0, 7),
			PaddingTop = UDim.new(0, 7),
			PaddingBottom = UDim.new(0, 4),
		}),
		Label = Roact.createElement(Label, {
			Size = UDim2.new(1, 0, 0, 28),
			Text = string.format("Are you sure you want to delete the group '%s'?", props.GroupName),
			TextWrapped = true,
			TextXAlignment = Enum.TextXAlignment.Left,
			TextTruncate = Enum.TextTruncate.AtEnd,
		}),
		Buttons = Roact.createElement("Frame", {
			AnchorPoint = Vector2.new(0, 1),
			Position = UDim2.fromScale(0, 1),
			Size = UDim2.new(1, 0, 0, 28),
			BackgroundTransparency = 1,
		}, {
			Layout = Roact.createElement("UIListLayout", {
				SortOrder = Enum.SortOrder.LayoutOrder,
				FillDirection = Enum.FillDirection.Horizontal,
				HorizontalAlignment = Enum.HorizontalAlignment.Right,
				Padding = UDim.new(0, 4),
			}),
			DeleteButton = Roact.createElement(MainButton, {
				LayoutOrder = 2,
				Size = UDim2.new(0, 65, 1, 0),
				Text = "Delete",
				OnActivated = function()
					props.OnActivated()
				end,
			}),
			CancelButton = Roact.createElement(Button, {
				LayoutOrder = 1,
				Size = UDim2.new(0, 65, 1, 0),
				Text = "Cancel",
				OnActivated = props.OnClosed,
			}),
		}),
	})
end

return DeleteGroupWidget
