local l_ChangeHistoryService_0 = game:GetService("ChangeHistoryService");
local l_GeometryService_0 = game:GetService("GeometryService");
local l_Workspace_0 = game:GetService("Workspace");
local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v4 = require(l_script_FirstAncestor_0.Packages.Dash);
local v5 = require(l_script_FirstAncestor_0.Packages.Framework);
local v6 = require(l_script_FirstAncestor_0.Packages.React);
local v7 = require(l_script_FirstAncestor_0.Src.Util.AvatarScalingTypes);
local v8 = require(l_script_FirstAncestor_0.Src.Components.AutoSetupContext);
local v9 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local v10 = require(l_script_FirstAncestor_0.Src.Util.SelectionWrapper);
local v11 = require(l_script_FirstAncestor_0.Src.Util.assetUriToId);
local v12 = require(l_script_FirstAncestor_0.Src.Util.findUnderlyingMeshAssetIds);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v14 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetupDisablePublish);
local v15 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerFixMeshSwitching);
local v16 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerScaleAfterAutosetup);
local v17 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetupTelemetry);
local v18 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetupTelemetryV2);
local l_Analytics_0 = v5.ContextServices.Analytics;
local function _(v20)
    if v20 == nil then
        return {
            type = "none"
        };
    else
        return {
            type = "hasSelection",
            target = v20
        };
    end;
end;
local function v36(v22, v23)
    local v24 = v4.keys(v7.types);
    table.sort(v24, function(v25, v26)
        return v7.types[v25].GuessMaxHeight < v7.types[v26].GuessMaxHeight;
    end);
    local v27 = nil;
    local v28 = nil;
    for _, v30 in v24, nil, nil do
        local v31 = v7.types[v30];
        if v23.ExtentsSize.Y < v31.GuessMaxHeight then
            v27 = v30;
            v28 = v31;
            break;
        end;
    end;
    assert(v28 ~= nil, "No scaling type info chosen");
    v7.setAvatarPartScaleTypeValueObjects(v22, v27);
    local l_BodyTypeScale_0 = v22.Humanoid:FindFirstChild("BodyTypeScale");
    local v33 = false;
    if l_BodyTypeScale_0 ~= nil then
        v33 = l_BodyTypeScale_0:IsA("NumberValue");
    end;
    assert(v33, "Couldn't find BodyTypeScale");
    l_BodyTypeScale_0.Value = v28.BodyTypeScale;
    local l_BodyProportionScale_0 = v22.Humanoid:FindFirstChild("BodyProportionScale");
    local v35 = false;
    if l_BodyProportionScale_0 ~= nil then
        v35 = l_BodyProportionScale_0:IsA("NumberValue");
    end;
    assert(v35, "Couldn't find BodyProportionScale");
    l_BodyProportionScale_0.Value = v28.BodyProportionScale;
