我有一些来自一个人的Bootply的代码,我已经将代码集成到了ember中,但它并没有像我想要的那样播放,也没有像主题播放的那样播放。ember中的滚动条位于右侧,而不是示例中的左侧div。
我有一个Brocfile.js文档:
/* global require, module */
var EmberApp = require('ember-cli/lib/broccoli/ember-app');
var app = new EmberApp();
// Use `app.import` to add additional libraries to the generated
// output files.
//
// If you need to use different assets in different
// environments, specify an object as the first parameter. That
// object's keys should be the environment name and the values
// should be the asset to use in that environment.
//
// If the library that you are including contains AMD or ES6
// modules that you would like to import into your application
// please specify an object with the list of modules as keys
// along with the exports of each module as its value.
app.import('vendor/css/bootstrap.min.css');
app.import('vendor/css/styles.css');
app.import('vendor/js/bootstrap.min.js');
app.import('vendor/js/scripts.js');
module.exports = app.toTree();
我有index.html:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>TestMap</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
{{content-for 'head'}}
<link rel="stylesheet" href="assets/vendor.css">
<link rel="stylesheet" href="assets/test-map.css">
{{content-for 'head-footer'}}
</head>
<body>
{{content-for 'body'}}
<script src="assets/vendor.js"></script>
<script src="assets/test-map.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.2/jquery.min.js"></script>
<script src="http://maps.googleapis.com/maps/api/js?sensor=false&extension=.js&output=embed"></script>
{{content-for 'body-footer'}}
</body>
</html>
对此有什么建议吗?我还会给你附上一些截图:
发布于 2015-09-30 16:08:58
Ember将您的应用程序包装在一个div
中。这里的问题是,如果不使用已弃用的Ember.View
,我们就无法将类添加到该div中。
目前,您可以通过使用body上的直接子选择器来修复此问题:
body > div {
width: 100%;
height: 100%;
overflow: hidden;
}
这将删除右侧的滚动条。
https://stackoverflow.com/questions/31392651
复制相似问题