Skip to content

Add widget rewrites + component migration #39

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 31 commits into from
Jul 23, 2024
Merged

Add widget rewrites + component migration #39

merged 31 commits into from
Jul 23, 2024

Conversation

PoojaB26
Copy link
Collaborator

Description

Provide a brief overview of what this documentation update is about. Explain what sections or topics are being added or revised.

Linear ticket and magic word Fixes DEVR-330

Type of change

  • Typo fix
  • New feature
  • Removed outdated references

Copy link

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@PoojaB26 PoojaB26 marked this pull request as ready for review June 12, 2024 13:31
@github-actions github-actions bot requested a review from pinkeshmars June 12, 2024 13:32
Copy link
Collaborator

@pinkeshmars pinkeshmars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @PoojaB26 currently I have reviewed widgets under the 'Built-in Components'. Majority are related to fixing links in all pages.

Will add more comments as I review the rest part of this PR :)

@@ -0,0 +1,2 @@

# Wrap
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing here?

@@ -0,0 +1,279 @@


# Badge
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be under the 'Built-in Widgets' section? Also, Barcode, Draggable, Expandable, and so on. I understand that these are not standard Flutter widgets (we might have used a package for these) but putting them under the 'Built-in Components' section might confuse users with the components available while creating a new component.
We can categorize 'Built-in Widgets' section just like we have now like 'Layout Widgets','Base Widgets'... wdyt?

8. Now, besides the **THEN**, click **Empty**. This will automatically select the **IF** widget in the widget tree. Inside that, add a widget that you want to display if this condition is true.
11. To add one more condition-based widget, click on the "+" button, add a condition for the **ELSE IF** section, and add a widget inside the **Else If** widget in the widget tree.
14. If none of the conditions are satisfied, add a default widget to display inside the **Else** widget.
17. Use the **Show In UI Builder** option to see that particular widget in the [canvas area](/getting-started/ui-builder/canvas-area). You can see only one widget at a time.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[canvas area] can be linked to existing canvas page.


To allow/disallows animating badge:

1. Select the **Badge** widget from the widget or the canvas area.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Extra empty line after each step


To add a Barcode widget to your app:

1. First, click on the **+ Add Widget**, drag the **Barcode** widget from the **Base Elements**
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like there is unusual space after each step.

5. To ensure that only a plant item is being dropped:

1. Select the **On Drag Accept** and select **+ Add Conditional Action**.
5. From the **set variable** menu, select **Drag Target > Dragged Data**. This captures the data of the draggable item that we added in [step 2](/widgets-and-components/widgets/base-elements/draggable-+-dragtarget#id-2.-add-draggable-widgets).
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. [step 2] link to the second step here.
  2. 'snackbar' message and 'update' link in step 4. We can just replace it with '#'

8. Now, select the **On Drag Exit** andadd an action to [update](/actions/actions/state-management/update-page-state) the `isShelfFull` variable to False. This ensures that if the user decides not to drop the item and moves it away, the shelf image reverts to the empty one.

<details>
<summary>On Drag Accept</summary>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can have this under the tab format like this:

import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem';

<Tabs><TabItem value="1" label="Apple" default>This is an apple 🍎</TabItem><TabItem value="2" label="Orange">This is an orange 🍊</TabItem></Tabs>

@@ -0,0 +1,33 @@


# Expandable
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems like it's WIP

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Components are not added to this PR completely, I did whatever I was able to do in the time span. But technically its part of another ticket. https://linear.app/flutterflow/issue/DEVR-403/built-in-components


To add a Markdown widget:

1. Open the [Widget Palette](/getting-started/ui-builder/navigation-menu/widget-and-component
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Widget Palette] link in step 1 and properties panel link in step 2


Here are the steps to build such an example:

2. First, ensure you have a Column widget on a page. if not, add it. Also, make the Column widget **scrollable** and **Primary**.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Steps number starting from '2'.

@PoojaB26
Copy link
Collaborator Author

Hey @PoojaB26 currently I have reviewed widgets under the 'Built-in Components'. Majority are related to fixing links in all pages.

Will add more comments as I review the rest part of this PR :)

For hyperlinks, we have to fix in the entire project because there are bunch of dead or empty links in most sections. We can resolve this as a separate task during the beta testing phase. So you can just review the content, and other stuff in this PR or upcoming PRs. @pinkeshmars

Copy link
Collaborator

@pinkeshmars pinkeshmars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @PoojaB26 I have added more comments. Could you please take a look?

- **Offset X & Offset Y:** These properties set the horizontal (X) and vertical (Y) displacement of
the shadow relative to the widget.

**Offset X** shifts the shadow horizontally, and **Offset Y**
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This para can be connected in its own point. (the last point i.e., Offset X & Offset Y:)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you mean? Like a header? Sorry didnt get you.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed it directly!

halfway point.
- The Transition Point for Color 3 is 1, which places the start of this color's transition at the
end of the gradient.
and choosing from Theme Colors, a color picker, or hex codes.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this picture explains it better.
Screenshot 2024-06-24 at 10 21 17 AM

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry didnt get you?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, I mean, in the 'Add Color:' point the later part of the description (i.e, after 'by adjusting their transition point...' is placed under the 'The Transition Point for Color 3 is 1...')

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you fix this directly please? I'm unable to understand :/

@@ -56,14 +56,14 @@ Some of the widgets that can handle multiple children include **Column, Row, Sta
GridView, and PageView**.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On this page check the 'Widget name' section. Correct the line 'the name appears as ' Container''. Extra space before Container in the quotes.

@pinkeshmars
Copy link
Collaborator

pinkeshmars commented Jun 24, 2024

@PoojaB26 Just FYI a few of them I directly committed. Please take latest :)

@PoojaB26
Copy link
Collaborator Author

@pinkeshmars Addressed comments, and left some notes. please check them soon!

@pinkeshmars
Copy link
Collaborator

Minor fixes have been pushed. @PoojaB26 this is good to merge now.

@PoojaB26 PoojaB26 merged commit de2b71e into main Jul 23, 2024
@PoojaB26 PoojaB26 deleted the pooja/widgets-3 branch July 23, 2024 06:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants