| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687 |
- //
- // 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 = [
- "๐ญ", "๐ฌ", "๐ฏ",
- "๐", "๐", "๐", "๐", "๐", "๐", "๐",
- "๐", "๐", "๐", "๐", "๐", "๐", "๐ฅ",
- "๐ฝ", "๐ฟ", "๐", "๐ก", "๐ฆ", "๐ง", "๐", "๐ฅ ",
- "โ๏ธ",
- ]
- return fast
- }()
- private static let medium: [String] = {
- var medium = [
- "๐ฎ", "๐", "๐ณ", "๐ฒ", "๐ฑ", "๐",
- "๐", "๐ ", "๐ค", "๐ฅ",
- "๐ฅช", "๐ฅซ", "๐ฅ", "๐ฅก", "๐ข", "๐ฃ",
- "๐
", "๐ฅ", "๐ฅ", "๐ถ", "๐ฅ", "๐ฅ", "๐", "๐ฅฆ",
- "๐", "๐ฅฅ", "๐", "๐ฅ", "๐ฅ", "๐ฅจ", "๐ฅ", "๐", "๐",
- "๐ผ", "๐ฅ", "๐ฎ", "๐ฅง",
- "๐จ", "๐ฉ", "๐ช", "๐ฐ", "๐ซ",
- ]
- return medium
- }()
- private static let slow: [String] = {
- var slow = [
- "๐", "๐ฅ", "๐ฅ", "๐ฐ", "๐ง", "๐", "๐", "๐ฅ",
- "๐", "๐ญ", "๐ฏ", "๐", "๐ฅฉ"
- ]
- return slow
- }()
- private static let other: [String] = {
- var other = [
- "๐ถ", "๐พ", "๐ท", "๐ธ", "๐บ", "๐ป", "๐ฅ", "๐ฅ",
- "๐น", "๐ฅฃ", "๐ฅค", "๐ฅข", "๐ต",
- "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: "โฏ "
- )
- ]
- }
- }
|