local D=script.Parent.Parent.Parent.Parent local E=D.Parent local s=require(D.Utility.FrameVisualizer)local d=require(E.Sift)local V=require(E.Roact)local B=V.createElement local v=require(script.Parent.TitleBar)local w=V.PureComponent:extend(script.Name)function w.render(D)local E=B(v,d.Dictionary.join({Icon=D.props.Icon and"\105\109\097\103\101\115\047\114\111\098\108\111\120\047\105\099\111\110\115\047\108\111\103\111\047\115\116\117\100\105\111\108\111\103\111\095\115\109\097\108\108\047\049\120"or nil,ReleaseText="\083\116\111\114\121",AlwaysShowClose=D.props.AlwaysShowClose,BackgroundColor="\099\111\108\111\114\115\047\066\097\099\107\103\114\111\117\110\100\047\070\105\108\108\095\067\111\108\111\114\047\083\111\108\105\100\095\066\097\099\107\103\114\111\117\110\100\047\066\097\115\101",Height=D.props.Size=="\083\116\097\110\100\097\114\100"and 32 or D.props.Size=="\076\097\114\103\101"and 48 or 29,OnClose=print;CaptionButtonWidth=D.props.Size=="\083\109\097\108\108"and 29 or 32},D.props.Props))if D.props.Wireframe then return B(s,{Size=UDim2.new(1,0,1,0)},E)else return E end end return{controls={AlwaysShowClose=false;Wireframe=false,Icon=false;Size={"\083\116\097\110\100\097\114\100";"\076\097\114\103\101","\083\109\097\108\108"}},stories={TitleBar=function(D)return B(w,D.controls)end}}
-- TitleBar: The top bar of a window component

local Winro = script.Parent.Parent.Parent.Parent
local Packages = Winro.Parent

local FrameVisualizer = require(Winro.Utility.FrameVisualizer)

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

local TitleBar = require(script.Parent.TitleBar)

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

function TitleBarStory:render()
	
	local TitleBar = new(TitleBar, Sift.Dictionary.join({
		Icon = self.props.Icon and 'images/roblox/icons/logo/studiologo_small/1x' or nil,
		ReleaseText = 'Story',
		AlwaysShowClose = self.props.AlwaysShowClose,
		BackgroundColor = 'colors/Background/Fill_Color/Solid_Background/Base',
		Height = self.props.Size == 'Standard' and 32 or self.props.Size == 'Large' and 48 or 29,
		OnClose = print,
		CaptionButtonWidth = self.props.Size == 'Small' and 29 or 32
	}, self.props.Props))

	if self.props.Wireframe then
		return new(FrameVisualizer, {
			Size = UDim2.new(1, 0, 1, 0),
		}, TitleBar)
	else
		return TitleBar
	end
end

return {
	controls = {
		AlwaysShowClose = false,
		Wireframe = false,
		Icon = false,
		Size = {'Standard', 'Large', 'Small'},
	},
	stories = {
		TitleBar = function(props)
			return new(TitleBarStory, props.controls)
		end
	}
}