end;
return function(v37)
    local v38 = l_Analytics_0:use();
    local v39 = v6.useContext(v8.Context);
    local v40 = v10:use():get();
    local v41, v42 = v6.useState(if v37 == nil then {
        type = "none"
    } else {
        type = "hasSelection",
        target = v37
    });
    if v15() then
        v6.useEffect(function()
            v42(function(v43)
                if v43.type == "none" then
                    local l_v37_0 = v37;
                    if l_v37_0 == nil then
                        return {
                            type = "none"
                        };
                    else
                        return {
                            type = "hasSelection",
                            target = l_v37_0
                        };
                    end;
                elseif v43.type == "hasSelection" then
                    if v37 == nil then
                        return v43;
                    else
                        return {
                            type = "hasSelection",
                            target = v37
                        };
                    end;
                else
                    return v43;
                end;
            end);
        end, {
            v37
        });
    end;
    local v45 = v6.useRef({});
    assert(v45.current ~= nil, v9.LUAU_ANALYZE_ERROR);
    local v52 = v6.useCallback(function(v46)
        assert(v37 ~= nil, "Inserting body with no target");
        l_ChangeHistoryService_0:SetWaypoint("Avatar Auto Setup");
        local v47 = v37.intendedName or v37.bodies[1].Name;
        if v47:lower():match((("%*$"):format(v9.BODY_MESH_SUFFIX))) then
            v47 = v47:sub(1, #v47 - #v9.BODY_MESH_SUFFIX);
        end;
        v46.Name = v47;
        assert(v46.PrimaryPart ~= nil, "Auto setup returned model with no primary part");
        if v16() then
            v46:ScaleTo((v37.bodies[1].Size / v37.bodies[1].MeshSize).X);
        end;
        v46.Parent = l_Workspace_0;
        v46.PrimaryPart.PivotOffset = v46:GetBoundingBox() * v46.PrimaryPart.CFrame:Inverse();
        v46:PivotTo(v37.bodies[1].ExtentsCFrame);
        v36(v46, v37.bodies[1]);
        for _, v49 in v37.otherChildren, nil, nil do
            v49:Clone().Parent = v46;
        end;
        local l_CFrame_0 = assert(l_Workspace_0.CurrentCamera, "No Workspace Camera").CFrame;
        local v51 = (l_CFrame_0.Position + l_CFrame_0.LookVector * 10) + Vector3.new(0, v37.bodies[1].Size.Y * 0.5, 0);
        if not v14() and not v18() then
            v46:SetAttribute(v9.ATTRIBUTE_PREFIX .. v9.ATTRIBUTE_CREATED_BY_AUTO_SETUP, true);
        else
            v46:SetAttribute(v9.ATTRIBUTE_CREATED_BY_AUTO_SETUP, true);
        end;
        if v18() then
            v46:SetAttribute(v9.ATTRIBUTE_AUTO_SETUP_INPUT_ASSET, v11(v37.bodies[1].MeshId));
        end;
        v46:PivotTo(CFrame.lookAt(v51, (Vector3.new(l_CFrame_0.Position.X, v51.Y, l_CFrame_0.Position.Z))));
        v40:Set({
            v46
        });
        v42({
            type = "none"
        });
    end, {
        v37
    });
    local v53 = v6.useRef(nil);
    v6.useEffect(function()
        if v53.current == nil then
            return ;
        else
            assert(v53.current ~= nil, v9.LUAU_ANALYZE_ERROR);
            task.cancel(v53.current);
            return ;
        end;
    end, {});
    local v60 = v6.useCallback(function()
        if v41.type ~= "hasSelection" and v41.type ~= "error" then
            return ;
        else
            if v53.current ~= nil then
                task.cancel(v53.current);
                v53.current = nil;
            end;
            assert(v37 ~= nil, "performAutoSetup called with no target");
            local v54 = assert(v37.bodies[1], "Auto setup target has no bodies");
            local v55 = l_GeometryService_0:HashMeshAsync(v54.MeshId);
            local v56 = v45.current[v55];
            if v56 ~= nil then
                v52(v56);
                if v39.autoSetupClickedSignal ~= nil then
                    v39.autoSetupClickedSignal:Fire();
                end;
                return ;
            else
                v42({
                    type = "inAutoSetup",
                    target = v37
                });
                v53.current = task.spawn(function()
                    local v57 = os.clock();
                    local l_status_0, l_result_0 = pcall(v39.startAutoSetupAsync, v54, function()
                    end);
                    if not l_status_0 then
                        warn("Something went wrong while performing auto setup.\n" .. l_result_0);
                        v42({
                            type = "error",
                            target = v37,
                            error = "ErrorSourceFail"
                        });
                        v38:report("autoSetupFailure", os.clock() - v57, v54.MeshId);
                    else
                        v45.current[v55] = l_result_0:Clone();
                        v52(l_result_0);
                        v38:report("autoSetupFinish", os.clock() - v57, v54.MeshId);
                        if v17() then
                            v38:report("autoSetupAssetsGenerated", v11(v54.MeshId), v12(l_result_0));
                            return ;
                        end;
                    end;
                end);
                if v39.autoSetupClickedSignal ~= nil then
                    v39.autoSetupClickedSignal:Fire();
                end;
                return ;
            end;
        end;
    end, {
        v41,
        v39.startAutoSetupAsync,
        v37,
        v52
    });
    local v62 = v6.useCallback(function()
        if v53.current ~= nil then
            task.cancel(v53.current);
        end;
        v42(function(v61)
            if v61.type == "none" then
                return v61;
            else
                return {
                    type = "hasSelection",
                    target = v61.target
                };
            end;
        end);
    end, {});
    v6.useEffect(function()
        if v37 == nil and (not (v41.type ~= "hasSelection") or v41.type == "none") then
            v42({
                type = "none"
            });
        end;
        v42(function(v63)
            if v37 == nil then
                if not (v63.type ~= "hasSelection") or v63.type == "none" then
                    return {
                        type = "none"
                    };
                end;
            elseif v37 ~= nil and v63.type == "none" then
                return {
                    type = "hasSelection",
                    target = v37
                };
            end;
            return v63;
        end);
    end, {
        v37
    });
    if v37 ~= nil and #v37.bodies > 1 then
        v41 = {
            type = "error",
            target = v37,
            error = "ErrorMultipleBodies"
        };
    end;
    return {
        state = v41,
        cancelAutoSetup = v62,
        startAutoSetup = v60
    };
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerEquippedHoverMenu);
local v3 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local _ = require(l_script_FirstAncestor_0.Src.Types);
return function(v5)
    return v1.useMemo(function()
        local v6 = {
            accessories = {},
            animation = nil,
            clothing = {},
            emotion = nil,
            patches = {},
            skinTone = nil
        };
        for v7, v8 in v5, nil, nil do
            local l_item_0 = v8.item;
            if l_item_0.source == v3.SOURCE_BUILTIN then
                assert(l_item_0.source == v3.SOURCE_BUILTIN, v3.LUAU_ANALYZE_ERROR);
                if not v2() then
                    v8.palette.WearBuiltin(l_item_0.builtinItem, v6, v7);
                elseif not v8.isHidden then
                    v8.palette.WearBuiltin(l_item_0.builtinItem, v6, v7);
                end;
            end;
        end;
        return v6;
    end, {
        v5
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v3 = require(l_script_FirstAncestor_0.Src.Util.EquipmentStateContext);
local v4 = require(l_script_FirstAncestor_0.Src.Util.OriginalLimbContext);
local v5 = require(l_script_FirstAncestor_0.Src.Util.filterDescendants);
local v6 = {
    HeadBodyPart = {
        "Head"
    },
    Torso = {
        "UpperTorso",
        "LowerTorso"
    },
    LeftArm = {
        "LeftUpperArm",
        "LeftLowerArm",
        "LeftHand"
    },
    RightArm = {
        "RightUpperArm",
        "RightLowerArm",
        "RightHand"
    },
    LeftLeg = {
        "LeftUpperLeg",
        "LeftLowerLeg",
        "LeftFoot"
    },
    RightLeg = {
        "RightUpperLeg",
        "RightLowerLeg",
        "RightFoot"
    }
};
return function(v7, v8)
    local v9 = v1.useContext(v3);
    local v10 = v1.useContext(v4);
    v1.useEffect(function()
        if v7 == nil then
            return ;
        else
            assert(v7 ~= nil, "Luau");
            local v11 = {};
            for _, v13 in v9.equippedItems, nil, nil do
                v11[v13.palette.Key] = true;
            end;
            for v14, v15 in v6, nil, nil do
                if not v11[v14] then
                    for _, v17 in v15, nil, nil do
                        if not v10.isLimbOriginal(v7:FindFirstChild(v17)) then
                            local l_v8_FirstChild_0 = v8:FindFirstChild(v17);
                            if not (not (l_v8_FirstChild_0 ~= nil) or not l_v8_FirstChild_0:IsA("BasePart")) then
                                assert(l_v8_FirstChild_0:IsA("BasePart"), "Luau");
                                local v19 = l_v8_FirstChild_0:Clone();
                                v5(v19);
                                v7.Humanoid:ReplaceBodyPartR15(Enum.BodyPartR15[v17], v19);
                            end;
                        end;
                    end;
                end;
            end;
            return ;
        end;
    end, {
        v7,
        v8,
        v9.equippedItems
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerEquippedHoverMenu);
local v2 = require(l_script_FirstAncestor_0.Packages.React);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v4 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local v5 = require(l_script_FirstAncestor_0.Src.Util.EquipmentStateContext);
return function(v6)
    local v7 = v2.useContext(v5);
    local v8 = v2.useRef({});
    local v9 = v2.useRef({});
    assert(v8.current ~= nil, v4.LUAU_ANALYZE_ERROR);
    assert(v9.current ~= nil, v4.LUAU_ANALYZE_ERROR);
    v2.useEffect(function()
        if v6 == nil then
            return ;
        else
            assert(v6 ~= nil, v4.LUAU_ANALYZE_ERROR);
            local l_current_0 = v8.current;
            local v11 = {};
            for v12, v13 in v7.equippedItems, nil, nil do
                if v13.item.source == v4.SOURCE_INSTANCE then
                    assert(v13.item.source == v4.SOURCE_INSTANCE, v4.LUAU_ANALYZE_ERROR);
                    if v8.current[v13] ~= nil then
                        if not (v1() and v13.isHidden) then
                            v11[v13] = l_current_0[v13];
                            if v13.palette.UpdateInstances ~= nil then
                                v13.palette.UpdateInstances(l_current_0[v13], v12);
                            end;
                        end;
                    elseif not v1() then
                        v11[v13] = v13.palette.WearInstance(v13.item.instance, v6, v12);
                    elseif not v13.isHidden then
                        v11[v13] = v13.palette.WearInstance(v13.item.instance, v6, v12);
                    end;
                end;
            end;
            for _, v15 in v9.current, nil, nil do
                if v11[v15] == nil and v8.current[v15] ~= nil then
                    for _, v17 in v8.current[v15], nil, nil do
                        if v17 ~= nil then
                            v17:Destroy();
                        end;
                    end;
                end;
            end;
            v9.current = v7.equippedItems;
            v8.current = v11;
            return ;
        end;
    end, {
        v6,
        v7.equippedItems
    });
    v2.useEffect(function()
        return function()
            for _, v19 in v8.current, nil, nil do
                for _, v21 in v19, nil, nil do
                    v21:Destroy();
                end;
            end;
            table.clear(v8.current);
        end;
    end, {
        v6
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v4 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerCageEditingTools);
local v5 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerCageEditingTools);
local v6 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerReplicateEditorStateOnWorldModel);
local function v15(v7, v8, v9)
    local v10 = {};
    local l_v8_0 = v8;
    while true do
        assert(l_v8_0 ~= nil, "Iterating reference is nil");
        table.insert(v10, l_v8_0.Name);
        l_v8_0 = l_v8_0.Parent;
        if not v6() then
            assert(l_v8_0 ~= nil, "Reference child wasn't a part of reference");
        elseif l_v8_0 == nil then
            error((("Reference child wasn't a part of reference. Was looking for %*"):format((v8:GetFullName()))));
        end;
        if not (l_v8_0 ~= v7) then
            break;
        end;
    end;
    local l_v9_0 = v9;
    for v13 = #v10, 1, -1 do
        local l_l_v9_0_FirstChild_0 = l_v9_0:FindFirstChild(v10[v13]);
        if l_l_v9_0_FirstChild_0 == nil then
            return nil;
        else
            assert(l_l_v9_0_FirstChild_0 ~= nil, v2.LUAU_ANALYZE_ERROR);
            l_v9_0 = l_l_v9_0_FirstChild_0;
        end;
    end;
    if l_v9_0.ClassName ~= v8.ClassName then
        return nil;
    else
        return l_v9_0;
    end;
end;
return function(v16, v17, v18)
    v1.useEffect(function()
        if v17 == nil then
            return nil;
        else
            assert(v17 ~= nil, v2.LUAU_ANALYZE_ERROR);
            if v4() and v16 == nil then
                return nil;
            else
                assert(v16 ~= nil, v2.LUAU_ANALYZE_ERROR);
                local v19 = {};
                local function _(v20, v21)
                    local v22 = v15(v16, v20, v17);
                    if v22 == nil then
                        return ;
                    else
                        assert(v22 ~= nil, v2.LUAU_ANALYZE_ERROR);
                        v22[v21] = v20[v21];
                        return ;
                    end;
                end;
                local function v38(v24)
                    if not v24:IsA("Attachment") then
                        if not v24:IsA("ValueBase") then
                            if not (not v4() or not v24:IsA("BaseWrap")) then
                                v19[v24] = {
                                    v24.VerticesModified:Connect(function()
                                        local v25 = v15(v16, v24, v17);
                                        if v25 == nil then
                                            return ;
                                        else
                                            local v26 = false;
                                            if v25 ~= nil then
                                                v26 = v25:IsA("BaseWrap");
                                            end;
                                            assert(v26, v2.LUAU_ANALYZE_ERROR);
                                            v25:ModifyVertices(Enum.CageType.Outer, v24:GetVertices(Enum.CageType.Outer));
                                            return ;
                                        end;
                                    end)
                                };
                            end;
                            return ;
                        else
                            v19[v24] = {
                                v24:GetPropertyChangedSignal("Value"):Connect(function()
                                    local l_v24_0 = v24;
                                    local v28 = v15(v16, l_v24_0, v17);
                                    if not (v28 == nil) then
                                        assert(v28 ~= nil, v2.LUAU_ANALYZE_ERROR);
                                        v28.Value = l_v24_0.Value;
                                    end;
                                    if v18 ~= nil and (not v5() or v24.Name ~= v2.ORIGINAL_POSITION_VALUE) then
                                        v18();
                                    end;
                                end)
                            };
                            return ;
                        end;
                    else
                        v19[v24] = {};
                        table.insert(v19[v24], v24:GetPropertyChangedSignal("CFrame"):Connect(function()
                            if not v6() or v24:IsDescendantOf(game) then
                                local l_v24_1 = v24;
                                local v30 = v15(v16, l_v24_1, v17);
                                if not (v30 == nil) then
                                    assert(v30 ~= nil, v2.LUAU_ANALYZE_ERROR);
                                    v30.CFrame = l_v24_1.CFrame;
                                end;
                                if not v5() then
                                    for _, v32 in v17:GetChildren() do
                                        if v32:IsA("Accessory") then
                                            local l_Handle_0 = v32:FindFirstChild("Handle");
                                            if l_Handle_0 ~= nil then
                                                assert(l_Handle_0 ~= nil, v2.LUAU_ANALYZE_ERROR);
                                                local l_l_Handle_0_FirstChild_0 = l_Handle_0:FindFirstChild(v24.Name);
                                                if not (not (l_l_Handle_0_FirstChild_0 ~= nil) or not l_l_Handle_0_FirstChild_0:IsA("Attachment")) then
                                                    local v35 = false;
                                                    if l_l_Handle_0_FirstChild_0 ~= nil then
                                                        v35 = l_l_Handle_0_FirstChild_0:IsA("Attachment");
                                                    end;
                                                    assert(v35, v2.LUAU_ANALYZE_ERROR);
                                                    local l_AccessoryWeld_0 = l_Handle_0:FindFirstChild("AccessoryWeld");
                                                    if not (not (l_AccessoryWeld_0 ~= nil) or not l_AccessoryWeld_0:IsA("Weld")) then
                                                        local v37 = false;
                                                        if l_AccessoryWeld_0 ~= nil then
                                                            v37 = l_AccessoryWeld_0:IsA("Weld");
                                                        end;
                                                        assert(v37, v2.LUAU_ANALYZE_ERROR);
                                                        l_AccessoryWeld_0.C0 = l_l_Handle_0_FirstChild_0.CFrame;
                                                        l_AccessoryWeld_0.C1 = v24.CFrame;
                                                    end;
                                                end;
                                            end;
                                        end;
                                    end;
                                end;
                                return ;
                            else
                                return ;
                            end;
                        end));
                        return ;
                    end;
                end;
                for _, v40 in v16:GetDescendants() do
                    v38(v40);
                end;
                local v41 = v16.DescendantAdded:Connect(v38);
                local v46 = v16.DescendantRemoving:Connect(function(v42)
                    local v43 = v19[v42];
                    if v43 == nil then
                        return ;
                    else
                        for _, v45 in v43, nil, nil do
                            v45:Disconnect();
                        end;
                        return ;
                    end;
                end);
                return function()
                    v41:Disconnect();
                    v46:Disconnect();
                    for _, v48 in v19, nil, nil do
                        for _, v50 in v48, nil, nil do
                            v50:Disconnect();
                        end;
                    end;
                end;
            end;
        end;
    end, {
        v16,
        v17
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v3 = require(l_script_FirstAncestor_0.Src.Hooks.useAttribute);
local _ = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetup);
local v5 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetupDisablePublish);
local v6 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetupTelemetryV2);
return function(v7)
    assert(v5() or v6(), "FFlagAvatarPreviewAutoSetupDisablePublish and FFlagAvatarPreviewerAutoSetupTelemetryV2 are not enabled");
    return not not v3(v7, v1.ATTRIBUTE_CREATED_BY_AUTO_SETUP);
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v3 = require(l_script_FirstAncestor_0.Src.Hooks.useAttribute);
local v4 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetup)();
return function(v5)
    assert(v4, "FFlagAvatarPreviewerAutoSetup is not enabled");
    return not not v3(v5.WorldModel, v1.ATTRIBUTE_PREFIX .. v1.ATTRIBUTE_CREATED_BY_AUTO_SETUP);
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Util.OriginalLimbContext);
local v3 = require(l_script_FirstAncestor_0.Src.Util.filterDescendants);
local v4 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local function v10(v6, v7)
    for _, v9 in v7:GetDescendants() do
        if v9:IsA("BasePart") then
            v6.markLimbAsOriginal(v9);
        end;
    end;
end;
return function(v11, v12)
    local v13, v14 = v1.useState(nil);
    local v15 = v1.useRef(v13);
    local v16 = v1.useContext(v2);
    v1.useEffect(function()
        v14(nil);
    end, {
        v11
    });
    v1.useEffect(function()
        if v13 == nil and v15.current ~= nil then
            v15.current.Parent = nil;
            return ;
        else
            v15.current = v13;
            return ;
        end;
    end, {
        v13
    });
    v1.useEffect(function()
        local l_current_0 = v15.current;
        if l_current_0 ~= nil and l_current_0:IsDescendantOf(game) then
            assert(l_current_0 ~= nil, v4.LUAU_ANALYZE_ERROR);
            task.spawn(function()
                l_current_0.Humanoid:ApplyDescription(v12);
            end);
            return nil;
        else
            local v18 = v11:Clone();
            v10(v16, v18);
            v3(v18, v4.ALL_ALLOWED_PART_NAMES);
            v14(v18);
            if v18:IsDescendantOf(game) then
                return nil;
            else
                local v19 = nil;
                v19 = v18.AncestryChanged:Connect(function()
                    if v18:IsDescendantOf(game) then
                        v19:Disconnect();
                        v18.Humanoid:ApplyDescription(v12);
                    end;
                end);
                return function()
                    v19:Disconnect();
                end;
            end;
        end;
    end, {
        v11,
        v12
    });
    return v13;
end;


local v0 = require(script:FindFirstAncestor("AvatarCompatibilityPreviewer").Packages.React);
return function(v1, v2, v3)
    local v4 = v0.useMemo(function()
        return v2;
    end, v3);
    v0.useEffect(function()
        local v5 = v1:Connect(v4);
        return function()
            v5:Disconnect();
        end;
    end, {
        v1,
        v4
    });
end;


local v0 = require(script:FindFirstAncestor("AvatarCompatibilityPreviewer").Packages.React);
return function()
    local v1, v2 = v0.useState(0);
    return {
        amount = v1,
        increment = v0.useCallback(function()
            v2(function(v3)
                return v3 + 1;
            end);
        end, {}),
        decrement = v0.useCallback(function()
            v2(function(v4)
                return v4 - 1;
            end);
        end, {})
    };
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.Dash);
local v2 = require(l_script_FirstAncestor_0.Packages.React);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v4 = require(l_script_FirstAncestor_0.Src.Hooks.useAddInstancesToUserCatalogAndEquip);
local v5 = require(l_script_FirstAncestor_0.Src.Hooks.useSerializedState);
return function(v6)
    local v7 = v4();
    local v8, v9 = v5(v6, "initialImportComplete", false);
    v2.useEffect(function()
        if not v8 then
            v9(true);
            task.defer(function()
                v7(v1.filter(v6:GetChildren(), function(v10)
                    return v10:IsA("Accessory") or v10:IsA("MeshPart") and v10.Name ~= "Head";
                end));
            end);
            return ;
        else
            return ;
        end;
    end, {
        v7,
        v8,
        v6
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.Framework);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v3 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerClothingTypeIcons);
local v4 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerNewCatalogAccessories);
local v5 = require(l_script_FirstAncestor_0.Src.Resources.BuiltinItems);
local v6 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local v7 = require(l_script_FirstAncestor_0.Src.Util.find);
local l_Localization_0 = v1.ContextServices.Localization;
local function _(v9)
    assert(v9.item.source == v6.SOURCE_INSTANCE, "Non-user item passed to findUserItemName");
    local l_FirstChild_0 = v9.item.instance:FindFirstChild(v6.REFERENCE_VALUE_NAME);
    if not (not (l_FirstChild_0 ~= nil) or not l_FirstChild_0:IsA("ObjectValue")) and l_FirstChild_0.Value ~= nil then
        return l_FirstChild_0.Value.Name;
    else
        return nil;
    end;
end;
return function(v12)
    local v13 = l_Localization_0:use();
    if v12.item.source ~= v6.SOURCE_BUILTIN then
        assert(v12.item.source == v6.SOURCE_INSTANCE, "Non-user item passed to findUserItemName");
        local l_FirstChild_1 = v12.item.instance:FindFirstChild(v6.REFERENCE_VALUE_NAME);
        if not (not (l_FirstChild_1 ~= nil) or not l_FirstChild_1:IsA("ObjectValue")) and l_FirstChild_1.Value ~= nil then
            return l_FirstChild_1.Value.Name;
        else
            return nil;
        end;
    else
        assert(v12.item.source == v6.SOURCE_BUILTIN, v6.LUAU_ANALYZE_ERROR);
        local l_builtinItem_0 = v12.item.builtinItem;
        if typeof(v12.item.builtinItem) == "number" then
            l_builtinItem_0 = v12.item.builtinItem;
        elseif typeof(v12.item.builtinItem) == "Color3" then
            return nil;
        elseif typeof(v12.item.builtinItem) == "table" then
            if v12.item.builtinItem.left ~= nil then
                l_builtinItem_0 = v12.item.builtinItem.left;
            else
                return nil;
            end;
        else
            return nil;
        end;
        local v16 = ("%*_%*"):format(v12.palette.Key, l_builtinItem_0);
        local v18 = if not v4() then nil else v7(v5.allItems, function(v17)
            return v17.id == l_builtinItem_0;
        end);
        local v19 = v13:getText("ItemNames2", v16) .. if (not not v4() and v18) and (not v3() or v18.accessoryType == "rigid") then (" (%*)"):format(v18.attachment) else "";
        if not v19:match(v16) then
            return v19;
        else
            return nil;
        end;
    end;
end;


