local C=script.Parent.Parent.Parent local U=C.Parent local Z=require(U.Sift)local b=require(U.Roact)local p=b.createElement local w=require(C.Utility.FrameVisualizer)local m=require(script.Parent.ContextMenu)local O=b.PureComponent:extend(script.Name)function O.render(C)local U=p(m,Z.Dictionary.join({Size=UDim2.new(0,200,0,0);FitContents=true;UseIcon=C.props.Icon,Options={{Selected=true,Text="\083\101\108\101\099\116\101\100",Icon="\105\109\097\103\101\115\047\114\111\098\108\111\120\047\105\099\111\110\115\047\097\099\116\105\111\110\115\047\114\097\110\100\111\109\105\122\101\047\049\120";OnClicked=print},{Selected=false,Text="\068\101\115\101\108\101\099\116\101\100";Icon="\105\109\097\103\101\115\047\114\111\098\108\111\120\047\105\099\111\110\115\047\099\111\110\116\114\111\108\115\047\107\101\121\115\047\099\111\109\109\097\110\100\047\049\120";OnClicked=print};{IsDivider=true},{Disabled=true;Text="\068\105\115\097\098\108\101\100";Icon="\105\109\097\103\101\115\047\114\111\098\108\111\120\047\105\099\111\110\115\047\099\111\110\116\114\111\108\115\047\107\101\121\115\047\097\108\116\047\049\120";OnClicked=print},{Selected=true;Disabled=true;Text="\068\105\115\097\098\108\101\100\083\101\108\101\099\116\101\100",Icon="\105\109\097\103\101\115\047\114\111\098\108\111\120\047\105\099\111\110\115\047\103\114\097\112\104\105\099\047\098\108\111\099\107\116\104\101\102\116\095\050\120\108\047\049\120";OnClicked=print},{Selected=false;Text="\078\111 \105\099\111\110";OnClicked=print};{IsDivider=true},{Selected=true;Text="\078\111 \105\099\111\110 \115\101\108\101\099\116\101\100",OnClicked=print}}},C.props.Props))if C.props.Wireframe then return p(w,{},U)else return U end end return{controls={Wireframe=false;Icon=true};stories={ContextMenu=function(C)return p(O,C.controls)end}}
local Winro = script.Parent.Parent.Parent
local Packages = Winro.Parent

local Sift = require(Packages.Sift)
local Roact = require(Packages.Roact)
local new = Roact.createElement

local FrameVisualizer = require(Winro.Utility.FrameVisualizer)
local ContextMenu = require(script.Parent.ContextMenu)

local ContextMenuStory = Roact.PureComponent:extend(script.Name)

function ContextMenuStory:render()
	local Element = new(ContextMenu, Sift.Dictionary.join({
		Size = UDim2.new(0, 200, 0, 0),
		FitContents = true,
		UseIcon = self.props.Icon,
		Options = {
			{
				Selected = true,
				Text = 'Selected',
				Icon = 'images/roblox/icons/actions/randomize/1x',
				OnClicked = print
			},
			{
				Selected = false,
				Text = 'Deselected',
				Icon = 'images/roblox/icons/controls/keys/command/1x',
				OnClicked = print
			},
			{ IsDivider = true },
			{
				Disabled = true,
				Text = 'Disabled',
				Icon = 'images/roblox/icons/controls/keys/alt/1x',
				OnClicked = print
			},
			{
				Selected = true,
				Disabled = true,
				Text = 'DisabledSelected',
				Icon = 'images/roblox/icons/graphic/blocktheft_2xl/1x',
				OnClicked = print
			},
			{
				Selected = false,
				Text = 'No icon',
				OnClicked = print
			},
			{ IsDivider = true },
			{
				Selected = true,
				Text = 'No icon selected',
				OnClicked = print
			},
		}
	}, self.props.Props))

	if self.props.Wireframe then
		return new(FrameVisualizer, {}, Element)
	else
		return Element
	end
end

return {
	controls = {
		Wireframe = false,
		Icon = true,
	},
	stories = {
		ContextMenu = function (props)
			return new(ContextMenuStory, props.controls)
		end
	}
}
