syntax = "proto3";

package com.wixpress.appservice.api;

import "wix/api/annotations.proto";
import "wix/api/validations.proto";
import "components_catalog_data/unified_components/shared.proto";
import "components_catalog_common.proto";

message WidgetInstallationSettings {
    // Deprecated, autoAdd should be mapped to static_container HOMEPAGE, essential should be mapped to container. Shared installation settings for unified components
    BaseInstallation base = 1 [deprecated = true, (.wix.api.field_deprecated) = {
        replaced_by: "static_container"
        target_removal_date: "2026-02-26"
    }];
    // Deprecated, default_preset should be mapped to presets, region is not relevant. Widget installation settings for unified components
    WidgetInstallation widget = 2 [deprecated = true, (.wix.api.field_deprecated) = {
        replaced_by: "presets"
        target_removal_date: "2026-02-26"
    }];
    // Default presets per breakpoint with which the widget should be installed
    DefaultPresets presets = 3;
    oneof target_container {
        // Which static container should the widget be installed at
        StaticContainer static_container = 4;
    }
}

message WidgetInstallation {
    enum RegionType {
        HEADER = 0;
        BODY = 1;
        FOOTER = 2;
    }
    // Preset should be selected defaultly with installation
    MainPresets default_preset = 1;
    // Region of widget
    RegionType region = 2;
}
