<%= pb_rails("contact", props: { contact_type: "cell", contact_value: "349-185-9988", }) %> <%= pb_rails("contact", props: { contact_value: 5555555555, }) %> <%= pb_rails("contact", props: { contact_type: "email", contact_value: "email@example.com", }) %> <%= pb_rails("contact", props: { contact_type: "wrong number", contact_value: "3245627482", }) %> <%= pb_rails("contact", props: { contact_type: "work-cell", contact_value: "349-185-9988", }) %>
<%= pb_rails("contact", props: { contact_type: "cell", contact_value: "349-185-9988", contact_detail: "Cell", }) %> <%= pb_rails("contact", props: { contact_value: 5555555555, contact_detail: "Home", }) %> <%= pb_rails("contact", props: { contact_type: "work", contact_value: "3245627482", contact_detail: "Work", }) %> <%= pb_rails("contact", props: { contact_type: "work-cell", contact_value: "3245627482", contact_detail: "Work-Cell", }) %> <%= pb_rails("contact", props: { contact_type: "extension", contact_value: "1233", contact_detail: "Ext", }) %>
<%= pb_rails("currency", props: { amount: "2,000.50", emphasized: false, label: "Emphasized False", margin_bottom: "md", size: "sm", }) %> <%= pb_rails("currency", props: { amount: "342", label: "Light", margin_bottom: "md", size: "sm", symbol: "€", variant: "light", }) %> <%= pb_rails("currency", props: { amount: "45", label: "Bold", size: "lg", unit: "/mo", variant: "bold", }) %>
<%= pb_rails("currency", props: { amount: "2,000.50", label: "Small", margin_bottom: "md", size: "sm", }) %> <%= pb_rails("currency", props: { amount: "342", label: "Medium", margin_bottom: "md", size: "md", symbol: "€", }) %> <%= pb_rails("currency", props: { amount: "45", label: "Large", size: "lg", unit: "/mo", }) %>
<%= pb_rails("currency", props: { amount: "2,000.50", label: "Left", size: "sm", }) %> <%= pb_rails("currency", props: { align: "center", amount: "342", label: "Center", size: "sm", symbol: "€", }) %> <%= pb_rails("currency", props: { align: "right", amount: "45", label: "Right", unit: "/mo", size: "sm", }) %>
<%= pb_rails("currency", props: { abbreviate: true, amount: "2,200.50", label: "Thousands (with Unit)", margin_bottom: "md", unit: "/mo", }) %> <%= pb_rails("currency", props: { abbreviate: true, amount: "3424123", label: "Millions", margin_bottom: "md", }) %> <%= pb_rails("currency", props: { abbreviate: true, amount: "45,300,000,000", label: "Billions", margin_bottom: "md", }) %> <%= pb_rails("currency", props: { abbreviate: true, amount: "983,200,000,000,000", label: "Trillions", }) %>
<%= pb_rails("currency", props: { amount: "372.12", decimals: "matching", label: "Small", margin_bottom: "md", size: "sm", unit: "/day", }) %> <%= pb_rails("currency", props: { amount: "30,327.43", decimals: "matching", label: "Medium", margin_bottom: "md", size: "md", symbol: "€", }) %> <%= pb_rails("currency", props: { amount: "621,953.99", decimals: "matching", label: "Large", size: "lg", }) %>
<%= pb_rails("dashboard_value", props: { stat_label: "Decreased Value", stat_value: { value: 1428, unit: "appts" }, stat_change: { change: "decrease", value: 26.1 } }) %> <br><br> <%= pb_rails("dashboard_value", props: { stat_label: "Increased Value", stat_value: { value: 938, unit: "homes" }, stat_change: { change: "increase", value: 56.1 } }) %> <br><br> <%= pb_rails("dashboard_value", props: { stat_label: "Neutral Value", stat_value: { value: 261, unit: "windows" }, stat_change: { value: 86 } }) %> <br><br> <%= pb_rails("dashboard_value", props: { stat_label: "Pitch Rate", stat_value: { value: 90.9, unit: "%" } }) %>
<%= pb_rails("dashboard_value", props: { stat_label: "Top Title Value", stat_value: {value: 1428, unit: "appts"}, stat_change: {change: "decrease", value: 26.1} }) %> <br><br> <%= pb_rails("dashboard_value", props: { align: "center", stat_label: "Top Title Value", stat_value: {value: 1428, unit: "appts"}, stat_change: {change: "decrease", value: 56 } }) %> <br><br> <%= pb_rails("dashboard_value", props: { align: "right", stat_label: "Top Title Value", stat_value: {value: 1428, unit: "appts"}, stat_change: {change: "decrease", value: 86.1 } }) %>
Use this kit on tables, card displays, or on modals. It's versatile for displaying in the most condensed areas.
Emphasis on street happens by default. (no prop needed)
Emphasis on "city" makes the city emphasized, rather than the street.
<%= pb_rails("home_address_street", props: { address: "70 Prospect Ave", address_cont: "Apt M18", city: "West Chester", home_id: 8250263, home_url: "https://powerhrg.com/", house_style: "Colonial", state: "PA", zipcode: "19382", territory: "PHL", }) %> <br> <br> <%= pb_rails("home_address_street", props: { address: "70 Prospect Ave", address_cont: "Apt M18", city: "West Chester", emphasis: "city", home_id: 8250263, home_url: "https://powerhrg.com/", house_style: "Colonial", state: "PA", zipcode: "19382", territory: "PHL", }) %>
Use the newWindow
/ new_window
prop to control whether the link opens on the same page or a new tab (same page is the default behavior)
Use this kit to display a label and a value with a certain status or color to highlight its significance or meaning. It can be a good design use to highlight the value incase it is important.
<%= pb_rails("label_pill", props: { label: "Service Needed", pill_value: "76", }) %> <%= pb_rails("label_pill", props: { label: "Waiting", pill_value: "69", variant: "success" }) %> <%= pb_rails("label_pill", props: { label: "In Service", pill_value: "28", variant: "error" }) %> <%= pb_rails("label_pill", props: { label: "Fully Serviced", pill_value: "101", variant: "warning" }) %> <%= pb_rails("label_pill", props: { label: "Inbox", pill_value: "197", variant: "info" }) %> <%= pb_rails("label_pill", props: { label: "Outbox", pill_value: "13", variant: "neutral" }) %> <%= pb_rails("label_pill", props: { label: "Inbox", pill_value: "218", variant: "primary" }) %>
Use this kit to display a label and value text for almost every data entry.
<%= pb_rails("label_value", props: { label: "Role", value: "Administrator, Moderator" }) %> <br> <%= pb_rails("label_value", props: { label: "Email", value: "anna.black@powerhrg.com" }) %> <br> <%= pb_rails("label_value", props: { label: "Bio", value: "Proin pulvinar feugiat massa in luctus. Donec urna nulla, elementum sit amet tincidunt nec, mattis nec urna. Cras viverra lorem odio, id pretium dui interdum ut. Nullam dignissim nisl vitae orci vehicula condimentum." }) %>
Variant details
can pass icon, description, title, date, and active props.
<%= pb_rails("label_value", props: { variant: "details", label: "Installer", icon: "truck", title: "JD Installations LLC", }) %> <br> <%= pb_rails("label_value", props: { variant: "details", label: "Project", icon: "home", description: "33-12345", title: "Jefferson-Smith", }) %> <br> <%= pb_rails("label_value", props: { variant: "details", label: "Project", icon: "home", description: "33-12345", title: "Jefferson-Smith", date: Date.new(2019, 11, 18) }) %> <br> <%= pb_rails("label_value", props: { variant: "details", active: true, label: "Project", icon: "home", description: "33-12345", title: "Jefferson-Smith", date: Date.new(2019, 11, 18) }) %>
<%= pb_rails("title", props: { text: "Patient Profile", tag: "h4", size: 4, margin_bottom: "sm" }) %> <%= pb_rails("flex") do %> <%= pb_rails("flex", props: {orientation: "column", margin_right: "lg" }) do %> <%= pb_rails("label_value", props: { variant: "details", label: "Age", icon: "user", title: "24 yrs old", padding_bottom: "sm" }) %> <%= pb_rails("label_value", props: { variant: "details", label: "Weight", icon: "weight", title: "91 kg", }) %> <% end %> <%= pb_rails("flex", props: {orientation: "column"}) do %> <%= pb_rails("label_value", props: { variant: "details", label: "Blood", icon: "tint", title: "A +", padding_bottom: "sm" }) %> <%= pb_rails("label_value", props: { variant: "details", label: "Height", icon: "arrows-v", title: "187 cm", }) %> <% end %> <% end %> <br><br><br> <%= pb_rails("title", props: { text: "Workout Schedule", tag: "h4", size: 4, margin_bottom: "sm" }) %> <%= pb_rails("label_value", props: { variant: "details", label: "Chest", icon: "dumbbell", description: "6 sets • 8 reps • 40-100 kg", title: "Bench Press", padding_bottom: "sm", active: true }) %> <%= pb_rails("label_value", props: { variant: "details", label: "Biceps", icon: "dumbbell", description: "5 sets • 12 reps • 20-40 kg", title: "Barbell Curl", padding_bottom: "sm", active: true }) %> <%= pb_rails("label_value", props: { variant: "details", label: "Back", icon: "dumbbell", description: "8 sets • 8 reps • 40-120 kg", title: "Back Squat", padding_bottom: "sm", active: true }) %>
Use this kit when displaying a message or a sort of communication with either a user or a bot. Use it in history displays, chat rooms, discussion threads or comments section.
<%= pb_rails("message", props: { label: "Anna Black", message: "How can we assist you today?", timestamp: "20 seconds ago", avatar_name: "Mike Bishop", avatar_url: "https://randomuser.me/api/portraits/men/50.jpg", avatar_status: "online" }) %> <br><br> <%= pb_rails("message", props: { label: "Patrick Welch", message: "We'll escalate this issue to a Senior Support agent.", timestamp: "9 minutes ago", avatar_name: "Wade Winningham", avatar_url: "https://randomuser.me/api/portraits/men/14.jpg", align_timestamp: "left" }) %> <br><br> <%= pb_rails("message", props: { label: "Lucille Sanchez", message: "Application for Kate Smith is waiting for your approval", timestamp: "4 hours ago", avatar_name: "Becca Jacobs", avatar_url: "https://randomuser.me/api/portraits/women/50.jpg" }) %> <br><br> <%= pb_rails("message", props: { label: "Beverly Reyes", message: "We're so sorry you had a bad experience!", timestamp: "2 days ago", avatar_name: "Tim Wenhold" }) %> <br><br> <%= pb_rails("message", props: { label: "Keith Craig", message: "Please hold for one moment, I'll check with my manager.", timestamp: "2 days ago" }) %> <br><br> <%= pb_rails("message", props: { label: "", message: "We're so sorry you had a bad experience!", timestamp: "2 days ago", avatar_name: "Tim Wenhold" }) %> <br><br> <%= pb_rails("message", props: { label: "", timestamp: "2 days ago", avatar_name: "Tim Wenhold" }) do %> <%= pb_rails("image", props: { alt: "picture of a misty forest", size: "xl", url: "https://unsplash.it/500/400/?image=634" }) %> <% end %> <br><br> <%= pb_rails("message", props: { label: "", message: "Please hold for one moment, I'll check with my manager.", timestamp: "2 days ago", avatar_name: "Tim Wenhold" }) do %> <%= pb_rails("image", props: { alt: "picture of a misty forest", size: "xl", url: "https://unsplash.it/500/400/?image=634" }) %> <% end %>
<%= pb_rails("message", props: { label: "Anna Black", message: "Hover over me to check out the real time I was made!", timestamp: "4 hours ago", timestamp_object: DateTime.current, avatar_name: "Lisa Thompson", avatar_url: "https://randomuser.me/api/portraits/women/39.jpg" }) %> <br><br> <%= pb_rails("message", props: { label: "Becca Jacobs", message: "Application for Kate Smith is waiting for your approval", timestamp: "12.20p", align_timestamp: "left", timestamp_object: DateTime.current, avatar_name: "Lisa Thompson", avatar_url: "https://randomuser.me/api/portraits/women/39.jpg" }) %>
<%= pb_rails("person_contact", props: { first_name: "Harvey", last_name: "Walters", contacts: [ { contact_type: "email", contact_value: "email@example.com" }, { contact_value: 5555555555, }, { contact_type: "work", contact_value: "3245627482" } ] }) %> <%= pb_rails("person_contact", props: { first_name: "Brenda", last_name: "Walters", contacts: [ { contact_value: 5555555555, } ] }) %>
<%= pb_rails("person_contact", props: { first_name: "Harvey", last_name: "Walters", contacts: [ { contact_type: "email", contact_value: "email@example.com" }, { contact_value: 5555555555, contact_detail: "Home" }, { contact_type: "work", contact_value: "3245627482", contact_detail: "Work" } ] }) %>
<%= pb_rails("person_contact", props: { first_name: "Pauline", last_name: "Smith", contacts: [ { contact_type: "email", contact_value: "email@example.com", }, { contact_value: 5555555555 }, { contact_type: "wrong-phone", contact_value: "3245627482", }, { contact_type: "phone", contact_value: "3048615385", }, ] }) %>
<%= pb_rails("source", props: { source: "BJ's Johnston-208", type: "retail" }) %> <br><br> <%= pb_rails("source", props: { source: "Referral-phrg", type: "inbound" }) %> <br><br> <%= pb_rails("source", props: { source: "BJ's Future CB", type: "user", user: { name: "Anna Black", image: { url: "https://randomuser.me/api/portraits/women/44.jpg" }, user_id: "48582" } }) %>
<%= pb_rails("source", props: { source: "BJ's Johnston-208", type: "retail", hide_icon: true }) %> <br><br> <%= pb_rails("source", props: { source: "Referral-phrg", type: "inbound", hide_icon: true }) %> <br><br> <%= pb_rails("source", props: { source: "BJ's Future CB", type: "user", user: { name: "Anna Black", image: {url: "https://randomuser.me/api/portraits/women/44.jpg"}, user_id: "48582" }, hide_icon: true }) %>
<%= pb_rails("source", props: { source: "BJ's Johnston-208", type: "retail" }) %> <br><br> <%= pb_rails("source", props: { source: "Referral-phrg", type: "inbound" }) %> <br><br> <%= pb_rails("source", props: { source: "B.B.B. Outbound", type: "outbound" }) %> <br><br> <%= pb_rails("source", props: { source: "Contractor.com", type: "prospecting" }) %> <br><br> <%= pb_rails("source", props: { source: "Beards, Beers and Brats", type: "events" }) %> <br><br> <%= pb_rails("source", props: { source: "BJ's Johnston-208", type: "referral" }) %> <br><br> <%= pb_rails("source", props: { source: "Employee Referral", type: "referral", user: { name: "Anna Black", image: {url: "https://randomuser.me/api/portraits/women/44.jpg"}, user_id: "48582" } }) %> <br><br> <%= pb_rails("source", props: { source: "BJ's Future CB", type: "user", user: { name: "Anna Black", image: {url: "https://randomuser.me/api/portraits/women/44.jpg"}, user_id: "48582" } }) %>
Increase colors your icon GREEN & Decrease colors your icon RED.
Use this to specify how many decimal places you want to show.
In react, you can pass in a string or number, but for this rails kit, we only accept numeric values and rails will not show trailing zero's unless specified.
Use this kit as a form of label value only for a numeric value.
<%= pb_rails("title_count", props: { title: "Remodeling Consultants", count: 527 }) %> <br> <%= pb_rails("title_count", props: { title: "Remodeling Consultants", count: 527, align: "center" }) %> <br> <%= pb_rails("title_count", props: { title: "Remodeling Consultants", count: 527, align: "right" }) %>
Use this kit in tables and cards to display data that doesn’t have a caption assigned.
<%= pb_rails("title_detail", props: { title: "Email Notifications", detail: "Commits data and history" }) %> <%= pb_rails("title_detail", props: { title: "Email Notifications", detail: "Commits data and history", align: "center" }) %> <%= pb_rails("title_detail", props: { title: "Email Notifications", detail: "Commits data and history", align: "right" }) %>