Search

CN-115840859-B - Navigation bar rendering method, device, equipment and medium

CN115840859BCN 115840859 BCN115840859 BCN 115840859BCN-115840859-B

Abstract

The embodiment of the disclosure provides a navigation bar rendering method, device, equipment and medium. The display parameter function of the navigation bar can be added in the target address information, so that after the target address information is acquired through the initiation page, the display parameter of the target address information is analyzed through the development component to obtain the display information, and then the navigation bar is rendered based on the display information through the development component, a configuration file is not required to be issued independently, the configuration file is not required to be updated, analyzed and the like, and the display parameter can be acquired directly from the target address information, so that the success rate of interface rendering can be improved.

Inventors

  • FANG JUN
  • MA JUN
  • LUO XIAOHUA

Assignees

  • 杭州网易再顾科技有限公司

Dates

Publication Date
20260505
Application Date
20221101

Claims (8)

  1. 1. A navigation bar rendering method, the method comprising: acquiring target address information through an initiating page, wherein the initiating page is used for providing an input function of the target address information, and the target address information comprises display parameters for indicating a display style of a navigation bar; analyzing the display parameters of the target address information through a native development component to obtain display information; Under the condition that the display information indicates that the original navigation bar is not hidden, rendering the navigation bar based on the display information through the original development component to obtain the original navigation bar; When the display information indicates to hide the native navigation bar, sending screen parameters and the display parameters to a webpage development component through the native development component, wherein the screen parameters are obtained from a system configuration file, and generating a return control through the native development component, wherein the return control is used for being displayed at a set position of the navigation bar; And rendering the native navigation bar based on the screen parameter and the display parameter through the webpage development component to obtain a rendered navigation bar.
  2. 2. The method of claim 1, wherein the rendering, by the web page development component, the native navigation bar based on the screen parameter and the display parameter, results in a rendered navigation bar, comprising: Analyzing the display parameters through the webpage development component to obtain the display information; Generating a space occupying block through the webpage development component under the condition that the display information indicates to hide a native navigation bar; Rendering the native navigation bar based on the screen parameters and the display information through the webpage development component to obtain a rendered navigation bar; and inserting the rendered navigation bar into the occupied block through the webpage development component.
  3. 3. The method of claim 1, wherein the Native development component is a Native component and the web page development component is an H5 component.
  4. 4. A navigation bar rendering device, the device comprising: The system comprises an acquisition module, a display module and a display module, wherein the acquisition module is used for acquiring target address information through an initiation page, the initiation page is used for providing an input function of the target address information, and the target address information comprises display parameters for indicating a display style of a navigation bar; The analysis module is used for analyzing the display parameters of the target address information through the original development component to obtain display information; A rendering module for: Under the condition that the display information indicates that the original navigation bar is not hidden, rendering the navigation bar based on the display information through the original development component to obtain the original navigation bar; when the display information indicates to hide the native navigation bar, sending screen parameters and the display parameters to a webpage development component through the native development component, wherein the screen parameters are obtained from a system configuration file; Rendering the native navigation bar based on the screen parameter and the display parameter through the webpage development component to obtain a rendered navigation bar; and the generation module is used for generating a return control through a native development component under the condition that the display information indicates to hide the native navigation bar, wherein the return control is used for being displayed at a set position of the navigation bar.
  5. 5. The apparatus of claim 4, wherein the rendering module, when configured to render, by the web page development component, the native navigation bar based on the screen parameter and the display parameter, to obtain a rendered navigation bar, is configured to: Analyzing the display parameters through the webpage development component to obtain the display information; Generating a space occupying block through the webpage development component under the condition that the display information indicates to hide a native navigation bar; Rendering the native navigation bar based on the screen parameters and the display information through the webpage development component to obtain a rendered navigation bar; and inserting the rendered navigation bar into the occupied block through the webpage development component.
  6. 6. The apparatus of claim 4, wherein the Native development component is a Native component and the web development component is an H5 component.
  7. 7. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the operations performed by the navigation bar rendering method of any one of claims 1 to 3 when the program is executed by the processor.
  8. 8. A computer-readable storage medium, having stored thereon a program that is executed by a processor to perform operations performed by the navigation bar rendering method of any one of claims 1 to 3.

Description

Navigation bar rendering method, device, equipment and medium Technical Field The embodiment of the disclosure relates to the technical field of page development, and more particularly relates to a navigation bar rendering method, device, equipment and medium. Background This section is intended to provide a background or context to the embodiments of the disclosure recited in the claims. The description herein is not admitted to be prior art by inclusion in this section. With the development of mobile terminal technology and the improvement of terminal equipment performance, interfaces in mobile terminal APP (Application) are increasingly diversified, and the frequency of occurrence of full screen interfaces is also increasingly high. In the related art, interface development is mainly realized through a Web (webpage) development technology, but the top of the interface developed by default through the Web development technology is provided with a Native navigation bar, and if full-screen interface development is to be realized, a configuration file capable of declaring the navigation bar style needs to be issued, so that the navigation bar of a corresponding style is rendered through a Native development technology. However, the links of issuing, updating, analyzing and the like of the configuration file may fail, so that the corresponding interface cannot be rendered correctly, and further the interface development cannot be completed smoothly. Disclosure of Invention In view of the problem that the corresponding interface cannot be rendered correctly due to failure in links such as issuing, updating and analyzing of the configuration file in the related art, the embodiments of the present disclosure at least provide a navigation bar rendering method, device, equipment and medium. In a first aspect of embodiments of the present disclosure, there is provided a navigation bar rendering method, the method including: Acquiring target address information through an initiating page, wherein the initiating page is used for providing an input function of the target address information, and the target address information comprises display parameters for indicating a display style of a navigation bar; analyzing display parameters of the target address information through a development component to obtain display information; The navigation bar is rendered based on the display information by the development component. In some embodiments, the development components include a native development component and a web page development component; rendering, by the development component, a navigation bar based on the display information, comprising: rendering the navigation bar based on the display information through the original development component to obtain an original navigation bar; Under the condition that the display information indicates to hide the native navigation bar, the native development component sends screen parameters and display parameters to the webpage development component, and the screen parameters are obtained from a system configuration file; and rendering the original navigation bar based on the screen parameters and the display parameters through the webpage development component to obtain a rendered navigation bar. In some embodiments, rendering, by a web page development component, the native navigation bar based on the screen parameters and the display parameters, resulting in a rendered navigation bar, comprising: Analyzing the display parameters through a webpage development component to obtain display information; Generating a space occupying block through a webpage development component under the condition that display information indicates hiding of the original navigation bar; Rendering the original navigation bar based on the screen parameters and the display information through a webpage development component to obtain a rendered navigation bar; and inserting the rendered navigation bar into the occupied block through the webpage development component. In some embodiments, the method further comprises: in the case where the display information indicates hiding of the native navigation bar, a return control is generated by the native development component for display at a set location of the navigation bar. In some embodiments, the parsing, by the development component, the display parameters of the target address information to obtain the display information includes: and analyzing the display parameters of the target address information through the original development component to obtain display information. In some embodiments, the target address information is a uniform resource locator, URL, the Native development component is a Native component, and the web page development component is an H5 component. In a second aspect of embodiments of the present disclosure, there is provided a navigation bar rendering apparatus, the apparatus including: The acquisition module is used for