local M = {}

--[[ This comment is for LuaDoc.
---
-- Some mods for little things in other modules
-- for my personal convenience.
module('_M.mods')]]

events.connect(events.LEXER_LOADED, function(str)

	if type(snippets) == 'table' then
		-- Additions to Global snippets (works in any file)
		snippets['lorem'] = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.'
		---
		-- Additions to HTML-specific snippets.
		-- @class table
		-- @name _G.snippets.html
		snippets.html = {
			['a'] = '<a href="%1">%2</a>%0',
			['br'] = '<br/>%0',
			['code'] = '<code>%1</code>%0',
			['div'] = '<div>%1</div>%0',
			['form'] = '<form class="%1" action="%2(index.html)" method="%3(post)">\n\t%3\n</form>%0',
			['h1'] = '<h1>%1</h1>%0',
			['h2'] = '<h2>%1</h2>%0',
			['h3'] = '<h3>%1</h3>%0',
			['h4'] = '<h4>%1</h4>%0',
			['h5'] = '<h5>%1</h5>%0',
			['h6'] = '<h6>%1</h6>%0',
			['html'] = '<!DOCTYPE html>\n<html>\n\t<head>\n\t\t<meta charset="utf-8">\n\t\t<title>%1</title>\n\t</head>\n\t<body>\n\t\t%0\n\t</body>\n</html>',
			['img'] = '<img src="%1" />%0',
			['input'] = '<input type="%1(text)" name="%2" value="%3" />%0',
			['label'] = '<label>%1</label>%0',
			['li'] = '<li>%1</li>%0',
			['link'] = '<link rel="%1(stylesheet)" href="%2(/css/master.css)">%0',
			['loremp'] = '<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>%0',
			['ol'] = '<ol>%1</ol>%0',
			['p'] = '<p>%1</p>%0',
			['pre'] = '<pre>%1</pre>%0',
			['strong'] = '<strong>%1</strong>%0',
			['span'] = '<span>%1</span>%0',
			['script'] = '<script type="text/javascript">\n\t%1\n</script>%0',
			['scriptsrc'] = '<script src="%1" type="text/javascript"></script>%0',
			['table'] = '<table>\n\t%1\n</table>%0',
			['tbody'] = '<tbody>\n\t%1\n</tbody>%0',
			['td'] = '<td>%1</td>%0',
			['textarea'] = '<textarea name="%1(name)" rows="%2(8)" cols="%3(80)">%4</textarea>%0',
			['th'] = '<th>%1</th>%0',
			['tr'] = '<tr>%1</tr>%0',
			['ul'] = '<ul>%1</ul>%0',
		}
	end

end)


return M