local v0 = require(script:FindFirstAncestor("AvatarCompatibilityPreviewer").Packages.React);
return function(v1, v2)
    local v3, v4 = v0.useState({});
    return if v3[v2] == nil then v1(v2) else v3[v2], (v0.useCallback(function(v5)
        v4(function(v6)
            v6 = table.clone(v6);
            v6[v2] = if v6[v2] == nil then v5(v1(v2)) else v5(v6[v2]);
            return v6;
        end);
    end, {
        v2,
        v1
    }));
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v3 = require(l_script_FirstAncestor_0.Src.Hooks.useSelectedAutoSetupTarget);
local v4 = require(l_script_FirstAncestor_0.Src.Hooks.useSelectedAvatar);
local v5 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetup)();
local v6 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerFixMeshSwitching);
return function()
    local v7 = nil;
    local v8 = nil;
    if v5 then
        local v9, v10 = v3();
        v7 = v9;
        v8 = v10;
    end;
    local v11, v12 = v4();
    local v13 = v1.useRef(nil);
    local v14 = v1.useRef(nil);
    local v15 = v1.useRef(nil);
    if not v6() then
        if v14.current ~= v7 then
            if (v7 == nil and v15.current ~= nil) and v15.current.autoSetupTarget ~= nil then
                v15.current = nil;
            elseif v7 ~= nil then
                v15.current = {
                    avatar = nil,
                    autoSetupTarget = v7
                };
            end;
            v14.current = v7;
        end;
        if v13.current ~= v11 then
            if (v11 == nil and v15.current ~= nil) and v15.current.avatar ~= nil then
                v15.current = nil;
            elseif v11 ~= nil then
                v15.current = {
                    avatar = v11,
                    autoSetupTarget = nil
                };
            end;
            v13.current = v11;
        end;
    else
        if not (v14.current == v7 and not v8) then
            if (v7 == nil and v15.current ~= nil) and v15.current.autoSetupTarget ~= nil then
                v15.current = nil;
            elseif v7 ~= nil and (not (v15.current ~= nil) or v15.current.autoSetupTarget ~= v7) then
                v15.current = {
                    avatar = nil,
                    autoSetupTarget = v7
                };
            end;
            v14.current = v7;
        end;
        if not (v13.current == v11 and not v12) then
            if (v11 == nil and v15.current ~= nil) and v15.current.avatar ~= nil then
                v15.current = nil;
            elseif v11 ~= nil and (not (v15.current ~= nil) or v15.current.avatar ~= v11) then
                v15.current = {
                    avatar = v11,
                    autoSetupTarget = nil
                };
            end;
            v13.current = v11;
        end;
    end;
    return v15.current;
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v4 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerCageEditingTools);
return function(v5)
    assert(v4(), "FFlagAvatarPreviewerEditingTools not enabled");
    v1.useEffect(function()
        if v5 == nil then
            return nil;
        else
            assert(v5 ~= nil, v2.LUAU_ANALYZE_ERROR);
            local function v14(v6)
                for _, v8 in v5:GetChildren() do
                    if v8:IsA("Accessory") then
                        local l_Handle_0 = v8:FindFirstChild("Handle");
                        if l_Handle_0 ~= nil then
                            assert(l_Handle_0 ~= nil, v2.LUAU_ANALYZE_ERROR);
                            local l_l_Handle_0_FirstChild_0 = l_Handle_0:FindFirstChild(v6.Name);
                            if not (not (l_l_Handle_0_FirstChild_0 ~= nil) or not l_l_Handle_0_FirstChild_0:IsA("Attachment")) then
                                local v11 = false;
                                if l_l_Handle_0_FirstChild_0 ~= nil then
                                    v11 = l_l_Handle_0_FirstChild_0:IsA("Attachment");
                                end;
                                assert(v11, v2.LUAU_ANALYZE_ERROR);
                                local l_AccessoryWeld_0 = l_Handle_0:FindFirstChild("AccessoryWeld");
                                if not (not (l_AccessoryWeld_0 ~= nil) or not l_AccessoryWeld_0:IsA("Weld")) then
                                    local v13 = false;
                                    if l_AccessoryWeld_0 ~= nil then
                                        v13 = l_AccessoryWeld_0:IsA("Weld");
                                    end;
                                    assert(v13, v2.LUAU_ANALYZE_ERROR);
                                    l_AccessoryWeld_0.C0 = l_l_Handle_0_FirstChild_0.CFrame;
                                    l_AccessoryWeld_0.C1 = v6.CFrame;
                                end;
                            end;
                        end;
                    end;
                end;
            end;
            local v15 = {};
            for _, v17 in v5:GetDescendants() do
                if v17:IsA("Attachment") then
                    assert(v17:IsA("Attachment"), v2.LUAU_ANALYZE_ERROR);
                    if v17:FindFirstAncestorWhichIsA("Accessory") == nil then
                        v14(v17);
                        table.insert(v15, v17:GetPropertyChangedSignal("CFrame"):Connect(function()
                            v14(v17);
                        end));
                    end;
                end;
            end;
            return function()
                for _, v19 in v15, nil, nil do
                    v19:Disconnect();
                end;
            end;
        end;
    end, {
        v5
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Resources.CatalogItems);
local v3 = require(l_script_FirstAncestor_0.Src.Util.EquipmentStateContext);
local v4 = require(l_script_FirstAncestor_0.Src.Util.getItemAccessoryType);
local v5 = require(l_script_FirstAncestor_0.Src.Util.DEPRECATED_isLayeredClothing);
local v6 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerClothingTypeIcons);
return function()
    local v7 = v1.useContext(v3);
    return v1.useCallback(function(v8, v9)
        local v10 = nil;
        local v11 = nil;
        local v12 = 0;
        for v13, v14 in v7.equippedItems, nil, nil do
            if not v6() then
                if not v5(v14) then
                    continue;
                end;
            elseif not (v4(v14) == "layered") then
                continue;
            end;
            v12 = v12 + 1;
            if v12 == v8 then
                v10 = v13;
            elseif v12 == v9 then
                v11 = v13;
            end;
            if not (not (v10 ~= nil) or v11 == nil) then
                break;
            end;
        end;
        if not (v10 ~= nil) or v11 == nil then
            local v15 = {
                "Couldn't resolve true indices of layered clothing",
                ("Swapping %* with %*"):format(v8, v9),
                ("trueLayeredClothingIndex = %*"):format(v10),
                (("#equipmentState.equippedItems = %*"):format(#v7.equippedItems))
            };
            for v16, v17 in v7.equippedItems, nil, nil do
                table.insert(v15, (("\t%*. %* (Layered clothing = %*)"):format(v16, v17.palette.Key, table.find(v2.clothing, v17.palette) ~= nil)));
            end;
            error(table.concat(v15, "\n"));
        end;
        v7.moveEquippedItemsToIndex(v10, v11);
    end, {
        v7.equippedItems
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local l_PluginActions_0 = require(l_script_FirstAncestor_0.Packages.Framework).ContextServices.PluginActions;
return function(v3, v4)
    local v5 = l_PluginActions_0:use():get(v3);
    v1.useEffect(function()
        assert(not v5.Enabled, "Plugin action already registered to something");
        v5.Enabled = true;
        local v6 = v5.Triggered:Connect(v4);
        return function()
            v5.Enabled = false;
            v6:Disconnect();
        end;
    end, {
        v5,
        v4
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.Cryo);
local v2 = require(l_script_FirstAncestor_0.Packages.Dash);
local v3 = require(l_script_FirstAncestor_0.Packages.React);
local v4 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local v5 = require(l_script_FirstAncestor_0.Src.Util.EquipmentStateContext);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v7 = require(l_script_FirstAncestor_0.Src.Util.copyHumanoidScaleToHumanoidDescription);
local v8 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerEditingTools);
local v9 = v8();
local v10 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerReplicateEditorStateOnWorldModel);
local v11 = game:DefineFastFlag("HumanoidDescriptionResetIncludesBodyParts", false);
local v12 = Color3.fromRGB(205, 205, 204);
local function _(v13, v14)
    v13.HeadColor = v14;
    v13.TorsoColor = v14;
    v13.LeftArmColor = v14;
    v13.RightArmColor = v14;
    v13.LeftLegColor = v14;
    v13.RightLegColor = v14;
end;
local function _(v16)
    return v2.map(v16, function(v17)
        return {
            AccessoryType = assert(v4.ASSET_TYPE_TO_ACCESSORY_TYPE[v17.AssetType], (("No known accessory type for %*"):format(v17.AssetType))),
            AssetId = v17.AssetId,
            Order = v17.Order
        };
    end);
end;
local function _(v19, v20, v21)
    local v22 = v19:Clone();
    for v23, v24 in v20, nil, nil do
        v22[v23.Name] = v24;
    end;
    v22:SetAccessories(v2.map(v21, function(v25)
        return {
            AccessoryType = assert(v4.ASSET_TYPE_TO_ACCESSORY_TYPE[v25.AssetType], (("No known accessory type for %*"):format(v25.AssetType))),
            AssetId = v25.AssetId,
            Order = v25.Order
        };
    end), true);
    return v22;
end;
return function(v27, v28, v29)
    local v30 = v3.useContext(v5);
    local v35 = if not v9 then v1.List.join(v30.avatarAssets.clothing, v2.collectArray(v30.avatarAssets.accessories, function(v31, v32)
        return {
            AssetId = v32,
            AssetType = v31
        };
    end)) else v3.useMemo(function()
        if not (v29 ~= nil) or v29.includeAccessories then
            return v1.List.join(v30.avatarAssets.clothing, v2.collectArray(v30.avatarAssets.accessories, function(v33, v34)
                return {
                    AssetId = v34,
                    AssetType = v33
                };
            end));
        else
            return {};
        end;
    end, {
        v29 and v29.includeAccessories,
        v30.avatarAssets.clothing,
        v30.avatarAssets.accessories
    });
    return v3.useMemo(function()
        local l_HumanoidDescription_0 = Instance.new("HumanoidDescription");
        if v30.avatarAssets.skinTone ~= nil then
            local l_l_HumanoidDescription_0_0 = l_HumanoidDescription_0;
            local l_skinTone_0 = v30.avatarAssets.skinTone;
            l_l_HumanoidDescription_0_0.HeadColor = l_skinTone_0;
            l_l_HumanoidDescription_0_0.TorsoColor = l_skinTone_0;
            l_l_HumanoidDescription_0_0.LeftArmColor = l_skinTone_0;
            l_l_HumanoidDescription_0_0.RightArmColor = l_skinTone_0;
            l_l_HumanoidDescription_0_0.LeftLegColor = l_skinTone_0;
            l_l_HumanoidDescription_0_0.RightLegColor = l_skinTone_0;
        else
            local l_BodyColors_0 = v27.WorldModel:FindFirstChildWhichIsA("BodyColors");
            if l_BodyColors_0 == nil then
                local l_l_HumanoidDescription_0_1 = l_HumanoidDescription_0;
                local l_v12_0 = v12;
                l_l_HumanoidDescription_0_1.HeadColor = l_v12_0;
                l_l_HumanoidDescription_0_1.TorsoColor = l_v12_0;
                l_l_HumanoidDescription_0_1.LeftArmColor = l_v12_0;
                l_l_HumanoidDescription_0_1.RightArmColor = l_v12_0;
                l_l_HumanoidDescription_0_1.LeftLegColor = l_v12_0;
                l_l_HumanoidDescription_0_1.RightLegColor = l_v12_0;
            else
                assert(l_BodyColors_0:IsA("BodyColors"), v4.LUAU_ANALYZE_ERROR);
                l_HumanoidDescription_0.HeadColor = l_BodyColors_0.HeadColor3;
                l_HumanoidDescription_0.TorsoColor = l_BodyColors_0.TorsoColor3;
                l_HumanoidDescription_0.LeftArmColor = l_BodyColors_0.LeftArmColor3;
                l_HumanoidDescription_0.RightArmColor = l_BodyColors_0.RightArmColor3;
                l_HumanoidDescription_0.LeftLegColor = l_BodyColors_0.LeftLegColor3;
                l_HumanoidDescription_0.RightLegColor = l_BodyColors_0.RightLegColor3;
            end;
        end;
        local l_l_HumanoidDescription_0_2 = l_HumanoidDescription_0;
        local l_patches_0 = v30.avatarAssets.patches;
        local l_v35_0 = v35;
        local v45 = l_l_HumanoidDescription_0_2:Clone();
        for v46, v47 in l_patches_0, nil, nil do
            v45[v46.Name] = v47;
        end;
        v45:SetAccessories(v2.map(l_v35_0, function(v48)
            return {
                AccessoryType = assert(v4.ASSET_TYPE_TO_ACCESSORY_TYPE[v48.AssetType], (("No known accessory type for %*"):format(v48.AssetType))),
                AssetId = v48.AssetId,
                Order = v48.Order
            };
        end), true);
        l_HumanoidDescription_0 = v45;
        v7(l_HumanoidDescription_0, v27.WorldModel.Humanoid);
        if ((not (not v11 or not v8()) and (v29 and v29.resetIncludesBodyParts) ~= nil) and v29 ~= nil) and v29.resetIncludesBodyParts ~= nil then
            l_HumanoidDescription_0.ResetIncludesBodyParts = v29.resetIncludesBodyParts;
        end;
        return l_HumanoidDescription_0;
    end, v1.List.join({
        if not v10() then v30 else v30.avatarAssets,
        if not v9 then nil else v35,
        if not v9 then nil else v29 and v29.resetIncludesBodyParts
    }, v28));
end;


local v0 = require(script:FindFirstAncestor("AvatarCompatibilityPreviewer").Packages.React);
return function(v1)
    local v2 = v0.useRef(nil);
    if v2.current == nil then
        v2.current = v1();
    end;
    return v2;
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Util.shallowEqual);
return function()
    local v3 = v1.useRef(nil);
    return v1.useCallback(function(v4)
        if not (v3.current ~= nil) or not v2(v3.current, v4) then
            v3.current = v4;
            return v4;
        else
            return v3.current;
        end;
    end, {});
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v3 = require(l_script_FirstAncestor_0.Src.Util.equippedItemDataEquals);
return function(v4)
    return v1.useCallback(function(v5)
        v4(function(v6)
            for v7, v8 in v6, nil, nil do
                if v3(v8, v5) then
                    local v9 = table.clone(v6);
                    table.remove(v9, v7);
                    return v9;
                end;
            end;
            return v6;
        end);
    end, {
        v4
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v2 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local v3 = require(l_script_FirstAncestor_0.Src.Hooks.useRememberLastValue);
local v4 = require(l_script_FirstAncestor_0.Src.Hooks.useTransformedSelectedInstance);
local v5 = {};
local function _(v6)
    if not v6:IsA("MeshPart") or not v6.Name:lower():match((("%*$"):format(v2.BODY_MESH_SUFFIX))) then
        return nil;
    else
        return v6;
    end;
end;
return function()
    local v8 = v3();
    local v9 = v3();
    return v4(function(v10)
        local v11 = if not not v10:IsA("MeshPart") and v10.Name:lower():match((("%*$"):format(v2.BODY_MESH_SUFFIX))) then v10 else nil;
        if v11 ~= nil then
            return {
                bodies = v8({
                    v11
                }),
                otherChildren = v5
            };
        else
            if v10:IsA("Model") then
                local v12 = {
                    bodies = {},
                    otherChildren = {},
                    intendedName = v10.Name
                };
                for _, v14 in v10:GetChildren() do
                    local v15 = if not not v14:IsA("MeshPart") and v14.Name:lower():match((("%*$"):format(v2.BODY_MESH_SUFFIX))) then v14 else nil;
                    if v15 ~= nil then
                        table.insert(v12.bodies, v15);
                    else
                        table.insert(v12.otherChildren, v14);
                    end;
                end;
                v12.bodies = v8(v12.bodies);
                v12.otherChildren = v9(v12.otherChildren);
                if #v12.bodies > 0 then
                    return v12;
                end;
            end;
            return nil;
        end;
    end);
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Src.Util.isAvatar);
local v2 = require(l_script_FirstAncestor_0.Src.Hooks.useTransformedSelectedInstance);
local _ = require(l_script_FirstAncestor_0.Src.Types);
return function()
    return v2(function(v4)
        if v1(v4) then
            return {
                WorldModel = v4
            };
        else
            return nil;
        end;
    end);
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Hooks.useEventConnection);
local v3 = require(l_script_FirstAncestor_0.Src.Util.SelectionWrapper);
return function()
    local v4 = v3:use():get();
    local v5, v6 = v1.useState(function()
        return v4:Get();
    end);
    v2(v4.SelectionChanged, function()
        v6(v4:Get());
    end, {});
    return v5;
end;


local l_Parent_0 = script.Parent.Parent.Parent;
local v1 = require(l_Parent_0.Packages.React);
local v2 = require(l_Parent_0.Src.Util.Constants);
local _ = require(l_Parent_0.Src.Types);
local v4 = require(l_Parent_0.Src.Flags.getFFlagDebugAvatarPreviewerAvoidSerialization);
return function(v5, v6, v7, v8, v9)
    local v10 = v1.useMemo(function()
        return v7;
    end, {
        v6
    });
    local v11 = v2.ATTRIBUTE_PREFIX .. v6;
    local v12 = v1.useRef(v7);
    local v13 = v1.useRef(false);
    local v14 = v1.useCallback(function()
        if not v4() then
            v5:SetAttribute(v11, if not not v9 and v12.current ~= nil then v9.serialize(v12.current) else v12.current);
            return ;
        else
            return ;
        end;
    end, {
        v11,
        v9,
        v5
    });
    v1.useEffect(function()
        local v15 = if not v4() then v5:GetAttribute(v11) else nil;
        if v15 == nil then
            v8(v10);
        else
            v8(if not v9 then v15 else v9.deserialize(v15));
        end;
        v13.current = true;
        return v14;
    end, {
        v5,
        v11,
        v8,
        v9,
        v10,
        v14
    });
    v1.useEffect(function()
        if v13.current then
            v12.current = v7;
            v14();
            return ;
        else
            return ;
        end;
    end, {
        v7
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Hooks.useSerializedEffect);
local _ = require(l_script_FirstAncestor_0.Src.Types);
return function(v4, v5, v6, v7)
    local v8, v9 = v1.useState(v6);
    v2(v4, v5, v8, v9, v7);
    return v8, v9;
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.Dash);
local v2 = require(l_script_FirstAncestor_0.Packages.React);
local _ = require(l_script_FirstAncestor_0.Src.Types);
return function(v4, v5)
    return v2.useCallback(function(v6)
        v4(function(v7)
            local v8 = table.clone(v7);
            local v10 = v1.findIndex(v8, function(v9)
                return (v9.palette.OverrideEquipKey or v9.palette.Key) == (v6.palette.OverrideEquipKey or v6.palette.Key);
            end);
            if v10 ~= nil then
                local v11 = table.clone(v8[v10]);
                v11.isHidden = v5;
                v8[v10] = v11;
            end;
            return v8;
        end);
    end, {
        v4,
        v5
    });
end;


local v0 = require(script:FindFirstAncestor("AvatarCompatibilityPreviewer").Packages.React);
return function(v1)
    local v2, v3 = v0.useState(v1);
    return {
        enabled = v2,
        enable = v0.useCallback(function()
            v3(true);
        end, {}),
        disable = v0.useCallback(function()
            v3(false);
        end, {}),
        toggle = v0.useCallback(function()
            v3(function(v4)
                return not v4;
            end);
        end, {})
    };
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v3 = require(l_script_FirstAncestor_0.Src.Util.EquipmentStateContext);
local v4 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerReplicateEditorStateOnWorldModel);
local v5 = require(l_script_FirstAncestor_0.Src.Hooks.useAddInstancesToUserCatalogAndEquip);
local v6 = require(l_script_FirstAncestor_0.Src.Hooks.useEventConnection);
return function(v7)
    local v8 = v5();
    local v9 = if not v4() then nil else v1.useContext(v3);
    v6(v7.ChildAdded, function(v10)
        if v4() then
            if not v9.isIgnoringChildren then
                if not v10:IsA("Accessory") then
                    return ;
                end;
            else
                return ;
            end;
        end;
        v8({
            v10
        });
    end, {
        v8,
        v7,
        if not v4() then nil else v9.isIgnoringChildren
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Util.SelectionWrapper);
local v3 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local v4 = require(l_script_FirstAncestor_0.Src.Hooks.useEventConnection);
local v5 = require(l_script_FirstAncestor_0.Src.Hooks.useIncrementedState);
local v6 = require(l_script_FirstAncestor_0.Src.Hooks.useRememberLastValue);
local v7 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerHandleAvatarDeletion);
local v8 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerFixMeshSwitching);
local function v16(v9, v10, v11)
    local v12 = {};
    local function v13()
        v11(v10(v9) and v9);
    end;
    table.insert(v12, v9.DescendantAdded:Connect(v13));
    table.insert(v12, v9.DescendantRemoving:Connect(function()
        task.defer(v13);
    end));
    table.insert(v12, v9:GetPropertyChangedSignal("Name"):Connect(v13));
    if v9:IsA("Model") then
        table.insert(v12, v9:GetPropertyChangedSignal("PrimaryPart"):Connect(v13));
    end;
    table.insert(v12, v9.Destroying:Connect(v13));
    if v7() then
        table.insert(v12, v9.AncestryChanged:Connect(function()
            v11(v10(v9) and v9);
        end));
    end;
    v11(v10(v9) and v9);
    return function()
        for _, v15 in v12, nil, nil do
            v15:Disconnect();
        end;
    end;
