1 line
9.8 KiB
JSON
1 line
9.8 KiB
JSON
{"metadata":{"modules":[{"name":"SlothCreator"}],"title":"Slothy: Integrating SlothCreator into an App","role":"sampleCode","roleHeading":"Sample Code","images":[{"identifier":"slothy-card.png","type":"card"}]},"abstract":[{"type":"text","text":"Integrate SlothCreator into an iOS app for creating and caring"},{"text":" ","type":"text"},{"type":"text","text":"for custom sloths."}],"primaryContentSections":[{"kind":"content","content":[{"level":2,"anchor":"Overview","text":"Overview","type":"heading"},{"type":"paragraph","inlineContent":[{"type":"text","text":"This sample creates "},{"inlineContent":[{"type":"text","text":"Slothy"}],"type":"emphasis"},{"type":"text","text":", an app for creating"},{"type":"text","text":" "},{"type":"text","text":"and caring for custom sloths."}]},{"identifier":"slothy-hero","type":"video"},{"type":"row","numberOfColumns":3,"columns":[{"content":[{"type":"paragraph","inlineContent":[{"text":"First, you customize your sloth by picking its","type":"text"},{"type":"text","text":" "},{"type":"reference","identifier":"doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator\/Sloth\/power-swift.property","isActive":true},{"text":".","type":"text"},{"text":" ","type":"text"},{"type":"text","text":"The power of your sloth influences its abilities and how well"},{"text":" ","type":"text"},{"type":"text","text":"they cope in their environment. The app displays a picker view"},{"type":"text","text":" "},{"text":"that showcases the available powers and previews your sloth","type":"text"},{"text":" ","type":"text"},{"text":"for the selected power.","type":"text"}]}],"size":2},{"size":1,"content":[{"type":"paragraph","inlineContent":[{"identifier":"slothy-powerPicker","type":"image"}]}]}]},{"numberOfColumns":3,"type":"row","columns":[{"content":[{"type":"paragraph","inlineContent":[{"identifier":"slothy-status","type":"image"}]}],"size":1},{"content":[{"inlineContent":[{"type":"text","text":"Once you’ve customized your sloth, it’s ready to"},{"text":" ","type":"text"},{"text":"ready to thrive. You’ll find that sloths will","type":"text"},{"type":"text","text":" "},{"text":"happily munch on a leaf, but may not be as","type":"text"},{"text":" ","type":"text"},{"text":"receptive to working out. Use the activity picker","type":"text"},{"type":"text","text":" "},{"type":"text","text":"to send some encouragement."}],"type":"paragraph"}],"size":2}]},{"text":"Localization","anchor":"Localization","level":3,"type":"heading"},{"inlineContent":[{"type":"text","text":"Slothy also showcases SlothCreator’s localized content."},{"type":"text","text":" "},{"type":"text","text":"The name of powers and food are presented in the device’s"},{"text":" ","type":"text"},{"type":"text","text":"current locale. Take a look at a few examples."}],"type":"paragraph"},{"type":"tabNavigator","tabs":[{"title":"English","content":[{"inlineContent":[{"type":"image","identifier":"slothy-localization_eng"}],"type":"paragraph"}]},{"title":"Chinese","content":[{"inlineContent":[{"type":"image","identifier":"slothy-localization_zh"}],"type":"paragraph"}]},{"title":"Spanish","content":[{"inlineContent":[{"type":"image","identifier":"slothy-localization_es"}],"type":"paragraph"}]}]}]}],"schemaVersion":{"patch":0,"major":0,"minor":3},"seeAlsoSections":[{"title":"Essentials","generated":true,"anchor":"Essentials","identifiers":["doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator\/GettingStarted","doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator\/Sloth"]}],"sampleCodeDownload":{"kind":"sampleDownload","action":{"overridingTitle":"View Source","isActive":true,"type":"reference","identifier":"https:\/\/example.com\/slothy-repository"}},"identifier":{"url":"doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator\/SlothySample","interfaceLanguage":"swift"},"variants":[{"traits":[{"interfaceLanguage":"swift"}],"paths":["\/documentation\/slothcreator\/slothysample"]}],"sections":[],"kind":"article","hierarchy":{"paths":[["doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator"]]},"references":{"slothy-localization_zh":{"type":"image","alt":"Two screenshots showing the Slothy app rendering with Chinese language content. The first screenshot shows a sloth map and the second screenshot shows a sloth power picker.","identifier":"slothy-localization_zh","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-localization_zh@2x.png","traits":["2x","light"]}]},"slothy-hero":{"poster":"slothy-hero-poster","type":"video","alt":"An animated video showing two screens in the Slothy app. The first screenshot shows a sloth map and the second screenshot shows a sloth power picker.","identifier":"slothy-hero","variants":[{"traits":["1x","light"],"url":"\/videos\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-hero.mp4"}]},"doc://slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator/documentation/SlothCreator/Sloth":{"title":"Sloth","navigatorTitle":[{"text":"Sloth","kind":"identifier"}],"type":"topic","url":"\/documentation\/slothcreator\/sloth","role":"symbol","kind":"symbol","identifier":"doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator\/Sloth","fragments":[{"text":"struct","kind":"keyword"},{"text":" ","kind":"text"},{"kind":"identifier","text":"Sloth"}],"abstract":[{"type":"text","text":"A model representing a sloth."}]},"slothy-powerPicker":{"type":"image","alt":"A screenshot of the power picker user interface with four powers displayed – ice, fire, wind, and lightning","identifier":"slothy-powerPicker","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-powerPicker@2x.png","traits":["2x","light"]}]},"slothy-card.png":{"type":"image","alt":null,"identifier":"slothy-card.png","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-card@2x.png","traits":["2x","light"]}]},"slothy-hero-poster":{"type":"image","alt":null,"identifier":"slothy-hero-poster","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-hero-poster.png","traits":["1x","light"]}]},"slothy-status":{"type":"image","alt":"A screenshot of the sloth status user interface that indicates the the amount of sleep, fun, and exercise a given sloth is in need of.","identifier":"slothy-status","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-status@2x.png","traits":["2x","light"]}]},"doc://slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator/documentation/SlothCreator":{"url":"\/documentation\/slothcreator","type":"topic","abstract":[{"text":"Catalog sloths you find in nature and create new adorable virtual sloths.","type":"text"}],"images":[{"identifier":"slothCreator-icon.png","type":"icon"}],"identifier":"doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator","title":"SlothCreator","role":"collection","kind":"symbol"},"slothy-localization_eng":{"alt":"Two screenshots showing the Slothy app rendering with English language content. The first screenshot shows a sloth map and the second screenshot shows a sloth power picker.","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-localization_eng@2x.png","traits":["2x","light"]}],"identifier":"slothy-localization_eng","type":"image"},"doc://slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator/documentation/SlothCreator/Sloth/power-swift.property":{"fragments":[{"text":"var","kind":"keyword"},{"kind":"text","text":" "},{"text":"power","kind":"identifier"},{"kind":"text","text":": "},{"text":"Power","kind":"typeIdentifier","preciseIdentifier":"s:12SlothCreator0A0V5PowerO"}],"type":"topic","kind":"symbol","title":"power","abstract":[{"text":"The power of the sloth.","type":"text"}],"identifier":"doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator\/Sloth\/power-swift.property","url":"\/documentation\/slothcreator\/sloth\/power-swift.property","role":"symbol"},"https://example.com/slothy-repository":{"checksum":null,"url":"https:\/\/example.com\/slothy-repository","type":"download","identifier":"https:\/\/example.com\/slothy-repository"},"doc://slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator/documentation/SlothCreator/GettingStarted":{"url":"\/documentation\/slothcreator\/gettingstarted","kind":"article","abstract":[{"type":"text","text":"Create a sloth and assign personality traits and abilities."}],"role":"article","images":[{"type":"card","identifier":"gettingStarted-card.png"}],"type":"topic","title":"Getting Started with Sloths","identifier":"doc:\/\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/documentation\/SlothCreator\/GettingStarted"},"slothCreator-icon.png":{"identifier":"slothCreator-icon.png","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothCreator-icon@2x.png","traits":["2x","light"]}],"type":"image","alt":"A technology icon representing the SlothCreator framework."},"gettingStarted-card.png":{"alt":"The profile images for a regular sloth and an ice sloth.","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/gettingStarted-card@2x.png","traits":["2x","light"]}],"identifier":"gettingStarted-card.png","type":"image"},"slothy-localization_es":{"identifier":"slothy-localization_es","variants":[{"url":"\/images\/slothcreatorbuildingdoccdocumentationinxcode-3.SlothCreator\/slothy-localization_es@2x.png","traits":["2x","light"]}],"type":"image","alt":"Two screenshots showing the Slothy app rendering with Spanish language content. The first screenshot shows a sloth map and the second screenshot shows a sloth power picker."}}} |