Download this file
| 1 | package main |
| 2 | |
| 3 | // The File menu's half of I13 (level-up build note 87): Import from |
| 4 | // Notion… is File's, for importers only, and never the account menu's. |
| 5 | const ( |
| 6 | frameFile = "internal/mapa/frame.go" |
| 7 | shellFile = "internal/mapa/shell.go" |
| 8 | ) |
| 9 | |
| 10 | var menuMutations = []mutation{ |
| 11 | {gate: "I13", name: "File offers Import to every member", |
| 12 | test: "TestI13", edits: []edit{{frameFile, |
| 13 | "menusFor(page, app.config.Importer(address))", |
| 14 | "menusFor(page, true)"}}}, |
| 15 | {gate: "I13", name: "the account menu offers Import again", |
| 16 | test: "TestI13", edits: []edit{{shellFile, |
| 17 | "if app.config.Directory != \"\" {", |
| 18 | "if app.config.Importer(address) {\n" + |
| 19 | "\t\taccount.Items = append(account.Items, menu.Item{" + |
| 20 | "Href: importPath, Label: \"Import from Notion\"})\n" + |
| 21 | "\t}\n\tif app.config.Directory != \"\" {"}}}, |
| 22 | } |
| 23 | |