{"action":"closed","issue":{"url":"https://api.github.com/repos/SpareBank1/designsystem/issues/115","repository_url":"https://api.github.com/repos/SpareBank1/designsystem","labels_url":"https://api.github.com/repos/SpareBank1/designsystem/issues/115/labels{/name}","comments_url":"https://api.github.com/repos/SpareBank1/designsystem/issues/115/comments","events_url":"https://api.github.com/repos/SpareBank1/designsystem/issues/115/events","html_url":"https://github.com/SpareBank1/designsystem/issues/115","id":307684085,"number":115,"title":"Inline javascript required to process less files","user":{"login":"oskaremil","id":1819584,"avatar_url":"https://avatars1.githubusercontent.com/u/1819584?v=4","gravatar_id":"","url":"https://api.github.com/users/oskaremil","html_url":"https://github.com/oskaremil","followers_url":"https://api.github.com/users/oskaremil/followers","following_url":"https://api.github.com/users/oskaremil/following{/other_user}","gists_url":"https://api.github.com/users/oskaremil/gists{/gist_id}","starred_url":"https://api.github.com/users/oskaremil/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oskaremil/subscriptions","organizations_url":"https://api.github.com/users/oskaremil/orgs","repos_url":"https://api.github.com/users/oskaremil/repos","events_url":"https://api.github.com/users/oskaremil/events{/privacy}","received_events_url":"https://api.github.com/users/oskaremil/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-03-22T15:06:50Z","updated_at":"2018-03-23T11:03:27Z","closed_at":"2018-03-23T11:03:27Z","author_association":"NONE","body":"There are two places where inline javascript is used in the less files:\r\n\r\n- packages\\ffe-form\\less\\dropdown.less:2:@bare-color: replace(~`'@{color}'`, '#', '');\r\n- packages\\ffe-searchable-dropdown-react\\less\\searchable-dropdown.less:2:  @bare-color: replace(~`\"@{color}\"`, \"#\", \"\");\r\n\r\nInline javascript makes it harder for angular-cli based projects to use all the components as the less-loader in webpack cannot be modified with options not provided by angular-cli.\r\n\r\nThe angular-cli team has already decided to not support more loader-options so I have to ask here if it is possible to rewrite these to classes to do the same without the use of inline javascript.\r\n\r\nTemporary workaround, instead of importing the entire ffe-form package with `@import '@sb1/ffe-form/less/form';`, import files one by one and skip dropdown:\r\n```\r\n/* Mixins */\r\n@import '@sb1/ffe-form/less/radioblob-mixin';\r\n\r\n/* Inputs*/\r\n@import '@sb1/ffe-form/less/input-field';\r\n@import '@sb1/ffe-form/less/textarea';\r\n@import '@sb1/ffe-form/less/checkbox';\r\n@import '@sb1/ffe-form/less/radio-input';\r\n@import '@sb1/ffe-form/less/radio-button';\r\n@import '@sb1/ffe-form/less/radio-switch';\r\n@import '@sb1/ffe-form/less/radio-block';\r\n@import '@sb1/ffe-form/less/file-upload';\r\n\r\n/* Form Layout */\r\n@import '@sb1/ffe-form/less/input-group';\r\n@import '@sb1/ffe-form/less/form-label';\r\n@import '@sb1/ffe-form/less/fieldset';\r\n@import '@sb1/ffe-form/less/tooltip';\r\n\r\n/* Validation */\r\n@import '@sb1/ffe-form/less/field-info-message';\r\n@import '@sb1/ffe-form/less/field-error-message';\r\n@import '@sb1/ffe-form/less/field-success-message';\r\n\r\nselect,\r\ntextarea,\r\ninput:not([type='radio']):not([type='checkbox']) {\r\n    appearance: none;\r\n}\r\n```"}}
{"actor":{"display_login":"oskaremil"}}