end;
return function(v17)
    local v18 = v2:use():get();
    local v19, v20 = v1.useState(nil);
    local v21 = v5();
    local v22, v23 = v1.useState(false);
    local v24 = v1.useRef(nil);
    local v26 = v1.useCallback(function(v25)
        if v25 ~= nil then
            if v8() then
                v23(true);
            end;
            v20(v25);
            return ;
        else
            if v8() then
                v23(false);
            end;
            v21.increment();
            return ;
        end;
    end, {});
    local v28 = v1.useCallback(function()
        if v24.current ~= nil then
            v24.current();
            v24.current = nil;
        end;
        local v27 = v18:Get()[1];
        if v27 == nil then
            return ;
        else
            v24.current = v16(v27, v17, v26);
            return ;
        end;
    end, {
        v26
    });
    v4(v18.SelectionChanged, v28, {
        v26
    });
    v1.useEffect(v28, {});
    v1.useEffect(function()
        if v19 == nil then
            return nil;
        else
            assert(v19 ~= nil, v3.LUAU_ANALYZE_ERROR);
            return (v16(v19, v17, v26));
        end;
    end, {
        v19,
        v26
    });
    local v29 = v6();
    return v1.useMemo(function()
        local v30 = v19 and v29(v17(v19));
        if not v8() then
            return v30, nil;
        else
            return v30, v22;
        end;
    end, {
        v19,
        v21.amount,
        if not v8() then nil else v22
    });
end;


local l_ChangeHistoryService_0 = game:GetService("ChangeHistoryService");
local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v2 = require(l_script_FirstAncestor_0.Packages.React);
local v3 = require(l_script_FirstAncestor_0.Src.Hooks.usePluginAction);
return function(v4, v5)
    v2.useEffect(function()
        l_ChangeHistoryService_0:SetEnabled(false);
        return function()
            l_ChangeHistoryService_0:SetEnabled(true);
        end;
    end, {});
    v3("Undo", v4);
    v3("Redo", v5);
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Util.Constants);
local function v6(v3)
    if not v3:IsA("MeshPart") then
        if not v3:IsA("SurfaceAppearance") then
            return nil;
        else
            local l_ColorMap_0 = v3.ColorMap;
            v3.ColorMap = "";
            return function()
                v3.ColorMap = l_ColorMap_0;
            end;
        end;
    else
        local l_TextureID_0 = v3.TextureID;
        v3.TextureID = "";
        return function()
            v3.TextureID = l_TextureID_0;
        end;
    end;
end;
return function(v7, v8)
    v1.useEffect(function()
        if v7 == nil then
            return nil;
        else
            assert(v7 ~= nil, v2.LUAU_ANALYZE_ERROR);
            if not v8 then
                local v9 = {};
                for _, v11 in v7:GetDescendants() do
                    v9[v11] = v6(v11);
                end;
                local v13 = v7.DescendantAdded:Connect(function(v12)
                    v9[v12] = v6(v12);
                end);
                local v15 = v7.DescendantRemoving:Connect(function(v14)
                    v9[v14] = nil;
                end);
                return function()
                    v13:Disconnect();
                    v15:Disconnect();
                    for _, v17 in v9, nil, nil do
                        v17();
                    end;
                end;
            else
                return nil;
            end;
        end;
    end, {
        v8,
        v7
    });
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.React);
local v2 = require(l_script_FirstAncestor_0.Src.Components.UGCAvatarServiceContext);
return function()
    local v3 = v1.useContext(v2);
    local l_Catalog_0 = v3:FindFirstChild("Catalog");
    if l_Catalog_0 ~= nil then
        return l_Catalog_0;
    else
        local l_Folder_0 = Instance.new("Folder");
        l_Folder_0.Name = "Catalog";
        l_Folder_0.Parent = v3;
        return l_Folder_0;
    end;
end;


local l_StudioFixPluginWidgetLocalizedIds_0 = game:GetFastFlag("StudioFixPluginWidgetLocalizedIds");
local l_MemStorageService_0 = game:GetService("MemStorageService");
local l_RunService_0 = game:GetService("RunService");
local l_Selection_0 = game:GetService("Selection");
local l_Parent_0 = script.Parent.Parent;
local v5 = require(l_Parent_0.Packages.AvatarToolsShared);
local v6 = require(l_Parent_0.Packages.Framework);
local v7 = require(l_Parent_0.Packages.React);
local v8 = require(l_Parent_0.Packages.ReactRoblox);
local l_UI_0 = v6.UI;
local l_DockWidget_0 = l_UI_0.DockWidget;
local l_PluginButton_0 = l_UI_0.PluginButton;
local l_PluginToolbar_0 = l_UI_0.PluginToolbar;
local l_ContextServices_0 = v6.ContextServices;
local l_Plugin_0 = l_ContextServices_0.Plugin;
local l_Mouse_0 = l_ContextServices_0.Mouse;
local v16 = require(l_Parent_0.Src.Resources.MakeTheme);
local v17 = require(l_Parent_0.Src.Util.SelectionWrapper);
local v18 = require(l_Parent_0.Src.Resources.createAnalyticsHandlers);
local v19 = require(l_Parent_0.Src.Util.makePluginActions);
local l_SourceStrings_0 = l_Parent_0.Src.Resources.Localization.SourceStrings;
local l_LocalizedStrings_0 = l_Parent_0.Src.Resources.Localization.LocalizedStrings;
local l_Components_0 = l_Parent_0.Src.Components;
local v23 = require(l_Components_0.App);
local v24 = require(l_Components_0.TestInExperienceManager);
local v25 = require(l_Parent_0.Src.Flags.getFFlagAvatarPreviewerCageEditingTools);
local v26 = require(l_Parent_0.Src.Flags.getFFlagImporterOpensAvatarPreviewerBetaCheck);
local v27 = v7.PureComponent:extend("MainPlugin");
v27.init = function(v28)
    v28:setState({
        enabled = false
    });
    v28.toggleEnabled = function()
        v28:setState(function(v29)
            return {
                enabled = not v29.enabled
            };
        end);
    end;
    v28.onClose = function()
        v28:setState({
            enabled = false
        });
    end;
    v28.onRestore = function(v30)
        v28:setState({
            enabled = v30
        });
    end;
    v28.onWidgetEnabledChanged = function(v31)
        v28:setState({
            enabled = v31.Enabled
        });
    end;
    v28.localization = l_ContextServices_0.Localization.new({
        stringResourceTable = l_SourceStrings_0,
        translationResourceTable = l_LocalizedStrings_0,
        pluginName = "AvatarCompatibilityPreviewer"
    });
    if v25() then
        v28.pluginActions = l_ContextServices_0.PluginActions.new(v28.props.Plugin, v19(v28.props.Plugin, v28.localization));
    end;
    if v26() then
        v28.onImporterValidateUgcRequestConnection = l_MemStorageService_0:Bind("ValidateUgcBody", function()
            v28:setState({
                enabled = true
            });
        end);
    end;
    v28.analytics = l_ContextServices_0.Analytics.new(v18);
end;
v27.renderButtons = function(v32, v33)
    return {
        Toggle = v7.createElement(l_PluginButton_0, {
            Toolbar = v33,
            Active = v32.state.enabled,
            Id = "previewAvatar",
            Title = v32.localization:getText("Plugin", "Button"),
            OnClick = v32.toggleEnabled,
            ClickableWhenViewportHidden = true
        })
    };
end;
if v26() then
    v27.willUnmount = function(v34)
        if v34.onImporterValidateUgcRequestConnection ~= nil then
            v34.onImporterValidateUgcRequestConnection:Disconnect();
            v34.onImporterValidateUgcRequestConnection = nil;
        end;
    end;
