How Do I Work with the Component Operation Panel?

267 views

 

Introducing the Component Operation Panel, designed for developers seeking efficiency in component management.This feature streamlines workflows, enabling users to Rename, Move, Delete and Add components seamlessly. Say goodbye to fragmented processes and hello to a more cohesive and intuitive component management experience.

 

1. Components Pane

  • Start exploring the available options for your components.
  • The Component Pane provides a gear icon, allowing you to access the Component Operations Panel.

Components Pane

2. Component Operations Panel

  • The Component Operations Panel is a centralized interface for managing and controlling various components within the application.
  • It provides essential tools for efficient oversight and interaction with the elements.

Component Operations Panel

3. Search Angular Component

  • Search for an Angular component effortlessly.
  • Utilize the search functionality to quickly find specific components within your project.

Search Angular Component

4. Search xpa Program

  • In the Component Operations Panel, you can easily search for XPA programs using the search bar.
  • This allows you to quickly locate specific programs and streamline your workflow.

Search xpa Program

5. Rename the Component using the Component Operations Panel

  • In Angular, a component acts as a vital building block that manages a distinct section of the user interface.
  • Each component consists of an HTML template, a TypeScript class, and optional styling.
  • In Magic xpa, the closest equivalent to an Angular component is a form or task, which combines a visual element with its corresponding logic.
  • SmartUX and xpa are closely intertwined; when you change a form name in xpa, the same component name must be updated accordingly.
  • To streamline this process and eliminate the need for manual adjustments, you can utilize this feature.

Rename Component using Component Operations Panel

6. Switch to xpa Studio

  • To begin, launch the Magic xpa Studio.Next, locate the program where you would like to modify the Form Name.
  • In this example, we will be updating the Form Name for the Welcome Program.

Switch to xpa Studio

7. Change the Form Name “MyWelcome”

  • What happens if a user renames the form to “MyWelcome” in XPA?
  • Since the Angular component is tied to the XPA form name, it is essential to update the component name and its corresponding file names accordingly.
  • Moreover, you must ensure that all relevant bindings in the component’s TypeScript files are modified to reflect this change.
  • To simplify this process and reduce manual effort, you can leverage the Component Operation Panel.
  • This feature is designed to automate many of these tasks, making it easier to manage changes efficiently.
  • Once you’ve made the necessary adjustments, save the changes to the XPA program and then switch to SmartUX Studio.

Change the Form Name 'MyWelcome'

8. Component Operation Panel

  • To begin, click the Refresh button.
  • You will notice that the Welcome component name is highlighted in red, indicating that its corresponding XPA program cannot be found.
  • In the XPA program, you will see that the Welcome component has been renamed to MyWelcome.
  • Next to the Welcome component, there is a button available for renaming it.

Component Operation Panel

9. Rename the Component to MyWelcome

  • Click the Rename button to open a pop-up window where you can update the component’s name.
  • Enter your desired name, ensuring it matches the Form Name provided in XPA for consistency.
  • Once you’ve made your changes, click the Save button to confirm.

Rename Component to MyWelcome

10. Confirmation dialog box

  • Confirm your save action to finalize your changes.

Confirmation dialog box

11. Save Changes

  • To complete the current task and proceed, simply click the ‘Done’ button in the Component Operations Panel.

Save Changes

12. Component “MyWelcome”

  • Take a moment to revisit the Components pane options.
  • You’ll notice that the Component name has been updated to MyWelcome, along with its associated files and TypeScript bindings.

Component 'MyWelcome'

13. Move the Angular Component using the Component Operation Panel

  • Easily Move Angular Components Using the Component Operation Panel.

Move Angular Component using Component Operation Panel

14. Folder Change in xpa Studio

  • What occurs when a user relocates an XPA program from one folder to another?
  • Given that the Angular component and Module are directly linked to the XPA program folder, it is crucial to update both the component Module and its associated file names accordingly.
  • Additionally, you must adjust all relevant bindings within the component’s TypeScript files to align with this change.
  • To streamline this process and minimize manual effort, you can utilize the Component Operation Panel.
  • This feature is specifically designed to automate many of these tasks, simplifying the management of changes and enhancing efficiency.

