Added Colors and Images for Menu Buttons

Tags:

Starting from V6/V6Preview5, text color, background color, and background image for products (IProduct) and product groups (IProductGroup) have become available, allowing for a convenient colorful menu to be displayed on mobile terminals and websites, similar to the SyrveFront app.

In the Syrve Office application, for menu items (products and product groups), you can set the text color, background color, and background image. Coloring the menu helps users visually remember the location of items and find the desired positions faster. However, the information about colors was not published in the API, which forced plugins to display a monochrome menu. Now, color information has become available through the API.

The following properties and methods have been added:

The specific design for drawing buttons is not specified. If background images are not used, it’s simple — text color, background color. With images, there are nuances. Firstly, text may be hard to read against an arbitrary background image. You can separate the area with text and the image on the button, make the text background solid (which will cover part of the image), choose contrasting combinations, and so on. Secondly, the aspect ratio of the background image may not match the proportions of the menu buttons. You can scale, crop, or display with margins, at the discretion of the plugin author.