Tip calculator FEM weekend challenge in Power Apps learnings
Tip calculator app FEM challenge Active States

Tip calculator FEM weekend challenge in Power Apps learnings

I wrote a short article about drop shadow properties for containers yesterday when I started to Power Appin' this Frontend Mentor | Tip calculator app coding challenge

I finished my app today morning. My learning from this challenge in Power Apps are the following:

No alt text provided for this image
FocusBorderThickness in Advanced section

  • I focused on the FocusBorderThickness property which had a default 4 px width set by default, I have to consider to allocate that space evenly for your inputs, buttons in galleries, containers otherwise that border is trimmed. This layout has a 2px solid border for inputs.

No alt text provided for this image
Width of inputs to fit container width but remembering about border thickness

  • TextFormat.Number property limits your input to numbers and decimal separator point, commas as used for thousands. I am localized for Poland on my iOS where for decimal separator we use comma I had to adjust in Settings > General > Language & Region > Number Format so I could limit the Input Format property in Powers Apps to TextFormat.Number and use cents as well.

No alt text provided for this image
Number Format to select the . separtor for decimals
No alt text provided for this image
Decimal separator selected as dot to test the app on iOS


  • You don't have control over hint text color prosperity ##757575 is hardcoded

No alt text provided for this image
Hint text and Format properties on Text Input control


  • Resetting the Text Inputs where one of the input is inside a gallery requires to use a local variable set for those inputs Reset property. Actually it is more convenient and less low-coding needed than to list out all the inputs in the form and reset it one by one. I have to set it to true and set again to false so changes are reflected. To reset a gallery make sure you add {}, empty curly brackets to Default property of the gallery. This on OnSelect property of the Reset Button:

UpdateContext({locReset:true});UpdateContext({locReset:!locReset});Reset([@GalleryTip]);        

  • DisplayMode of Reset Button was also a nice challenge to set its mode to Disabled or Edit based on the empty values of inputs. However the custom input is in a gallery, and my input by default has a 0 value so if no custom value is provided you just simple does not want give a tip I could add another Or condition (GalleryTip.Selected.Value=0 And IsBlank(TextInputCustom)) but to keep it simple my validation to activate the Reset Button looks like this.

If(IsBlank(TextInputBill) Or IsBlank(GalleryTip.Selected) Or IsBlank(TextInputPeople),DisplayMode.Disabled,DisplayMode.Edit)        

Selected Values on gallery. This one was a nice challenge due to different columns and rows on desktop vs. mobile layout. If you know that Vertical Gallery wraps horizontally into columns but Horizontal Gallery wraps vertically into rows you are set. Items order is essential to understand for those controls. How to identify which blank gallery was used?

  1. Turn on the navigation and/or scrollbars and add some Template padding to check which way navigate/scroll.

No alt text provided for this image
Horizontal Gallery vs. Vertical Gallery


  1. Set wrap count back to 1 and see items stacked from top to bottom or left to right.

No alt text provided for this image
Difference of wrap on Vertical vs Horziontal Gallery in Power Apps

You can achieve the same result both way just on horizontal one you must adjust the order of the Items based on wrap count and the X positioning of your items in the gallery will different X and the Template size property.

I think the vertical wrap is easier in this case since Tip% values do not require adjustment. I read from left to right not from top to bottom. If you go with the horizontal way another If condition will be required for Gallery's Items property:

If(App.ActiveScreen.Size>2, [5,25,10,50,15,0], [5,15,50,10,25,0])        
No alt text provided for this image
Box-shadow ??????

  • I could add a simple but native Power Apps property drop shadow on the container, more about this new feature here.

No alt text provided for this image
Hover effect on Desktop version
No alt text provided for this image
No hover effects on mobile ;)

This was a fun challenge.

I was thinking about how to take this simple app into the next level.

My ideas:

  1. Use a form recognizer to get the scanned bill Total value and check if Tip is already included.
  2. Detect your location and based on Country preselect default Tip %

Tipping Around the World: A Global Guide | Western Union

Thanks for scrolling this far. Happy Power Apping.

要查看或添加评论,请登录

Krzysztof Borkowski的更多文章

  • Uploading Files to Canvas Power Apps from Different Folders with Non-Unique Names

    Uploading Files to Canvas Power Apps from Different Folders with Non-Unique Names

    TLDR: In this article, I will try to explain how do I upload files as media to Canvas Power Apps when these files are…

  • Centering (flex) containers in Power Apps

    Centering (flex) containers in Power Apps

    Hi everyone, Happy April's 1st. I also fooled myself with trying to vertically center align a container.

    4 条评论
  • SetFocus() to the rescue ??♂?

    SetFocus() to the rescue ??♂?

    How I used SetFocus() to improve the user experience of my Power Apps project Hi ?? everyone, I hope you are having or…

    13 条评论
  • FEM Job listing with filtering got PowerApp'ed

    FEM Job listing with filtering got PowerApp'ed

    This Sunday low-code project was challenging for different reasons. Here it is Frontend Mentor | Job listings with…

  • This weekend was about WeatherAPI

    This weekend was about WeatherAPI

    Kristine just dropped a Free Power Apps design masterclass on Youtube last Friday evening. So I decided to let's build…

    2 条评论
  • Where in the world FEM challenge got Power App'ed

    Where in the world FEM challenge got Power App'ed

    This weekend challenge was pretty massive and indeed a bit more time consuming than I previously estimated for it…

    5 条评论
  • Time tracking dashboard Power App'ed

    Time tracking dashboard Power App'ed

    Saturday afternoon challenged myself to build this Frontend Mentor | Time tracking dashboard coding challenge with…

  • Friday evening fun with Power Apps basic animation capabilities

    Friday evening fun with Power Apps basic animation capabilities

    This Friday evening I took this Frontend Mentor | Fylo data storage component coding challenge, low-coded and added…

  • FEM Four Cards Challenge Power App'ed

    FEM Four Cards Challenge Power App'ed

    Frontend Mentor | Four card feature section coding challenge As a Saturday relaxation I was trying to wrap my head…

  • FAQ accordion card in PowerApps

    FAQ accordion card in PowerApps

    Quick tutorial how to create a simple accordion card with flexible height gallery in Power Apps. Layout, text, colors…

社区洞察

其他会员也浏览了