Folder Change in xpa Studio

15. Folder changed to “MyFolder”

  • You have successfully changed the folder from MainWC to MyFolder.
  • To streamline your workflow, switch to SmartUX Studio and take advantage of the Component Operations Panel, which helps you avoid manual adjustments.

Folder changed to 'MyFolder'

16. Component Operations Panel

  • To get started, click the Refresh button.
  • You’ll see that the MyWelcome component name is highlighted in red, signaling that its associated XPA program folder is missing.
  • Within the XPA program, you’ll notice that the MyWelcome component has been relocated to MyFolder.
  • Adjacent to the MyWelcome component, there’s a button that allows you to easily move the component from one folder to another.

Component Operations Panel

17. Select the folder

  • To update the component’s folder, click the ‘Move’ button.
  • This action will open a pop-up window where you can select a new folder.
  • Ensure that your chosen folder aligns with the selected folder in XPA for consistency.
  • After making your selections, don’t forget to click the ‘Save’ button to confirm your changes.

Select the folder

18. Confirmation dialog

  • Confirm your save action to ensure all updates are captured.

Confirmation dialog

19. Save Changes

  • After saving your changes, you’ll notice that the component has been relocated to ‘MyFolder’ within the Component Operations Panel under the Angular Component section.
  • Next, click the ‘Done’ button to confirm that all your actions have been saved and finalized.

Save Changes

20. Components Pane

  • Navigate back to the Components Pane.
  • Expand the modules, and you will notice that the MyWelcome component has been relocated to MyFolder.

Components Pane

21. Delete the Angular Component using the Component Operation Panel

  • Effortlessly Remove an Angular Component via the Component Operation Panel

Delete Angular Component using Component Operation Panel

22. Delete Angular Component

  • What should you do if you want to delete an Angular component?
  • In the past, removing an Angular component required you to manually delete all associated files and ensure that any bindings related to that component were fully removed to prevent potential errors.
  • Now, you can streamline this process! In the Component Operations Panel, simply locate the Delete button next to the Angular Component you wish to remove.

Delete Angular Component

23. Confirmation Dialog box

  • Confirm your action to proceed with component changes.

Confirmation Dialog box

24. Component Operation Panel

  • Upon completing the delete operation, you will find that the component and all its associated bindings have been successfully removed from the project.
  • Additionally, the deleted component will now appear in the XPA Programs section, highlighted in red, indicating that it is available for re-adding.

Component Operation Panel

25. Component Removed

  • The deleted Angular component has now been removed from the Component pane.

Component Removed

26. Add Angular Component using Component Operation Panel

  • Easily add a new Angular Component by utilizing the Component Operation Panel feature.

Add Angular Component using Component Operation Panel

27. Add Angular Component

  • What if a user wants to add a component?
  • To simplify this process and reduce manual effort, you can make use of the Component Operation Panel.
  • This panel allows users to seamlessly add a new component.
  • You will notice an ‘Add’ button located next to any XPA program that is not yet listed in the Angular component section.
  • For instance, if MyComponent is not currently displayed on your screen, it will feature the ‘Add’ button, indicating that you can easily include it.

Add Angular Component

28. Add Program screen

  • Clicking the ‘Add’ button will launch the ‘Add Program’ window for the Component Template.Here, you can either select your preferred component template or opt for a blank template.
  • Once you’ve made your selection, click the ‘Finish’ button to successfully add the component.

Add Program screen

29. Component Operation Panel

  • You can now find the newly added component in the Angular Component section.
  • To save your changes and exit the Panel, simply click the ‘Done’ button.

Component Operation Panel

30. Components Pane

  • You can find the newly added component in the Components pane, allowing you to proceed seamlessly with your design and development tasks.

Components Pane

By mastering the Component Operation Panel, users will enhance their productivity, gain better control over component organization, and enjoy a smoother workflow. This feature not only simplifies tasks but also empowers users to focus on creating innovative solutions without unnecessary distractions.

Share this Article

How Do I Work with the Component Operation Panel?

Or copy link

CONTENTS