end;
v27.render = function(v35)
    local l_props_0 = v35.props;
    local l_state_0 = v35.state;
    local l_Plugin_1 = l_props_0.Plugin;
    local l_enabled_0 = l_state_0.enabled;
    local v40 = {
        l_Plugin_0.new(l_Plugin_1),
        l_Mouse_0.new(l_Plugin_1:getMouse()),
        v16(),
        v35.localization,
        v35.analytics,
        v5.Contexts.PreviewContext.new()
    };
    if v25() then
        table.insert(v40, v35.pluginActions);
    end;
    table.insert(v40, v17.new(l_Selection_0));
    return l_ContextServices_0.provide(v40, {
        Toolbar = v7.createElement(l_PluginToolbar_0, {
            Title = "AvatarPreviewer",
            RenderButtons = function(v41)
                return v35:renderButtons(v41);
            end
        }),
        TestInExperienceManager = if not l_RunService_0:IsRunning() then v7.createElement(v24) else nil,
        MainWidget = v7.createElement(l_DockWidget_0, {
            Id = if not l_StudioFixPluginWidgetLocalizedIds_0 then nil else "AvatarCompatibilityPreviewer",
            Enabled = l_enabled_0,
            Title = v35.localization:getText("Plugin", "Name"),
            ZIndexBehavior = Enum.ZIndexBehavior.Sibling,
            InitialDockState = Enum.InitialDockState.Left,
            Size = Vector2.new(450, 600),
            MinSize = Vector2.new(240, 250),
            OnClose = v35.onClose,
            ShouldRestore = true,
            OnWidgetRestored = v35.onRestore,
            [v8.Change.Enabled] = v35.onWidgetEnabledChanged
        }, {
            App = v35.state.enabled and v7.createElement(v23)
        })
    });
end;
return v27;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local _ = require(l_script_FirstAncestor_0.Src.Types);
local v2 = require(l_script_FirstAncestor_0.Src.Util.flatten);
local v3 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerClothingTypeIcons);
local v4 = {};
local function v10(v5, v6)
    local v7 = {};
    for _, v9 in v6, nil, nil do
        table.insert(v7, {
            id = v9,
            attachment = v5,
            accessoryType = "rigid"
        });
    end;
    return v7;
end;
local function _(v11)
    return function(v12)
        return {
            id = v12,
            attachment = v11,
            accessoryType = "rigid"
        };
    end;
end;
local function _(v14)
    v14.accessoryType = "layered";
    return v14;
end;
local function v20(v16)
    local v17 = {};
    for _, v19 in v16, nil, nil do
        table.insert(v17, {
            id = v19,
            accessoryType = "layered"
        });
    end;
    return v17;
end;
if not v3() then
    v4.hair = v10("HairAttachment", {
        13902886383,
        11195420056,
        10966682388,
        846803597,
        9244114211,
        7193451306,
        7193386173,
        7193452166
    });
else
    local v21 = "HairAttachment";
    local l_v21_0 = v21 --[[ copy: 10 -> 23 ]];
    local function v24(v23)
        return {
            id = v23,
            attachment = l_v21_0,
            accessoryType = "rigid"
        };
    end;
    v21 = {};
    local v25 = v24(13902886383);
    local v26 = v24(11195420056);
    v26.accessoryType = "layered";
    local l_v26_0 = v26;
    v26 = v24(10966682388);
    local v28 = v24(846803597);
    local v29 = v24(9244114211);
    v29.accessoryType = "layered";
    local l_v29_0 = v29;
    local v31 = v24(7193451306);
    v31.accessoryType = "layered";
    v29 = v31;
    local v32 = v24(7193386173);
    v32.accessoryType = "layered";
    v31 = v32;
    local v33 = v24(7193452166);
    v33.accessoryType = "layered";
    v32 = v33;
    setlist { ['R010[1 to 8]'] = 'R011 to R018' };
    v4.hair = v21;
end;
v4.head = v10("HatAttachment", {
    9111390490,
    16018338042,
    1744330435,
    3757852497
});
local v34 = "FaceCenterAttachment";
local l_v34_0 = v34 --[[ copy: 10 -> 24 ]];
local function v37(v36)
    return {
        id = v36,
        attachment = l_v34_0,
        accessoryType = "rigid"
    };
end;
local v38 = "FaceFrontAttachment";
local l_v38_0 = v38 --[[ copy: 11 -> 25 ]];
v34 = function(v40)
    return {
        id = v40,
        attachment = l_v38_0,
        accessoryType = "rigid"
    };
end;
if not v3() then
    v4.face = {
        v34(16640910727),
        v34(16648934240),
        v34(9992285857),
        v34(14179786408),
        v34(12794788453),
        v34(12796340774),
        v34(12794916165),
        v34(12796163960),
        v37(16648984941),
        v37(16649071525),
        v37(13538969595),
        v37(16648586095)
    };
else
    v38 = {};
    local v41 = v34(16640910727);
    local v42 = v34(16648934240);
    local v43 = v34(9992285857);
    local v44 = v34(14179786408);
    local v45 = v34(12794788453);
    v45.accessoryType = "layered";
    local l_v45_0 = v45;
    local v47 = v34(12796340774);
    v47.accessoryType = "layered";
    v45 = v47;
    local v48 = v34(12794916165);
    v48.accessoryType = "layered";
    v47 = v48;
    local v49 = v34(12796163960);
    v49.accessoryType = "layered";
    v48 = v49;
    v49 = v37(16648984941);
    local v50 = v37(16649071525);
    local v51 = v37(13538969595);
    ??? = v37(16648586095);
    setlist { ['R011[1 to ???]'] = 'R012 to ???' };
    v4.face = v38;
end;
v4.front = v10("BodyFrontAttachment", {
    16648690355,
    16648652231,
    16648706823,
    16648698037
});
v4.neck = v10("NeckAttachment", {
    16648958003,
    16648625265,
    3690490960,
    15696295454
});
local v52 = "LeftCollarAttachment";
local l_v52_0 = v52 --[[ copy: 12 -> 26 ]];
v38 = function(v54)
    return {
        id = v54,
        attachment = l_v52_0,
        accessoryType = "rigid"
    };
end;
local v55 = "RightCollarAttachment";
local l_v55_0 = v55 --[[ copy: 13 -> 27 ]];
v52 = function(v57)
    return {
        id = v57,
        attachment = l_v55_0,
        accessoryType = "rigid"
    };
end;
local v58 = "LeftShoulderAttachment";
local l_v58_0 = v58 --[[ copy: 14 -> 28 ]];
v55 = function(v60)
    return {
        id = v60,
        attachment = l_v58_0,
        accessoryType = "rigid"
    };
end;
local v61 = "RightShoulderAttachment";
local l_v61_0 = v61 --[[ copy: 15 -> 29 ]];
v58 = function(v63)
    return {
        id = v63,
        attachment = l_v61_0,
        accessoryType = "rigid"
    };
end;
v4.shoulder = {
    v55(16648897492),
    v58(16648905400),
    v55(16648604510),
    v58(16648615805),
    v55(16649028183),
    v58(16649036767),
    v55(9175325868),
    v58(9175327271),
    v38(16648502798),
    v52(16648553830),
    v38(16648441318),
    v52(16648488869),
    v38(16648993618),
    v52(16649003855),
    v38(16648866296),
    v52(16648873760)
};
v4.back = v10("BodyBackAttachment", {
    9111378574,
    11774181392,
    10685856744,
    9175323644
});
local v64 = "WaistBackAttachment";
local l_v64_0 = v64 --[[ copy: 16 -> 30 ]];
v61 = function(v66)
    return {
        id = v66,
        attachment = l_v64_0,
        accessoryType = "rigid"
    };
end;
local v67 = "WaistCenterAttachment";
local l_v67_0 = v67 --[[ copy: 17 -> 31 ]];
v64 = function(v69)
    return {
        id = v69,
        attachment = l_v67_0,
        accessoryType = "rigid"
    };
end;
local v70 = "WaistFrontAttachment";
v67 = function(v71)
    return {
        id = v71,
        attachment = v70,
        accessoryType = "rigid"
    };
end;
v4.waist = {
    v67(16648852016),
    v67(16648681897),
    v67(7065897530),
    v67(6494274794),
    v64(16648672949),
    v64(16649078388),
    v64(8697885688),
    v64(3230476122),
    v61(10616839810),
    v61(13902900757),
    v61(13207223896),
    v61(4707869391)
};
if not v3() then
    v4.allItems = v2(v4.hair, v4.head, v4.face, v4.front, v4.neck, v4.shoulder, v4.back, v4.waist);
    return v4;
else
    v4.shirts = v20({
        7178736794,
        7178735702,
        6984729814,
        7178740556,
        9620950227,
        9620976296
    });
    v4.tshirts = v20({
        9112474888,
        7178736794,
        7178737816
    });
    v4.jackets = v20({
        6984765766,
        6984767443,
        7272485361,
        7192535654,
        7192544729
    });
    v4.sweaters = v20({
        9240758221,
        9913119150,
        9913110927,
        9174379982,
        6984769289,
        6984771334,
        9240757332,
        9274353324
    });
    v4.pants = v20({
        6984763785,
        6984740059,
        7192673981,
        7192681239,
        7192679765
    });
    v4.shorts = v20({
        6984773235,
        7192683061,
        7192685245
    });
    v4.skirts = v20({
        7192691582,
        7192690731,
        9284466791,
        10278865927,
        7192695838
    });
    v4.shoes = v20({
        8722031289,
        7193170137,
        7193104827
    });
    v4.eyebrows = v20({
        11572097774
    });
    v4.eyelashes = v20({
        11572100557
    });
    v4.allItems = v2(v4.hair, v4.head, v4.face, v4.front, v4.neck, v4.shoulder, v4.back, v4.waist, v4.shirts, v4.tshirts, v4.jackets, v4.sweaters, v4.pants, v4.shorts, v4.skirts, v4.shoes, v4.eyebrows, v4.eyelashes);
    return v4;
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.Cryo);
local v2 = require(l_script_FirstAncestor_0.Packages.Framework);
local v3 = require(l_script_FirstAncestor_0.Src.Resources.Theme);
local l_Style_0 = v2.Style;
local l_StyleKey_0 = l_Style_0.StyleKey;
local l_DarkTheme_0 = l_Style_0.Themes.DarkTheme;
local l_LightTheme_0 = l_Style_0.Themes.LightTheme;
local l_StudioTheme_0 = l_Style_0.Themes.StudioTheme;
local v9 = v1.Dictionary.join(l_DarkTheme_0, {
    [l_StyleKey_0.Dots] = "rbxasset://studio_svg_textures/Lua/ImportPreview/Dark/Large/OptionsDots.png",
    [l_StyleKey_0.DotsVertical] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Standard/dots_vertical.png",
    [l_StyleKey_0.Hide] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/hide.png",
    [l_StyleKey_0.HideHover] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/hide_hover.png",
    [l_StyleKey_0.HoverMenu] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/hover_menu.png",
    [l_StyleKey_0.HoverMenuDisabled] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/hover_menu_disabled.png",
    [l_StyleKey_0.PlayImage] = "rbxasset://textures/LayeredClothingEditor/Icon_Play_Light.png",
    [l_StyleKey_0.PreviewerBackgroundImage] = "rbxasset://textures/AvatarCompatibilityPreviewer/bg_dark.png",
    [l_StyleKey_0.ResetCameraImage] = "rbxasset://textures/AssetImport/btn_dark_resetcam_28x28.png",
    [l_StyleKey_0.SendFeedback] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Standard/rate_feedback@2x.png",
    [l_StyleKey_0.Star] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/star.png",
    [l_StyleKey_0.StarUnfilled] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/star_unfilled.png",
    [l_StyleKey_0.UGCValidationSuccessImage] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/ugc_validation_success.png",
    [l_StyleKey_0.Unhide] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/unhide.png",
    [l_StyleKey_0.UnhideHover] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/unhide_hover.png"
});
local v10 = v1.Dictionary.join(l_LightTheme_0, {
    [l_StyleKey_0.Dots] = "rbxasset://studio_svg_textures/Lua/ImportPreview/Light/Large/OptionsDots.png",
    [l_StyleKey_0.DotsVertical] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Standard/dots_vertical.png",
    [l_StyleKey_0.Hide] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/hide.png",
    [l_StyleKey_0.HideHover] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/hide_hover.png",
    [l_StyleKey_0.HoverMenu] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/hover_menu.png",
    [l_StyleKey_0.HoverMenuDisabled] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/hover_menu_disabled.png",
    [l_StyleKey_0.PlayImage] = "rbxasset://textures/LayeredClothingEditor/Icon_Play_Dark.png",
    [l_StyleKey_0.PreviewerBackgroundImage] = "rbxasset://textures/AvatarCompatibilityPreviewer/bg_light.png",
    [l_StyleKey_0.ResetCameraImage] = "rbxasset://textures/AssetImport/btn_light_resetcam_28x28.png",
    [l_StyleKey_0.SendFeedback] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Standard/rate_feedback@2x.png",
    [l_StyleKey_0.Star] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/star.png",
    [l_StyleKey_0.StarUnfilled] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/star_unfilled.png",
    [l_StyleKey_0.UGCValidationSuccessImage] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/ugc_validation_success.png",
    [l_StyleKey_0.Unhide] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/unhide.png",
    [l_StyleKey_0.UnhideHover] = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Light/Large/unhide_hover.png"
});
return function(v11)
    local _ = nil;
    return (if not v11 then l_StudioTheme_0.new(v9, v10) else l_StudioTheme_0.mock(v9, v10)):extend(v3);
end;


local l_script_FirstAncestor_0 = script:FindFirstAncestor("AvatarCompatibilityPreviewer");
local v1 = require(l_script_FirstAncestor_0.Packages.Cryo);
local v2 = require(l_script_FirstAncestor_0.Packages.Framework);
local l_Style_0 = v2.Style;
local l_StyleKey_0 = l_Style_0.StyleKey;
local l_StyleModifier_0 = v2.Util.StyleModifier;
local l_ComponentSymbols_0 = l_Style_0.ComponentSymbols;
local l_UIData_0 = v2.UIData;
local v8 = require(l_UIData_0.Alert.style);
local v9 = require(l_UIData_0.Button.style);
local v10 = require(l_UIData_0.DropdownMenu.style);
local v11 = require(l_UIData_0.Image.style);
local v12 = require(l_UIData_0.Pane.style);
local v13 = require(l_UIData_0.ScrollingFrame.style);
local v14 = require(l_UIData_0.SelectInput.style);
local v15 = require(l_UIData_0.Separator.style);
local v16 = require(l_UIData_0.SimpleTab.style);
local v17 = require(l_UIData_0.Tooltip.style);
local v18 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerAutoSetup);
local v19 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerEditingTools);
local v20 = require(l_script_FirstAncestor_0.Src.Flags.getFFlagAvatarPreviewerPickTabsMenu);
local v21 = v2.SharedFlags.getFFlagDevFrameworkAssetRenderModelEnableSky();
local v22 = game:DefineFastFlag("DebugAvatarPreviewerDropdownMenuInfiniteMaxHeight", false);
local v23 = {};
l_ComponentSymbols_0:add("AddItemButton");
v23[l_ComponentSymbols_0.AddItemButton] = {
    Height = 42,
    Image = "rbxasset://textures/AvatarCompatibilityPreviewer/add.png",
    ImageColor = l_StyleKey_0.TextSecondary,
    ImageColorDisabled = l_StyleKey_0.TextDisabled,
    ImageSize = 20,
    PaddingTop = 3,
    PaddingBottom = 3,
    FailureDialogSpacing = UDim.new(0, 4)
};
l_ComponentSymbols_0:add("AnimationControllerDisplay");
v23[l_ComponentSymbols_0.AnimationControllerDisplay] = {
    Padding = 30,
    Position = UDim2.new(0, 0, 1, -12),
    Size = UDim2.new(1, 0, 0, 32)
};
l_ComponentSymbols_0:add("AnimationPlaybackSlider");
v23[l_ComponentSymbols_0.AnimationPlaybackSlider] = {
    PlayImage = l_StyleKey_0.PlayImage,
    PauseImage = "rbxasset://textures/LayeredClothingEditor/Icon_Pause.png",
    PlayButtonWidth = 20,
    PlayTimeLabelWidth = 60,
    Padding = 12
};
l_ComponentSymbols_0:add("AnimationPreview");
v23[l_ComponentSymbols_0.AnimationPreview] = {
    PausedAnimationAlpha = 0.5,
    ["&BodyPreview"] = {
        FrontRightAngleLerp = 0.4
    },
    ["&FacePreview"] = {
        FieldOfView = 30,
        FrontRightAngleLerp = 0.08,
        InitialDistance = 2.8
    }
};
l_ComponentSymbols_0:add("AssetPalettes");
v23[l_ComponentSymbols_0.AssetPalettes] = {
    BackgroundColor = l_StyleKey_0.SubBackground2,
    BackgroundColorHover = l_StyleKey_0.ActionHover,
    ScrollingFrame = v1.Dictionary.join(v13, {
        BackgroundColor3 = l_StyleKey_0.SubBackground2,
        BackgroundTransparency = 0,
        Padding = 0,
        ScrollBarThickness = 0,
        Spacing = UDim.new(0, 5)
    }),
    Size = UDim2.new(1, 0, 0, 24)
};
l_ComponentSymbols_0:add("AutoSetupScreen");
v23[l_ComponentSymbols_0.AutoSetupScreen] = {
    AlertPaddingHorizontal = UDim.new(0, 20),
    AlertPaddingVertical = UDim.new(0, 8),
    ControlsPosition = UDim2.new(1, -16, 1, -16),
    SpinRate = -0.25
};
l_ComponentSymbols_0:add("AvatarScreen");
v23[l_ComponentSymbols_0.AvatarScreen] = {
    AssetPalettes = {
        BackgroundColor = l_StyleKey_0.SubBackground2,
        SeparatorColor = l_StyleKey_0.SubBackground,
        SeparatorWidth = 4,
        Width = 122
    },
    Tabs = {
        Height = 64,
        VerticalOffset = -4
    }
};
l_ComponentSymbols_0:add("Background");
v23[l_ComponentSymbols_0.Background] = {
    Image = l_StyleKey_0.PreviewerBackgroundImage
};
if v19() then
    l_ComponentSymbols_0:add("BodyPointsTool");
    v23[l_ComponentSymbols_0.BodyPointsTool] = {
        ProjectionImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "projection.png",
        SymmetricalImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "symmetry.png"
    };
end;
if v19() then
    l_ComponentSymbols_0:add("CageEditingTool");
    v23[l_ComponentSymbols_0.CageEditingTool] = {
        FalloffImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "radius@2x.png",
        RadiusImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "radius@2x.png",
        SymmetryImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "symmetry@2x.png"
    };
end;
l_ComponentSymbols_0:add("Catalog");
v23[l_ComponentSymbols_0.Catalog] = {
    ScrollingFrame = v1.Dictionary.join(v13, {
        BorderColor3 = l_StyleKey_0.Border,
        Padding = 10,
        VerticalScrollBarInset = Enum.ScrollBarInset.ScrollBar
    }),
    ScrollingFrameHeight = UDim.new(1, -42),
    CellSize = UDim2.fromOffset(90, 90)
};
l_ComponentSymbols_0:add("CatalogItemButton");
v23[l_ComponentSymbols_0.CatalogItemButton] = {
    HoverX = {
        Color = l_StyleKey_0.TextSecondary,
        Image = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Standard/x_dark.png",
        AnchorPoint = Vector2.new(1, 0),
        Position = UDim2.new(1, -4, 0, 4),
        Size = UDim2.fromOffset(13, 13)
    },
    AccessoryTypeImage = {
        Color = l_StyleKey_0.TextSecondary,
        AnchorPoint = Vector2.new(0, 0),
        Position = UDim2.fromOffset(4, 4),
        Size = UDim2.fromOffset(13, 13),
        LayeredImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Standard/layered@2x.png",
        RigidImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Standard/rigid@2x.png"
    },
    UserImage = {
        Color = l_StyleKey_0.TextSecondary,
        Image = "rbxasset://textures/AvatarCompatibilityPreviewer/user.png",
        AnchorPoint = Vector2.new(1, 0),
        Position = UDim2.new(1, -4, 1, -20),
        Size = UDim2.fromOffset(13, 16)
    },
    ItemNamePaddingBottom = UDim.new(0, 12)
};
l_ComponentSymbols_0:add("ContextualSurveyDialogButton");
v23[l_ComponentSymbols_0.ContextualSurveyDialogButton] = {
    Image = l_StyleKey_0.SendFeedback,
    Position = UDim2.new(0, 28, 1, -60),
    Size = UDim2.fromOffset(24, 24)
};
if not v18() then
    l_ComponentSymbols_0:add("DummyPreview");
    v23[l_ComponentSymbols_0.DummyPreview] = {
        Ambient = Color3.fromRGB(170, 185, 200),
        LightColor = Color3.fromRGB(242, 236, 227),
        LightDirection = Vector3.new(0.5, -1, 0.1),
        PanSpeedMultiplier = 0.25,
        PlatformHeight = 0.2,
        PlatformSize = 5
    };
end;
l_ComponentSymbols_0:add("EquippedItemsSidebar");
v23[l_ComponentSymbols_0.EquippedItemsSidebar] = {
    CellSize = UDim2.fromOffset(50, 50),
    FrameSizeOffset = 50,
    ItemSpacing = UDim.new(0, 2),
    PositionOffset = UDim2.fromOffset(5, 10),
    ScrollingFrameSizeOffset = 83,
    SidebarSpacing = 10,
    Size = UDim2.new(0, 50, 1, -20)
};
l_ComponentSymbols_0:add("EquippedItemPreview");
v23[l_ComponentSymbols_0.EquippedItemPreview] = {
    HoverX = {
        Image = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Standard/x_dark.png",
        AnchorPoint = Vector2.new(1, 0),
        Position = UDim2.new(1, -4, 0, 4),
        Size = UDim2.fromOffset(13, 13)
    },
    StrokeColor = l_StyleKey_0.Border,
    StrokeThickness = 1,
    ItemHiddenTransparency = 0.7,
    ItemWornTransparency = 0
};
l_ComponentSymbols_0:add("EquippedItemSideMenu");
v23[l_ComponentSymbols_0.EquippedItemSideMenu] = {
    DotsBackground = l_StyleKey_0.TextSecondary,
    DotsBackgroundHover = l_StyleKey_0.TextContrast,
    IconSize = 16,
    Margin = 1
};
l_ComponentSymbols_0:add("ImportPage");
v23[l_ComponentSymbols_0.ImportPage] = {
    ArrowImage = "rbxasset://textures/AvatarCompatibilityPreviewer/img_triangle.png",
    ArrowColor = l_StyleKey_0.TextPrimary,
    Avatar = {
        IconSize = 75,
        InnerPadding = 2,
        NameFontSize = 16,
        NameLines = 2,
        Padding = 4,
        TitleColor = l_StyleKey_0.TextLink,
        PreviewAmbient = Color3.new(0.4, 0.4, 0.4)
    },
    BackButton = {
        Size = UDim2.fromOffset(24, 24),
        IconSize = 12
    },
    HeaderHeight = 35,
    GridPadding = UDim2.fromOffset(5, 15),
    SearchBarHeight = UDim.new(0.8, 0)
};
l_ComponentSymbols_0:add("ItemDataPreviewModel");
v23[l_ComponentSymbols_0.ItemDataPreviewModel] = {
    InstanceAmbient = Color3.new(0.4, 0.4, 0.4)
};
l_ComponentSymbols_0:add("ModelPreview");
v23[l_ComponentSymbols_0.ModelPreview] = {
    Ambient = Color3.fromRGB(170, 185, 200),
    EnableSky = true,
    LightColor = if not v21 then Color3.fromRGB(242, 236, 227) else Color3.fromRGB(221, 242, 242),
    LightDirection = if not v21 then Vector3.new(0.5, -1, 0.1) else Vector3.new(0.4, -0.5, 0.6),
    PanSpeedMultiplier = 0.25,
    PlatformHeight = 0.2,
    PlatformSize = 5
};
l_ComponentSymbols_0:add("Notice");
v23[l_ComponentSymbols_0.Notice] = {
    BackgroundColor = l_StyleKey_0.SubBackground,
    CornerRadius = UDim.new(0, 6),
    TextColor = l_StyleKey_0.TextPrimary,
    TextSize = 20,
    Padding = {
        Left = 8,
        Right = 8,
        Top = 4,
        Bottom = 4
    }
};
l_ComponentSymbols_0:add("PickTabMenu");
if v20() then
    v23[l_ComponentSymbols_0.PickTabMenu] = {
        CornerRadius = UDim.new(0, 6),
        ImageColor = l_StyleKey_0.TextPrimary,
        Padding = 6,
        Position = UDim2.new(1, -32, 0, 0),
        Size = UDim2.fromOffset(32, 32)
    };
end;
if not v18() then
    l_ComponentSymbols_0:add("PrimaryDummyPreview");
    v23[l_ComponentSymbols_0.PrimaryDummyPreview] = {
        BackgroundImage = l_StyleKey_0.PreviewerBackgroundImage
    };
end;
l_ComponentSymbols_0:add("ResetCameraButton");
v23[l_ComponentSymbols_0.ResetCameraButton] = {
    Size = UDim2.fromOffset(32, 32),
    Spacing = 5,
    Image = l_StyleKey_0.ResetCameraImage
};
l_ComponentSymbols_0:add("SelectScreen");
v23[l_ComponentSymbols_0.SelectScreen] = {
    ButtonHeight = 24,
    Spacing = UDim.new(0, 18)
};
l_ComponentSymbols_0:add("SkinPreview");
v23[l_ComponentSymbols_0.SkinPreview] = {
    HoveredBorderColor = l_StyleKey_0.SecondaryStatesHoverOutlineBorder,
    HoveredBorderThickness = 1,
    SelectedBorderColor = l_StyleKey_0.PrimaryMain,
    SelectedBorderThickness = 2,
    DisabledColorToBlend = Color3.fromRGB(76, 76, 76)
};
l_ComponentSymbols_0:add("StageSelector");
v23[l_ComponentSymbols_0.StageSelector] = {
    BackgroundColor = l_StyleKey_0.MainBackground,
    ButtonSelectedBackgroundColor = l_StyleKey_0.ButtonHover,
    ButtonHeight = 32,
    IconColor = l_StyleKey_0.MainText,
    IconColorDisabled = l_StyleKey_0.MainTextDisabled,
    IconSize = 18,
    Width = 64
};
l_ComponentSymbols_0:add("Stars");
v23[l_ComponentSymbols_0.Stars] = {
    StarColor = l_StyleKey_0.MainText,
    StarSize = UDim2.fromOffset(16, 16),
    StarFilled = l_StyleKey_0.Star,
    StarUnfilled = l_StyleKey_0.StarUnfilled,
    StarSpacing = 4,
    RatingSpacing = 10
};
l_ComponentSymbols_0:add("SubmitDialog");
v23[l_ComponentSymbols_0.SubmitDialog] = {
    Width = 500
};
l_ComponentSymbols_0:add("SubmitInner");
v23[l_ComponentSymbols_0.SubmitInner] = {
    CallToActionSpacing = UDim.new(0, 18),
    CheckboxSpacing = UDim.new(0, 4),
    ContentPadding = 40
};
l_ComponentSymbols_0:add("Survey");
v23[l_ComponentSymbols_0.Survey] = {
    HeadIndent = 22,
    Spacing = 10,
    MessageHeight = 96
};
l_ComponentSymbols_0:add("SurveyDialog");
v23[l_ComponentSymbols_0.SurveyDialog] = {
    Width = 440,
    FinishDialogSize = Vector2.new(250, 30)
};
l_ComponentSymbols_0:add("TabBar");
if v20() then
    v23[l_ComponentSymbols_0.TabBar] = {
        BackgroundColor = l_StyleKey_0.SubBackground,
        BackgroundColorHover = l_StyleKey_0.ActionHover
    };
end;
l_ComponentSymbols_0:add("TestingScreen");
v23[l_ComponentSymbols_0.TestingScreen] = {
    ButtonHeight = 24,
    Spacing = UDim.new(0, 18)
};
l_ComponentSymbols_0:add("UGCValidationErrorDialog");
v23[l_ComponentSymbols_0.UGCValidationErrorDialog] = {
    DetailsSpacing = 12,
    IconTextSpacing = 4,
    TitleDetailsSpacing = 26,
    AlertMinContentSize = Vector2.new(500, 300),
    TextSize = 18,
    WarningColor = l_StyleKey_0.WarningText,
    WarningFont = Enum.Font.SourceSansSemibold,
    WarningImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "warning.png"
};
l_ComponentSymbols_0:add("UGCValidationNotice");
v23[l_ComponentSymbols_0.UGCValidationNotice] = {
    Position = UDim2.fromOffset(8, -4),
    Size = UDim2.new(1, -64, 0, 48),
    ValidationIconSize = UDim2.fromOffset(24, 24),
    WarningColor = l_StyleKey_0.WarningText,
    WarningImage = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "warning.png"
};
l_ComponentSymbols_0:add("UGCValidationStatusIcon");
local v24 = {
    Color = Color3.new(1, 1, 1),
    Position = UDim2.fromOffset(4, 14),
    Size = UDim2.fromOffset(24, 24)
};
v23[l_ComponentSymbols_0.UGCValidationStatusIcon] = {
    ["&Failure"] = v1.Dictionary.join(v24, {
        Color = l_StyleKey_0.WarningText,
        Image = "rbxasset://studio_svg_textures/Lua/AvatarCompatibilityPreviewer/Dark/Large/" .. "warning.png"
    }),
    ["&Success"] = v1.Dictionary.join(v24, {
        Image = l_StyleKey_0.UGCValidationSuccessImage
    })
};
l_ComponentSymbols_0:add("DisambiguationMenu");
v23[l_ComponentSymbols_0.DisambiguationMenu] = {
    MinContentSize = Vector2.new(500, 300),
    ConfirmCancelContentSize = Vector2.new(200, 150),
    HorizontalSpacing = 8,
    VerticalSpacing = 8,
    TitleContentsSpacing = 24,
    TextSpacing = 8,
    DropdownWidth = 150,
    AttachmentDropdownWidth = 120,
    IconBackground = l_StyleKey_0.SubBackground,
    IconSize = UDim2.fromOffset(72, 72)
};
v23[l_ComponentSymbols_0.Alert] = v1.Dictionary.join(v8, {
    ["&WarningLong"] = v1.Dictionary.join(v8["&Warning"], {
        MaxWidth = 900
    })
});
if v19() then
    v23[l_ComponentSymbols_0.Button] = v1.Dictionary.join(v9, {
        ["&RoundHighlighted"] = v1.Dictionary.join(v9["&Round"], {
            BackgroundStyle = v1.Dictionary.join(v9.BackgroundStyle, {
                BorderColor = l_StyleKey_0.SubText
            }),
            [l_StyleModifier_0.Hover] = v1.Dictionary.join(v9[l_StyleModifier_0.Hover], {
                BackgroundStyle = v1.Dictionary.join(v9[l_StyleModifier_0.Hover].BackgroundStyle, {
                    BorderColor = l_StyleKey_0.SubText
                })
            })
        })
    });
end;
if v22 then
    v23[l_ComponentSymbols_0.DropdownMenu] = v1.Dictionary.join(v10, {
        MaxHeight = math.huge
    });
    v23[l_ComponentSymbols_0.SelectInput] = v1.Dictionary.join(v14, {
        DropdownMenu = v1.Dictionary.join(v14.DropdownMenu, {
            MaxHeight = math.huge
        })
    });
end;
v23[l_ComponentSymbols_0.Image] = v1.Dictionary.join(v11, {
    ["&EquippedItemHideIcon"] = {
        Image = l_StyleKey_0.Hide
    },
    ["&EquippedItemHideHoverIcon"] = {
        Image = l_StyleKey_0.HideHover
    },
    ["&EquippedItemHoverMenuBackground"] = {
        Image = l_StyleKey_0.HoverMenu
    },
    ["&EquippedItemUnhideIcon"] = {
        Image = l_StyleKey_0.Unhide
    },
    ["&EquippedItemUnhideHoverIcon"] = {
        Image = l_StyleKey_0.UnhideHover
    },
    ["&EquippedItemDisabledBackground"] = {
        Image = l_StyleKey_0.HoverMenuDisabled
    },
    ["&EquippedItemDotsIcon"] = {
        Image = l_StyleKey_0.Dots,
        ImageColor3 = l_StyleKey_0.Button,
        [l_StyleModifier_0.Hover] = {
            ImageColor3 = l_StyleKey_0.ImageButtonHover
        }
    },
    ["&PickTabMenu"] = {
        Image = l_StyleKey_0.DotsVertical,
        Size = UDim2.fromOffset(20, 20)
    }
});
v23[l_ComponentSymbols_0.Separator] = v1.Dictionary.join(v15, {
    ["&SelectScreenSeparator"] = {
        StretchMargin = 5
    }
});
v23[l_ComponentSymbols_0.Pane] = v1.Dictionary.join(v12, {
    ["&EquippedItemPreview"] = {
        Background = l_StyleKey_0.Button,
        CornerRadius = UDim.new(0, 4),
        [l_StyleModifier_0.Hover] = {
            Background = l_StyleKey_0.ButtonHover
        },
        [l_StyleModifier_0.Disabled] = {
            Background = l_StyleKey_0.ButtonPressed
        }
    },
    ["&EquippedItemPreviewInner"] = {
        CornerRadius = UDim.new(0, 4)
    },
    ["&EquippedItemHoverMenu"] = {
        Background = l_StyleKey_0.ForegroundMuted
    },
    ["&SkinPreview"] = {
        CornerRadius = UDim.new(0, 4)
    }
});
v23[l_ComponentSymbols_0.SimpleTab] = v1.Dictionary.join(v16, {
    ["&AssetPaletteTab"] = {
        BackgroundColor = l_StyleKey_0.SubBackground2,
        BackgroundTransparency = 1,
        BorderSize = 0,
        Padding = {
            Left = 12,
            Top = 2,
            Bottom = 0,
            Right = 12
        },
        TopLineHeight = 0,
        [l_StyleModifier_0.Selected] = {
            BackgroundColor = l_StyleKey_0.SubBackground2,
            Font = Enum.Font.SourceSansBold
        }
    },
    ["&CategoryTab"] = {
        BorderSize = 0
    }
});
v23[l_ComponentSymbols_0.Tooltip] = v1.Dictionary.join(v17, {
    ["&NoDelay"] = {
        ShowDelay = 0
    }
});
return v23;