| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199 |
- //
- // FoodEmojiDataSource.swift
- // LoopKit
- //
- // Copyright ยฉ 2017 LoopKit Authors. All rights reserved.
- //
- public func CarbAbsorptionInputController() -> EmojiInputController {
- return EmojiInputController.instance(withEmojis: FoodEmojiDataSource())
- }
- private class FoodEmojiDataSource: EmojiDataSource {
- private static let fast: [String] = {
- var fast = [
- "๐ญ", // lollipop
- "๐ง", // juice box
- "๐ฅค", // cup with straw (soda)
- "๐ฌ", // candy
- "๐ฏ", // honey pot
- "๐", // grapes
- "๐ซ", // blueberries
- "๐", // melon
- "๐", // watermelon
- "๐", // tangerine
- "๐", // lemon
- "๐", // banana
- "๐", // pineapple
- "๐", // red apple
- "๐", // green apple
- "๐", // pear
- "๐", // peach
- "๐", // cherries
- "๐", // strawberry
- "๐ฅ", // kiwi fruit
- "๐ฅญ", // mango
- "๐ฝ", // ear of corn
- "๐ฟ", // popcorn
- "๐", // rice cracker
- "๐ก", // dango
- "๐ฆ", // soft ice cream
- "๐ง", // shaved ice
- "๐", // birthday cake
- "๐ฅ ", // fortune cookie
- "โ๏ธ", // coffee
- "๐ซ" // tea
- ]
- return fast
- }()
- private static let medium: [String] = {
- var medium = [
- "๐ฎ", // taco
- "๐", // french fries
- "๐ณ", // cooking
- "๐ฒ", // pot of food
- "๐ฅ", // pan of food
- "๐ฑ", // bento box
- "๐", // curry rice
- "๐", // steaming bowl (ramen / noodle soup)
- "๐ ", // roasted sweet potato
- "๐ค", // fried shrimp
- "๐ฆช", // oyster
- "๐ฅ", // fish cake with swirl
- "๐ฅช", // sandwich
- "๐ฅ", // pita sandwich
- "๐ง", // falafel
- "๐ซ", // tamale
- "๐ฅซ", // canned food
- "๐ฅ", // dumpling
- "๐ฅก", // takeout box
- "๐ข", // oden
- "๐ฃ", // sushi
- "๐
", // tomato
- "๐ฅ", // potato
- "๐ฅ", // carrot
- "๐ถ", // hot pepper
- "๐ซ", // bell pepper
- "๐ง
", // onion
- "๐ง", // garlic
- "๐ฅ", // potato
- "๐ฅ", // cucumber
- "๐ฅ", // green salad
- "๐ฅฌ", // leafy green
- "๐", // mushroom
- "๐ฅฆ", // broccoli
- "๐", // eggplant
- "๐ซ", // beans
- "๐ฅฅ", // coconut
- "๐", // bread
- "๐ฅ", // croissant
- "๐ฅ", // baguette bread
- "๐ฅฏ", // bagel
- "๐ซ", // flat bread
- "๐ฅจ", // pretzel
- "๐ฅ", // pancakes
- "๐ง", // waffle
- "๐", // rice ball
- "๐", // cooked rice
- "๐ผ", // baby bottle
- "๐ฅ", // glass of milk
- "๐ฎ", // custard
- "๐ฅง", // pie
- "๐จ", // ice cream
- "๐ฉ", // doughnut
- "๐ช", // cookie
- "๐ง", // cupcake
- "๐ฅฎ", // moon cake
- "๐ฐ", // shortcake
- "๐ซ", // chocolate bar
- "๐ง", // bubble tea
- ]
- return medium
- }()
- private static let slow: [String] = {
- var slow = [
- "๐", // pizza
- "๐ฅ", // avocado
- "๐ฅ", // egg
- "๐ฅ", // peanuts
- "๐ฐ", // chestnut
- "๐ง", // cheese wedge
- "๐ซ", // fondue
- "๐", // meat on bone
- "๐", // poultry leg
- "๐ฅ", // bacon
- "๐", // hamburger
- "๐ญ", // hot dog
- "๐ฏ", // burrito
- "๐", // spaghetti
- "๐ฅฉ", // cut of meat
- "๐ง", // butter
- "๐ฆด", // bone
- ]
- return slow
- }()
- private static let other: [String] = {
- var other = [
- "๐ถ", // sake
- "๐พ", // bottle with popping cork
- "๐ท", // wine glass
- "๐ธ", // cocktail glass
- "๐บ", // beer mug
- "๐ป", // clinking beer mugs
- "๐ฅ", // clinking glasses
- "๐ฅ", // tumbler glass
- "๐น", // tropical drink
- "๐ง", // mate
- "๐ซ", // pouring liquid
- "๐ฅฃ", // bowl with spoon
- "๐ฅค", // cup with straw
- "๐ฅข", // chopsticks
- "๐ต", // teacup without handle
- "๐ด", // fork and knife
- "๐ฝ", // fork and knife with plate
- "๐ฅ", // spoon
- "๐ซ", // jar
- "๐ง", // ice cube
- "๐ง", // salt
- "1๏ธโฃ", "2๏ธโฃ", "3๏ธโฃ", "4๏ธโฃ", "5๏ธโฃ",
- "6๏ธโฃ", "7๏ธโฃ", "8๏ธโฃ", "9๏ธโฃ", "๐"
- ]
- return other
- }()
- let sections: [EmojiSection]
- init() {
- sections = [
- EmojiSection(
- title: LocalizedString("Fast", comment: "Section title for fast absorbing food"),
- items: type(of: self).fast,
- indexSymbol: " ๐ญ "
- ),
- EmojiSection(
- title: LocalizedString("Medium", comment: "Section title for medium absorbing food"),
- items: type(of: self).medium,
- indexSymbol: "๐ฎ"
- ),
- EmojiSection(
- title: LocalizedString("Slow", comment: "Section title for slow absorbing food"),
- items: type(of: self).slow,
- indexSymbol: "๐"
- ),
- EmojiSection(
- title: LocalizedString("Other", comment: "Section title for no-carb food"),
- items: type(of: self).other,
- indexSymbol: "โฏ "
- )
- ]
- }
- }
|