Add themeParameters.secondary_background_color.

This commit is contained in:
levlam 2022-06-20 16:15:09 +03:00
parent f00c568339
commit 71573fd320
3 changed files with 5 additions and 4 deletions

View File

@ -1478,10 +1478,10 @@ bankCardInfo title:string actions:vector<bankCardActionOpenUrl> = BankCardInfo;
address country_code:string state:string city:string street_line1:string street_line2:string postal_code:string = Address;
//@description Contains parameters of the application theme @background_color A color of the background in the RGB24 format @text_color A color of text in the RGB24 format
//@hint_color A color of hints in the RGB24 format @link_color A color of links in the RGB24 format @button_color A color of the buttons in the RGB24 format
//@description Contains parameters of the application theme @background_color A color of the background in the RGB24 format @secondary_background_color A secondary color for the background in the RGB24 format
//@text_color A color of text in the RGB24 format @hint_color A color of hints in the RGB24 format @link_color A color of links in the RGB24 format @button_color A color of the buttons in the RGB24 format
//@button_text_color A color of text on the buttons in the RGB24 format
themeParameters background_color:int32 text_color:int32 hint_color:int32 link_color:int32 button_color:int32 button_text_color:int32 = ThemeParameters;
themeParameters background_color:int32 secondary_background_color:int32 text_color:int32 hint_color:int32 link_color:int32 button_color:int32 button_text_color:int32 = ThemeParameters;
//@description Portion of the price of a product (e.g., "delivery cost", "tax amount") @label Label for this portion of the product price @amount Currency amount in the smallest units of the currency

View File

@ -270,6 +270,7 @@ string get_theme_parameters_json_string_impl(const td_api::object_ptr<td_api::th
return json_encode<string>(json_object([&theme](auto &o) {
auto get_color = &get_color_json<for_web_view>;
o("bg_color", get_color(theme->background_color_));
o("secondary_bg_color", get_color(theme->secondary_background_color_));
o("text_color", get_color(theme->text_color_));
o("hint_color", get_color(theme->hint_color_));
o("link_color", get_color(theme->link_color_));

View File

@ -1688,7 +1688,7 @@ class CliClient final : public Actor {
}
static td_api::object_ptr<td_api::themeParameters> get_theme_parameters() {
return td_api::make_object<td_api::themeParameters>(0, -1, 256, 65536, 123456789, 65535);
return td_api::make_object<td_api::themeParameters>(0, 1, -1, 256, 65536, 123456789, 65535);
}
static td_api::object_ptr<td_api::BackgroundFill> get_background_fill(int32 color) {