Chrysolites Tech Academy

Photo Social App with FlutterFlow and Supabase · Course book

Chapter 7: Creating a Post

Pairs with Lesson 7: Designing the Create Post Pages

Creating a post is the moment a viewer becomes a contributor, so the flow must be quick and obvious: choose or take a photo, see it as it will appear, add a caption and share. This chapter designs that flow in FlutterFlow: an add-post page that previews the selected image with a gallery strip beneath it, a bottom section for switching between gallery and camera, a camera screen, and a details page for the caption. Along the way it sets out several principles of good interface design, including visual hierarchy, contrast and the size of touch targets, with Fitts's law worked out by hand, and it calculates how a camera photo is cropped to the feed's shape.

The add-post page

The add-post page follows a pattern people already know from photo apps. An app bar has a close button on the left, the title "New post" in the middle and a "Next" action on the right. Below it, the selected image fills the width of the screen, shown in the shape it will have in the feed. Below that, a grid of recent photos from the device's gallery lets the user pick a different one with a single tap. The design makes the photo the hero of the page and keeps every control at the edges, out of its way.

In this design phase, the preview and gallery use placeholder images; later parts connect the image picker and upload. The structure, a column holding the preview and an Expanded grid, ensures the gallery fills whatever height remains on any phone, and scrolls if there are many photos.

Several details make the page feel professional. The selected photo in the gallery strip should be marked, for example with a border or a dimmed overlay and a tick, so the user can see which one is in the preview. A small button on the preview can switch between showing the whole photo and cropping it to the feed's shape. Some apps allow selecting several photos for a multi-image post, shown with numbered circles in the order chosen; even if this app supports only one image per post, designing the selection so that it could grow later avoids a redesign. Finally, the "Next" action should be disabled until a photo has been chosen, so the user cannot reach the details page with nothing to post.

Access to the gallery requires permission from the user, and on recent phones people can choose to share only selected photos. The page should explain why access is needed the first time, handle a refusal gracefully, with a button to open the system settings, and still offer the camera as an alternative.

The bottom section and the camera screen

At the bottom of the add-post page, a small bottom section switches between sources: "Library" to choose an existing photo and "Photo" to take a new one. It can be built as a row of two text buttons with the selected one in bold, or as a segmented control, a rounded bar with the selected segment highlighted. Switching to "Photo" opens the camera screen.

The camera screen shows a full-screen preview with a large circular shutter button centred near the bottom, a button to flip between front and back cameras on one side, a flash toggle at the top and a close button. Each control sits over the preview in a corner or along the bottom edge, over a subtle dark gradient so that white icons stay visible against bright scenes. FlutterFlow provides camera widgets and actions; on the web, camera behaviour differs, so testing on a phone is essential. The camera also needs its own permission, separate from the gallery's, with a clear explanation of why it is requested.

Camera sensors usually capture images in a 4:3 shape, while the feed uses 4:5 portraits, so a photo must be cropped to match.

Worked example. A phone takes a portrait photo of 3,024 × 4,032 pixels, a 3:4 shape. To crop it to 4:5 while keeping the full width, the height becomes 3,024 × 5 / 4 = 3,780 pixels, so 4,032 − 3,780 = 252 pixels are removed, 126 from the top and 126 from the bottom to keep the subject centred. The cropped image has 3,024 × 3,780 = 11.4 million pixels, compared with 12.2 million before. Showing the user this crop in the preview, rather than surprising them afterwards, avoids heads and feet being cut off unexpectedly.

The post details page

After choosing a photo and tapping "Next", the user reaches the details page. A row at the top shows a small thumbnail of the photo beside a multi-line caption field with the hint "Write a caption". Below it, a list of optional settings follows, each as a row with an icon, a label and a chevron: add a location, tag people, and so on. A prominent "Share" button completes the flow, at the bottom of the page or in the app bar.

Keeping the caption field near the top matters because the keyboard will cover the lower part of the screen while typing. The share button should show a loading state while the post uploads and only then return the user to the feed, where their new post appears at the top.

Leaving the flow part-way needs thought too. If someone has chosen a photo and written half a caption, then taps the close button, the app should ask whether to discard the post, or offer to keep it as a draft. Going back from the details page to the add-post page should keep the caption already typed, so that choosing a slightly different photo does not cost the user their words. These behaviours are easy to forget in design and frustrating when missing, so they are worth noting on the page designs now, even though they are implemented later with page state and app state.

PageMain contentPrimary actionSecondary actions
Add postLarge preview and gallery gridNextClose; switch to camera
CameraFull-screen previewShutterFlip camera, flash, close
Post detailsThumbnail and caption fieldShareLocation, tags, back

Principles of good interface design

A few principles explain why these pages look the way they do, and they apply to every page in the app.

  • Visual hierarchy: the most important element on each page is the biggest, boldest or most colourful. On the add-post page that is the photo; on the details page, the caption field and the share button.
  • One primary action per page: a single, clearly styled main button, with secondary actions quieter, so users never wonder what to do next.
  • Contrast: text and icons must stand out from their background, aiming for a contrast ratio of at least 4.5 to 1 for normal text, the guideline used in web accessibility standards.
  • Consistency: the same icons, colours and spacing mean the same things everywhere, so users learn the app once.
  • Feedback: every tap produces a visible response, from a pressed state on a button to a loading indicator during uploads.

Touch target size is one principle that can be measured. Fitts's law models how long it takes to reach a target: the time grows with an index of difficulty, ID = log2(D / W + 1), where D is the distance to the target and W is its width. Larger or closer targets are faster to hit.

Worked example. A thumb moves 300 points to reach a button. If the button is 16 points wide, ID = log2(300 / 16 + 1) = log2(19.75) = 4.30 bits. At 44 points, the size recommended for touch targets on iOS, ID = log2(300 / 44 + 1) = log2(7.82) = 2.97 bits. At 80 points, ID = log2(4.75) = 2.25 bits. Going from 16 to 44 points removes 1.33 bits of difficulty, while going from 44 to 80 removes only 0.72 more: large gains come first, which is why a minimum size of around 44 points matters most.
4.302.97 at 44 pt2.252.00 024 164480100 target width (points), distance 300index of difficulty (bits)
Figure 7.1 — Fitts's index of difficulty falls steeply as tiny targets grow, then levels off. Reaching about 44 points captures most of the benefit.

The practical lessons are to make frequently used buttons large, to place them where thumbs rest, which on a phone is the lower half of the screen, and to separate destructive actions, such as delete, from common ones, so they are not hit by accident. These pages are the last of the interface design; the next parts create the Supabase tables and storage buckets, then bring every page to life with real data.

Practice tasks

  1. Crop a 3,000 × 4,000 photo to 4:5, keeping its width. How many pixels are removed from the top and from the bottom?
  2. Compute Fitts's index of difficulty for a 32-point button 400 points away, and for a 64-point button the same distance away.
  3. Identify the primary action and two secondary actions on the camera screen.
  4. Why should the caption field sit near the top of the details page?
  5. List three ways the add-post flow gives the user feedback.
  6. Explain the principle of visual hierarchy using the add-post page as an example.

Install Chrysolites Tech Academy

Android / Chrome / Edge: open the browser menu and choose Install app or Add to Home screen.

iPhone / iPad (Safari): tap the Share button, then Add to Home Screen.